{% extends 'D2PartnerBundle::base.html.twig' %} {% block head_script_extra %} {% endblock head_script_extra %} {% block page_header %}
{% for k, v in app.request.query %} {% if k|lower not in ['search', 'limit', 'page', 'month', 'year', 'partner', 'ma_acc', 'service', 'customer', 'company', 'filter', 'adv_sort', 'min_mass', 'max_mass', 'min_rkg', 'max_rkg', 'min_cost', 'max_cost'] %} {% endif %} {% endfor %}
Displaying {{ all_waybills|length }} Waybill records
{% endblock page_header %} {% block content %} {% macro sort_path(name, direction) %} {{ path('partner_waybill_list_all', {'sort': name,'direction': direction, 'month': app.request.get('month'), 'year': app.request.get('year'), 'partner': app.request.get('partner'), 'customer': app.request.get('customer'), 'filter': app.request.get('filter'), 'adv_sort': app.request.get('adv_sort'), 'service': app.request.get('service'), 'ma_acc': app.request.get('ma_acc'), 'company': app.request.get('company'), 'min_mass': app.request.get('min_mass'), 'max_mass': app.request.get('max_mass'), 'min_rkg': app.request.get('min_rkg'), 'max_rkg': app.request.get('max_rkg'), 'min_cost': app.request.get('min_cost'), 'max_cost': app.request.get('max_cost'), 'page': app.request.get('page'), 'limit': app.request.get('limit') }) }} {% endmacro %} {% macro page_path(to_page) %} {{ path('partner_waybill_list_all', {'page': to_page, 'month': app.request.get('month'), 'year': app.request.get('year'), 'partner': app.request.get('partner'), 'customer': app.request.get('customer'), 'filter': app.request.get('filter'), 'adv_sort': app.request.get('adv_sort'), 'service': app.request.get('service'), 'ma_acc': app.request.get('ma_acc'), 'company': app.request.get('company'), 'min_mass': app.request.get('min_mass'), 'max_mass': app.request.get('max_mass'), 'min_rkg': app.request.get('min_rkg'), 'max_rkg': app.request.get('max_rkg'), 'min_cost': app.request.get('min_cost'), 'max_cost': app.request.get('max_cost'), 'limit': app.request.get('limit') }) }} {% endmacro %} {% set sort_dir = 'ASC' %} {% for k, v in app.request.query %} {% if k == 'direction' %} {% if v == 'ASC' %} {% set sort_dir = 'DESC' %} {% else %} {% set sort_dir = 'ASC' %} {% endif %} {% endif %} {% endfor %} {% if app.request.get('adv_sort') == '5' %}
SET ALL CLEAR
{% endif %} {% if app.request.get('adv_sort') == '3' or app.request.get('adv_sort') == '5' %} {% else %} {% endif %} {% for wb in all_waybills %} {% if app.request.get('adv_sort') == '3' or app.request.get('adv_sort') == '5' %} {% else %} {% endif %} {% if wb.markup_sub_total == 0.00 and wb.markup_vat == 0.00 and wb.markup_total == 0.00 %} {% set markup_color = 'red' %} {% else %} {% set markup_color = 'black' %} {% endif %} {% if wb.sub_total > 0.00 %} {% set wb_markup = ((wb.markup_sub_total - wb.sub_total)/wb.sub_total)*100 %} {% else %} {% set wb_markup = 0.00 %} {% endif %} {% endfor %}
Customer Partner AccountPartner Account CustomerDate Waybill Service Level Esculation Ref 1 Ref 2 Sender Orig Receiver Dest Pcs Act Mass Chrg Mass Incl Mass Basic Other R/KG Sub-Total Vat Total Markup
{{ wb.customer_name }} {{ wb.partner_name }} {{ wb.ma_account_name }}{{ wb.partner_name }} {{ wb.ma_account_name }} {{ wb.customer_name }}{% if wb.waybill_date is not null %} {{ wb.waybill_date|date("Y/m/d") }} {% endif %} {{ wb.waybill }} {{ wb.service }} {% if wb.esculation_level != 0 %}{{ wb.esculation_level }}{% endif %} {{ wb.esculation }} {% if wb.credit_request_number is not null %}
[CREDIT REQUEST: {{ wb.credit_request_number }} R{{ wb.credit_req_ex_vat|number_format(2, '.', '') }} R{{ wb.credit_req_vat|number_format(2, '.', '') }} R{{ wb.credit_req_inc_vat|number_format(2, '.', '') }}] {% endif %} {% if wb.credit_note_number is not null %}
[CREDIT NOTE: {{ wb.credit_note_number }} R{{ wb.credit_ex_vat|number_format(2, '.', '') }} R{{ wb.credit_vat|number_format(2, '.', '') }} R{{ wb.credit_inc_vat|number_format(2, '.', '') }}] {% endif %} {% if wb.quoted %} {% set quote = d2_waybill_quote(wb.waybill) %} {% if quote is not null %}
[QUOTE: {{ quote.docNo }} R{{ quote.total|number_format(2, '.', '') }} {% if wb.early_invoiced %} {% if quote.invoice is not null %}
[INVOICE: {{ quote.invoice.docNo }} R{{ quote.invoice.total|number_format(2, '.', '') }} {% endif %} {% endif %} {% endif %} {% endif %}
{{ wb.ref1 }} {{ wb.ref2 }} {{ wb.sender }} {{ wb.orig }} {{ wb.receiver }} {{ wb.dest }} {{ wb.pcs }} {{ wb.act_mass|number_format(2, '.', '') }} {{ wb.mass_chrg|number_format(2, '.', '') }} {{ wb.incl_mass|number_format(2, '.', '') }} {{ wb.basic_chrg|number_format(2, '.', '') }} {{ wb.other_chrg|number_format(2, '.', '') }} {{ wb.cost_per_kg|number_format(1, '.', '') }}{{ wb.sub_total|number_format(2, '.', '') }}
{{ wb.markup_sub_total|number_format(2, '.', '') }}
{{ wb.vat_ex|number_format(2, '.', '') }}
{{ wb.markup_vat|number_format(2, '.', '') }}
{{ wb.total|number_format(2, '.', '') }}
{{ wb.markup_total|number_format(2, '.', '') }}
{{ wb_markup|number_format(2, '.', '') }}%
{% set cur_page = app.request.get('page') %} {% set prev_page = cur_page - 1 %} {% set next_page = cur_page + 1 %} {% set rec_limit = app.request.get('limit') %} {% endblock content %}