parent
91414a8151
commit
9b5d238e28
10 changed files with 90 additions and 130 deletions
@ -1,12 +1,39 @@ |
||||
{% extends 'partials/base.html' %} |
||||
|
||||
{% block content %} |
||||
<form action="{% url 'projects:edit' pk=proj.pk %}" method="POST"> |
||||
{% csrf_token %} |
||||
|
||||
{{ form }} |
||||
|
||||
<input type="hidden" name="next" value="{% url 'projects:detail' pk=proj.pk %}"> |
||||
<button type="submit">Сохранить</button> |
||||
</form> |
||||
{% endblock %} |
||||
{% load staticfiles %} |
||||
|
||||
<!doctype html> |
||||
<html> |
||||
<head> |
||||
<meta charset='utf-8'> |
||||
<meta http-equiv='X-UA-Compatible' content='IE=edge, chrome=1'> |
||||
<meta name='viewport' content='width=device-width, initial-scale=1'> |
||||
<!--<meta name='viewport' content='initial-scale=1.0, user-scalable=no, maximum-scale=1'>--> |
||||
|
||||
<title>Archilance</title> |
||||
|
||||
<link rel='stylesheet' href='{% static "css/bootstrap.css" %}'> |
||||
|
||||
<link rel='stylesheet' href='{% static "css/dev-colors.css" %}'> <!-- Dev-time only, temporary!!! --> |
||||
</head> |
||||
|
||||
<body> |
||||
{% if messages %} |
||||
{% for message in messages %} |
||||
<div class="c" style='padding: 10px; margin-bottom: 6px'>{{ message | safe }}</div> |
||||
{% endfor %} |
||||
{% endif %} |
||||
|
||||
<h1>"pk": {{ pk }}</h1> |
||||
|
||||
<form action="{% url 'projects:edit' pk=pk %}" method="POST"> |
||||
{% csrf_token %} |
||||
|
||||
{{ form.as_p }} |
||||
|
||||
<input type="hidden" name="next" value="{% url 'projects:detail' pk=pk %}"> |
||||
<button type="submit">Сохранить</button> |
||||
</form> |
||||
|
||||
<script src='{% static "js/jquery-2.2.3.min.js" %}'></script> |
||||
<script src='{% static "js/bootstrap.min.js" %}'></script> |
||||
</body> |
||||
</html> |
||||
|
||||
@ -1,7 +0,0 @@ |
||||
<h1>Test page</h1> |
||||
<form action="" method="post">{% csrf_token %} |
||||
{{ form.as_p }} |
||||
{{ realty_form.errors}} |
||||
{{ realty_form.as_p }} |
||||
<input type="submit" value="Send message" /> |
||||
</form> |
||||
@ -1,8 +0,0 @@ |
||||
<h1>Test form</h1> |
||||
<form action="" method="post">{% csrf_token %} |
||||
{{ form.errors }} |
||||
{{ form.as_p }} |
||||
{{ second_form.errors }} |
||||
{{ second_form.as_p }} |
||||
<input type="submit" value="Send message" /> |
||||
</form> |
||||
Loading…
Reference in new issue