summaryrefslogtreecommitdiff
path: root/ishtar_common/templates
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2019-09-13 12:28:23 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2019-09-13 12:28:23 +0200
commit2e608dde86b1de6fa5b66ebbbcd8c1b719981b45 (patch)
treebd15fd64ca8040b4a1c5933bd332d9f593a8e1f5 /ishtar_common/templates
parent126f599442b9b18f1a540a0e422aa3ea24596317 (diff)
downloadIshtar-2e608dde86b1de6fa5b66ebbbcd8c1b719981b45.tar.bz2
Ishtar-2e608dde86b1de6fa5b66ebbbcd8c1b719981b45.zip
Fix organization form - fix quick add with delayed cached_label
Diffstat (limited to 'ishtar_common/templates')
-rw-r--r--ishtar_common/templates/ishtar/forms/qa_new_item.html8
1 files changed, 4 insertions, 4 deletions
diff --git a/ishtar_common/templates/ishtar/forms/qa_new_item.html b/ishtar_common/templates/ishtar/forms/qa_new_item.html
index 78162d759..ae57adfc2 100644
--- a/ishtar_common/templates/ishtar/forms/qa_new_item.html
+++ b/ishtar_common/templates/ishtar/forms/qa_new_item.html
@@ -2,15 +2,15 @@
{% load i18n inline_formset table_form %}
{% block main_form %}
-{% if new_item_label %}
-<p>{{new_item_label}} {% trans "created." %}</p>
+{% if new_item_pk %}
+<p>{% if new_item_label %}{{new_item_label}}{% else %}{% trans "Item" %}{% endif %} {% trans "created." %}</p>
{% else %}
{% bs_compact_form form %}
{% endif %}
{% endblock %}
{% block footer %}
-{% if new_item_label %}
+{% if new_item_pk %}
<button type="button" data-dismiss="modal"
aria-label="Close" class="btn btn-secondary">
{% trans "Close" %}
@@ -21,7 +21,7 @@
{% endblock %}
{% block js_ready %}
-{% if new_item_label %}
+{% if new_item_pk %}
save_and_close_window{% if many %}_many{% endif %}_data(null, "{{parent_name}}", "{{parent_pk}}", "{{new_item_label|safe}}", "{{new_item_pk}}");
{% endif %}
{% endblock %} \ No newline at end of file