kernel
This commit is contained in:
14
views/main_layout.html.twig
Normal file
14
views/main_layout.html.twig
Normal file
@ -0,0 +1,14 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="ru-RU">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Примеры шаблонизатора Twig</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>HEADER</h1>
|
||||
{% block content %}
|
||||
{% endblock %}
|
||||
<h1>FOOTER</h1>
|
||||
|
||||
</body>
|
||||
</html>
|
13
views/question_create.html.twig
Normal file
13
views/question_create.html.twig
Normal file
@ -0,0 +1,13 @@
|
||||
{% extends "main_layout.html.twig" %}
|
||||
|
||||
{% block content %}
|
||||
<form action="/admin/question" method="post">
|
||||
Вопрос: <br>
|
||||
<label>
|
||||
<textarea name = "question" rows="10" cols="50" placeholder="Введите здесь ваш вопрос"></textarea>
|
||||
</label> <br> <br>
|
||||
|
||||
<input type = "submit" value="Подтвердить">
|
||||
<input type="reset">
|
||||
</form>
|
||||
{% endblock %}
|
23
views/user_create.html.twig
Normal file
23
views/user_create.html.twig
Normal file
@ -0,0 +1,23 @@
|
||||
{% extends "mainLayout.html" %}
|
||||
|
||||
{% block content %}
|
||||
<form action="/admin/user/" method="post">
|
||||
Логин:<br>
|
||||
<label>
|
||||
<input type = "text" name = "username" required size="50" autofocus placeholder="Логин">
|
||||
</label> <br> <br>
|
||||
|
||||
Пароль:<br>
|
||||
<label>
|
||||
<input type = "text" name = "password_hash" required size="50" placeholder="Пароль">
|
||||
</label> <br> <br>
|
||||
|
||||
Email адрес: <br>
|
||||
<label>
|
||||
<input type="Email" name="email" required placeholder="Email">
|
||||
</label> <br><br>
|
||||
|
||||
<input type = "submit" value="Подтвердить">
|
||||
<input type="reset">
|
||||
</form>
|
||||
{% endblock %}
|
26
views/user_table.html.twig
Normal file
26
views/user_table.html.twig
Normal file
@ -0,0 +1,26 @@
|
||||
{% extends "mainLayout.html" %}
|
||||
|
||||
{% block content %}
|
||||
<table border="1" style="width: 80%;">
|
||||
<thead>
|
||||
<tr>
|
||||
<td>id</td>
|
||||
<td>Username</td>
|
||||
<td>Email</td>
|
||||
<td>Created at</td>
|
||||
<td>Updated at</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for users in userArr %}
|
||||
<tr>
|
||||
<td>{{ users.id }}</td>
|
||||
<td>{{ users.username }}</td>
|
||||
<td>{{ users.email }}</td>
|
||||
<td>{{ users.created_at }}</td>
|
||||
<td>{{ users.updated_at }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% endblock %}
|
28
views/user_update.html.twig
Normal file
28
views/user_update.html.twig
Normal file
@ -0,0 +1,28 @@
|
||||
{% extends "mainLayout.html" %}
|
||||
|
||||
{% block content %}
|
||||
<form action="/admin/user/edit" method="post">
|
||||
id пользователя:<br>
|
||||
<label>
|
||||
<input type = "text" name = "id" required size="50" autofocus placeholder="id">
|
||||
</label> <br> <br>
|
||||
|
||||
Логин:<br>
|
||||
<label>
|
||||
<input type = "text" name = "username" required size="50" autofocus placeholder="Логин">
|
||||
</label> <br> <br>
|
||||
|
||||
Пароль:<br>
|
||||
<label>
|
||||
<input type = "text" name = "password_hash" required size="50" placeholder="Пароль">
|
||||
</label> <br> <br>
|
||||
|
||||
Email адрес: <br>
|
||||
<label>
|
||||
<input type="Email" name="email" required>
|
||||
</label> <br><br>
|
||||
|
||||
<input type = "submit" value="Подтвердить">
|
||||
<input type="reset">
|
||||
</form>
|
||||
{% endblock %}
|
Reference in New Issue
Block a user