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

(-)a/koha-tmpl/intranet-tmpl/prog/js/checkouts.js (-14 / +5 lines)
Lines 526-538 $(document).ready(function() { Link Here
526
                                    + __("No renewal before %s").format(oObj.can_renew_date)
526
                                    + __("No renewal before %s").format(oObj.can_renew_date)
527
                                    + "</span>";
527
                                    + "</span>";
528
528
529
                            span_style = "display: none";
530
                            span_class = "renewals-allowed";
531
                        } else if ( oObj.can_renew_error == "auto_too_soon" ) {
532
                            msg += "<span class='renewals-disabled'>"
533
                                    + __("Scheduled for automatic renewal")
534
                                    + "</span>";
535
536
                            span_style = "display: none";
529
                            span_style = "display: none";
537
                            span_class = "renewals-allowed";
530
                            span_class = "renewals-allowed";
538
                        } else if ( oObj.can_renew_error == "auto_too_late" ) {
531
                        } else if ( oObj.can_renew_error == "auto_too_late" ) {
Lines 554-566 $(document).ready(function() { Link Here
554
                                    + __("Automatic renewal failed, account expired")
547
                                    + __("Automatic renewal failed, account expired")
555
                                    + "</span>";
548
                                    + "</span>";
556
549
557
                            span_style = "display: none";
558
                            span_class = "renewals-allowed";
559
                        } else if ( oObj.can_renew_error == "auto_renew" ) {
560
                            msg += "<span class='renewals-disabled'>"
561
                                    + __("Scheduled for automatic renewal")
562
                                    + "</span>";
563
564
                            span_style = "display: none";
550
                            span_style = "display: none";
565
                            span_class = "renewals-allowed";
551
                            span_class = "renewals-allowed";
566
                        } else if ( oObj.can_renew_error == "onsite_checkout" ) {
552
                        } else if ( oObj.can_renew_error == "onsite_checkout" ) {
Lines 608-613 $(document).ready(function() { Link Here
608
                            }
594
                            }
609
                            content += ")</span>";
595
                            content += ")</span>";
610
                        }
596
                        }
597
                        if(oObj.auto_renew){
598
                            content += "<span class='renewals-info'>(";
599
                            content += __("Scheduled for automatic renewal");
600
                            content += ")</span>";
601
                        }
611
602
612
                        return content;
603
                        return content;
613
                    }
604
                    }
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-user.tt (-8 / +3 lines)
Lines 500-516 Link Here
500
                                                                    / [% ISSUE.unseenleft | html %] of [% ISSUE.unseenallowed | html %] renewals left before the item must be seen by the library
500
                                                                    / [% ISSUE.unseenleft | html %] of [% ISSUE.unseenallowed | html %] renewals left before the item must be seen by the library
501
                                                                [% END %]
501
                                                                [% END %]
502
                                                            )</span>
502
                                                            )</span>
503
                                                        [% ELSIF ( ISSUE.auto_renew || ISSUE.auto_too_soon ) %]
504
                                                            <span class="usr-msg automatic-renewal">Automatic renewal</span>
505
                                                            <span class="renewals">(
506
                                                                [% ISSUE.renewsleft | html %] of [% ISSUE.renewsallowed | html %] renewals remaining
507
                                                                [% IF Koha.Preference('UnseenRenewals') && ISSUE.unseenallowed %]
508
                                                                    / [% ISSUE.unseenleft | html %] of [% ISSUE.unseenallowed | html %] renewals left before the item must be seen by the library
509
                                                                [% END %]
510
                                                            )</span>
511
                                                        [% ELSIF ( ISSUE.item_denied_renewal ) %]
503
                                                        [% ELSIF ( ISSUE.item_denied_renewal ) %]
512
                                                            Renewal not allowed
504
                                                            Renewal not allowed
513
                                                        [% END %]
505
                                                        [% END %]
506
                                                        [% IF ( ISSUE.auto_renew || ISSUE.auto_too_soon ) %]
507
                                                            <br><span class="usr-msg automatic-renewal">This item is scheduled for auto renewal.</span>
508
                                                        [% END %]
514
                                                        </td>
509
                                                        </td>
515
                                                    [% END %]
510
                                                    [% END %]
516
                                                    [% IF ( OPACFinesTab ) %]
511
                                                    [% IF ( OPACFinesTab ) %]
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt (-3 / +4 lines)
Lines 358-366 Link Here
358
                                                                    <input type="submit" value="Renew item" class="btn btn-primary btn-sm renew" />
358
                                                                    <input type="submit" value="Renew item" class="btn btn-primary btn-sm renew" />
359
                                                                [% END %]
359
                                                                [% END %]
360
                                                            [% ELSE %]
360
                                                            [% ELSE %]
361
                                                                [% IF ISSUE.renew_error == 'auto_renew' OR ISSUE.renew_error == 'auto_too_soon' %]
361
                                                                [% IF ISSUE.renew_error == 'onsite_checkout' %]
362
                                                                    <span>This item has been scheduled for automatic renewal and cannot be renewed</span>
363
                                                                [% ELSIF ISSUE.renew_error == 'onsite_checkout' %]
364
                                                                    <span>This is a on-site checkout, it cannot be renewed.</span>
362
                                                                    <span>This is a on-site checkout, it cannot be renewed.</span>
365
                                                                [% ELSIF ISSUE.renew_error == 'too_unseen' %]
363
                                                                [% ELSIF ISSUE.renew_error == 'too_unseen' %]
366
                                                                    <span>You have renewed this item the maximum number of consecutive times without it being seen by the library.</span>
364
                                                                    <span>You have renewed this item the maximum number of consecutive times without it being seen by the library.</span>
Lines 375-380 Link Here
375
                                                                    <input type="hidden" name="confirmed" value=""  />
373
                                                                    <input type="hidden" name="confirmed" value=""  />
376
                                                                [% END %]
374
                                                                [% END %]
377
                                                            [% END %]
375
                                                            [% END %]
376
                                                            [% IF ISSUE.auto_renew %]
377
                                                                <br><span>This item is scheduled for automatic renewal</span>
378
                                                            [% END %]
378
                                                        </form>
379
                                                        </form>
379
                                                    </td>
380
                                                    </td>
380
                                                    [% UNLESS ( nofines ) %]
381
                                                    [% UNLESS ( nofines ) %]
(-)a/svc/checkouts (-1 / +2 lines)
Lines 72-77 my $sql = ' Link Here
72
        issues.date_due,
72
        issues.date_due,
73
        issues.date_due < now() as date_due_overdue,
73
        issues.date_due < now() as date_due_overdue,
74
        issues.timestamp,
74
        issues.timestamp,
75
        issues.auto_renew,
75
76
76
        issues.onsite_checkout,
77
        issues.onsite_checkout,
77
78
Lines 272-277 while ( my $c = $sth->fetchrow_hashref() ) { Link Here
272
        date_due            => $c->{date_due},
273
        date_due            => $c->{date_due},
273
        date_due_overdue    => $c->{date_due_overdue} ? JSON::true : JSON::false,
274
        date_due_overdue    => $c->{date_due_overdue} ? JSON::true : JSON::false,
274
        timestamp           => $c->{timestamp},
275
        timestamp           => $c->{timestamp},
276
        auto_renew          => $c->{auto_renew},
275
        onsite_checkout     => $c->{onsite_checkout},
277
        onsite_checkout     => $c->{onsite_checkout},
276
        enumchron           => $c->{enumchron},
278
        enumchron           => $c->{enumchron},
277
        renewals_count      => $renewals_count,
279
        renewals_count      => $renewals_count,
278
- 

Return to bug 25393