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

(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/item-status.inc (-15 / +15 lines)
Lines 9-17 Link Here
9
9
10
[% IF ( item.itemlost ) %]
10
[% IF ( item.itemlost ) %]
11
    [% SET itemavailable = 0 %]
11
    [% SET itemavailable = 0 %]
12
    [% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.itemlost', authorised_value => item.itemlost, opac => 1 ) %]
12
    [% itemlost_lib = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.itemlost', authorised_value => item.itemlost, opac => 1 ) %]
13
    [% IF ( av_lib_include ) %]
13
    [% IF itemlost_lib %]
14
        <span class="item-status lost">[% av_lib_include | html %]</span>
14
        <span class="item-status lost">[% itemlost_lib | html %]</span>
15
    [% ELSE %]
15
    [% ELSE %]
16
        <span class="item-status lost">Item lost</span>
16
        <span class="item-status lost">Item lost</span>
17
    [% END %]
17
    [% END %]
Lines 71-95 Link Here
71
71
72
[% IF ( item.withdrawn ) %]
72
[% IF ( item.withdrawn ) %]
73
    [% SET itemavailable = 0 %]
73
    [% SET itemavailable = 0 %]
74
    [% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => item.withdrawn, opac => 1 ) %]
74
    [% withdrawn_lib = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => item.withdrawn, opac => 1 ) %]
75
    [% IF av_lib_include %]
75
    [% IF withdrawn_lib %]
76
        <span class="item-status withdrawn">[% av_lib_include | html %]</span>
76
        <span class="item-status withdrawn">[% withdrawn_lib | html %]</span>
77
    [% ELSE %]
77
    [% ELSE %]
78
        <span class="item-status withdrawn">Item withdrawn</span>
78
        <span class="item-status withdrawn">Item withdrawn</span>
79
    [% END %]
79
    [% END %]
80
[% END %]
80
[% END %]
81
81
82
82
83
[% IF NOT ( item.isa('Koha::Item') ) AND item.itemnotforloan %]
83
[% SET restricted_lib = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => item.withdrawn, opac => 1 ) %]
84
[% IF item.notforloan %]
84
    [% SET itemavailable = 0 %]
85
    [% SET itemavailable = 0 %]
85
    [% IF ( item.notforloanvalueopac ) %]
86
    [% notforloan_lib = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => item.withdrawn, opac => 1 ) %]
86
        <span class="item-status notforloan">[% item.notforloanvalueopac | html %] [% IF ( item.restrictedvalueopac ) %]<span class="restricted">([% item.restrictedvalueopac | html %])</span>[% END %]</span>
87
    [% IF notforloan_lib %]
88
        <span class="item-status notforloan">[% notforloan_lib | html %] [% IF restricted_lib %]<span class="restricted">([% restricted_lib | html %])</span>[% END %]</span>
87
    [% ELSE %]
89
    [% ELSE %]
88
        <span class="item-status notforloan">Not for loan [% IF ( item.restrictedvalueopac ) %]<span class="restricted">([% item.restrictedvalueopac | html %])</span>[% END %]</span>
90
        <span class="item-status notforloan">Not for loan [% IF restricted_lib %]<span class="restricted">([% restricted_lib | html %])</span>[% END %]</span>
89
    [% END %]
91
    [% END %]
90
[% ELSIF NOT ( item.isa('Koha::Item') ) AND item.notforloan_per_itemtype %]
92
[% ELSIF item.itemtype.notforloan %]
91
    [% SET itemavailable = 0 %]
93
    [% SET itemavailable = 0 %]
92
    <span class="item-status notforloan">Not for loan [% IF ( item.restrictedvalueopac ) %]<span class="restricted">([% item.restrictedvalueopac | html %])</span>[% END %]</span>
94
    <span class="item-status notforloan">Not for loan [% IF restricted_lib %]<span class="restricted">([% restricted_lib | html %])</span>[% END %]</span>
93
[% END %]
95
[% END %]
94
96
95
[% IF ( item.bundle_host ) %]
97
[% IF ( item.bundle_host ) %]
Lines 122-127 Link Here
122
[% END %]
124
[% END %]
123
125
124
[% IF ( itemavailable ) %]
126
[% IF ( itemavailable ) %]
125
    [% IF NOT item.isa('Koha::Item') %][% SET restrictedvalueopac = item.restrictedvalueopac %][% END %]
127
    <span class="item-status available">Available [% IF restricted_lib %]<span class="restricted">([% restricted_lib | html %])</span>[% END %]</span>
126
    <span class="item-status available">Available [% IF restrictedvalueopac %]<span class="restricted">([% restrictedvalueopac | html %])</span>[% END %]</span>
127
[% END %]
128
[% END %]
128
- 

Return to bug 32445