{% extends "base_view.html" %} {% load widget_tweaks %} {% block title %} meliza-lab : new order {% endblock %} {% block content %}

Create a new order

{% csrf_token %}

Instructions: This form is used to create a new order. Leave the account field blank if you are not sure what it should be. After the order is created, you can add items to it.

{% if form.non_field_errors %}
{{ form.non_field_errors }}
{% endif %} {% for field in form %}
{% if field.field.widget.input_type == 'checkbox' %} {# Handle multiple checkboxes #} {% if field.field.choices %}
{% for choice in field %}
{% endfor %}
{% else %} {# Single checkbox #}
{% render_field field %}
{% endif %} {% else %} {# Regular form control #} {% render_field field class+="form-control" %} {% endif %} {% if field.help_text %}

{{ field.help_text }}

{% endif %} {% if field.errors %} {{ field.errors }} {% endif %}
{% endfor %}
{% endblock %}