1 [% USE HTML %][% USE L %][% USE LxERP %]
3 <h1>[% FORM.title %]</h1>
5 [%- INCLUDE "common/flash.html" %]
7 [% LIST_ACTION = 'list_invoices' %]
8 [%- PROCESS 'mass_invoice_create_print_from_do/_filter.html' filter=SELF.invoice_models.filtered.laundered %]
11 [% invoices = SELF.invoice_models.get;
12 MODELS = SELF.invoice_models %]
13 [%- IF !invoices.size %]
15 [%- LxERP.t8("There are currently no open invoices, or none matches your filter conditions.") %]
19 <form method="post" action="controller.pl" id="report_form">
22 <tr class="listheading">
23 <th>[% L.checkbox_tag("", id="check_all", checkall="[data-checkall=1]") %]</th>
24 <th>[% L.sortable_table_header("transdate") %]</th>
25 <th>[% L.sortable_table_header("reqdate") %]</th>
26 <th>[% L.sortable_table_header("invnumber") %]</th>
27 <th>[% L.sortable_table_header("donumber") %]</th>
28 <th>[% L.sortable_table_header("customer") %]</th>
29 <th>[% LxERP.t8("Shipto") %]</th>
34 [%- FOREACH invoice = invoices %]
35 [% invoice_id = invoice.id
36 delivery_order = invoice.delivery_order %]
38 <td>[% L.checkbox_tag('id[]', value=invoice.id, "data-checkall"=1, checked=selected_ids.$invoice_id) %]</td>
39 <td>[% HTML.escape(invoice.transdate_as_date) %]</td>
40 <td>[% HTML.escape(invoice.deliverydate_as_date) %]</td>
41 <td>[% L.link(SELF.url_for(controller="is.pl", action="edit", type="sales_invoice", id=invoice.id), invoice.invnumber) %]</td>
43 [% IF delivery_order %]
44 [% L.link(SELF.url_for(controller="do.pl", action="edit", id=delivery_order.id), delivery_order.donumber) %]
46 [% HTML.escape(invoice.donumber) %]
49 <td>[% HTML.escape(invoice.customer.name) %]</td>
50 <td>[% HTML.escape(SELF.make_shipto_title(invoice.shipto || delivery_order.custom_shipto)) %]</td>
56 [% IF !SELF.invoice_ids.size %]
57 [% L.paginate_controls %]
60 [% L.hidden_tag("action", "MassInvoiceCreatePrint/dispatch") %]
61 [% L.hidden_tag("printer_id") %]
62 [% L.hidden_tag("bothsided") %]
65 [% IF SELF.printers.size %]
66 <div id="print_options" class="hidden">
68 [% LxERP.t8("Print both sided") %]:
69 [% L.checkbox_tag('', id="print_options_bothsided") %]
72 [% LxERP.t8("Print destination") %]:
73 [% SET printers = [ { description=LxERP.t8("Download PDF, do not print") } ] ;
74 CALL printers.import(SELF.printers);
75 L.select_tag("", printers, id="print_options_printer_id", title_key="description", default=FORM.printer_id) %]
79 [% L.button_tag("kivi.MassInvoiceCreatePrint.massPrint()", LxERP.t8('Print')) %]