$(document).ready(function(){
var pendingt = $("#pendingt").dataTable($.extend(true, {}, dataTablesDefaults, {
"aoColumnDefs": [
- { "aTargets": [ 3, 7, 8 ], "bSortable": false, "bSearchable": false },
+ { "aTargets": [ 3, 8, 9 ], "bSortable": false, "bSearchable": false },
],
"aoColumns": [
{ "sType": "num-html" },
null,
null,
null,
+ null,
],
"sPaginationType": "four_button"
} ) );
var receivedt = $("#receivedt").dataTable($.extend(true, {}, dataTablesDefaults, {
"aoColumnDefs": [
- { "aTargets": [ 3 ], "bSortable": false, "bSearchable": false },
+ { "aTargets": [ 3, -1 ], "bSortable": false, "bSearchable": false },
],
"aoColumns": [
{ "sType": "num-html" },
],
"sPaginationType": "four_button"
} ) );
+/*
+ $("#pendingt").tablesorter({
+ headers: { 2: { sorter: 'articles' },3: { sorter: false },8:{sorter:false}}
+ });
+*/
rowCountPending = $("#pendingt tbody.filterclass tr").length;
rowCountReceived = $("#receivedt tbody.filterclass tr").length;
$("#pendingcollapserow").remove();
$("#pendingt tr").show();
$("#pendingt tbody.filterclass tr:gt(" + (rowsToCollapse-1) + ")").hide();
- $("#pendingt").before("<p id=\"pendingcollapserow\">" + _("Only the first ") + rowsToCollapse + _(" items are displayed.") + "<a href=\"javascript:pendingExpand();\">" + _("Click here to show all ") + rowCountPending + _(" items") + "<\/a>.<\/p>");
+ $("#pendingt").before("<p id=\"pendingcollapserow\">" + _("Only the first ") + rowsToCollapse + _(" items are displayed.") + " <a href=\"javascript:pendingExpand();\">" + _("Click here to show all ") + rowCountPending + _(" items") + "<\/a>.<\/p>");
}
$("#pendingcollapserow").remove();
$("#pendingt tr").show();
$("#pendingt tbody.filterclass tr.orderfound").remove();
- $("#pendingt").before("<p id=\"pendingcollapserow\">" + rowCountPending + _(" items are displayed.") + "<a href=\"javascript:pendingCollapse();\">" + _("Click here to show only the first ") + rowsToCollapse + _(" items") + "<\/a>.<\/p>");
+ $("#pendingt").before("<p id=\"pendingcollapserow\">" + rowCountPending + _(" items are displayed.") + " <a href=\"javascript:pendingCollapse();\">" + _("Click here to show only the first ") + rowsToCollapse + _(" items") + "<\/a>.<\/p>");
}
// Collapse already received items table
$.cookie("receivedKeepExpanded", 0, { path: "/", expires: 9999 });
$("#receivedcollapserow").remove();
$("#receivedt tbody.filterclass tr:gt(" + (rowsToCollapse-1) + ")").hide();
- $("#receivedt").before("<p id=\"receivedcollapserow\">" + _("Only the first ") + rowsToCollapse + _(" items are displayed.") + "<a href=\"javascript:receivedExpand();\">" + _("Click here to show all ") + rowCountReceived + _(" items") + "<\/a>.<\/p>");
+ $("#receivedt").before("<p id=\"receivedcollapserow\">" + _("Only the first ") + rowsToCollapse + _(" items are displayed.") + " <a href=\"javascript:receivedExpand();\">" + _("Click here to show all ") + rowCountReceived + _(" items") + "<\/a>.<\/p>");
}
// Expand already received items table
$.cookie("receivedKeepExpanded", 1, { path: "/", expires: 9999 });
$("#receivedcollapserow").remove();
$("#receivedt tr").show();
- $("#receivedt").before("<p id=\"receivedcollapserow\">" + _("All ") + rowCountReceived + _(" items are displayed.") + "<a href=\"javascript:receivedCollapse();\">" + _("Click here to show only the first ") + rowsToCollapse + _(" items") + "<\/a>.<\/p>");
+ $("#receivedt").before("<p id=\"receivedcollapserow\">" + _("All ") + rowCountReceived + _(" items are displayed.") + " <a href=\"javascript:receivedCollapse();\">" + _("Click here to show only the first ") + rowsToCollapse + _(" items") + "<\/a>.<\/p>");
}
//]]>
<div id="acqui_receive_summary">
<p><strong>Invoice number:</strong> [% invoice %] <strong>Received by:</strong> [% loggedinusername %] <strong>On:</strong> [% formatteddatereceived %]</p>
-<p><a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% invoiceid %]">Go to invoice details</a></p>
</div>
[% UNLESS (invoiceclosedate) %]
<div id="acqui_receive_search">
<th>Quantity</th>
<th>Unit cost</th>
<th>Order cost</th>
+ <th>Fund</th>
<th> </th>
<th> </th>
</tr>
</thead>
- <tfoot>
- <tr><td colspan="4" class="total">TOTAL</td>
- <td> [% totalPquantity %] </td>
- <td> </td>
- <td>[% ordergrandtotal %]</td>
- <td> </td>
- <td> </td>
- </tr>
- </tfoot>
<tbody class="filterclass">
[% FOREACH loop_order IN loop_orders %]
<tr>
<td>[% loop_order.quantity %]</td>
<td>[% loop_order.ecost %]</td>
<td>[% loop_order.ordertotal %]</td>
+ <td>[% loop_order.budget_name %]</td>
<td>
<a href="orderreceive.pl?ordernumber=[% loop_order.ordernumber %]&invoiceid=[% invoiceid %]">Receive</a>
-
</td>
<td>
[% IF ( loop_order.left_holds_on_order ) %]
</div>
[% ELSE %]
<p>
- Invoice is close, so you can't receive orders.
+ Invoice is closed, so you can't receive orders anymore.
<a href="/cgi-bin/koha/acqui/invoice.pl?op=reopen&invoiceid=[% invoiceid %]&referer=/cgi-bin/koha/acqui/parcel.pl%3Finvoiceid=[% invoiceid %]">Reopen it</a>.
</p>
[% END %]
</tr>
</thead>
<tfoot>
- <tr>
- <td colspan="4" class="total">SUBTOTAL</td>
- <td colspan="2"> </td>
- <td>[% totalprice %]</td>
- <td>[% tototal %]</td>
- <td></td>
- </tr>
-
- [% IF ( totalfreight ) %]
- <tr>
- <td colspan="6">
- </td>
- <td>Shipping</td>
- <td>[% totalfreight %]</td>
- </tr>
- [% END %]
- [% IF ( gst ) %]
- <tr>
- <td colspan="6">
- <p class="message">
- <b>HELP</b><br />
- The total at the bottom of the page should be within a few cents of the total for the invoice.
- </p>
- </td>
- <td><b>Tax rate</b></td>
- <td>[% gst %]</td>
- </tr>
- [% END %]
- <tr>
- <td colspan="4" class="total">TOTAL</td>
- <td>[% totalquantity %]</td>
- <td colspan="2"> </td>
- <td>[% grandtot %]</td>
- <td></td>
- </tr>
+ <tr>
+ <th colspan="7" class="total">Total tax exc.</th>
+ <th>[% total_gste %]</th>
+ <th></th>
+ </tr>
+ [% FOREACH book_foot IN book_foot_loop %]
+ <tr>
+ <th colspan="7">Total (GST [% book_foot.gstrate * 100 | format ("%.1f") %]%)</th>
+ <th>[% book_foot.value %]</th>
+ <th></th>
+ </tr>
+ [% END %]
+ <tr>
+ <th colspan="7" class="total">Total tax inc.</th>
+ <th>[% total_gsti %]</th>
+ <th></th>
+ </tr>
</tfoot>
<tbody class="filterclass">
[% FOREACH loop_receive IN loop_received %]
</div>
<!--<form action="/cgi-bin/koha/acqui/parcels.pl?booksellerid=[% booksellerid %]" method="post">-->
-<form action="parcels.pl?booksellerid=[% booksellerid %]" method="post">
- <input type="hidden" name="booksellerid" value="[% booksellerid %]" />
- <fieldset class="action">
- <input type="submit" value="Finish receiving" />
- </fieldset>
-</form>
+[% IF (invoiceclosedate) %]
+ <a href="/cgi-bin/koha/acqui/invoice.pl?invoiceid=[% invoiceid %]">View invoice</a>
+[% ELSE %]
+ <form action="/cgi-bin/koha/acqui/invoice.pl" method="get">
+ <input type="hidden" name="invoiceid" value="[% invoiceid %]" />
+ <fieldset class="action">
+ <input type="submit" value="Finish receiving" />
+ </fieldset>
+ </form>
+[% END %]
</div>
</div>
<input type="hidden" value="[% invoice %]" name="invoice" />
<input type="hidden" value="[% invoicedatereceived %]" name="datereceived" />
<input type="submit" value="Filter" />
- <a href="/cgi-bin/koha/acqui/parcel.pl?booksellerid=[% booksellerid %]&invoice=[% invoice %]&op=new&datereceived=[% formatteddatereceived %]">Clear</a>
+ <a href="/cgi-bin/koha/acqui/parcel.pl?booksellerid=[% booksellerid %]&invoice=[% invoice %]&op=new&datereceived=[% formatteddatereceived %]">Clear</a>
</fieldset>