add db to repo
This commit is contained in:
parent
f2fc2362a7
commit
9b3973805e
7 changed files with 97 additions and 55 deletions
|
@ -127,7 +127,7 @@
|
|||
{% endif %}
|
||||
</div>
|
||||
{% else %}
|
||||
<form method="post" enctype="multipart/form-data">
|
||||
<form method="post" enctype="multipart/form-data" id="installation-report-form">
|
||||
{% csrf_token %}
|
||||
<div class="mb-3">
|
||||
<div class="">
|
||||
|
@ -285,7 +285,7 @@
|
|||
<span></span>
|
||||
{% endif %}
|
||||
<div class="d-flex gap-2">
|
||||
<button type="submit" class="btn btn-primary">ثبت گزارش</button>
|
||||
<button type="submit" class="btn btn-primary" form="installation-report-form">ثبت گزارش</button>
|
||||
{% if next_step %}
|
||||
<a href="{% url 'processes:step_detail' instance.id next_step.id %}" class="btn btn-success">بعدی</a>
|
||||
{% endif %}
|
||||
|
|
|
@ -62,7 +62,7 @@ def installation_report_step(request, instance_id, step_id):
|
|||
assignment = InstallationAssignment.objects.filter(process_instance=instance).first()
|
||||
existing_report = InstallationReport.objects.filter(assignment=assignment).order_by('-created').first()
|
||||
edit_mode = True if request.GET.get('edit') == '1' else False
|
||||
|
||||
print("edit_mode", edit_mode)
|
||||
# current quote items baseline
|
||||
quote = Quote.objects.filter(process_instance=instance).first()
|
||||
quote_items = list(quote.items.select_related('item').all()) if quote else []
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue