7 [% INCLUDE 'doc-head-open.inc' %]
8 <title>Koha › Reports [% IF ( do_it ) %]› Cash register statistics › Results[% ELSE %]› Cash register statistics[% END %]</title>
9 [% INCLUDE 'doc-head-close.inc' %]
12 <body id="cash_register_stats" class="rep">
13 [% INCLUDE 'header.inc' %]
14 [% INCLUDE 'cat-search.inc' %]
16 <div id="breadcrumbs">
17 <a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/reports/reports-home.pl">Reports</a>
20 <a href="/cgi-bin/koha/reports/cash_register_stats.pl">Cash register statistics</a> › Results
22 Cash register statistics
26 <div class="main container-fluid">
28 <div class="col-sm-10 col-sm-push-2">
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 == "OVERDUE" %]
82 <option value="OVERDUE" selected="selected">Fine</option>
84 <option value="OVERDUE">Fine</option>
87 [% IF transaction_type == "OVERDUEA" %]
88 <option value="OVERDUEA" selected="selected">Accruing fine</option>
90 <option value="OVERDUEA">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 [% IF transaction_type == manualinv.authorised_value %]
125 <option value="[% manualinv.authorised_value | html %]" selected="selected">[% manualinv.authorised_value | html %]</option>
127 <option value="[% manualinv.authorised_value | html %]">[% manualinv.authorised_value | html %]</option>
133 <label>Transaction library</label>
134 <select name="branch" id="branch">
135 <option value="ALL">All</option>
136 [% FOREACH branchloo IN branchloop %]
137 [% IF ( branchloo.selected ) %]
138 <option value="[% branchloo.branchcode | html %]" selected="selected">[% branchloo.branchname | html %]</option>
140 <option value="[% branchloo.branchcode | html %]">[% branchloo.branchname | html %]</option>
150 <fieldset class="rows">
151 <legend>Output</legend>
154 <label for="outputscreen">To screen into the browser: </label>
155 <input type="radio" checked="checked" name="output" id="outputscreen" value="screen" />
158 <label for="outputfile">To a file:</label>
159 <input type="radio" name="output" value="file" id="outputfile" />
160 <label class="inline" for="basename">Named: </label><input type="text" name="basename" id="basename" value="Export" />
166 <fieldset class="action">
167 <input type="submit" value="Submit" name="do_it" />
173 <table id="tbl_cash_register_stats">
176 <th>Manager name</th>
177 <th>Patron card number</th>
179 <th>Transaction branch</th>
180 <th>Transaction date</th>
181 <th>Transaction type</th>
184 <th>Bibliographic record title</th>
189 [% FOREACH loopresul IN loopresult %]
191 <td>[% loopresul.mfirstname | html %] [% loopresul.msurname | html %]</td>
192 <td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% loopresul.borrowernumber | uri %]">[% loopresul.cardnumber | html %]</a></td>
193 <td>[% loopresul.bfirstname | html %] [% loopresul.bsurname | html %]</td>
194 <td>[% loopresul.branchname | html %]</td>
195 <td>[% loopresul.date | $KohaDates %]</td>
197 [% IF loopresul.accounttype == "ACT" %]
198 <span>All payments to the library</span>
199 [% ELSIF loopresul.accounttype == "C" || loopresul.accounttype == "CR" %]
201 [% ELSIF loopresul.accounttype == "FORW" || loopresul.accounttype == "W" %]
202 <span>Write off</span>
203 [% ELSIF loopresul.accounttype == "OVERDUE" && loopresul.status != "UNRETURNED" %]
205 [% ELSIF loopresul.accounttype == "OVERDUE" && loopresul.status == "UNRETURNED" %]
206 <span>Accruing fine</span>
207 [% ELSIF loopresul.accounttype == "Pay" %]
209 [% ELSIF loopresul.accounttype == "A" %]
210 <span>Account management fee</span>
211 [% ELSIF loopresul.accounttype == "M" %]
213 [% ELSIF loopresul.accounttype == "L" || loopresul.accounttype == "LR" %]
214 <span>Lost item</span>
215 [% ELSIF loopresul.accounttype == "N" %]
216 <span>New card</span>
218 [% FOREACH manualinv IN manualinv_types %]
219 [% value_manualinv = manualinv.authorised_value|truncate(5, '') %]
220 [% IF loopresul.accounttype == value_manualinv %]
221 <span>[% manualinv.authorised_value | html %]</span>
227 <td>[% loopresul.note | html %]</td>
228 <td style="text-align:right;">[% loopresul.amount | $Price %]</td>
229 <td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% loopresul.biblionumber | uri %]">[% loopresul.title | html %]</a></td>
230 <td>[% loopresul.barcode | html %]</td>
231 <td>[% ItemTypes.GetDescription(loopresul.itype) | html %]</td>
236 [% IF transaction_type == "ACT" %]
237 <th colspan="7" style="text-align:right;">TOTAL</th>
238 <th style="text-align:right;">[% total | $Price %]</th>
239 <th colspan="3"> </th>
245 [% END %] [%# do_it %]
248 </div> <!-- /.col-sm-10.col-sm-push-2 -->
250 <div class="col-sm-2 col-sm-pull-10">
252 [% INCLUDE 'reports-menu.inc' %]
254 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
255 </div> <!-- /.row -->
257 [% MACRO jsinclude BLOCK %]
258 [% INCLUDE 'datatables.inc' %]
260 $(document).ready(function() {
261 $("#tbl_cash_register_stats").dataTable($.extend(true, {}, dataTablesDefaults, {
262 "iDisplayLength": 50,
263 "sPaginationType": "full_numbers"
267 [% INCLUDE 'calendar.inc' %]
271 $(document).ready(function() {
272 // http://jqueryui.com/demos/datepicker/#date-range
273 var dates = $( "#filter_date_begin, #filter_date_end" ).datepicker({
276 onSelect: function( selectedDate ) {
277 var option = this.id == "filter_date_begin" ? "minDate" : "maxDate",
278 instance = $( this ).data( "datepicker" );
279 date = $.datepicker.parseDate(
280 instance.settings.dateFormat ||
281 $.datepicker._defaults.dateFormat,
282 selectedDate, instance.settings );
283 dates.not( this ).datepicker( "option", option, date );
287 $('#frmCashRegister').submit(function() {
288 var isFormValid = true;
289 var alertString= _("Form not submitted because of the following problem(s)")+"\n";
291 alertString +="-------------------------------------------------------------------\n\n";
293 if ( !$('#from').val() || !$('#to').val()){
295 alertString += "\n- " + _("Dates cannot be empty");
307 [% INCLUDE 'intranet-bottom.inc' %]