1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha › Patrons › Collect fine payment for [% borrower.firstname %] [% borrower.surname %]</title>
3 [% INCLUDE 'doc-head-close.inc' %]
4 <script type= "text/javascript">
6 function moneyFormat(textObj) {
7 var newValue = textObj.value;
13 for(i=0; i < newValue.length; i++) {
14 aChar = newValue.substring(i, i+1);
15 if (aChar >= "0" && aChar <= "9") {
17 decAmount = "" + decAmount + aChar;
20 dolAmount = "" + dolAmount + aChar;
32 if (dolAmount == "") {
36 if (dolAmount.length > 1) {
37 while(dolAmount.length > 1 && dolAmount.substring(0,1) == "0") {
38 dolAmount = dolAmount.substring(1,dolAmount.length);
41 if (decAmount.length > 2) {
42 decAmount = decAmount.substring(0,2);
45 if (decAmount.length == 1) {
46 decAmount = decAmount + "0";
48 if (decAmount.length == 0) {
49 decAmount = decAmount + "00";
52 textObj.value = dolAmount + "." + decAmount;
57 <body id="pat_paycollect" class="pat">
58 [% INCLUDE 'header.inc' %]
59 [% INCLUDE 'patron-search.inc' %]
60 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/members/members-home.pl">Patrons</a> › <a href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% borrower.borrowernumber %]">Pay fines for [% borrower.firstname %] [% borrower.surname %]</a> › [% IF ( pay_individual ) %]Pay an individual fine[% ELSIF ( writeoff_individual ) %]Write off an individual fine[% ELSE %][% IF ( selected_accts ) %]Pay an amount toward selected fines[% ELSE %]Pay an amount toward all fines[% END %][% END %]</div>
62 <div id="doc3" class="yui-t2">
67 [% INCLUDE 'members-toolbar.inc' borrowernumber=borrower.borrowernumber %]
70 <!-- The manual invoice and credit buttons -->
71 <div class="statictabs">
74 <a href="/cgi-bin/koha/members/boraccount.pl?borrowernumber=[% borrower.borrowernumber %]">Account</a>
77 <a href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% borrower.borrowernumber %]" >Pay fines</a>
80 <a href="/cgi-bin/koha/members/maninvoice.pl?borrowernumber=[% borrower.borrowernumber %]" >Create manual invoice</a>
83 <a href="/cgi-bin/koha/members/mancredit.pl?borrowernumber=[% borrower.borrowernumber %]" >Create manual credit</a>
86 <div class="tabs-container">
88 <div id="error_message" class="dialog alert">
93 [% IF ( pay_individual ) %]
94 <form name="payindivfine" onsubmit="return validatePayment(this);" method="post" action="/cgi-bin/koha/members/paycollect.pl">
95 <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% borrower.borrowernumber %]" />
96 <input type="hidden" name="pay_individual" id="pay_individual" value="[% pay_individual %]" />
97 <input type="hidden" name="itemnumber" id="itemnumber" value="[% itemnumber %]" />
98 <input type="hidden" name="description" id="description" value="[% description %]" />
99 <input type="hidden" name="accounttype" id="accounttype" value="[% accounttype %]" />
100 <input type="hidden" name="notify_id" id="notify_id" value="[% notify_id %]" />
101 <input type="hidden" name="notify_level" id="notify_level" value="[% notify_level %]" />
102 <input type="hidden" name="amount" id="amount" value="[% amount %]" />
103 <input type="hidden" name="amountoutstanding" id="amountoutstanding" value="[% amountoutstanding %]" />
104 <input type="hidden" name="accountno" id="accountno" value="[% accountno %]" />
105 <input type="hidden" name="accountlines_id" id="accountlines_id" value="[% accountlines_id %]" />
106 <input type="hidden" name="title" id="title" value="[% title %]" />
108 <fieldset class="rows">
109 <legend>Pay an individual fine</legend>
113 <th>Account type</th>
117 <th>Amount outstanding</th>
120 <td colspan="5">Total amount payable:</td><td>[% amountoutstanding | format('%.2f') %]</td>
124 [% description %] [% title %]
126 <td>[% accounttype %]</td>
127 <td>[% notify_id %]</td>
128 <td>[% notify_level %]</td>
129 <td class="debit">[% amount | format('%.2f') %]</td>
130 <td class="debit">[% amountoutstanding | format('%.2f') %]</td>
137 <label for="paid">Collect from patron: </label>
138 <!-- default to paying all -->
139 <input name="paid" id="paid" value="[% amountoutstanding | format('%.2f') %]" onchange="moneyFormat(document.payindivfine.paid)"/>
144 <div class="action"><input type="submit" name="submitbutton" value="Confirm" />
145 <a class="cancel" href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% borrower.borrowernumber %]">Cancel</a></div>
147 [% ELSIF ( writeoff_individual ) %]
148 <form name="woindivfine" action="/cgi-bin/koha/members/pay.pl" method="post" >
149 <fieldset class="rows">
150 <legend>Write off an individual fine</legend>
151 <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% borrower.borrowernumber %]" />
152 <input type="hidden" name="pay_individual" id="pay_individual" value="[% pay_individual %]" />
153 <input type="hidden" name="itemnumber" id="itemnumber" value="[% itemnumber %]" />
154 <input type="hidden" name="description" id="description" value="[% description %]" />
155 <input type="hidden" name="accounttype" id="accounttype" value="[% accounttype %]" />
156 <input type="hidden" name="notify_id" id="notify_id" value="[% notify_id %]" />
157 <input type="hidden" name="notify_level" id="notify_level" value="[% notify_level %]" />
158 <input type="hidden" name="amount" id="amount" value="[% amount %]" />
159 <input type="hidden" name="amountoutstanding" id="amountoutstanding" value="[% amountoutstanding %]" />
160 <input type="hidden" name="accountno" id="accountno" value="[% accountno %]" />
161 <input type="hidden" name="accountlines_id" id="accountlines_id" value="[% accountlines_id %]" />
162 <input type="hidden" name="title" id="title" value="[% title %]" />
166 <th>Account type</th>
170 <th>Amount outstanding</th>
172 <tfoot><td colspan="5">Total amount to be written off:</td><td>[% amountoutstanding | format('%.2f') %]</td></tfoot>
174 <td>[% description %] [% title %]</td>
175 <td>[% accounttype %]</td>
176 <td>[% notify_id %]</td>
177 <td>[% notify_level %]</td>
178 <td class="debit">[% amount | format('%.2f') %]</td>
179 <td class="debit">[% amountoutstanding | format('%.2f') %]</td>
183 <div class="action"><input type="submit" name="confirm_writeoff" id="confirm_writeoff" value="Write off this charge" />
184 <a class="cancel" href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% borrower.borrowernumber %]">Cancel</a></div>
188 <form name="payfine" onsubmit="return validatePayment(this);" method="post" action="/cgi-bin/koha/members/paycollect.pl">
189 <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% borrower.borrowernumber %]" />
190 <input type="hidden" name="selected_accts" id="selected_accts" value="[% selected_accts %]" />
191 <input type="hidden" name="total" id="total" value="[% total %]" />
193 <fieldset class="rows">
194 [% IF ( selected_accts ) %]<legend>Pay an amount toward selected fines</legend>[% ELSE %]<legend>Pay an amount toward all fines</legend>[% END %]
197 <span class="label">Total amount outstanding: </span>
198 <span class="debit">[% total | format('%.2f') %]</span>
201 <label for="paid">Collect from patron: </label>
202 <!-- default to paying all -->
203 <input name="paid" id="paid" value="[% total | format('%.2f') %]" onchange="moneyFormat(document.payfine.paid)"/>
207 <div class="action"><input type="submit" name="submitbutton" value="Confirm" />
208 <a class="cancel" href="/cgi-bin/koha/members/boraccount.pl?borrowernumber=[% borrower.borrowernumber %]">Cancel</a></div>
216 [% INCLUDE 'circ-menu.tt' %]
219 [% INCLUDE 'intranet-bottom.inc' %]