<li>Last cashup: [% register.last_cashup.timestamp | $KohaDates with_hours => 1 %] (<a data-toggle="modal" data-cashup="[% register.last_cashup.id | html %]" data-register="[% register.description | html %]" href="#cashupSummaryModal" class="button">Summary</a>)</li>
[% END %]
<li>Float: [% register.starting_float | $Price %]</li>
- <li>Total income (cash): [% accountlines.credits_total * -1 | $Price %] ([% accountlines.credits_total(payment_type => 'CASH') * -1 | $Price %])</li>
- <li>Total outgoing (cash): [% accountlines.debits_total * -1 | $Price %] ([% accountlines.debits_total( payment_type => 'CASH') * -1 | $Price %])</li>
- <li>Total bankable: [% accountlines.total( payment_type => 'CASH') * -1 | $Price %]</li>
+ <li>Total income (cash): [% accountlines.credits_total * -1 | $Price %] ([% accountlines.credits_total(payment_type => [ 'CASH', 'SIP00' ]) * -1 | $Price %])</li>
+ <li>Total outgoing (cash): [% accountlines.debits_total * -1 | $Price %] ([% accountlines.debits_total( payment_type => [ 'CASH', 'SIP00' ]) * -1 | $Price %])</li>
+ <li>Total bankable: [% accountlines.total( payment_type => [ 'CASH', 'SIP00' ]) * -1 | $Price %]</li>
</ul>
[% IF register.last_cashup %]
<ol>
<li>
<label for="trange_f">From: </label>
- <input type="text" size="10" id="from" class="flatpickr" data-start_for="to" name="trange_f" value="[% trange_f | html %]"/>
+ <input type="text" size="10" id="from" class="flatpickr" data-date_to="to" name="trange_f" value="[% trange_f | html %]"/>
<label class="inline" for="trange_t">To: </label>
<input type="text" size="10" id="to" class="flatpickr" name="trange_t" value="[% trange_t | html %]" />
<span class="hint">[% INCLUDE 'date-format.inc' %]</span>
<h4 class="modal-title" id="confirmCashupLabel">Confirm cashup of <em>[% register.description | html %]</em></h4>
</div>
<div class="modal-body">
- Please confirm that you have removed [% accountlines.total( payment_type => 'CASH') * -1 | $Price %] from the cash register and left a float of [% register.starting_float | $Price %].
+ Please confirm that you have removed [% accountlines.total( payment_type => [ 'CASH', 'SIP00' ]) * -1 | $Price %] from the cash register and left a float of [% register.starting_float | $Price %].
</div> <!-- /.modal-body -->
<div class="modal-footer">
<a href="/cgi-bin/koha/pos/register.pl?op=cashup" class="btn btn-default" id="pos_cashup_confirm">Confirm</a>
[% MACRO jsinclude BLOCK %]
[% INCLUDE 'datatables.inc' %]
[% Asset.js("lib/jquery/plugins/rowGroup/dataTables.rowGroup.min.js") | $raw %]
+ [% INCLUDE 'format_price.inc' %]
[% Asset.js("js/cashup_modal.js") | $raw %]
[% INCLUDE 'calendar.inc' %]
[% INCLUDE 'js-date-format.inc' %]
$("#returned, #refund_type").focus();
});
- $(".printReceipt").click(function() {
+ $("body").on('click', ".printReceipt", function() {
var accountlines_id = $(this).data('accountline');
var win = window.open('/cgi-bin/koha/pos/printreceipt.pl?action=print&accountlines_id=' + accountlines_id, '_blank');
win.focus();
});
- $('.modal.printable').on('shown.bs.modal', function() {
- $('.modal-dialog', this).addClass('focused');
- $('body').addClass('modalprinter');
-
- if ($(this).hasClass('autoprint')) {
- window.print();
- }
- }).on('hidden.bs.modal', function () {
- $('.modal-dialog', this).removeClass('focused');
- $('body').removeClass('modalprinter');
- });
-
- $('.printModal').click(function() {
- window.print();
- });
-
-
var cashups_table_url = "/api/v1/cash_registers/[% register.id | html %]/cashups?";
- var cashups_table = $("#table_cashups").api({
+ var cashups_table = $("#table_cashups").kohaTable({
"ajax": {
"url": cashups_table_url
},