{% extends "ishtar/forms/qa_base.html" %} {% load i18n inline_formset table_form %} {% block main_form %} {% if form.non_field_errors %} {% endif %} {% for hidden in form.hidden_fields %} {{hidden}} {% if hidden.errors %}
{{ hidden.errors }}
{% endif %} {% endfor %} {% if form.qa_bf_basket %}
 
{% else %} {% endif %}
{% with form.qa_bf_label as field %} {% include "blocks/bs_field_snippet.html" %} {% endwith %}
{% if form.qa_bf_basket %}
 
{% with form.qa_bf_basket as field %} {% include "blocks/bs_field_snippet.html" %} {% endwith %}
{% endif %} {% endblock %} {% block js %} var qa_bf_update_form_display = function(){ if ($("#qa_bf_update-choice:checked").length){ $("#qa_bf_new-basket").hide(); $("#qa_bf_update-basket").show(); } else { $("#qa_bf_update-basket").hide(); $("#qa_bf_new-basket").show(); } } $(document).ready(function(){ $("#qa_bf_create-choice").click(qa_bf_update_form_display); $("#qa_bf_update-choice").click(qa_bf_update_form_display); qa_bf_update_form_display(); }); {% endblock %}