Lines 1-3
Link Here
|
|
|
1 |
[%# Lets keep this include in sync between OPAC and staff: make your changes in that perspective at both sides please ! %] |
2 |
|
1 |
[% USE Branches %] |
3 |
[% USE Branches %] |
2 |
[% USE AuthorisedValues %] |
4 |
[% USE AuthorisedValues %] |
3 |
[% SET itemavailable = 1 %] |
5 |
[% SET itemavailable = 1 %] |
Lines 7-15
Link Here
|
7 |
[%#- structure is used by course reserves pages, which do -%] |
9 |
[%#- structure is used by course reserves pages, which do -%] |
8 |
[%#- not use an API to fetch items that populates item.datedue. -%] |
10 |
[%#- not use an API to fetch items that populates item.datedue. -%] |
9 |
|
11 |
|
|
|
12 |
[% SET opac = staff ? 0 : 1 %] |
13 |
|
10 |
[% IF ( item.itemlost ) %] |
14 |
[% IF ( item.itemlost ) %] |
11 |
[% SET itemavailable = 0 %] |
15 |
[% SET itemavailable = 0 %] |
12 |
[% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.itemlost', authorised_value => item.itemlost ) %] |
16 |
[% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.itemlost', authorised_value => item.itemlost, 'opac' => opac ) %] |
13 |
[% IF ( av_lib_include ) %] |
17 |
[% IF ( av_lib_include ) %] |
14 |
<span class="item-status lost">[% av_lib_include | html %]</span> |
18 |
<span class="item-status lost">[% av_lib_include | html %]</span> |
15 |
[% ELSE %] |
19 |
[% ELSE %] |
Lines 54-60
Link Here
|
54 |
|
58 |
|
55 |
[% IF ( item.withdrawn ) %] |
59 |
[% IF ( item.withdrawn ) %] |
56 |
[% SET itemavailable = 0 %] |
60 |
[% SET itemavailable = 0 %] |
57 |
[% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => item.withdrawn ) %] |
61 |
[% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => item.withdrawn, 'opac' => opac ) %] |
58 |
[% IF av_lib_include %] |
62 |
[% IF av_lib_include %] |
59 |
<span class="item-status withdrawn">[% av_lib_include | html %]</span> |
63 |
<span class="item-status withdrawn">[% av_lib_include | html %]</span> |
60 |
[% ELSE %] |
64 |
[% ELSE %] |
Lines 62-70
Link Here
|
62 |
[% END %] |
66 |
[% END %] |
63 |
[% END %] |
67 |
[% END %] |
64 |
|
68 |
|
65 |
[% IF ( item.notforloan ) %] |
69 |
[% IF ( NOT ( item.isa('Koha::Item') ) AND item.itemnotforloan ) OR item.notforloan %] |
66 |
[% SET itemavailable = 0 %] |
70 |
[% SET itemavailable = 0 %] |
67 |
[% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.notforloan', authorised_value => item.notforloan ) %] |
71 |
[% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.notforloan', authorised_value => item.notforloan, 'opac' => opac ) %] |
68 |
[% IF av_lib_include %] |
72 |
[% IF av_lib_include %] |
69 |
<span class="item-status notforloan">[% av_lib_include | html %]</span> |
73 |
<span class="item-status notforloan">[% av_lib_include | html %]</span> |
70 |
[% ELSE %] |
74 |
[% ELSE %] |
Lines 74-80
Link Here
|
74 |
|
78 |
|
75 |
[% IF ( item.damaged ) %] |
79 |
[% IF ( item.damaged ) %] |
76 |
[% SET itemavailable = 0 %] |
80 |
[% SET itemavailable = 0 %] |
77 |
[% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.damaged', authorised_value => item.damaged ) %] |
81 |
[% av_lib_include = AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.damaged', authorised_value => item.damaged, 'opac' => opac ) %] |
78 |
[% IF av_lib_include %] |
82 |
[% IF av_lib_include %] |
79 |
<span class="item-status damaged">[% av_lib_include | html %]</span> |
83 |
<span class="item-status damaged">[% av_lib_include | html %]</span> |
80 |
[% ELSE %] |
84 |
[% ELSE %] |