diff options
Diffstat (limited to 'ishtar_common/templates')
5 files changed, 32 insertions, 9 deletions
diff --git a/ishtar_common/templates/blocks/JQueryJqGrid.html b/ishtar_common/templates/blocks/JQueryJqGrid.html index e8647dadf..1639c70f2 100644 --- a/ishtar_common/templates/blocks/JQueryJqGrid.html +++ b/ishtar_common/templates/blocks/JQueryJqGrid.html @@ -1,5 +1,4 @@ {% load i18n %} -</table> <button id='search_{{name}}' class='submit'>{% trans "Search" %}</button> @@ -42,7 +41,15 @@ jQuery(document).ready(function(){ for (idx in query_vars) { var key = query_vars[idx]; - var val = jQuery("#id_"+key).val(); + var item = jQuery("#id_"+key); + var val = null; + if (item.prop('type') == 'checkbox'){ + if (item.prop('checked')){ + var val = item.val(); + } + } else { + var val = item.val(); + } if (val){ if (data) data += "&"; data += key + "=" + val; diff --git a/ishtar_common/templates/blocks/form_flex_snippet.html b/ishtar_common/templates/blocks/form_flex_snippet.html new file mode 100644 index 000000000..03d8b15f0 --- /dev/null +++ b/ishtar_common/templates/blocks/form_flex_snippet.html @@ -0,0 +1,14 @@ +{% load i18n %} +<ul class='form-flex'> + {% if form.non_field_errors %}<li class='errors'> + {{form.non_field_errors}} + </li>{%endif%} + {% for field in form %}{% if not field.is_hidden %} + <li{% if field.field.required %} class='required'{% endif %}> + {{ field.label_tag }} + <p class='input'>{{ field.errors }}{{field|safe}}</p>{% if field.help_text %} + <a href="#{{field.auto_id}}" class="help_display" title="{% trans "Help"%}">?</a> + <div class="help_text" id="{{field.auto_id}}_help"> + {{field.help_text}}</div> + {%endif%}</li>{% else %}{{field}}{% endif %}{% endfor %} +</ul> diff --git a/ishtar_common/templates/ishtar/sheet_source.html b/ishtar_common/templates/ishtar/sheet_source.html index 47e285017..06001f783 100644 --- a/ishtar_common/templates/ishtar/sheet_source.html +++ b/ishtar_common/templates/ishtar/sheet_source.html @@ -12,6 +12,9 @@ {% field "Item number" item.item_number %} {% field "Ref." item.reference %} {% field "Internal ref." item.internal_reference %} +{% field "Creation date" item.creation_date %} +{% field "Receipt date" item.receipt_date %} +{% field "Receipt date in documentation" item.receipt_date_in_documentation %} {% field "Has a duplicate" item.duplicate %} {% field "Description" item.description %} {% field "Comment" item.comment %} diff --git a/ishtar_common/templates/ishtar/wizard/default_wizard.html b/ishtar_common/templates/ishtar/wizard/default_wizard.html index a39037d10..1a17cf32b 100644 --- a/ishtar_common/templates/ishtar/wizard/default_wizard.html +++ b/ishtar_common/templates/ishtar/wizard/default_wizard.html @@ -35,9 +35,9 @@ <tr class='modify'><td colspan="2"><button name="formset_modify" value="{{wizard.steps.current}}">{% trans "Add/Modify" %}</button></td></tr></li> </table> {% else %} -<table> +{% if not is_search %}<table>{% endif %} {% table_form wizard.form %} -</table> +{% if not is_search %}</table>{% endif %} {% endif %} <input type="hidden" name="{{ step_field }}" value="{{ step0 }}" /> {{ previous_fields|safe }} diff --git a/ishtar_common/templates/ishtar/wizard/search.html b/ishtar_common/templates/ishtar/wizard/search.html index 5cf96552b..e5066cf87 100644 --- a/ishtar_common/templates/ishtar/wizard/search.html +++ b/ishtar_common/templates/ishtar/wizard/search.html @@ -8,8 +8,8 @@ <ul id='form_path'> <li class='current'><a href='#'>{{current_step.form_label}}</a></li> </ul> -<div class='form'> {% if wizard.form.forms %} +<div class='form'> <div class='top_button'><input type="submit" id="submit_form" value="{% trans "Validate" %}"/></div> <table class='formset'> {%if wizard.form.non_form_errors%}<tr class='error'><th colspan='2'>{{wizard.form.non_form_errors}}</th></tr>{%endif%} @@ -20,9 +20,8 @@ <tr class='modify'><td colspan="2"><button name="formset_modify" value="{{wizard.steps.current}}">{% trans "Add/Modify" %}</button></td></tr></li> </table> {% else %} -<table> - {{ wizard.form.as_table }} -</table> -{% endif %} +<div class='form'> + {{ wizard.form.as_p }} </div> +{% endif %} {% endblock %} |