Lines 18-23
Link Here
|
18 |
[% USE Branches %] |
18 |
[% USE Branches %] |
19 |
[% USE Price %] |
19 |
[% USE Price %] |
20 |
[% USE AuthorisedValues %] |
20 |
[% USE AuthorisedValues %] |
|
|
21 |
[% USE ColumnsSettings %] |
21 |
[% SET footerjs = 1 %] |
22 |
[% SET footerjs = 1 %] |
22 |
[% INCLUDE 'doc-head-open.inc' %] |
23 |
[% INCLUDE 'doc-head-open.inc' %] |
23 |
<title>Koha › Acquisitions › [% UNLESS ( basketno ) %]New [% END %]Basket [% basketname | html %] ([% basketno | html %]) for [% booksellername | html %]</title> |
24 |
<title>Koha › Acquisitions › [% UNLESS ( basketno ) %]New [% END %]Basket [% basketname | html %] ([% basketno | html %]) for [% booksellername | html %]</title> |
Lines 387-418
Link Here
|
387 |
|
388 |
|
388 |
<div id="acqui_basket_content" class="yui-g"> |
389 |
<div id="acqui_basket_content" class="yui-g"> |
389 |
[% IF ( books_loop ) %] |
390 |
[% IF ( books_loop ) %] |
390 |
<h2>Orders</h2> |
391 |
<h2>Orders</h2> |
391 |
<label for="show_all_details"> |
|
|
392 |
<input type="checkbox" style="vertical-align: middle;" id="show_all_details" /> |
393 |
Show all details |
394 |
</label> |
395 |
<table id="orders"> |
392 |
<table id="orders"> |
396 |
<thead> |
393 |
<thead> |
397 |
<tr> |
394 |
<tr> |
398 |
<th>No.</th> |
395 |
<th>No.</th> |
399 |
<th class="anti-the">Order</th> |
396 |
<th>Order</th> |
400 |
<th class="tax_excluded">RRP tax exc.</th> |
397 |
<th>RRP tax exc.</th> |
401 |
<th class="tax_excluded">ecost tax exc.</th> |
398 |
<th>ecost tax exc.</th> |
402 |
<th class="tax_included">RRP tax inc.</th> |
399 |
<th>RRP tax inc.</th> |
403 |
<th class="tax_included">ecost tax inc.</th> |
400 |
<th>ecost tax inc.</th> |
404 |
<th class="replacementprice">Replacement price</th> |
401 |
<th>Replacement price</th> |
405 |
<th>Qty.</th> |
402 |
<th>Qty.</th> |
406 |
<th class="tax_excluded">Total tax exc. ([% currency | html %])</th> |
403 |
<th>Total tax exc. ([% currency | html %])</th> |
407 |
<th class="tax_included">Total tax inc. ([% currency | html %])</th> |
404 |
<th>Total tax inc. ([% currency | html %])</th> |
408 |
<th>GST %</th> |
405 |
<th>GST %</th> |
409 |
<th>GST</th> |
406 |
<th>GST</th> |
410 |
<th>Fund</th> |
407 |
<th>Fund</th> |
411 |
<th>Supplier report</th> |
408 |
<th>Supplier report</th> |
412 |
[% IF ( active ) %] |
409 |
[% IF ( active ) %] |
413 |
[% UNLESS ( closedate ) %] |
410 |
[% UNLESS ( closedate ) %] |
414 |
<th>Modify</th> |
411 |
<th class="NoSort">Modify</th> |
415 |
<th>Cancel order</th> |
412 |
<th class="NoSort">Cancel order</th> |
416 |
[% END %] |
413 |
[% END %] |
417 |
[% END %] |
414 |
[% END %] |
418 |
</tr> |
415 |
</tr> |
Lines 422-435
Link Here
|
422 |
<tr> |
419 |
<tr> |
423 |
<th></th> |
420 |
<th></th> |
424 |
<th>Total (GST [% foot_loo.tax_rate * 100 | html %])</th> |
421 |
<th>Total (GST [% foot_loo.tax_rate * 100 | html %])</th> |
425 |
<th class="tax_excluded"> </th> |
422 |
<th> </th> |
426 |
<th class="tax_excluded"> </th> |
423 |
<th> </th> |
427 |
<th class="tax_included"> </th> |
424 |
<th> </th> |
428 |
<th class="tax_included"> </th> |
425 |
<th> </th> |
429 |
<th class="replacementprice"> </th> |
426 |
<th> </th> |
430 |
<th>[% foot_loo.quantity | html %]</th> |
427 |
<th>[% foot_loo.quantity | html %]</th> |
431 |
<th class="tax_excluded">[% foot_loo.total_tax_excluded | $Price %]</th> |
428 |
<th>[% foot_loo.total_tax_excluded | $Price %]</th> |
432 |
<th class="tax_included">[% foot_loo.total_tax_included | $Price %]</th> |
429 |
<th>[% foot_loo.total_tax_included | $Price %]</th> |
433 |
<th> </th> |
430 |
<th> </th> |
434 |
<th>[% foot_loo.tax_value | $Price %]</th> |
431 |
<th>[% foot_loo.tax_value | $Price %]</th> |
435 |
<th> </th> |
432 |
<th> </th> |
Lines 445-458
Link Here
|
445 |
<tr> |
442 |
<tr> |
446 |
<th></th> |
443 |
<th></th> |
447 |
<th>Total ([% currency | html %])</th> |
444 |
<th>Total ([% currency | html %])</th> |
448 |
<th class="tax_excluded"> </th> |
445 |
<th> </th> |
449 |
<th class="tax_excluded"> </th> |
446 |
<th> </th> |
450 |
<th class="tax_included"> </th> |
447 |
<th> </th> |
451 |
<th class="tax_included"> </th> |
448 |
<th> </th> |
452 |
<th class="replacementprice"> </th> |
449 |
<th> </th> |
453 |
<th>[% total_quantity | html %]</th> |
450 |
<th>[% total_quantity | html %]</th> |
454 |
<th class="tax_excluded">[% total_tax_excluded | $Price %]</th> |
451 |
<th>[% total_tax_excluded | $Price %]</th> |
455 |
<th class="tax_included">[% total_tax_included | $Price %]</th> |
452 |
<th>[% total_tax_included | $Price %]</th> |
456 |
<th> </th> |
453 |
<th> </th> |
457 |
<th>[% total_tax_value | $Price %]</th> |
454 |
<th>[% total_tax_value | $Price %]</th> |
458 |
<th> </th> |
455 |
<th> </th> |
Lines 521-534
Link Here
|
521 |
</td> |
518 |
</td> |
522 |
[% SET zero_regex = "^0{1,}\.?0{1,}[^1-9]" %] [%# 0 or 0.0 or 0.00 or 00 or 00.0 or 00.00 or 0.000 ... %] |
519 |
[% SET zero_regex = "^0{1,}\.?0{1,}[^1-9]" %] [%# 0 or 0.0 or 0.00 or 00 or 00.0 or 00.00 or 0.000 ... %] |
523 |
[%# FIXME: use of a regexp is not ideal; bugs 9410 and 10929 suggest better way of handling this %] |
520 |
[%# FIXME: use of a regexp is not ideal; bugs 9410 and 10929 suggest better way of handling this %] |
524 |
<td class="number tax_excluded [% IF books_loo.rrp_tax_excluded.search(zero_regex) %]error[% END %]">[% books_loo.rrp_tax_excluded | $Price %]</td> |
521 |
<td class="number [% IF books_loo.rrp_tax_excluded.search(zero_regex) %]error[% END %]">[% books_loo.rrp_tax_excluded | $Price | html %]</td> |
525 |
<td class="number tax_excluded [% IF books_loo.ecost_tax_excluded.search(zero_regex) %]error[% END %]">[% books_loo.ecost_tax_excluded | $Price %]</td> |
522 |
<td class="number [% IF books_loo.ecost_tax_excluded.search(zero_regex) %]error[% END %]">[% books_loo.ecost_tax_excluded | $Price | html %]</td> |
526 |
<td class="number tax_included [% IF books_loo.rrp_tax_included.search(zero_regex) %]error[% END %]">[% books_loo.rrp_tax_included | $Price %]</td> |
523 |
<td class="number [% IF books_loo.rrp_tax_included.search(zero_regex) %]error[% END %]">[% books_loo.rrp_tax_included | $Price | html %]</td> |
527 |
<td class="number tax_included [% IF books_loo.ecost_tax_included.search(zero_regex) %]error[% END %]">[% books_loo.ecost_tax_included | $Price %]</td> |
524 |
<td class="number [% IF books_loo.ecost_tax_included.search(zero_regex) %]error[% END %]">[% books_loo.ecost_tax_included | $Price | html %]</td> |
528 |
<td class="number replacementprice [% IF books_loo.replacementprice.search(zero_regex) %]error[% END %]">[% books_loo.replacementprice | $Price %]</td> |
525 |
<td class="number [% IF books_loo.replacementprice.search(zero_regex) %]error[% END %]">[% books_loo.replacementprice | $Price %]</td> |
529 |
<td class="number [% IF books_loo.quantity.search(zero_regex) %]error[% END %]">[% books_loo.quantity | html %]</td> |
526 |
<td class="number [% IF books_loo.quantity.search(zero_regex) %]error[% END %]">[% books_loo.quantity | html %]</td> |
530 |
<td class="number tax_excluded [% IF books_loo.total_tax_excluded.search(zero_regex) %]error[% END %]">[% books_loo.total_tax_excluded | $Price %]</td> |
527 |
<td class="number [% IF books_loo.total_tax_excluded.search(zero_regex) %]error[% END %]">[% books_loo.total_tax_excluded | $Price | html %]</td> |
531 |
<td class="number tax_included [% IF books_loo.total_tax_included.search(zero_regex) %]error[% END %]">[% books_loo.total_tax_included | $Price %]</td> |
528 |
<td class="number [% IF books_loo.total_tax_included.search(zero_regex) %]error[% END %]">[% books_loo.total_tax_included | $Price | html %]</td> |
532 |
<td class="number">[% books_loo.tax_rate * 100 | html %]</td> |
529 |
<td class="number">[% books_loo.tax_rate * 100 | html %]</td> |
533 |
<td class="number [% IF books_loo.tax_value.search(zero_regex) %]error[% END %]">[% books_loo.tax_value | $Price %]</td> |
530 |
<td class="number [% IF books_loo.tax_value.search(zero_regex) %]error[% END %]">[% books_loo.tax_value | $Price %]</td> |
534 |
<td>[% books_loo.budget_name | html %]</td> |
531 |
<td>[% books_loo.budget_name | html %]</td> |
Lines 637-650
Link Here
|
637 |
</p> |
634 |
</p> |
638 |
[% END %] |
635 |
[% END %] |
639 |
</td> |
636 |
</td> |
640 |
<td class="number tax_excluded">[% order.rrp_tax_excluded | $Price %]</td> |
637 |
<td class="number">[% order.rrp_tax_excluded | $Price | html %]</td> |
641 |
<td class="number tax_excluded">[% order.ecost_tax_excluded | $Price %]</td> |
638 |
<td class="number">[% order.ecost_tax_excluded | $Price | html %]</td> |
642 |
<td class="number tax_included">[% order.rrp_tax_included | $Price %]</td> |
639 |
<td class="number">[% order.rrp_tax_included | $Price | html %]</td> |
643 |
<td class="number tax_included">[% order.ecost_tax_included | $Price %]</td> |
640 |
<td class="number">[% order.ecost_tax_included | $Price | html %]</td> |
644 |
<td class="number replacementprice">[% order.replacementprice | $Price %]</td> |
641 |
<td class="number">[% order.replacementprice | $Price %]</td> |
645 |
<td class="number">[% order.quantity | html %]</td> |
642 |
<td class="number">[% order.quantity | html %]</td> |
646 |
<td class="number tax_excluded">[% order.total_tax_excluded | $Price %]</td> |
643 |
<td class="number">[% order.total_tax_excluded | $Price | html %]</td> |
647 |
<td class="number tax_included">[% order.total_tax_included | $Price %]</td> |
644 |
<td class="number">[% order.total_tax_included | $Price | html %]</td> |
648 |
<td class="number">[% order.tax_rate * 100 | html %]</td> |
645 |
<td class="number">[% order.tax_rate * 100 | html %]</td> |
649 |
<td class="number">[% order.tax_value | $Price %]</td> |
646 |
<td class="number">[% order.tax_value | $Price %]</td> |
650 |
<td>[% order.budget_name | html %] |
647 |
<td>[% order.budget_name | html %] |
Lines 763-768
Link Here
|
763 |
[% MACRO jsinclude BLOCK %] |
760 |
[% MACRO jsinclude BLOCK %] |
764 |
[% Asset.js("js/acquisitions-menu.js") | $raw %] |
761 |
[% Asset.js("js/acquisitions-menu.js") | $raw %] |
765 |
[% INCLUDE 'datatables.inc' %] |
762 |
[% INCLUDE 'datatables.inc' %] |
|
|
763 |
[% INCLUDE 'columns_settings.inc' %] |
766 |
[% Asset.js("lib/jquery/plugins/jquery.fixFloat.js") | $raw %] |
764 |
[% Asset.js("lib/jquery/plugins/jquery.fixFloat.js") | $raw %] |
767 |
<script> |
765 |
<script> |
768 |
function updateColumnsVisibility(visible) { |
766 |
function updateColumnsVisibility(visible) { |
Lines 779-790
Link Here
|
779 |
|
777 |
|
780 |
$(document).ready(function() { |
778 |
$(document).ready(function() { |
781 |
if ( $('#toolbar').length ) {$('#toolbar').fixFloat();} |
779 |
if ( $('#toolbar').length ) {$('#toolbar').fixFloat();} |
782 |
$("#show_all_details").click(function(){ |
|
|
783 |
updateColumnsVisibility($(this).is(":checked")); |
784 |
}); |
785 |
|
786 |
$("#show_all_details").prop('checked', false); |
787 |
updateColumnsVisibility(false); |
788 |
[% UNLESS ( closedate ) %] |
780 |
[% UNLESS ( closedate ) %] |
789 |
$('#addtoBasket').on('show', function () { |
781 |
$('#addtoBasket').on('show', function () { |
790 |
$(this).find(".modal-body").html($(".acqui_basket_add")[0].outerHTML); |
782 |
$(this).find(".modal-body").html($(".acqui_basket_add")[0].outerHTML); |
Lines 895-912
Link Here
|
895 |
[% END %] |
887 |
[% END %] |
896 |
[% END %] |
888 |
[% END %] |
897 |
<script> |
889 |
<script> |
|
|
890 |
<<<<<<< HEAD |
891 |
======= |
892 |
var columns_settings = [% ColumnsSettings.GetColumns( 'acqui', 'basket', 'orders', 'json' ) %]; |
893 |
>>>>>>> Bug 20966: Add column configuration to table of orders in a basket |
898 |
$(document).ready(function() { |
894 |
$(document).ready(function() { |
899 |
var orderst = $("#orders").dataTable($.extend(true, {}, dataTablesDefaults, { |
895 |
KohaTable("orders", { |
900 |
"sPaginationType": "four_button", |
|
|
901 |
[% IF ( active ) %] |
896 |
[% IF ( active ) %] |
902 |
"aoColumnDefs": [ |
897 |
"aoColumnDefs": [ |
903 |
[% UNLESS ( closedate ) %] |
898 |
{ "bSortable": false, "bSearchable": false, 'aTargets': [ 'NoSort' ] }, |
904 |
{ "aTargets": [ -1, -2 ], "bSortable": false, "bSearchable": false }, |
|
|
905 |
[% END %] |
906 |
{ "sType": "anti-the", "aTargets": [ "anti-the" ] } |
899 |
{ "sType": "anti-the", "aTargets": [ "anti-the" ] } |
907 |
], |
900 |
], |
908 |
[% END %] |
901 |
[% END %] |
909 |
} ) ); |
902 |
"sPaginationType": "four_button", |
|
|
903 |
"autoWidth": false |
904 |
}, columns_settings); |
905 |
|
910 |
var cancelledorderst = $("#cancelledorderst").dataTable($.extend(true, {}, dataTablesDefaults, { |
906 |
var cancelledorderst = $("#cancelledorderst").dataTable($.extend(true, {}, dataTablesDefaults, { |
911 |
"sPaginationType": "four_button" |
907 |
"sPaginationType": "four_button" |
912 |
} ) ); |
908 |
} ) ); |
913 |
- |
|
|