@@ -, +, @@
amount column is out of place
extra line before total
---
koha-tmpl/intranet-tmpl/prog/en/includes/accounts.inc | 8 ++++----
.../prog/en/modules/reports/cash_register_stats.tt | 10 +++-------
.../prog/en/modules/reports/csv/cash_register_stats.tt | 11 ++++-------
koha-tmpl/opac-tmpl/bootstrap/en/includes/accounts.inc | 8 ++++----
reports/cash_register_stats.pl | 5 ++---
5 files changed, 17 insertions(+), 25 deletions(-)
--- a/koha-tmpl/intranet-tmpl/prog/en/includes/accounts.inc
+++ a/koha-tmpl/intranet-tmpl/prog/en/includes/accounts.inc
@@ -1,16 +1,16 @@
[%- BLOCK account_type_description -%]
[%- IF account.credit_type_code -%]
- [%- PROCESS credit_type_description credit_type = account.credit_type -%]
+ [%- PROCESS credit_type_description credit_type_code = account.credit_type_code -%]
[%- ELSIF account.debit_type_code -%]
- [%- PROCESS debit_type_description debit_type = account.debit_type -%]
+ [%- PROCESS debit_type_description debit_type_code = account.debit_type_code -%]
[%- END -%]
[%- PROCESS account_status_description account=account -%]
[%- END -%]
[%- BLOCK debit_type_description -%]
- [%- SWITCH debit_type.code -%]
+ [%- SWITCH debit_type_code -%]
[%- CASE 'ACCOUNT' -%]Account creation fee
[%- CASE 'ACCOUNT_RENEW' -%]Account renewal fee
[%- CASE 'LOST' -%]Lost item
@@ -30,7 +30,7 @@
[%- END -%]
[%- BLOCK credit_type_description -%]
- [%- SWITCH credit_type.code -%]
+ [%- SWITCH credit_type_code -%]
[%- CASE 'PAYMENT' -%]Payment
[%- CASE 'WRITEOFF' -%]Writeoff
[%- CASE 'FORGIVEN' -%]Forgiven
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/cash_register_stats.tt
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/cash_register_stats.tt
@@ -16,6 +16,7 @@
[% INCLUDE 'header.inc' %]
[% INCLUDE 'cat-search.inc' %]
+[% INCLUDE 'accounts.inc' %]
Home ›
Reports
@@ -158,13 +159,8 @@
[% loopresul.bfirstname | html %] [% loopresul.bsurname | html %] |
[% loopresul.branchname | html %] |
[% loopresul.date | $KohaDates %] |
-
- [% IF loopresul.credit_type == "ACT" %]
- All payments to the library
- [% ELSE %]
- [%- PROCESS account_type_description account=loopresul -%]
- [% END %]
- |
+
[% loopresul.timestamp | $KohaDates with_hours = 1 %] |
+
[% PROCESS account_type_description account=loopresul %] |
[% loopresul.note | html %] |
[% loopresul.amount | $Price %] |
[% loopresul.title | html %] |
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/csv/cash_register_stats.tt
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/csv/cash_register_stats.tt
@@ -1,9 +1,6 @@
[%- USE ItemTypes -%]
[%- INCLUDE csv_headers/reports/cash_register_stats.tt -%]
-[%- INCLUDE empty_line.inc -%]
-[%- FOREACH row IN rows -%]
- [%- FOREACH field IN row; field IF !loop.last; ItemTypes.GetDescription(field) IF loop.last; sep IF !loop.last; END -%]
- [%- INCLUDE empty_line.inc -%]
-[%- END -%]
-TOTAL[%- INCLUDE empty_line.inc -%]
-[%- FOREACH field IN total; field; sep IF !loop.last; END -%]
+[%- FOREACH row IN rows %]
+ [% FOREACH field IN row; field IF !loop.last; ItemTypes.GetDescription(field) IF loop.last; sep IF !loop.last; END %]
+[%- END %]
+TOTAL[% sep %][%- FOREACH field IN total; field; sep IF !loop.last; END -%]
--- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/accounts.inc
+++ a/koha-tmpl/opac-tmpl/bootstrap/en/includes/accounts.inc
@@ -1,16 +1,16 @@
[%- BLOCK account_type_description -%]
[%- IF account.credit_type_code -%]
- [%- PROCESS credit_type_description credit_type = account.credit_type -%]
+ [%- PROCESS credit_type_description credit_type_code = account.credit_type_code -%]
[%- ELSIF account.debit_type_code -%]
- [%- PROCESS debit_type_description debit_type = account.debit_type -%]
+ [%- PROCESS debit_type_description debit_type_code = account.debit_type_code -%]
[%- END -%]
[%- PROCESS account_status_description account=account -%]
[%- END -%]
[%- BLOCK debit_type_description -%]
- [%- SWITCH debit_type.code -%]
+ [%- SWITCH debit_type_code -%]
[%- CASE 'ACCOUNT' -%]Account creation fee
[%- CASE 'ACCOUNT_RENEW' -%]Account renewal fee
[%- CASE 'LOST' -%]Lost item
@@ -30,7 +30,7 @@
[%- END -%]
[%- BLOCK credit_type_description -%]
- [%- SWITCH credit_type.code -%]
+ [%- SWITCH credit_type_code -%]
[%- CASE 'PAYMENT' -%]Payment
[%- CASE 'WRITEOFF' -%]Writeoff
[%- CASE 'FORGIVEN' -%]Forgiven
--- a/reports/cash_register_stats.pl
+++ a/reports/cash_register_stats.pl
@@ -166,8 +166,7 @@ if ($do_it) {
$row->{bfirstname} . ' ' . $row->{bsurname},
$row->{branchname},
$row->{date},
- $row->{credit_type_code},
- $row->{debit_type_code},
+ $row->{credit_type_code} || $row->{debit_type_code},
$row->{note},
$row->{amount},
$row->{title},
@@ -176,7 +175,7 @@ if ($do_it) {
push (@rows, \@rowValues) ;
}
my @total;
- for (1..6){push(@total,"")};
+ for (1..7){push(@total,"")};
push(@total, $grantotal);
print $input->header(
-type => 'text/csv',
--