5 [% INCLUDE 'doc-head-open.inc' %]
6 <title>Koha › Reports [% IF ( do_it ) %]› Cash register statistics › Results[% ELSE %]› Cash register statistics[% END %]</title>
7 [% INCLUDE 'doc-head-close.inc' %]
8 <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" />
11 <body id="cash_register_stats" class="rep">
12 [% INCLUDE 'header.inc' %]
13 [% INCLUDE 'cat-search.inc' %]
15 <div id="breadcrumbs">
16 <a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/reports/reports-home.pl">Reports</a>
19 <a href="/cgi-bin/koha/reports/cash_register_stats.pl">Cash register statistics</a> › Results
21 Cash register statistics
25 <div id="doc3" class="yui-t2">
31 <h1>Cash register statistics</h1>
32 <form method="post" action="/cgi-bin/koha/reports/cash_register_stats.pl" id="frmCashRegister">
33 <fieldset class="rows">
34 <legend>Cash register statistics [% beginDate | $KohaDates %] to [% endDate | $KohaDates %]</legend>
38 <label for="from">From: </label>
39 <input type="text" size="10" id="from" name="from" value="[% beginDate | $KohaDates %]" class="datepickerfrom" />
40 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
43 <label for="to">To: </label>
44 <input type="text" size="10" id="to" name="to" value="[% endDate | $KohaDates %]" class="datepickerto" />
45 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
49 <label for="">Transaction type:</label>
50 <select name="transaction_type" id="transaction_type">
51 [% IF transaction_type == "ALL" %]
52 <option value="ALL" selected="selected">All transactions</option>
54 <option value="ALL">All transactions</option>
57 [% IF transaction_type == "ACT" %]
58 <option value="ACT" selected="selected">All payments to the library</option>
60 <option value="ACT">All payments to the library</option>
63 [% IF transaction_type == "C" %]
64 <option value="C" selected="selected">Credit</option>
66 <option value="C">Credit</option>
69 [% IF transaction_type == "CR" %]
70 <option value="CR" selected="selected">Credit (item returned)</option>
72 <option value="CR">Credit (item returned)</option>
75 [% IF transaction_type == "FORW" %]
76 <option value="FORW" selected="selected">Write off</option>
78 <option value="FORW">Write off</option>
81 [% IF transaction_type == "F" %]
82 <option value="F" selected="selected">Fine</option>
84 <option value="F">Fine</option>
87 [% IF transaction_type == "FU" %]
88 <option value="FU" selected="selected">Accruing fine</option>
90 <option value="FU">Accruing fine</option>
93 [% IF transaction_type == "PAY" %]
94 <option value="PAY" selected="selected">Payment</option>
96 <option value="PAY">Payment</option>
99 [% IF transaction_type == "A" %]
100 <option value="A" selected="selected">Account management fee</option>
102 <option value="A">Account management fee</option>
105 [% IF transaction_type == "M" %]
106 <option value="M" selected="selected">Sundry</option>
108 <option value="M">Sundry</option>
111 [% IF transaction_type == "L" %]
112 <option value="L" selected="selected">Lost item</option>
114 <option value="L">Lost item</option>
117 [% IF transaction_type == "N" %]
118 <option value="N" selected="selected">New card</option>
120 <option value="N">New card</option>
123 [% FOREACH manualinv IN manualinv_types %]
124 [% value_manualinv = manualinv.authorised_value|truncate(5, '') %]
125 [% IF transaction_type == value_manualinv %]
126 <option value="[% value_manualinv %]" selected="selected">[% manualinv.authorised_value %]</option>
128 <option value="[% value_manualinv %]">[% manualinv.authorised_value %]</option>
134 <label>Transaction branch</label>
135 <select name="branch" id="branch">
136 <option value="ALL">All</option>
137 [% FOREACH branchloo IN branchloop %]
138 [% IF ( branchloo.selected ) %]
139 <option value="[% branchloo.branchcode %]" selected="selected">[% branchloo.branchname %]</option>
141 <option value="[% branchloo.branchcode %]">[% branchloo.branchname %]</option>
151 <fieldset class="rows">
152 <legend>Output</legend>
155 <label for="outputscreen">To screen into the browser: </label>
156 <input type="radio" checked="checked" name="output" id="outputscreen" value="screen" />
159 <label for="outputfile">To a file:</label>
160 <input type="radio" name="output" value="file" id="outputfile" />
161 <label class="inline" for="basename">Named: </label><input type="text" name="basename" id="basename" value="Export" />
167 <fieldset class="action">
168 <input type="submit" value="Submit" name="do_it" />
174 <table id="tbl_cash_register_stats">
177 <th>Manager name</th>
178 <th>Patron card number</th>
180 <th>Transaction branch</th>
181 <th>Transaction date</th>
182 <th>Transaction type</th>
185 <th>Biblio title</th>
190 [% FOREACH loopresul IN loopresult %]
192 <td>[% loopresul.mfirstname %] [% loopresul.msurname %]</td>
193 <td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% loopresul.borrowernumber %]">[% loopresul.cardnumber %]</a></td>
194 <td>[% loopresul.bfirstname %] [% loopresul.bsurname %]</td>
195 <td>[% loopresul.branchname %]</td>
196 <td>[% loopresul.date | $KohaDates %]</td>
198 [% IF loopresul.accounttype == "ACT" %]
199 <span>All payments to the library</span>
200 [% ELSIF loopresul.accounttype == "C" || loopresul.accounttype == "CR" %]
202 [% ELSIF loopresul.accounttype == "FORW" || loopresul.accounttype == "W" %]
203 <span>Write off</span>
204 [% ELSIF loopresul.accounttype == "F" %]
206 [% ELSIF loopresul.accounttype == "FU" %]
207 <span>Accruing fine</span>
208 [% ELSIF loopresul.accounttype == "Pay" %]
210 [% ELSIF loopresul.accounttype == "A" %]
211 <span>Account management fee</span>
212 [% ELSIF loopresul.accounttype == "M" %]
214 [% ELSIF loopresul.accounttype == "L" || loopresul.accounttype == "LR" %]
215 <span>Lost item</span>
216 [% ELSIF loopresul.accounttype == "N" %]
217 <span>New card</span>
219 [% FOREACH manualinv IN manualinv_types %]
220 [% value_manualinv = manualinv.authorised_value|truncate(5, '') %]
221 [% IF loopresul.accounttype == value_manualinv %]
222 <span>[% manualinv.authorised_value %]</span>
228 <td>[% loopresul.note %]</td>
229 <td style="text-align:right;">[% loopresul.amount | $Price %]</td>
230 <td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% loopresul.biblionumber %]">[% loopresul.title %]</a></td>
231 <td>[% loopresul.barcode %]</td>
232 <td>[% ItemTypes.GetDescription(loopresul.itype) %]</td>
237 [% IF transaction_type == "ACT" %]
238 <th colspan="7" style="text-align:right;">TOTAL</th>
239 <th style="text-align:right;">[% total | $Price %]</th>
240 <th colspan="3"> </th>
246 [% END %] [%# do_it %]
250 [% INCLUDE 'reports-menu.inc' %]
254 [% MACRO jsinclude BLOCK %]
255 [% INCLUDE 'datatables.inc' %]
256 <script type="text/javascript" id="js">
257 $(document).ready(function() {
258 $("#tbl_cash_register_stats").dataTable($.extend(true, {}, dataTablesDefaults, {
259 "iDisplayLength": 50,
260 "sPaginationType": "full_numbers"
264 [% INCLUDE 'calendar.inc' %]
265 <script type="text/javascript">
268 $(document).ready(function() {
269 // http://jqueryui.com/demos/datepicker/#date-range
270 var dates = $( "#filter_date_begin, #filter_date_end" ).datepicker({
273 onSelect: function( selectedDate ) {
274 var option = this.id == "filter_date_begin" ? "minDate" : "maxDate",
275 instance = $( this ).data( "datepicker" );
276 date = $.datepicker.parseDate(
277 instance.settings.dateFormat ||
278 $.datepicker._defaults.dateFormat,
279 selectedDate, instance.settings );
280 dates.not( this ).datepicker( "option", option, date );
284 $('#frmCashRegister').submit(function() {
285 var isFormValid = true;
286 var alertString= _("Form not submitted because of the following problem(s)")+"\n";
288 alertString +="-------------------------------------------------------------------\n\n";
290 if ( !$('#from').val() || !$('#to').val()){
292 alertString += "\n- " + _("Dates cannot be empty");
304 [% INCLUDE 'intranet-bottom.inc' %]