View | Details | Raw Unified | Return to bug 15486
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt (-114 / +106 lines)
Lines 202-320 $(document).ready(function() { Link Here
202
            </tr>
202
            </tr>
203
            </thead>
203
            </thead>
204
            <tbody>
204
            <tbody>
205
				[% FOREACH rule IN rules %]
205
            [% FOREACH rule IN rules %]
206
					<tr id="row_[% loop.count %]">
206
                <tr id="row_[% loop.count %]">
207
							<td>[% IF ( rule.default_humancategorycode ) %]
207
                    <td>[% IF ( rule.default_humancategorycode ) %]
208
									<em>All</em>
208
                            <em>All</em>
209
								[% ELSE %]
209
                        [% ELSE %]
210
									[% rule.humancategorycode %]
210
                            [% rule.humancategorycode %]
211
								[% END %]
211
                        [% END %]</td>
212
							</td>
212
                    <td>[% IF rule.default_translated_description %]
213
                            <td>[% IF rule.default_translated_description %]
213
                            <em>All</em>
214
									<em>All</em>
214
                        [% ELSE %]
215
								[% ELSE %]
215
                            [% rule.translated_description %]
216
									[% rule.translated_description %]
216
                        [% END %]</td>
217
								[% END %]
217
                    <td class="actions">
218
							</td>
218
                      <a href="#" class="editrule btn btn-default btn-xs"><i class="fa fa-pencil"></i> Edit</a>
219
                                                        <td class="actions">
219
                      <a class="btn btn-default btn-xs delete" href="/cgi-bin/koha/admin/smart-rules.pl?op=delete&amp;itemtype=[% rule.itemtype %]&amp;categorycode=[% rule.categorycode %]&amp;branch=[% rule.current_branch %]">
220
                                                          <a href="#" class="editrule btn btn-default btn-xs"><i class="fa fa-pencil"></i> Edit</a>
220
                        <i class="fa fa-trash"></i> Delete</a></td>
221
                                                          <a class="btn btn-default btn-xs delete" href="/cgi-bin/koha/admin/smart-rules.pl?op=delete&amp;itemtype=[% rule.itemtype %]&amp;categorycode=[% rule.categorycode %]&amp;branch=[% rule.current_branch %]"><i class="fa fa-trash"></i> Delete</a>
221
                    <td>[% IF ( rule.unlimited_maxissueqty ) %]
222
                                                        </td>
222
                            Unlimited
223
223
                        [% ELSE %]
224
							<td>[% IF ( rule.unlimited_maxissueqty ) %]
224
                            [% rule.maxissueqty %]
225
									Unlimited
225
                        [% END %]</td>
226
								[% ELSE %]
226
                    <td>[% IF rule.unlimited_maxonsiteissueqty %]
227
									[% rule.maxissueqty %]
227
                            Unlimited
228
								[% END %]
228
                        [% ELSE %]
229
							</td>
229
                            [% rule.maxonsiteissueqty %]
230
                            <td>[% IF rule.unlimited_maxonsiteissueqty %]
230
                        [% END %]</td>
231
                                    Unlimited
231
                    <td>[% rule.issuelength %]</td>
232
                                [% ELSE %]
232
                    <td>[% rule.lengthunit %]</td>
233
                                    [% rule.maxonsiteissueqty %]
233
                    <td>[% IF ( rule.hardduedate ) %]
234
                                [% END %]
234
                            [% IF ( rule.hardduedatebefore ) %]
235
                            </td>
235
                                before [% rule.hardduedate %]
236
							<td>[% rule.issuelength %]</td>
236
                                <input type="hidden" name="hardduedatecomparebackup" value="-1" />
237
							<td>
237
                            [% ELSIF ( rule.hardduedateexact ) %]
238
							    [% rule.lengthunit %]
238
                                on [% rule.hardduedate %]
239
							</td>
239
                                <input type="hidden" name="hardduedatecomparebackup" value="0" />
240
                            <td>
240
                            [% ELSIF ( rule.hardduedateafter ) %]
241
                              [% IF ( rule.hardduedate ) %]
241
                                after [% rule.hardduedate %]
242
                                [% IF ( rule.hardduedatebefore ) %]
242
                                <input type="hidden" name="hardduedatecomparebackup" value="1" />
243
                                  before [% rule.hardduedate %]
243
                            [% END %]
244
                                  <input type="hidden" name="hardduedatecomparebackup" value="-1" />
244
                        [% ELSE %]
245
                                [% ELSIF ( rule.hardduedateexact ) %]
245
                            None defined
246
                                  on [% rule.hardduedate %]
246
                        [% END %]</td>
247
                                  <input type="hidden" name="hardduedatecomparebackup" value="0" />
247
                    <td>[% rule.fine %]</td>
248
                                [% ELSIF ( rule.hardduedateafter ) %]
248
                    <td>[% rule.chargeperiod %]</td>
249
                                  after [% rule.hardduedate %]
249
                    <td>[% IF rule.chargeperiod_charge_at %]
250
                                  <input type="hidden" name="hardduedatecomparebackup" value="1" />
250
                            Start of interval
251
                                [% END %]
251
                        [% ELSE %]
252
                              [% ELSE %]
252
                            End of interval
253
                                None defined
253
                        [% END %]</td>
254
                              [% END %]
254
                    <td>[% rule.firstremind %]</td>
255
                            </td>
255
                    <td>[% rule.overduefinescap FILTER format("%.2f") %]</td>
256
							<td>[% rule.fine %]</td>
256
                    <td>[% IF rule.cap_fine_to_replacement_price %]
257
							<td>[% rule.chargeperiod %]</td>
257
                            <input type="checkbox" checked="checked" disabled="disabled" />
258
                <td>[% IF rule.chargeperiod_charge_at %]Start of interval[% ELSE %]End of interval[% END %]</td>
258
                        [% ELSE %]
259
							<td>[% rule.firstremind %]</td>
259
                            <input type="checkbox" disabled="disabled" />
260
                            <td>[% rule.overduefinescap FILTER format("%.2f") %]</td>
260
                        [% END %]</td>
261
                            <td>
261
                    <td>[% rule.finedays %]</td>
262
                                [% IF rule.cap_fine_to_replacement_price %]
262
                    <td>[% rule.maxsuspensiondays %]</td>
263
                                    <input type="checkbox" checked="checked" disabled="disabled" />
263
                    <td>[% rule.renewalsallowed %]</td>
264
                                [% ELSE %]
264
                    <td>[% rule.renewalperiod %]</td>
265
                                    <input type="checkbox" disabled="disabled" />
265
                    <td>[% rule.norenewalbefore %]</td>
266
                                [% END %]
266
                    <td>[% IF ( rule.auto_renew ) %]
267
                            </td>
267
                            Yes
268
							<td>[% rule.finedays %]</td>
268
                        [% ELSE %]
269
                            <td>[% rule.maxsuspensiondays %]</td>
269
                            No
270
							<td>[% rule.renewalsallowed %]</td>
270
                        [% END %]</td>
271
                            <td>[% rule.renewalperiod %]</td>
271
                    <td>[% rule.no_auto_renewal_after %]</td>
272
                            <td>[% rule.norenewalbefore %]</td>
272
                    <td>[% rule.no_auto_renewal_after_hard_limit %]</td>
273
                            <td>
273
                    <td>[% rule.reservesallowed %]</td>
274
                                [% IF ( rule.auto_renew ) %]
274
                    <td>[% IF rule.unlimited_holds_per_day %]
275
                                Yes
275
                            Unlimited
276
                                [% ELSE %]
276
                        [% ELSE %]
277
                                No
277
                            [% rule.holds_per_day %]
278
                                [% END %]
278
                        [% END %]</td>
279
                            </td>
279
                    <td>[% rule.holds_per_record %]</td>
280
                            <td>[% rule.no_auto_renewal_after %]</td>
280
                    <td>[% IF rule.onshelfholds == 1 %]
281
                            <td>[% rule.no_auto_renewal_after_hard_limit %]</td>
281
                            Yes
282
							<td>[% rule.reservesallowed %]</td>
282
                        [% ELSIF rule.onshelfholds == 2 %]
283
                            <td>[% IF rule.unlimited_holds_per_day %]
283
                            If all unavailable
284
                                    Unlimited
284
                        [% ELSE %]
285
                                [% ELSE %]
285
                            If any unavailable
286
                                    [% rule.holds_per_day %]
286
                        [% END %]</td>
287
                                [% END %]
287
                    <td>[% IF rule.opacitemholds == 'F'%]
288
                            </td>
288
                            Force
289
                                                        <td>[% rule.holds_per_record %]</td>
289
                        [% ELSIF rule.opacitemholds == 'Y'%]
290
                                                        <td>
290
                            Allow
291
                                                            [% IF rule.onshelfholds == 1 %]
291
                        [% ELSE %]
292
                                                                Yes
292
                            Don't allow
293
                                                            [% ELSIF rule.onshelfholds == 2 %]
293
                        [% END %]</td>
294
                                                                If all unavailable
294
                    <td>[% IF rule.article_requests == 'no' %]
295
                                                            [% ELSE %]
295
                            No
296
                                                                If any unavailable
296
                        [% ELSIF rule.article_requests == 'yes' %]
297
                                                            [% END %]</td>
297
                            Yes
298
                                                        <td>[% IF rule.opacitemholds == 'F'%]Force[% ELSIF rule.opacitemholds == 'Y'%]Allow[% ELSE %]Don't allow[% END %]</td>
298
                        [% ELSIF rule.article_requests == 'bib_only' %]
299
                                                        <td>
299
                            Record only
300
                                                            [% IF rule.article_requests == 'no' %]
300
                        [% ELSIF rule.article_requests == 'item_only' %]
301
                                                                No
301
                            Item only
302
                                                            [% ELSIF rule.article_requests == 'yes' %]
302
                        [% END %]</td>
303
                                                                Yes
303
                    <td>[% rule.rentaldiscount %]</td>
304
                                                            [% ELSIF rule.article_requests == 'bib_only' %]
304
                    <td class="actions">
305
                                                                Record only
305
                        <a href="#" class="editrule btn btn-default btn-xs">
306
                                                            [% ELSIF rule.article_requests == 'item_only' %]
306
                            <i class="fa fa-pencil"></i> Edit</a>
307
                                                                Item only
307
                        <a class="btn btn-default btn-xs delete" href="/cgi-bin/koha/admin/smart-rules.pl?op=delete&amp;itemtype=[% rule.itemtype %]&amp;categorycode=[% rule.categorycode %]&amp;branch=[% rule.current_branch %]">
308
                                                            [% END %]
308
                            <i class="fa fa-trash"></i> Delete</a></td>
309
                                                        </td>
309
                </tr>
310
							<td>[% rule.rentaldiscount %]</td>
310
            [% END %]
311
                                                        <td class="actions">
312
                                                          <a href="#" class="editrule btn btn-default btn-xs"><i class="fa fa-pencil"></i> Edit</a>
313
                                                          <a class="btn btn-default btn-xs delete" href="/cgi-bin/koha/admin/smart-rules.pl?op=delete&amp;itemtype=[% rule.itemtype %]&amp;categorycode=[% rule.categorycode %]&amp;branch=[% rule.current_branch %]"><i class="fa fa-trash"></i> Delete</a>
314
                                                        </td>
315
316
                	</tr>
317
            	[% END %]
318
                <tr id="edit_row">
311
                <tr id="edit_row">
319
                    <td>
312
                    <td>
320
                        <select name="categorycode" id="categorycode">
313
                        <select name="categorycode" id="categorycode">
321
- 

Return to bug 15486