Files
partsERP/templates/pages/store/_suppliers.html

69 lines
3.5 KiB
HTML

{% extends 'layouts/layout.html' %}
{% block page_body %}
<link rel="stylesheet" href="{{ url_for('static', filename='dist/css/store_suppliers.bundle.css') }}">
<form id="{{ model.ID_FORM_FILTERS }}" class="{{ model.FLAG_FILTER }} {{ model.FLAG_ROW }} {{ model.FLAG_CARD }}" action="{{ url_for('routes_store_supplier.filter_supplier') }}" method="POST"> <!-- {{ model.FLAG_CONTAINER }} -->
{{ model.form_filters.hidden_tag() }}
<div class="{{ model.FLAG_CONTAINER }} {{ model.FLAG_COLUMN }}">
<div class="{{ model.FLAG_CONTAINER_INPUT }} {{ model.FLAG_ROW }} {{ model.FLAG_FILTER }} {{ model.FLAG_ACTIVE }}">
{{ model.form_filters.active.label }}
{{ model.form_filters.active() }}
{% for error in model.form_filters.active.errors %}
<p class="error">{{ error }}</p>
{% endfor %}
</div>
</div>
{% set block_id = 'buttons_table_default' %}
{% include 'components/common/buttons/_buttons_save_cancel.html' %}
</form>
<table id="{{ model.ID_TABLE_MAIN }}" class="{{ model.FLAG_ROW }} {{ model.FLAG_CARD }}">
<thead>
<tr class="{{ model.FLAG_SUPPLIER }}">
<th class="{{ model.FLAG_NAME_COMPANY }}">Company</th>
<th class="{{ model.FLAG_NAME_CONTACT }}">Contact Name</th>
<th class="{{ model.FLAG_DEPARTMENT_CONTACT }}">Contact Department</th>
<th class="{{ model.FLAG_ADDRESS }} {{ model.FLAG_COLLAPSED }}">Address</th>
<th class="{{ model.FLAG_PHONE_NUMBER }}">Phone Number</th>
<th class="{{ model.FLAG_FAX }}">Fax Number</th>
<th class="{{ model.FLAG_EMAIL }}">Email</th>
<th class="{{ model.FLAG_WEBSITE }}">Website</th>
<th class="{{ model.FLAG_CURRENCY }}">Currency</th>
<th class="{{ model.FLAG_ACTIVE}}">
{% set block_id = 'button_add' %}
{% include 'components/common/buttons/_buttons_save_cancel.html' %}
</th>
</tr>
</thead>
<tbody>
{% set is_blank_row = False %}
{% for supplier in model.suppliers %}
{% include 'components/store/_row_supplier.html' %}
{% endfor %}
{% set is_blank_row = True %}
{% include 'components/store/_row_supplier.html' %}
</tbody>
</table>
{% include 'components/common/temporary/_overlay_confirm.html' %}
{% include 'components/common/temporary/_overlay_error.html' %}
<script src="{{ url_for('routes_store.scripts_section_store') }}"></script>
<script>
{#
var addresses = {{ model.convert_list_objects_to_dict_json_by_attribute_key_default(model.addresses) | tojson | safe }};
#}
var currencies = {{ model.convert_list_objects_to_dict_json_by_attribute_key_default(model.currencies) | tojson | safe }};
var flagDepartmentContact = "{{ model.FLAG_DEPARTMENT_CONTACT }}";
var flagNameCompany = "{{ model.FLAG_NAME_COMPANY }}";
var flagNameContact = "{{ model.FLAG_NAME_CONTACT }}";
var regions = {{ model.convert_list_objects_to_dict_json_by_attribute_key_default(model.regions) | tojson | safe }};
var supplierAddresses = {{ model.supplier_addresses | tojson | safe }};
var suppliers = {{ model.convert_list_objects_to_dict_json_by_attribute_key_default(model.suppliers) | tojson | safe }};
</script>
{% endblock %}