|
Lines 58-100
Link Here
|
| 58 |
</head> |
58 |
</head> |
| 59 |
<body id="sco_main" class="sco"> |
59 |
<body id="sco_main" class="sco"> |
| 60 |
|
60 |
|
| 61 |
[% INCLUDE 'masthead-sco.inc' %] |
61 |
[% INCLUDE 'masthead-sco.inc' %] |
| 62 |
|
62 |
|
| 63 |
<main class="main"> |
63 |
<main class="main"> |
| 64 |
[% IF ( display_patron_image ) %] |
64 |
[% IF ( display_patron_image ) %] |
| 65 |
[% SET main_div_class = 'col-10 order-first order-md-first order-lg-2' %] |
65 |
[% SET main_div_class = 'col-10 order-first order-md-first order-lg-2' %] |
| 66 |
[% ELSE %] |
66 |
[% ELSE %] |
| 67 |
[% SET main_div_class = 'col order-first order-md-first order-lg-2' %] |
67 |
[% SET main_div_class = 'col order-first order-md-first order-lg-2' %] |
| 68 |
[% END %] |
68 |
[% END %] |
| 69 |
|
69 |
|
| 70 |
[% UNLESS ( hide_main ) %] |
70 |
[% UNLESS ( hide_main ) %] |
| 71 |
[% IF ( validuser ) %] |
71 |
[% IF ( validuser ) %] |
| 72 |
<div class="container-fluid"> |
72 |
<div class="container-fluid"> |
| 73 |
<div class="row"> |
73 |
<div class="row"> |
| 74 |
<div class="[% main_div_class | html %]"> |
74 |
<div class="[% main_div_class | html %]"> |
| 75 |
<div id="masthead"><h1>[% LibraryName | html %] Self-checkout system</h1></div> |
75 |
<div id="masthead"><h1>[% LibraryName | html %] Self-checkout system</h1></div> |
| 76 |
|
76 |
|
| 77 |
[% PROCESS display_errors %] |
77 |
[% PROCESS display_errors %] |
| 78 |
|
78 |
|
| 79 |
<div class="alert alert-info">You are logged in as [% borrowername | html %].</div> |
79 |
<div class="alert alert-info">You are logged in as [% borrowername | html %].</div> |
| 80 |
[% INCLUDE 'opac-note.inc' sco="true" %] |
80 |
[% INCLUDE 'opac-note.inc' sco="true" %] |
| 81 |
[% IF patron_has_hold_fee %] |
81 |
[% IF patron_has_hold_fee %] |
| 82 |
<div class="alert alert-warning">A hold fee was charged to your account for collecting this item.</div> |
82 |
<div class="alert alert-warning">A hold fee was charged to your account for collecting this item.</div> |
| 83 |
[% END %] |
83 |
[% END %] |
| 84 |
|
84 |
|
| 85 |
<div id="newcheckout" class="sco_entry"> |
85 |
<div id="newcheckout" class="sco_entry"> |
| 86 |
<form id="scan_form" name="scan_form" method="post" action="/cgi-bin/koha/sco/sco-main.pl"> |
86 |
<form id="scan_form" name="scan_form" method="post" action="/cgi-bin/koha/sco/sco-main.pl"> |
| 87 |
[% INCLUDE 'csrf-token.inc' %] |
87 |
[% INCLUDE 'csrf-token.inc' %] |
| 88 |
<fieldset class="mb-3"> |
88 |
<fieldset class="mb-3"> |
| 89 |
<legend> |
89 |
<legend> |
| 90 |
<h2> |
90 |
<h2> |
| 91 |
[% IF ( Koha.Preference('SCOAllowCheckin') ) %] |
91 |
[% IF ( Koha.Preference('SCOAllowCheckin') ) %] |
| 92 |
<span>Check out, return, or renew an item:</span> |
92 |
<span>Check out, return, or renew an item:</span> |
| 93 |
[% ELSE %] |
93 |
[% ELSE %] |
| 94 |
<span>Check out or renew an item:</span> |
94 |
<span>Check out or renew an item:</span> |
| 95 |
[% END %] |
95 |
[% END %] |
| 96 |
</h2> |
96 |
</h2> |
| 97 |
</legend> |
97 |
</legend> |
| 98 |
<div class="row"> |
98 |
<div class="row"> |
| 99 |
<div class="col"> |
99 |
<div class="col"> |
| 100 |
<label for="barcode">Scan a new item or enter its barcode[% IF batch_checkouts_allowed %](or for <b>multiple checkouts only,</b> enter a barcode list, one barcode per line)[% END %]:</label> |
100 |
<label for="barcode">Scan a new item or enter its barcode[% IF batch_checkouts_allowed %](or for <b>multiple checkouts only,</b> enter a barcode list, one barcode per line)[% END %]:</label> |
|
Lines 118-386
Link Here
|
| 118 |
</div> |
118 |
</div> |
| 119 |
</div> |
119 |
</div> |
| 120 |
<!-- /.row --> |
120 |
<!-- /.row --> |
| 121 |
</fieldset> |
121 |
</fieldset> |
| 122 |
</form> |
122 |
</form> |
| 123 |
<!-- /#scan_form --> |
123 |
<!-- /#scan_form --> |
| 124 |
</div> |
|
|
| 125 |
<!-- / #newcheckout --> |
| 126 |
</div> |
124 |
</div> |
| 127 |
<!-- / .span12/12 --> |
125 |
<!-- / #newcheckout --> |
| 128 |
[% IF ( display_patron_image ) %] |
|
|
| 129 |
<div class="col-lg-2"> |
| 130 |
<img src="/cgi-bin/koha/sco/sco-patron-image.pl" alt="" /> |
| 131 |
</div> |
| 132 |
[% END %] |
| 133 |
</div> |
126 |
</div> |
| 134 |
<!-- / .row --> |
127 |
<!-- / .span12/12 --> |
| 135 |
|
128 |
[% IF ( display_patron_image ) %] |
| 136 |
<div class="row"> |
129 |
<div class="col-lg-2"> |
| 137 |
<div class="col order-first order-md-first order-lg-2"> |
130 |
<img src="/cgi-bin/koha/sco/sco-patron-image.pl" alt="" /> |
| 138 |
[% WRAPPER tabs id="checkouts" %] |
131 |
</div> |
| 139 |
[% WRAPPER tabs_nav %] |
132 |
[% END %] |
| 140 |
[% WRAPPER tab_item tabname= "checkouts" bt_active= 1 %] |
133 |
</div> |
| 141 |
<span>Checkouts ([% issues_count | html %])</span> |
134 |
<!-- / .row --> |
|
|
135 |
|
| 136 |
<div class="row"> |
| 137 |
<div class="col order-first order-md-first order-lg-2"> |
| 138 |
[% WRAPPER tabs id="checkouts" %] |
| 139 |
[% WRAPPER tabs_nav %] |
| 140 |
[% WRAPPER tab_item tabname= "checkouts" bt_active= 1 %] |
| 141 |
<span>Checkouts ([% issues_count | html %])</span> |
| 142 |
[% END %] |
| 143 |
[% WRAPPER tab_item tabname= "holds" %] |
| 144 |
[% IF waiting_holds_count %] |
| 145 |
<i class="fa fa-exclamation-circle" aria-hidden="true"></i> |
| 142 |
[% END %] |
146 |
[% END %] |
| 143 |
[% WRAPPER tab_item tabname= "holds" %] |
147 |
<span>Holds</span> ([% HOLDS.count | html %]) |
| 144 |
[% IF waiting_holds_count %] |
148 |
[% END %] |
| 145 |
<i class="fa fa-exclamation-circle" aria-hidden="true"></i> |
149 |
[% WRAPPER tab_item tabname= "account" %] |
|
|
150 |
<span>Charges ([% total | $Price %])</span> |
| 151 |
[% END %] |
| 152 |
[% END # /WRAPPER tabs_nav %] |
| 153 |
|
| 154 |
[% WRAPPER tab_panels %] |
| 155 |
[% WRAPPER tab_panel tabname="checkouts" bt_active= 1 %] |
| 156 |
<div id="borrowerdetails"> |
| 157 |
[% IF ( new_issue ) %] |
| 158 |
<div class="lastchecked"> |
| 159 |
<p> |
| 160 |
<strong>Checked out: </strong> |
| 161 |
[% new_issue.item.biblio.title | html %] ([% new_issue.item.barcode | html %]). |
| 162 |
[% IF new_issue.item.is_bundle %] |
| 163 |
[% SET bundle_items_count = new_issue.item.bundle_items.count %] |
| 164 |
[% tnx('Bundle of {count} item', 'Bundle of {count} items', bundle_items_count, { count = bundle_items_count }) | html %]. |
| 165 |
[% END %] |
| 166 |
Due on [% new_issue.date_due | $KohaDates as_due_date => 1 %] |
| 167 |
</p> |
| 168 |
</div> |
| 146 |
[% END %] |
169 |
[% END %] |
| 147 |
<span>Holds</span> ([% HOLDS.count | html %]) |
170 |
[% IF ( issues_count ) %] |
| 148 |
[% END %] |
171 |
[% IF ( Koha.Preference('SCOLoadCheckoutsByDefault') || load_checkouts ) %] |
| 149 |
[% WRAPPER tab_item tabname= "account" %] |
172 |
<table id="loanTable" class="table table-bordered table-striped"> |
| 150 |
<span>Charges ([% total | $Price %])</span> |
173 |
<caption>Checkouts for [% borrowername | html %] <span class="count">([% issues_count | html %] total)</span></caption> |
| 151 |
[% END %] |
174 |
<!-- ISSUES TABLE ROWS --> |
| 152 |
[% END # /WRAPPER tabs_nav %] |
175 |
<thead> |
| 153 |
|
176 |
<tr> |
| 154 |
[% WRAPPER tab_panels %] |
177 |
<th class="noshow">Checked out on</th> |
| 155 |
[% WRAPPER tab_panel tabname="checkouts" bt_active= 1 %] |
178 |
<th class="all anti-the">Title</th> |
| 156 |
<div id="borrowerdetails"> |
179 |
<th>Call number</th> |
| 157 |
[% IF ( new_issue ) %] |
180 |
<th class="psort">Due</th> |
| 158 |
<div class="lastchecked"> |
181 |
<th class="all no-sort">Renew</th> |
| 159 |
<p> |
182 |
[% IF Koha.Preference('SCOAllowCheckin') %] |
| 160 |
<strong>Checked out: </strong> |
183 |
<th class="all no-sort">Check in</th> |
| 161 |
[% new_issue.item.biblio.title | html %] ([% new_issue.item.barcode | html %]). |
|
|
| 162 |
[% IF new_issue.item.is_bundle %] |
| 163 |
[% SET bundle_items_count = new_issue.item.bundle_items.count %] |
| 164 |
[% tnx('Bundle of {count} item', 'Bundle of {count} items', bundle_items_count, { count = bundle_items_count }) | html %]. |
| 165 |
[% END %] |
184 |
[% END %] |
| 166 |
Due on [% new_issue.date_due | $KohaDates as_due_date => 1 %] |
185 |
[% UNLESS ( nofines ) %] |
| 167 |
</p> |
186 |
<th>Fines</th> |
| 168 |
</div> |
187 |
[% END %] |
| 169 |
[% END %] |
188 |
<th class="dtr-control-col"></th> |
| 170 |
[% IF ( issues_count ) %] |
189 |
</tr> |
| 171 |
[% IF ( Koha.Preference('SCOLoadCheckoutsByDefault') || load_checkouts ) %] |
190 |
</thead> |
| 172 |
<table id="loanTable" class="table table-bordered table-striped"> |
191 |
<tbody> |
| 173 |
<caption>Checkouts for [% borrowername | html %] <span class="count">([% issues_count | html %] total)</span></caption> |
192 |
[% FOREACH ISSUE IN ISSUES %] |
| 174 |
<!-- ISSUES TABLE ROWS --> |
193 |
<tr> |
| 175 |
<thead> |
194 |
<td>[% ISSUE.issuedate | html %]</td> |
| 176 |
<tr> |
195 |
<td> |
| 177 |
<th class="noshow">Checked out on</th> |
196 |
[% UNLESS ( noitemlinks ) %] |
| 178 |
<th class="all anti-the">Title</th> |
197 |
<a href="/cgi-bin/koha/opac-detail.pl?bib=[% ISSUE. biblionumber | uri %]">[% ISSUE.title | html %]</a> |
| 179 |
<th>Call number</th> |
198 |
[% ELSE %] |
| 180 |
<th class="psort">Due</th> |
199 |
<strong>[% ISSUE.title | html %]</strong> |
| 181 |
<th class="all no-sort">Renew</th> |
|
|
| 182 |
[% IF Koha.Preference('SCOAllowCheckin') %] |
| 183 |
<th class="all no-sort">Check in</th> |
| 184 |
[% END %] |
200 |
[% END %] |
| 185 |
[% UNLESS ( nofines ) %] |
201 |
[% IF ( newissues.match(ISSUE.barcode)) %] |
| 186 |
<th>Fines</th> |
202 |
<span class="badge text-bg-info">NEW</span> |
| 187 |
[% END %] |
203 |
[% END %] |
| 188 |
<th class="dtr-control-col"></th> |
204 |
<span class="item-details">[% ISSUE.author | html %]</span> |
| 189 |
</tr> |
205 |
([% ISSUE.barcode | html %]) |
| 190 |
</thead> |
206 |
</td> |
| 191 |
<tbody> |
207 |
<td>[% ISSUE.itemcallnumber | html %]</td> |
| 192 |
[% FOREACH ISSUE IN ISSUES %] |
208 |
[% IF ( ISSUE.overdue ) %] |
| 193 |
<tr> |
209 |
<td class="overdue" data-order="[% ISSUE.date_due | html %]"> [% ISSUE.date_due | $KohaDates as_due_date => 1 %] </td> |
| 194 |
<td>[% ISSUE.issuedate | html %]</td> |
210 |
[% ELSE %] |
| 195 |
<td> |
211 |
<td data-order="[% ISSUE.date_due | html %]"> [% ISSUE.date_due | $KohaDates as_due_date => 1 %] </td> |
| 196 |
[% UNLESS ( noitemlinks ) %] |
212 |
[% END %] |
| 197 |
<a href="/cgi-bin/koha/opac-detail.pl?bib=[% ISSUE. biblionumber | uri %]">[% ISSUE.title | html %]</a> |
213 |
<td> |
|
|
214 |
<form action="/cgi-bin/koha/sco/sco-main.pl" method="post"> |
| 215 |
[% INCLUDE 'csrf-token.inc' %] |
| 216 |
<fieldset> |
| 217 |
<legend class="sr-only">Issue renews</legend> |
| 218 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 219 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 220 |
<input type="hidden" name="barcode" value="[% ISSUE.barcode | html %]" /> |
| 221 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 222 |
[% IF ISSUE.can_be_renewed %] |
| 223 |
<input type="hidden" name="op" value="cud-renew" /> |
| 224 |
<input type="hidden" name="confirmed" value="1" /> |
| 225 |
[% UNLESS ( ISSUE.renew ) %] |
| 226 |
<input type="submit" value="Renew item" name="confirm " class="btn btn-primary btn-sm renew" /> |
| 227 |
[% ELSE %] |
| 228 |
<input type="submit" value="Renew item" class="btn btn-primary btn-sm renew" /> |
| 229 |
[% END %] |
| 198 |
[% ELSE %] |
230 |
[% ELSE %] |
| 199 |
<strong>[% ISSUE.title | html %]</strong> |
231 |
[% IF ISSUE.renew_error == 'onsite_checkout' %] |
|
|
232 |
<span>This is a on-site checkout, it cannot be renewed.</span> |
| 233 |
[% ELSIF ISSUE.renew_error == 'too_unseen' %] |
| 234 |
<span>You have renewed this item the maximum number of consecutive times without it being seen by the library.</span> |
| 235 |
[% ELSIF ISSUE.renew_error == 'too_soon' %] |
| 236 |
<span>This item cannot yet be renewed.</span> |
| 237 |
[% ELSE %] |
| 238 |
<span>No renewals allowed</span> |
| 239 |
[% END %] |
| 200 |
[% END %] |
240 |
[% END %] |
| 201 |
[% IF ( newissues.match(ISSUE.barcode)) %] |
241 |
[% IF ISSUE.auto_renew %] |
| 202 |
<span class="badge text-bg-info">NEW</span> |
242 |
<br /><span>This item is scheduled for automatic renewal</span> |
| 203 |
[% END %] |
243 |
[% END %] |
| 204 |
<span class="item-details">[% ISSUE.author | html %]</span> |
244 |
</fieldset> |
| 205 |
([% ISSUE.barcode | html %]) |
245 |
</form> |
| 206 |
</td> |
246 |
</td> |
| 207 |
<td>[% ISSUE.itemcallnumber | html %]</td> |
247 |
[% IF Koha.Preference('SCOAllowCheckin') %] |
| 208 |
[% IF ( ISSUE.overdue ) %] |
248 |
<td> |
| 209 |
<td class="overdue" data-order="[% ISSUE.date_due | html %]"> [% ISSUE.date_due | $KohaDates as_due_date => 1 %] </td> |
249 |
<form action="/cgi-bin/koha/sco/sco-main.pl" method="post"> |
| 210 |
[% ELSE %] |
250 |
[% INCLUDE 'csrf-token.inc' %] |
| 211 |
<td data-order="[% ISSUE.date_due | html %]"> [% ISSUE.date_due | $KohaDates as_due_date => 1 %] </td> |
251 |
<fieldset> |
| 212 |
[% END %] |
|
|
| 213 |
<td> |
| 214 |
<form action="/cgi-bin/koha/sco/sco-main.pl" method="post"> |
| 215 |
[% INCLUDE 'csrf-token.inc' %] |
| 216 |
<fieldset> |
| 217 |
<legend class="sr-only">Issue renews</legend> |
252 |
<legend class="sr-only">Issue renews</legend> |
| 218 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
253 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 219 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
254 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 220 |
<input type="hidden" name="barcode" value="[% ISSUE.barcode | html %]" /> |
255 |
<input type="hidden" name="barcode" value="[% ISSUE.barcode | html %]" /> |
| 221 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
256 |
<input type="submit" value="Check in item" name="confirm" class="btn btn-info btn-sm return" /> |
| 222 |
[% IF ISSUE.can_be_renewed %] |
257 |
<input type="hidden" name="op" value="cud-returnbook" /> |
| 223 |
<input type="hidden" name="op" value="cud-renew" /> |
258 |
<input type="hidden" name="confirmed" value="" /> |
| 224 |
<input type="hidden" name="confirmed" value="1" /> |
259 |
</fieldset> |
| 225 |
[% UNLESS ( ISSUE.renew ) %] |
260 |
</form> |
| 226 |
<input type="submit" value="Renew item" name="confirm " class="btn btn-primary btn-sm renew" /> |
261 |
</td> |
| 227 |
[% ELSE %] |
262 |
[% END %] |
| 228 |
<input type="submit" value="Renew item" class="btn btn-primary btn-sm renew" /> |
263 |
[% UNLESS ( nofines ) %] |
| 229 |
[% END %] |
264 |
<td> [% IF ( ISSUE.charges ) %]Yes[% ELSE %]No[% END %] </td> |
| 230 |
[% ELSE %] |
265 |
[% END %] |
| 231 |
[% IF ISSUE.renew_error == 'onsite_checkout' %] |
266 |
<td></td> |
| 232 |
<span>This is a on-site checkout, it cannot be renewed.</span> |
267 |
</tr> |
| 233 |
[% ELSIF ISSUE.renew_error == 'too_unseen' %] |
268 |
[% END # / FOREACH ISSUE %] |
| 234 |
<span>You have renewed this item the maximum number of consecutive times without it being seen by the library.</span> |
269 |
</tbody> |
| 235 |
[% ELSIF ISSUE.renew_error == 'too_soon' %] |
270 |
</table> |
| 236 |
<span>This item cannot yet be renewed.</span> |
271 |
[% ELSE %] |
| 237 |
[% ELSE %] |
272 |
<a class="btn btn-secondary" href="?load_checkouts=1#scan_form"><i class="fa fa-book" aria-hidden="true"></i> Show your checkouts</a> |
| 238 |
<span>No renewals allowed</span> |
273 |
[% END # / IF ( Koha.preference('SCOLoadCheckoutsByDefault') || load_checkouts ) %] |
| 239 |
[% END %] |
|
|
| 240 |
[% END %] |
| 241 |
[% IF ISSUE.auto_renew %] |
| 242 |
<br /><span>This item is scheduled for automatic renewal</span> |
| 243 |
[% END %] |
| 244 |
</fieldset> |
| 245 |
</form> |
| 246 |
</td> |
| 247 |
[% IF Koha.Preference('SCOAllowCheckin') %] |
| 248 |
<td> |
| 249 |
<form action="/cgi-bin/koha/sco/sco-main.pl" method="post"> |
| 250 |
[% INCLUDE 'csrf-token.inc' %] |
| 251 |
<fieldset> |
| 252 |
<legend class="sr-only">Issue renews</legend> |
| 253 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 254 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 255 |
<input type="hidden" name="barcode" value="[% ISSUE.barcode | html %]" /> |
| 256 |
<input type="submit" value="Check in item" name="confirm" class="btn btn-info btn-sm return" /> |
| 257 |
<input type="hidden" name="op" value="cud-returnbook" /> |
| 258 |
<input type="hidden" name="confirmed" value="" /> |
| 259 |
</fieldset> |
| 260 |
</form> |
| 261 |
</td> |
| 262 |
[% END %] |
| 263 |
[% UNLESS ( nofines ) %] |
| 264 |
<td> [% IF ( ISSUE.charges ) %]Yes[% ELSE %]No[% END %] </td> |
| 265 |
[% END %] |
| 266 |
<td></td> |
| 267 |
</tr> |
| 268 |
[% END # / FOREACH ISSUE %] |
| 269 |
</tbody> |
| 270 |
</table> |
| 271 |
[% ELSE %] |
| 272 |
<a class="btn btn-secondary" href="?load_checkouts=1#scan_form"><i class="fa fa-book" aria-hidden="true"></i> Show your checkouts</a> |
| 273 |
[% END # / IF ( Koha.preference('SCOLoadCheckoutsByDefault') || load_checkouts ) %] |
| 274 |
[% ELSE %] |
| 275 |
<h3>You currently have nothing checked out.</h3> |
| 276 |
[% END # / IF issues_count %] |
| 277 |
</div> |
| 278 |
<!-- / #borrowerdetails --> |
| 279 |
[% END # /tab_panel %] |
| 280 |
[% WRAPPER tab_panel tabname="holds" %] |
| 281 |
[% IF HOLDS.count > 0 %] |
| 282 |
[% PROCESS 'holds-table.inc' HOLDS = HOLDS, SuspendHoldsOpac = SuspendHoldsOpac, showpriority = showpriority, AutoResumeSuspendedHolds = AutoResumeSuspendedHolds, onlyinfo = 'true' %] |
| 283 |
[% ELSE %] |
274 |
[% ELSE %] |
| 284 |
<h3>You currently have no pending holds.</h3> |
275 |
<h3>You currently have nothing checked out.</h3> |
| 285 |
[% END %] |
276 |
[% END # / IF issues_count %] |
| 286 |
[% END # /tab_panel %] |
277 |
</div> |
| 287 |
[% WRAPPER tab_panel tabname="account" %] |
278 |
<!-- / #borrowerdetails --> |
| 288 |
[% PROCESS 'account-table.inc' %] |
279 |
[% END # /tab_panel %] |
| 289 |
[% END # /tab_panel %] |
280 |
[% WRAPPER tab_panel tabname="holds" %] |
| 290 |
[% END # /WRAPPER tab_panels %] |
281 |
[% IF HOLDS.count > 0 %] |
| 291 |
[% END # /WRAPPER tabs %] |
282 |
[% PROCESS 'holds-table.inc' HOLDS = HOLDS, SuspendHoldsOpac = SuspendHoldsOpac, showpriority = showpriority, AutoResumeSuspendedHolds = AutoResumeSuspendedHolds, onlyinfo = 'true' %] |
| 292 |
|
283 |
[% ELSE %] |
| 293 |
[% IF ( SCOMainUserBlock ) %] |
284 |
<h3>You currently have no pending holds.</h3> |
| 294 |
<div id="scomainuserblock"> [% PROCESS koha_news_block news => SCOMainUserBlock %] </div> |
285 |
[% END %] |
| 295 |
[% END %] |
286 |
[% END # /tab_panel %] |
| 296 |
</div> |
287 |
[% WRAPPER tab_panel tabname="account" %] |
| 297 |
<!-- / .span12 --> |
288 |
[% PROCESS 'account-table.inc' %] |
| 298 |
</div> |
289 |
[% END # /tab_panel %] |
| 299 |
<!-- / .row --> |
290 |
[% END # /WRAPPER tab_panels %] |
| 300 |
</div> |
291 |
[% END # /WRAPPER tabs %] |
| 301 |
<!-- / .container-fluid --> |
292 |
|
| 302 |
[% ELSE # IF validuser %] |
293 |
[% IF ( SCOMainUserBlock ) %] |
| 303 |
<div class="container-fluid"> |
294 |
<div id="scomainuserblock"> [% PROCESS koha_news_block news => SCOMainUserBlock %] </div> |
| 304 |
<div class="row"> |
295 |
[% END %] |
| 305 |
<div class="[% main_div_class | html %]"> |
|
|
| 306 |
<div id="masthead"><h1>[% LibraryName | html %] Self-checkout system</h1></div> |
| 307 |
|
| 308 |
[% PROCESS display_errors %] |
| 309 |
|
| 310 |
[% IF patronid && nouser %] |
| 311 |
<div class="alert alert-warning"> |
| 312 |
<p |
| 313 |
>You entered an incorrect username or password. Please try again! But note that passwords are case sensitive. |
| 314 |
[% IF Koha.Preference('FailedLoginAttempts') %] |
| 315 |
Your account will be locked after a fixed number of failed login attempts. |
| 316 |
[% END %] |
| 317 |
Please contact a library staff member if you continue to have problems.</p |
| 318 |
> |
| 319 |
</div> |
| 320 |
[% END %] |
| 321 |
|
| 322 |
<div class="sco_entry"> |
| 323 |
<form id="mainform" action="/cgi-bin/koha/sco/sco-main.pl" name="mainform" method="post"> |
| 324 |
[% INCLUDE 'csrf-token.inc' %] |
| 325 |
<fieldset> |
| 326 |
<legend>Log in to your account</legend> |
| 327 |
<div class="row"> |
| 328 |
<div class="col-md-6"> |
| 329 |
[% IF ( Koha.Preference('SelfCheckoutByLogin') ) %] |
| 330 |
<div class="row"> |
| 331 |
<div class="col-md-12"> [% PROCESS login_label for="patronlogin" %] </div> |
| 332 |
<div class="col-md-12"> |
| 333 |
<input type="text" id="patronlogin" class="form-control focus noEnterSubmit" size="20" name="patronlogin" autocomplete="off" /> |
| 334 |
</div> |
| 335 |
<div class="col-md-12"> |
| 336 |
<label for="patronpw">Password:</label> |
| 337 |
</div> |
| 338 |
<div class="col-md-12"> |
| 339 |
<input type="password" id="patronpw" class="form-control" size="20" name="patronpw" autocomplete="off" /> |
| 340 |
</div> |
| 341 |
<div class="col-md-12"> |
| 342 |
<button type="submit" class="btn btn-primary">Log in</button> |
| 343 |
</div> |
| 344 |
</div> |
| 345 |
<!-- /.row --> |
| 346 |
[% ELSE %] |
| 347 |
<div class="row"> |
| 348 |
<div class="col-md-12"> |
| 349 |
<label for="patronid">Please enter your card number:</label> |
| 350 |
</div> |
| 351 |
<div class="col-md-12"> |
| 352 |
<input type="text" id="patronid" class="form-control focus" size="20" name="patronid" autocomplete="off" /> |
| 353 |
</div> |
| 354 |
<div class="col-md-12"> |
| 355 |
<button type="submit" class="btn btn-primary">Submit</button> |
| 356 |
</div> |
| 357 |
</div> |
| 358 |
<!-- /.row --> |
| 359 |
[% END %] |
| 360 |
</div> |
| 361 |
<!-- /.col-md-6 --> |
| 362 |
</div> |
| 363 |
<!-- /.row --> |
| 364 |
[% FOREACH INPUT IN INPUTS %] |
| 365 |
<input type="hidden" name="[% INPUT.name | html %]" value="[% INPUT.value | html %]" /> |
| 366 |
[% END %] |
| 367 |
<input type="hidden" name="op" value="cud-login" /> |
| 368 |
</fieldset> |
| 369 |
</form> |
| 370 |
<!-- /#mainform --> |
| 371 |
</div> |
| 372 |
<!-- / .sco_entry --> |
| 373 |
[% IF ( SCOMainUserBlock ) %] |
| 374 |
<div id="scomainuserblock"> [% PROCESS koha_news_block news => SCOMainUserBlock %] </div> |
| 375 |
[% END %] |
| 376 |
</div> |
| 377 |
<!-- / .span12 --> |
| 378 |
</div> |
296 |
</div> |
| 379 |
<!-- / .row --> |
297 |
<!-- / .span12 --> |
| 380 |
</div> |
298 |
</div> |
| 381 |
<!-- / .container-fluid --> |
299 |
<!-- / .row --> |
| 382 |
[% END # / IF validuser %] |
300 |
</div> |
| 383 |
[% ELSE # / UNLESS ( hide_main %] |
301 |
<!-- / .container-fluid --> |
|
|
302 |
[% ELSE # IF validuser %] |
| 384 |
<div class="container-fluid"> |
303 |
<div class="container-fluid"> |
| 385 |
<div class="row"> |
304 |
<div class="row"> |
| 386 |
<div class="[% main_div_class | html %]"> |
305 |
<div class="[% main_div_class | html %]"> |
|
Lines 388-393
Link Here
|
| 388 |
|
307 |
|
| 389 |
[% PROCESS display_errors %] |
308 |
[% PROCESS display_errors %] |
| 390 |
|
309 |
|
|
|
310 |
[% IF patronid && nouser %] |
| 311 |
<div class="alert alert-warning"> |
| 312 |
<p |
| 313 |
>You entered an incorrect username or password. Please try again! But note that passwords are case sensitive. |
| 314 |
[% IF Koha.Preference('FailedLoginAttempts') %] |
| 315 |
Your account will be locked after a fixed number of failed login attempts. |
| 316 |
[% END %] |
| 317 |
Please contact a library staff member if you continue to have problems.</p |
| 318 |
> |
| 319 |
</div> |
| 320 |
[% END %] |
| 321 |
|
| 322 |
<div class="sco_entry"> |
| 323 |
<form id="mainform" action="/cgi-bin/koha/sco/sco-main.pl" name="mainform" method="post"> |
| 324 |
[% INCLUDE 'csrf-token.inc' %] |
| 325 |
<fieldset> |
| 326 |
<legend>Log in to your account</legend> |
| 327 |
<div class="row"> |
| 328 |
<div class="col-md-6"> |
| 329 |
[% IF ( Koha.Preference('SelfCheckoutByLogin') ) %] |
| 330 |
<div class="row"> |
| 331 |
<div class="col-md-12"> [% PROCESS login_label for="patronlogin" %] </div> |
| 332 |
<div class="col-md-12"> |
| 333 |
<input type="text" id="patronlogin" class="form-control focus noEnterSubmit" size="20" name="patronlogin" autocomplete="off" /> |
| 334 |
</div> |
| 335 |
<div class="col-md-12"> |
| 336 |
<label for="patronpw">Password:</label> |
| 337 |
</div> |
| 338 |
<div class="col-md-12"> |
| 339 |
<input type="password" id="patronpw" class="form-control" size="20" name="patronpw" autocomplete="off" /> |
| 340 |
</div> |
| 341 |
<div class="col-md-12"> |
| 342 |
<button type="submit" class="btn btn-primary">Log in</button> |
| 343 |
</div> |
| 344 |
</div> |
| 345 |
<!-- /.row --> |
| 346 |
[% ELSE %] |
| 347 |
<div class="row"> |
| 348 |
<div class="col-md-12"> |
| 349 |
<label for="patronid">Please enter your card number:</label> |
| 350 |
</div> |
| 351 |
<div class="col-md-12"> |
| 352 |
<input type="text" id="patronid" class="form-control focus" size="20" name="patronid" autocomplete="off" /> |
| 353 |
</div> |
| 354 |
<div class="col-md-12"> |
| 355 |
<button type="submit" class="btn btn-primary">Submit</button> |
| 356 |
</div> |
| 357 |
</div> |
| 358 |
<!-- /.row --> |
| 359 |
[% END %] |
| 360 |
</div> |
| 361 |
<!-- /.col-md-6 --> |
| 362 |
</div> |
| 363 |
<!-- /.row --> |
| 364 |
[% FOREACH INPUT IN INPUTS %] |
| 365 |
<input type="hidden" name="[% INPUT.name | html %]" value="[% INPUT.value | html %]" /> |
| 366 |
[% END %] |
| 367 |
<input type="hidden" name="op" value="cud-login" /> |
| 368 |
</fieldset> |
| 369 |
</form> |
| 370 |
<!-- /#mainform --> |
| 371 |
</div> |
| 372 |
<!-- / .sco_entry --> |
| 391 |
[% IF ( SCOMainUserBlock ) %] |
373 |
[% IF ( SCOMainUserBlock ) %] |
| 392 |
<div id="scomainuserblock"> [% PROCESS koha_news_block news => SCOMainUserBlock %] </div> |
374 |
<div id="scomainuserblock"> [% PROCESS koha_news_block news => SCOMainUserBlock %] </div> |
| 393 |
[% END %] |
375 |
[% END %] |
|
Lines 397-730
Link Here
|
| 397 |
<!-- / .row --> |
379 |
<!-- / .row --> |
| 398 |
</div> |
380 |
</div> |
| 399 |
<!-- / .container-fluid --> |
381 |
<!-- / .container-fluid --> |
| 400 |
[% END # / UNLESS ( hide_main %] |
382 |
[% END # / IF validuser %] |
| 401 |
</main> |
383 |
[% ELSE # / UNLESS ( hide_main %] |
| 402 |
<!-- / .main --> |
384 |
<div class="container-fluid"> |
| 403 |
<span id="audio-alert"></span> |
385 |
<div class="row"> |
| 404 |
|
386 |
<div class="[% main_div_class | html %]"> |
| 405 |
[% INCLUDE 'opac-bottom.inc' %] |
387 |
<div id="masthead"><h1>[% LibraryName | html %] Self-checkout system</h1></div> |
| 406 |
[% BLOCK jsinclude %] |
|
|
| 407 |
[% INCLUDE 'datatables.inc' %] |
| 408 |
<script> |
| 409 |
function mungeHistory() { |
| 410 |
// prevent back button from allowing form resubmission |
| 411 |
if (history && history.pushState) { |
| 412 |
history.replaceState(null, document.title, window.location.href); |
| 413 |
} |
| 414 |
} |
| 415 |
var mainTimeout; |
| 416 |
function sco_init() { |
| 417 |
mainTimeout = setTimeout(function() { |
| 418 |
location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
| 419 |
}, [% SelfCheckTimeout | html %]); |
| 420 |
} |
| 421 |
function dofocus() { // named function req'd for body onload event by some FF and IE7 security models |
| 422 |
// alert("dofocus called"); |
| 423 |
$(".focus:last").select(); |
| 424 |
} |
| 425 |
var slip_re = /slip/; |
| 426 |
function printx_window(print_type) { |
| 427 |
var handler = print_type.match(slip_re) ? "printslip" : "moremember"; |
| 428 |
|
388 |
|
| 429 |
return false; |
389 |
[% PROCESS display_errors %] |
|
|
390 |
|
| 391 |
[% IF ( SCOMainUserBlock ) %] |
| 392 |
<div id="scomainuserblock"> [% PROCESS koha_news_block news => SCOMainUserBlock %] </div> |
| 393 |
[% END %] |
| 394 |
</div> |
| 395 |
<!-- / .span12 --> |
| 396 |
</div> |
| 397 |
<!-- / .row --> |
| 398 |
</div> |
| 399 |
<!-- / .container-fluid --> |
| 400 |
[% END # / UNLESS ( hide_main %] |
| 401 |
</main> |
| 402 |
<!-- / .main --> |
| 403 |
<span id="audio-alert"></span> |
| 404 |
|
| 405 |
[% INCLUDE 'opac-bottom.inc' %] |
| 406 |
[% BLOCK jsinclude %] |
| 407 |
[% INCLUDE 'datatables.inc' %] |
| 408 |
<script> |
| 409 |
function mungeHistory() { |
| 410 |
// prevent back button from allowing form resubmission |
| 411 |
if (history && history.pushState) { |
| 412 |
history.replaceState(null, document.title, window.location.href); |
| 430 |
} |
413 |
} |
| 431 |
function checkout_confirm(patronid) { |
414 |
} |
| 432 |
var barcode = $("#barcode").val(); |
415 |
var mainTimeout; |
| 433 |
// alert("checkout_confirm('" + patronid + "') called for barcode '" + barcode + "'"); |
416 |
function sco_init() { |
| 434 |
if (! barcode) { dofocus(); return false; } // no barcode |
417 |
mainTimeout = setTimeout(function() { |
| 435 |
if (barcode == "__KOHA_NEW_CIRC__") { // magic barcode |
418 |
location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
| 436 |
window.location.href='/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
419 |
}, [% SelfCheckTimeout | html %]); |
| 437 |
return false; |
420 |
} |
| 438 |
} |
421 |
function dofocus() { // named function req'd for body onload event by some FF and IE7 security models |
| 439 |
return true; |
422 |
// alert("dofocus called"); |
|
|
423 |
$(".focus:last").select(); |
| 424 |
} |
| 425 |
var slip_re = /slip/; |
| 426 |
function printx_window(print_type) { |
| 427 |
var handler = print_type.match(slip_re) ? "printslip" : "moremember"; |
| 428 |
|
| 429 |
return false; |
| 430 |
} |
| 431 |
function checkout_confirm(patronid) { |
| 432 |
var barcode = $("#barcode").val(); |
| 433 |
// alert("checkout_confirm('" + patronid + "') called for barcode '" + barcode + "'"); |
| 434 |
if (! barcode) { dofocus(); return false; } // no barcode |
| 435 |
if (barcode == "__KOHA_NEW_CIRC__") { // magic barcode |
| 436 |
window.location.href='/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
| 437 |
return false; |
| 440 |
} |
438 |
} |
| 441 |
[% IF Koha.Preference('AudioAlerts') %] |
439 |
return true; |
| 442 |
var AUDIO_ALERTS = JSON.parse( "[% To.json(AudioAlerts.AudioAlerts) | $raw %]" ); |
440 |
} |
| 443 |
$( document ).ready(function() { |
441 |
[% IF Koha.Preference('AudioAlerts') %] |
| 444 |
if ( AUDIO_ALERTS ) { |
442 |
var AUDIO_ALERTS = JSON.parse( "[% To.json(AudioAlerts.AudioAlerts) | $raw %]" ); |
| 445 |
for ( var k in AUDIO_ALERTS ) { |
443 |
$( document ).ready(function() { |
| 446 |
var alert = AUDIO_ALERTS[k]; |
444 |
if ( AUDIO_ALERTS ) { |
| 447 |
if ( $( alert.selector ).length ) { |
445 |
for ( var k in AUDIO_ALERTS ) { |
| 448 |
playSound( alert.sound ); |
446 |
var alert = AUDIO_ALERTS[k]; |
| 449 |
break; |
447 |
if ( $( alert.selector ).length ) { |
| 450 |
} |
448 |
playSound( alert.sound ); |
|
|
449 |
break; |
| 451 |
} |
450 |
} |
| 452 |
} |
451 |
} |
| 453 |
}); |
|
|
| 454 |
function playSound( sound ) { |
| 455 |
if (!(sound.indexOf("http://") === 0 || sound.indexOf("https://") === 0)) { |
| 456 |
sound = '[% interface | html %]' + '/bootstrap/sound/' + sound; |
| 457 |
} |
| 458 |
document.getElementById("audio-alert").innerHTML = '<audio src="' + sound + '" autoplay="autoplay" autobuffer="autobuffer"></audio>'; |
| 459 |
} |
452 |
} |
| 460 |
[% END %] |
|
|
| 461 |
|
| 462 |
$( window ).on( "load", function() { |
| 463 |
dofocus(); |
| 464 |
}); |
453 |
}); |
|
|
454 |
function playSound( sound ) { |
| 455 |
if (!(sound.indexOf("http://") === 0 || sound.indexOf("https://") === 0)) { |
| 456 |
sound = '[% interface | html %]' + '/bootstrap/sound/' + sound; |
| 457 |
} |
| 458 |
document.getElementById("audio-alert").innerHTML = '<audio src="' + sound + '" autoplay="autoplay" autobuffer="autobuffer"></audio>'; |
| 459 |
} |
| 460 |
[% END %] |
| 465 |
|
461 |
|
| 466 |
$( window ).on( "unload", function() { |
462 |
$( window ).on( "load", function() { |
| 467 |
mungeHistory(); |
463 |
dofocus(); |
| 468 |
}); |
464 |
}); |
| 469 |
|
465 |
|
| 470 |
$(document).ready(function() { |
466 |
$( window ).on( "unload", function() { |
| 471 |
dofocus(); |
467 |
mungeHistory(); |
| 472 |
[% IF ( patronid ) %]sco_init();[% END %] |
468 |
}); |
| 473 |
|
469 |
|
| 474 |
var dTables = $("#loanTable, #holdst, #finestable"); |
470 |
$(document).ready(function() { |
| 475 |
dTables.each(function(){ |
471 |
dofocus(); |
| 476 |
var thIndex = $(this).find("th.psort").index(); |
472 |
[% IF ( patronid ) %]sco_init();[% END %] |
| 477 |
$(this).kohaTable({ |
473 |
|
| 478 |
sorting: [[thIndex, "asc"]], |
474 |
var dTables = $("#loanTable, #holdst, #finestable"); |
| 479 |
dom: '<"top"<"table_entries"><"table_controls"f>>t<"clear">', |
475 |
dTables.each(function(){ |
| 480 |
columnDefs: [ |
476 |
var thIndex = $(this).find("th.psort").index(); |
| 481 |
{ targets: ["noshow"], visible: false, searchable: false }, |
477 |
$(this).kohaTable({ |
| 482 |
{ visible: false, targets: ["hidden"] }, |
478 |
sorting: [[thIndex, "asc"]], |
| 483 |
{ className: "dtr-control", orderable: false, targets: -1 }, |
479 |
dom: '<"top"<"table_entries"><"table_controls"f>>t<"clear">', |
| 484 |
], |
480 |
columnDefs: [ |
| 485 |
language: { |
481 |
{ targets: ["noshow"], visible: false, searchable: false }, |
| 486 |
search: "_INPUT_", |
482 |
{ visible: false, targets: ["hidden"] }, |
| 487 |
searchPlaceholder: _("Search"), |
483 |
{ className: "dtr-control", orderable: false, targets: -1 }, |
| 488 |
}, |
484 |
], |
| 489 |
responsive: { |
485 |
language: { |
| 490 |
details: { |
486 |
search: "_INPUT_", |
| 491 |
type: "column", |
487 |
searchPlaceholder: _("Search"), |
| 492 |
target: -1, |
488 |
}, |
| 493 |
}, |
489 |
responsive: { |
|
|
490 |
details: { |
| 491 |
type: "column", |
| 492 |
target: -1, |
| 494 |
}, |
493 |
}, |
| 495 |
}); |
494 |
}, |
| 496 |
}); |
495 |
}); |
|
|
496 |
}); |
| 497 |
|
497 |
|
| 498 |
$('a[data-bs-toggle="tab"]').on('shown.bs.tab', function (event) { |
498 |
$('a[data-bs-toggle="tab"]').on('shown.bs.tab', function (event) { |
| 499 |
dTables.DataTable().responsive.recalc(); |
499 |
dTables.DataTable().responsive.recalc(); |
| 500 |
} ); |
500 |
} ); |
| 501 |
|
501 |
|
| 502 |
$("#logout_form").on("click", function(e){ |
502 |
$("#logout_form").on("click", function(e){ |
| 503 |
e.preventDefault(e); |
503 |
e.preventDefault(e); |
| 504 |
clearTimeout(mainTimeout); |
504 |
clearTimeout(mainTimeout); |
| 505 |
[% IF Koha.Preference('SelfCheckReceiptPrompt') %] |
505 |
[% IF Koha.Preference('SelfCheckReceiptPrompt') %] |
| 506 |
confirmModal("", _("Would you like to print a receipt?"), _("Print receipt and end session"), _("End session"), function(result) { |
506 |
confirmModal("", _("Would you like to print a receipt?"), _("Print receipt and end session"), _("End session"), function(result) { |
| 507 |
if ( result ){ |
507 |
if ( result ){ |
| 508 |
var win = window.open("/cgi-bin/koha/sco/printslip.pl?print=qslip"); |
508 |
var win = window.open("/cgi-bin/koha/sco/printslip.pl?print=qslip"); |
| 509 |
location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
509 |
location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
| 510 |
} else { |
510 |
} else { |
| 511 |
location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
511 |
location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
| 512 |
} |
512 |
} |
| 513 |
}); |
513 |
}); |
| 514 |
[% ELSE %] |
514 |
[% ELSE %] |
| 515 |
location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
515 |
location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; |
| 516 |
[% END %] |
516 |
[% END %] |
| 517 |
|
517 |
|
| 518 |
return true; |
518 |
return true; |
| 519 |
}); |
519 |
}); |
| 520 |
|
520 |
|
| 521 |
$("#scan_form").on("submit", function(){ |
521 |
$("#scan_form").on("submit", function(){ |
| 522 |
return checkout_confirm('[% patronid | html %]'); |
522 |
return checkout_confirm('[% patronid | html %]'); |
| 523 |
}); |
523 |
}); |
| 524 |
}); |
524 |
}); |
|
|
525 |
</script> |
| 526 |
[% Asset.js("js/holds.js") | $raw %] |
| 527 |
[% IF ( Koha.Preference('SCOUserJS') ) %] |
| 528 |
<script> |
| 529 |
[% Koha.Preference('SCOUserJS') | $raw %] |
| 525 |
</script> |
530 |
</script> |
| 526 |
[% Asset.js("js/holds.js") | $raw %] |
|
|
| 527 |
[% IF ( Koha.Preference('SCOUserJS') ) %] |
| 528 |
<script> |
| 529 |
[% Koha.Preference('SCOUserJS') | $raw %] |
| 530 |
</script> |
| 531 |
[% END %] |
| 532 |
[% END %] |
531 |
[% END %] |
|
|
532 |
[% END %] |
| 533 |
|
533 |
|
| 534 |
[% BLOCK display_errors %] |
534 |
[% BLOCK display_errors %] |
| 535 |
[% FOREACH item IN impossible %] |
535 |
[% FOREACH item IN impossible %] |
| 536 |
<!-- We tried to issue, but failed. --> |
536 |
<!-- We tried to issue, but failed. --> |
| 537 |
<div class="alert alert-warning"> |
537 |
<div class="alert alert-warning"> |
| 538 |
<span class="sco-alert-warning noissue"></span> |
538 |
<span class="sco-alert-warning noissue"></span> |
| 539 |
<h2>Item cannot be checked out.</h2> |
539 |
<h2>Item cannot be checked out.</h2> |
| 540 |
<p>Sorry, this item cannot be checked out at this station.</p> |
540 |
<p>Sorry, this item cannot be checked out at this station.</p> |
| 541 |
[% IF ( item.title ) %] |
541 |
[% IF ( item.title ) %] |
| 542 |
<p>Title: <em>[% item.title | html %]</em> </p> |
542 |
<p>Title: <em>[% item.title | html %]</em> </p> |
| 543 |
[% END %] |
543 |
[% END %] |
| 544 |
|
544 |
|
| 545 |
<p> |
545 |
<p> |
| 546 |
[% IF ( item.circ_error_UNKNOWN_BARCODE ) %] |
546 |
[% IF ( item.circ_error_UNKNOWN_BARCODE ) %] |
| 547 |
<span id="ce_unknown_barcode">The system does not recognize this barcode.</span> |
547 |
<span id="ce_unknown_barcode">The system does not recognize this barcode.</span> |
| 548 |
[% ELSIF ( item.circ_error_max_loans_allowed ) %] |
548 |
[% ELSIF ( item.circ_error_max_loans_allowed ) %] |
| 549 |
<span id="ce_max_loans_allowed">You have reached the maximum limit of items checked out.</span> |
549 |
<span id="ce_max_loans_allowed">You have reached the maximum limit of items checked out.</span> |
| 550 |
[% ELSIF ( item.circ_error_ISSUED_TO_ANOTHER ) %] |
550 |
[% ELSIF ( item.circ_error_ISSUED_TO_ANOTHER ) %] |
| 551 |
<span id="ce_issued_to_another">This item is checked out to someone else.</span> |
551 |
<span id="ce_issued_to_another">This item is checked out to someone else.</span> |
| 552 |
[% ELSIF ( item.circ_error_NO_MORE_RENEWALS ) %] |
552 |
[% ELSIF ( item.circ_error_NO_MORE_RENEWALS ) %] |
| 553 |
<span id="ce_no_more_renewals">You cannot renew this item again.</span> |
553 |
<span id="ce_no_more_renewals">You cannot renew this item again.</span> |
| 554 |
[% ELSIF ( item.circ_error_NOT_FOR_LOAN ) %] |
554 |
[% ELSIF ( item.circ_error_NOT_FOR_LOAN ) %] |
| 555 |
<span id="ce_not_for_loan">This item is not for loan.</span> |
555 |
<span id="ce_not_for_loan">This item is not for loan.</span> |
| 556 |
[% ELSIF ( item.circ_error_DEBT ) %] |
556 |
[% ELSIF ( item.circ_error_DEBT ) %] |
| 557 |
<span id="ce_too_much_debt">You owe the library [% item.DEBT | $Price with_symbol => 1 %] and cannot check out.</span> |
557 |
<span id="ce_too_much_debt">You owe the library [% item.DEBT | $Price with_symbol => 1 %] and cannot check out.</span> |
| 558 |
[% ELSIF ( item.circ_error_WTHDRAWN ) %] |
558 |
[% ELSIF ( item.circ_error_WTHDRAWN ) %] |
| 559 |
<span id="ce_wthdrawn">This item has been withdrawn from the collection.</span> |
559 |
<span id="ce_wthdrawn">This item has been withdrawn from the collection.</span> |
| 560 |
[% ELSIF ( item.circ_error_RESTRICTED ) %] |
560 |
[% ELSIF ( item.circ_error_RESTRICTED ) %] |
| 561 |
<span id="ce_restricted">This item is restricted.</span> |
561 |
<span id="ce_restricted">This item is restricted.</span> |
| 562 |
[% ELSIF ( item.circ_error_RESERVED ) %] |
562 |
[% ELSIF ( item.circ_error_RESERVED ) %] |
| 563 |
<span id="ce_reserved">This item is on hold for another patron.</span> |
563 |
<span id="ce_reserved">This item is on hold for another patron.</span> |
| 564 |
[% ELSIF ( item.circ_error_ITEMNOTSAMEBRANCH ) %] |
564 |
[% ELSIF ( item.circ_error_ITEMNOTSAMEBRANCH ) %] |
| 565 |
<span id="ce_itemnotsamebranch">This item belongs to another library.</span> |
565 |
<span id="ce_itemnotsamebranch">This item belongs to another library.</span> |
| 566 |
[% ELSIF ( item.circ_error_EXPIRED ) %] |
566 |
[% ELSIF ( item.circ_error_EXPIRED ) %] |
| 567 |
<span id="ce_expired">Your account has expired.</span> |
567 |
<span id="ce_expired">Your account has expired.</span> |
| 568 |
[% ELSIF ( item.circ_error_DEBARRED ) %] |
568 |
[% ELSIF ( item.circ_error_DEBARRED ) %] |
| 569 |
<span id="ce_debarred">Your account has been suspended.</span> |
569 |
<span id="ce_debarred">Your account has been suspended.</span> |
| 570 |
[% ELSIF ( item.circ_error_CARD_LOST ) %] |
570 |
[% ELSIF ( item.circ_error_CARD_LOST ) %] |
| 571 |
<span id="ce_card_lost">This library card has been declared lost.</span> |
571 |
<span id="ce_card_lost">This library card has been declared lost.</span> |
| 572 |
[% ELSIF ( item.circ_error_GNA ) %] |
572 |
[% ELSIF ( item.circ_error_GNA ) %] |
| 573 |
<span id="ce_gna">Your contact information seems to be incomplete.</span> |
573 |
<span id="ce_gna">Your contact information seems to be incomplete.</span> |
| 574 |
[% ELSIF ( item.circ_error_INVALID_DATE ) %] |
574 |
[% ELSIF ( item.circ_error_INVALID_DATE ) %] |
| 575 |
<span id="ce_invalid_date">Due date is not valid.</span> |
575 |
<span id="ce_invalid_date">Due date is not valid.</span> |
| 576 |
[% ELSIF ( item.circ_error_ADDITIONAL_MATERIALS ) %] |
576 |
[% ELSIF ( item.circ_error_ADDITIONAL_MATERIALS ) %] |
| 577 |
<span id="ce_addtional_materials">Item must be checked out at a circulation desk.</span> |
577 |
<span id="ce_addtional_materials">Item must be checked out at a circulation desk.</span> |
| 578 |
[% END %] |
|
|
| 579 |
<span id="ce_see_staff">Please see a member of the library staff.</span> |
| 580 |
</p> |
| 581 |
|
| 582 |
[% IF ( item.returnitem && Koha.Preference('SCOAllowCheckin') ) %] |
| 583 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="errorForm" class="inline" method="post"> |
| 584 |
[% INCLUDE 'csrf-token.inc' %] |
| 585 |
<legend class="sr-only">Return</legend> |
| 586 |
<input type="hidden" name="op" value="cud-returnbook" /> |
| 587 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 588 |
<input type="hidden" name="barcode" value="[% item.barcode | html %]" /> |
| 589 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 590 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 591 |
<button type="submit" name="returnbook" class="btn btn-primary"><i class="fa fa-undo" aria-hidden="true"></i> Return this item</button> |
| 592 |
</form> |
| 593 |
[% END %] |
578 |
[% END %] |
| 594 |
|
579 |
<span id="ce_see_staff">Please see a member of the library staff.</span> |
| 595 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="errorForm" class="inline" method="get"> |
580 |
</p> |
| 596 |
<legend class="sr-only">Error</legend> |
581 |
|
| 597 |
<input type="hidden" name="op" value="" /> |
582 |
[% IF ( item.returnitem && Koha.Preference('SCOAllowCheckin') ) %] |
|
|
583 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="errorForm" class="inline" method="post"> |
| 584 |
[% INCLUDE 'csrf-token.inc' %] |
| 585 |
<legend class="sr-only">Return</legend> |
| 586 |
<input type="hidden" name="op" value="cud-returnbook" /> |
| 598 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
587 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 599 |
<input type="hidden" name="barcode" value="[% item.barcode | html %]" /> |
588 |
<input type="hidden" name="barcode" value="[% item.barcode | html %]" /> |
| 600 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
589 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 601 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
590 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 602 |
<input type="submit" name="confirm" value="Return to account summary" class="btn btn-info back focus" /> |
591 |
<button type="submit" name="returnbook" class="btn btn-primary"><i class="fa fa-undo" aria-hidden="true"></i> Return this item</button> |
| 603 |
</form> |
592 |
</form> |
| 604 |
</div> |
593 |
[% END %] |
| 605 |
<!-- / .alert --> |
|
|
| 606 |
[% END # / FOREACH impossible %] |
| 607 |
|
| 608 |
[% FOREACH c IN confirm %] |
| 609 |
<!-- We need to confirm the issue.. --> |
| 610 |
<div class="alert alert-warning" |
| 611 |
><h2>Please confirm the checkout:</h2> |
| 612 |
<span class="sco-alert-warning confirm"></span> |
| 613 |
[% IF ( c.confirm_renew_issue ) %] |
| 614 |
<p>This item is already checked out to you: <b>[% c.confirm | html %]</b> <i>([% c.barcode | html %])</i></p> |
| 615 |
[% END %] |
| 616 |
|
594 |
|
| 617 |
[% IF ( c.renew && Koha.Preference('SCOAllowCheckin') ) %] |
595 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="errorForm" class="inline" method="get"> |
| 618 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="confirmForm" class="inline" method="post"> |
596 |
<legend class="sr-only">Error</legend> |
| 619 |
[% INCLUDE 'csrf-token.inc' %] |
597 |
<input type="hidden" name="op" value="" /> |
| 620 |
<legend class="sr-only">Return</legend> |
598 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 621 |
<input type="hidden" name="op" value="cud-returnbook" /> |
599 |
<input type="hidden" name="barcode" value="[% item.barcode | html %]" /> |
| 622 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
600 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 623 |
<input type="hidden" name="barcode" value="[% c.barcode | html %]" /> |
601 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 624 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
602 |
<input type="submit" name="confirm" value="Return to account summary" class="btn btn-info back focus" /> |
| 625 |
<input type="hidden" name="confirmed" value="" /> |
603 |
</form> |
| 626 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
604 |
</div> |
| 627 |
<button type="submit" name="returnbook" class="btn btn-primary"><i class="fa fa-undo" aria-hidden="true"></i> Return this item</button> |
605 |
<!-- / .alert --> |
| 628 |
</form> |
606 |
[% END # / FOREACH impossible %] |
| 629 |
[% END %] |
607 |
|
|
|
608 |
[% FOREACH c IN confirm %] |
| 609 |
<!-- We need to confirm the issue.. --> |
| 610 |
<div class="alert alert-warning" |
| 611 |
><h2>Please confirm the checkout:</h2> |
| 612 |
<span class="sco-alert-warning confirm"></span> |
| 613 |
[% IF ( c.confirm_renew_issue ) %] |
| 614 |
<p>This item is already checked out to you: <b>[% c.confirm | html %]</b> <i>([% c.barcode | html %])</i></p> |
| 615 |
[% END %] |
| 630 |
|
616 |
|
| 631 |
[% UNLESS ( c.renew ) %] |
617 |
[% IF ( c.renew && Koha.Preference('SCOAllowCheckin') ) %] |
| 632 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="confirmForm" class="inline" method="post"> |
618 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="confirmForm" class="inline" method="post"> |
| 633 |
[% INCLUDE 'csrf-token.inc' %] |
619 |
[% INCLUDE 'csrf-token.inc' %] |
| 634 |
<legend class="sr-only">Renew</legend> |
620 |
<legend class="sr-only">Return</legend> |
| 635 |
<input type="hidden" name="op" value="cud-renew" /> |
621 |
<input type="hidden" name="op" value="cud-returnbook" /> |
| 636 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
622 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 637 |
<input type="hidden" name="barcode" value="[% c.barcode | html %]" /> |
623 |
<input type="hidden" name="barcode" value="[% c.barcode | html %]" /> |
| 638 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
624 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 639 |
<input type="hidden" name="confirmed" value="1" /> |
625 |
<input type="hidden" name="confirmed" value="" /> |
| 640 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
626 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 641 |
<button type="submit" name="confirm" class="btn btn-primary"><i class="fa-solid fa-rotate" aria-hidden="true"></i> Renew item</button> |
627 |
<button type="submit" name="returnbook" class="btn btn-primary"><i class="fa fa-undo" aria-hidden="true"></i> Return this item</button> |
| 642 |
</form> |
628 |
</form> |
| 643 |
[% ELSE %] |
629 |
[% END %] |
| 644 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="confirmForm" class="inline" method="post"> |
|
|
| 645 |
[% INCLUDE 'csrf-token.inc' %] |
| 646 |
<legend class="sr-only">Renew</legend> |
| 647 |
<input type="hidden" name="op" value="cud-renew" /> |
| 648 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 649 |
<input type="hidden" name="barcode" value="[% c.barcode | html %]" /> |
| 650 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 651 |
<input type="hidden" name="confirmed" value="1" /> |
| 652 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 653 |
<button type="submit" class="btn btn-primary"><i class="fa-solid fa-rotate" aria-hidden="true"></i> Renew item</button> |
| 654 |
</form> |
| 655 |
[% END %] |
| 656 |
|
630 |
|
| 657 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="confirmForm" class="inline" method="get"> |
631 |
[% UNLESS ( c.renew ) %] |
| 658 |
<legend class="sr-only">Cancel</legend> |
632 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="confirmForm" class="inline" method="post"> |
| 659 |
<input type="hidden" name="op" value="" /> |
633 |
[% INCLUDE 'csrf-token.inc' %] |
|
|
634 |
<legend class="sr-only">Renew</legend> |
| 635 |
<input type="hidden" name="op" value="cud-renew" /> |
| 660 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
636 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
|
|
637 |
<input type="hidden" name="barcode" value="[% c.barcode | html %]" /> |
| 661 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
638 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
|
|
639 |
<input type="hidden" name="confirmed" value="1" /> |
| 662 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
640 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 663 |
<button type="submit" class="btn btn-primary"><i class="fa fa-cancel" aria-hidden="true"></i> Cancel</button> |
641 |
<button type="submit" name="confirm" class="btn btn-primary"><i class="fa-solid fa-rotate" aria-hidden="true"></i> Renew item</button> |
| 664 |
</form> |
642 |
</form> |
| 665 |
</div> |
643 |
[% ELSE %] |
| 666 |
[% END # / FOREACH confirm %] |
644 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="confirmForm" class="inline" method="post"> |
| 667 |
|
645 |
[% INCLUDE 'csrf-token.inc' %] |
| 668 |
[% IF ( nopermission ) %] |
646 |
<legend class="sr-only">Renew</legend> |
| 669 |
<!-- This is what is displayed if user doesn't have permission --> |
647 |
<input type="hidden" name="op" value="cud-renew" /> |
| 670 |
<div class="alert alert-warning"> |
648 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 671 |
<span class="sco-alert-warning nopermission"></span> |
649 |
<input type="hidden" name="barcode" value="[% c.barcode | html %]" /> |
| 672 |
<h2>Access denied</h2> |
650 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 673 |
<p>Sorry, this self-checkout station has lost authentication. Please contact the administrator to resolve this problem.</p> |
651 |
<input type="hidden" name="confirmed" value="1" /> |
| 674 |
</div> |
652 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 675 |
[% END %] |
653 |
<button type="submit" class="btn btn-primary"><i class="fa-solid fa-rotate" aria-hidden="true"></i> Renew item</button> |
|
|
654 |
</form> |
| 655 |
[% END %] |
| 676 |
|
656 |
|
| 677 |
[% IF ( different_ip ) %] |
657 |
<form action="/cgi-bin/koha/sco/sco-main.pl" name="confirmForm" class="inline" method="get"> |
| 678 |
<!-- This is what is displayed if user doesn't have permission --> |
658 |
<legend class="sr-only">Cancel</legend> |
| 679 |
<div class="alert alert-warning"> |
659 |
<input type="hidden" name="op" value="" /> |
| 680 |
<span class="sco-alert-warning sessionlost"></span> |
660 |
<input type="hidden" name="patronid" value="[% patronid | html %]" /> |
| 681 |
<h2>Session lost</h2> |
661 |
<input type="hidden" name="load_checkouts" value="[% load_checkouts | html %]" /> |
| 682 |
<p>You are accessing self-checkout from a different IP address! please log in again.</p> |
662 |
<input type="hidden" name="newissues" value="[% newissues | html %]" /> |
| 683 |
</div> |
663 |
<button type="submit" class="btn btn-primary"><i class="fa fa-cancel" aria-hidden="true"></i> Cancel</button> |
| 684 |
[% END %] |
664 |
</form> |
|
|
665 |
</div> |
| 666 |
[% END # / FOREACH confirm %] |
| 667 |
|
| 668 |
[% IF ( nopermission ) %] |
| 669 |
<!-- This is what is displayed if user doesn't have permission --> |
| 670 |
<div class="alert alert-warning"> |
| 671 |
<span class="sco-alert-warning nopermission"></span> |
| 672 |
<h2>Access denied</h2> |
| 673 |
<p>Sorry, this self-checkout station has lost authentication. Please contact the administrator to resolve this problem.</p> |
| 674 |
</div> |
| 675 |
[% END %] |
| 685 |
|
676 |
|
| 686 |
[% IF ( invalid_username_or_password ) %] |
677 |
[% IF ( different_ip ) %] |
| 687 |
<!-- This is what is displayed if user doesn't have permission --> |
678 |
<!-- This is what is displayed if user doesn't have permission --> |
| 688 |
<div class="alert alert-warning"> |
679 |
<div class="alert alert-warning"> |
| 689 |
<span class="sco-alert-warning notfound"></span> |
680 |
<span class="sco-alert-warning sessionlost"></span> |
| 690 |
<h2>Record not found</h2> |
681 |
<h2>Session lost</h2> |
| 691 |
<p>Your userid was not found in the database. Please try again.</p> |
682 |
<p>You are accessing self-checkout from a different IP address! please log in again.</p> |
| 692 |
</div> |
683 |
</div> |
| 693 |
[% END %] |
684 |
[% END %] |
| 694 |
|
685 |
|
| 695 |
[% IF ( issued ) %] |
686 |
[% IF ( invalid_username_or_password ) %] |
| 696 |
[% IF batch_checkouts_allowed %] |
687 |
<!-- This is what is displayed if user doesn't have permission --> |
| 697 |
[% FOREACH barcode IN newissues.split(',') %] |
688 |
<div class="alert alert-warning"> |
| 698 |
<span class="sco-alert-success issue"></span> |
689 |
<span class="sco-alert-warning notfound"></span> |
| 699 |
<div class="alert alert-info"> |
690 |
<h2>Record not found</h2> |
| 700 |
<p>Item checked out <i>([% barcode | html %])</i></p> |
691 |
<p>Your userid was not found in the database. Please try again.</p> |
| 701 |
</div> |
692 |
</div> |
| 702 |
[% END %] |
693 |
[% END %] |
| 703 |
[% ELSE %] |
694 |
|
|
|
695 |
[% IF ( issued ) %] |
| 696 |
[% IF batch_checkouts_allowed %] |
| 697 |
[% FOREACH barcode IN newissues.split(',') %] |
| 704 |
<span class="sco-alert-success issue"></span> |
698 |
<span class="sco-alert-success issue"></span> |
| 705 |
<div class="alert alert-info"> |
699 |
<div class="alert alert-info"> |
| 706 |
<p>Item checked out <i>([% newissues.split(',').last | html %])</i></p> |
700 |
<p>Item checked out <i>([% barcode | html %])</i></p> |
| 707 |
</div> |
701 |
</div> |
| 708 |
[% END %] |
702 |
[% END %] |
| 709 |
[% ELSIF ( renewed ) %] |
703 |
[% ELSE %] |
| 710 |
<span class="sco-alert-success renew"></span> |
704 |
<span class="sco-alert-success issue"></span> |
| 711 |
<div class="alert alert-info"> |
|
|
| 712 |
<p>Item renewed <i>([% barcode | html %])</i></p> |
| 713 |
</div> |
| 714 |
[% ELSIF ( renewed == 0) %] |
| 715 |
<span class="sco-alert-warning renew"></span> |
| 716 |
<div class="alert alert-info"> |
| 717 |
<p>Item not renewed</p> |
| 718 |
</div> |
| 719 |
[% ELSIF ( returned == 0 ) %] |
| 720 |
<span class="sco-alert-warning return"></span> |
| 721 |
<div class="alert alert-info"> |
| 722 |
<p>Item not checked in: please see circulation staff for assistance</p> |
| 723 |
</div> |
| 724 |
[% ELSIF ( returned == 1 ) %] |
| 725 |
<span class="sco-alert-success return"></span> |
| 726 |
<div class="alert alert-info"> |
705 |
<div class="alert alert-info"> |
| 727 |
<p>Item checked in <i>([% barcode | html %])</i></p> |
706 |
<p>Item checked out <i>([% newissues.split(',').last | html %])</i></p> |
| 728 |
</div> |
707 |
</div> |
| 729 |
[% END %] |
708 |
[% END %] |
|
|
709 |
[% ELSIF ( renewed ) %] |
| 710 |
<span class="sco-alert-success renew"></span> |
| 711 |
<div class="alert alert-info"> |
| 712 |
<p>Item renewed <i>([% barcode | html %])</i></p> |
| 713 |
</div> |
| 714 |
[% ELSIF ( renewed == 0) %] |
| 715 |
<span class="sco-alert-warning renew"></span> |
| 716 |
<div class="alert alert-info"> |
| 717 |
<p>Item not renewed</p> |
| 718 |
</div> |
| 719 |
[% ELSIF ( returned == 0 ) %] |
| 720 |
<span class="sco-alert-warning return"></span> |
| 721 |
<div class="alert alert-info"> |
| 722 |
<p>Item not checked in: please see circulation staff for assistance</p> |
| 723 |
</div> |
| 724 |
[% ELSIF ( returned == 1 ) %] |
| 725 |
<span class="sco-alert-success return"></span> |
| 726 |
<div class="alert alert-info"> |
| 727 |
<p>Item checked in <i>([% barcode | html %])</i></p> |
| 728 |
</div> |
| 730 |
[% END %] |
729 |
[% END %] |
| 731 |
- |
730 |
[% END %] |