5 [% PROCESS 'i18n.inc' %]
6 [% INCLUDE 'doc-head-open.inc' %]
7 <title>[% FILTER collapse %]
8 [% t("Files") | html %] ›
9 [% t("Invoice") | html %] ›
10 [% t("Acquisitions") | html %] ›
11 [% t("Koha") | html %]
13 [% INCLUDE 'doc-head-close.inc' %]
16 <body id="acq_invoice_files" class="acq">
17 [% WRAPPER 'header.inc' %]
18 [% INCLUDE 'acquisitions-search.inc' %]
21 [% WRAPPER 'sub-header.inc' %]
22 [% WRAPPER breadcrumbs %]
23 [% WRAPPER breadcrumb_item %]
24 <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a>
26 [% WRAPPER breadcrumb_item %]
27 <a href="/cgi-bin/koha/acqui/invoices.pl">Invoices</a>
29 [% WRAPPER breadcrumb_item %]
30 <a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% invoiceid | uri %]">[% invoicenumber | html %]</a>
32 [% WRAPPER breadcrumb_item bc_active= 1 %]
35 [% END #/ WRAPPER breadcrumbs %]
36 [% END #/ WRAPPER sub-header.inc %]
38 <div class="main container-fluid">
40 <div class="col-sm-10 col-sm-push-2">
43 <h1>Files for invoice: [% invoicenumber | html %]</h1>
44 <p><strong>Vendor: </strong><a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% booksellerid | uri %]">[% suppliername | html %]</a></p>
47 <div class="dialog alert">
48 [% IF errors.empty_upload %]The file you are attempting to upload has no contents.[% END %]
49 [% IF errors.no_file %]You did not select a file to upload.[% END %]
50 [% IF errors.invalid_parameter %]Invalid or missing script parameter.[% END %]
54 <table id="invoice_files_details_table">
67 [% FOREACH f IN files %]
69 <td><a href="?invoiceid=[% invoiceid | uri %]&op=download&view=1&file_id=[% f.file_id | uri %]">[% f.file_name | html %]</a></td>
70 <td>[% f.file_type | html %]</td>
71 <td>[% f.file_description | html %]</td>
72 <td data-order="[% f.date_uploaded | html %]">
73 [% f.date_uploaded | $KohaDates %]
75 <td>[% f.file_size | html %]</td>
76 <td><a class="delete_file" href="?invoiceid=[% invoiceid | html %]&op=delete&file_id=[% f.file_id | html %]">Delete</a></td>
77 <td><a href="?invoiceid=[% invoiceid | uri %]&op=download&file_id=[% f.file_id | uri %]">Download</a></td>
83 <div class="dialog message">
84 <p>This invoice has no files attached.</p>
89 <form method="post" action="/cgi-bin/koha/acqui/invoice-files.pl" enctype="multipart/form-data">
90 <fieldset class="rows">
91 <legend>Upload new file</legend>
93 <li><input type="hidden" name="op" value="upload" />
94 <input type="hidden" name="invoiceid" value="[% invoiceid | html %]" />
95 <label for="description">Description:</label>
96 <input name="description" id="description" type="text" /></li>
97 <li><label for="uploadfile">File:</label><input name="uploadfile" type="file" id="uploadfile" /></li>
100 <fieldset class="action"><input name="upload" type="submit" id="upload" class="btn btn-primary" value="Upload file" /></fieldset>
104 </div> <!-- /.col-sm-10.col-sm-push-2 -->
106 <div class="col-sm-2 col-sm-pull-10">
108 [% INCLUDE 'acquisitions-menu.inc' %]
110 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
111 </div> <!-- /.row -->
113 [% MACRO jsinclude BLOCK %]
114 [% Asset.js("js/acquisitions-menu.js") | $raw %]
115 [% INCLUDE 'datatables.inc' %]
117 $(document).ready(function() {
118 $("#invoice_files_details_table").dataTable($.extend(true, {}, dataTablesDefaults, {
120 { "aTargets": [ -1, -2 ], "bSortable": false, "bSearchable": false }
127 $("a.delete_file").click(function(){
128 return ( confirm( _("Are you sure you want to delete this file ?") ) );
134 [% INCLUDE 'intranet-bottom.inc' %]