2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-18 04:55:44 +00:00

Generic AjaxCreateView

- Allows for same form to be posted
This commit is contained in:
Oliver
2018-04-25 14:10:56 +10:00
parent 8bc4050d05
commit d88da28871
6 changed files with 98 additions and 59 deletions

View File

@ -1,10 +1,10 @@
<form method="post" action='/part/category/new/' class='js-modal-form'>
<form method="post" action='{{ form_action }}' class='js-modal-form'>
{% csrf_token %}
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
<h4 class="modal-title">Form Title Here</h4>
<h4 class="modal-title">{{ form_title }}</h4>
</div>
<div class="modal-body">
{% load crispy_forms_tags %}
@ -12,6 +12,6 @@
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
<button type="submit" class="btn btn-primary">Submit</button>
<button type="submit" class="btn btn-primary">{{ submit_text }}</button>
</div>
</form>