Lines 74-147
Link Here
|
74 |
<div id="cataloguing_additem_itemlist"> |
74 |
<div id="cataloguing_additem_itemlist"> |
75 |
[% IF items %] |
75 |
[% IF items %] |
76 |
[% SET date_fields = [ 'dateaccessioned', 'onloan', 'datelastseen', 'datelastborrowed', 'replacementpricedate' ] %] |
76 |
[% SET date_fields = [ 'dateaccessioned', 'onloan', 'datelastseen', 'datelastborrowed', 'replacementpricedate' ] %] |
77 |
<div> |
77 |
<div class="page-section"> |
78 |
<table id="itemst"> |
78 |
<table id="itemst"> |
79 |
<thead> |
79 |
<thead> |
80 |
<tr> |
80 |
<tr> |
81 |
<th class="NoSort"> </th> |
81 |
<th class="NoSort"> </th> |
82 |
[% FOREACH item_header IN item_header_loop %] |
82 |
[% FOREACH item_header IN item_header_loop %] |
83 |
<th data-colname="[% item_header.attribute | html %]"> |
83 |
<th data-colname="[% item_header.attribute | html %]"> |
84 |
[% item_header.header_value | html %] |
84 |
[% item_header.header_value | html %] |
85 |
</th> |
85 |
</th> |
86 |
[% END %] |
86 |
[% END %] |
87 |
</tr> |
87 |
</tr> |
88 |
</thead> |
88 |
</thead> |
89 |
<tbody> |
89 |
<tbody> |
90 |
[% FOREACH item IN items %] |
90 |
[% FOREACH item IN items %] |
91 |
[% SET can_be_edited = ! ( Koha.Preference('IndependentBranches') && ! logged_in_user.is_superlibrarian && item.homebranch != Branches.GetLoggedInBranchname() ) %] |
91 |
[% SET can_be_edited = ! ( Koha.Preference('IndependentBranches') && ! logged_in_user.is_superlibrarian && item.homebranch != Branches.GetLoggedInBranchname() ) %] |
92 |
[% IF item.itemnumber == itemnumber%] |
92 |
[% IF item.itemnumber == itemnumber%] |
93 |
[% UNLESS can_be_edited %] |
93 |
[% UNLESS can_be_edited %] |
94 |
<tr id="row[% item.itemnumber | html %]" class="active"> |
94 |
<tr id="row[% item.itemnumber | html %]" class="active"> |
|
|
95 |
[% ELSE %] |
96 |
<tr id="row[% item.itemnumber | html %]" class="active editable"> |
97 |
[% END %] |
95 |
[% ELSE %] |
98 |
[% ELSE %] |
96 |
<tr id="row[% item.itemnumber | html %]" class="active editable"> |
99 |
[% UNLESS can_be_edited %] |
|
|
100 |
<tr id="row[% item.itemnumber | html %]"> |
101 |
[% ELSE %] |
102 |
<tr id="row[% item.itemnumber | html %]" class="editable"> |
103 |
[% END %] |
97 |
[% END %] |
104 |
[% END %] |
98 |
[% ELSE %] |
|
|
99 |
[% UNLESS can_be_edited %] |
105 |
[% UNLESS can_be_edited %] |
100 |
<tr id="row[% item.itemnumber | html %]"> |
106 |
<td> </td> |
101 |
[% ELSE %] |
107 |
[% ELSE %] |
102 |
<tr id="row[% item.itemnumber | html %]" class="editable"> |
108 |
<td> |
103 |
[% END %] |
109 |
<div class="btn-group dropup"> |
104 |
[% END %] |
110 |
<a class="btn btn-default btn-xs dropdown-toggle" id="itemactions[% item.itemnumber | html %]" role="button" data-toggle="dropdown" href="#"> |
105 |
[% UNLESS can_be_edited %] |
111 |
Actions <b class="caret"></b> |
106 |
<td> </td> |
112 |
</a> |
107 |
[% ELSE %] |
113 |
<ul class="dropdown-menu" role="menu" aria-labelledby="itemactions[% item.itemnumber | html %]"> |
108 |
<td> |
|
|
109 |
<div class="btn-group dropup"> |
110 |
<a class="btn btn-default btn-xs dropdown-toggle" id="itemactions[% item.itemnumber | html %]" role="button" data-toggle="dropdown" href="#"> |
111 |
Actions <b class="caret"></b> |
112 |
</a> |
113 |
<ul class="dropdown-menu" role="menu" aria-labelledby="itemactions[% item.itemnumber | html %]"> |
114 |
|
114 |
|
115 |
[% IF item.biblionumber != biblio.biblionumber %] [%# Host item %] |
115 |
[% IF item.biblionumber != biblio.biblionumber %] [%# Host item %] |
116 |
<li><a href="additem.pl?op=edititem&biblionumber=[% item.biblionumber | uri %]&itemnumber=[% item.itemnumber | uri %]#edititem">Edit in host</a> <a class="delete" href="/cgi-bin/koha/cataloguing/additem.pl?op=delinkitem&biblionumber=[% biblio.biblionumber | html %]&hostitemnumber=[% item.itemnumber | html %]&searchid=[% searchid | html %]">Delink</a></li> |
116 |
<li><a href="additem.pl?op=edititem&biblionumber=[% item.biblionumber | uri %]&itemnumber=[% item.itemnumber | uri %]#edititem">Edit in host</a> <a class="delete" href="/cgi-bin/koha/cataloguing/additem.pl?op=delinkitem&biblionumber=[% biblio.biblionumber | html %]&hostitemnumber=[% item.itemnumber | html %]&searchid=[% searchid | html %]">Delink</a></li> |
|
|
117 |
[% ELSE %] |
118 |
<li><a href="additem.pl?op=edititem&biblionumber=[% biblio.biblionumber | uri %]&itemnumber=[% item.itemnumber | uri %]&searchid=[% searchid | uri %]#edititem">Edit</a></li> |
119 |
<li><a href="additem.pl?op=dupeitem&biblionumber=[% biblio.biblionumber | uri %]&itemnumber=[% item.itemnumber | uri %]&searchid=[% searchid | uri %]#additema">Duplicate</a></li> |
120 |
<li class="print_label"><a href="/cgi-bin/koha/labels/label-edit-batch.pl?op=add&number_type=itemnumber&number_list=[% item.itemnumber | uri %]" target="_blank" >Print label</a></li> |
121 |
<li><a class="delete" href="/cgi-bin/koha/cataloguing/additem.pl?op=delitem&biblionumber=[% item.biblionumber | html %]&itemnumber=[% item.itemnumber | html %]&searchid=[% searchid | html %]" onclick="return confirm_deletion();">Delete</a></li> |
122 |
[% END %] |
123 |
[% IF ( OPACBaseURL ) %] |
124 |
<li class="view-in-opac"><a target="_blank" href="[% Koha.Preference('OPACBaseURL') | url %]/cgi-bin/koha/opac-detail.pl?biblionumber=[% item.biblionumber | uri %]">OPAC view</a></li> |
125 |
[% END %] |
126 |
</ul> |
127 |
</div> |
128 |
</td> |
129 |
[% END %] |
130 |
[% FOREACH header IN item_header_loop %] |
131 |
[% SET attribute = header.attribute %] |
132 |
[% IF header.attribute AND date_fields.grep('^' _ attribute _ '$').size %] |
133 |
<td data-order="[% item.$attribute | html %]">[% item.$attribute | $KohaDates %]</td> |
134 |
[% ELSIF ( item.$attribute && ( attribute == 'price' || attribute == 'replacementprice' ) ) %] |
135 |
<td data-order="[% item.$attribute | html %]">[% item.$attribute | $Price %]</td> |
117 |
[% ELSE %] |
136 |
[% ELSE %] |
118 |
<li><a href="additem.pl?op=edititem&biblionumber=[% biblio.biblionumber | uri %]&itemnumber=[% item.itemnumber | uri %]&searchid=[% searchid | uri %]#edititem">Edit</a></li> |
137 |
<td>[% item.$attribute | html %]</td> |
119 |
<li><a href="additem.pl?op=dupeitem&biblionumber=[% biblio.biblionumber | uri %]&itemnumber=[% item.itemnumber | uri %]&searchid=[% searchid | uri %]#additema">Duplicate</a></li> |
|
|
120 |
<li class="print_label"><a href="/cgi-bin/koha/labels/label-edit-batch.pl?op=add&number_type=itemnumber&number_list=[% item.itemnumber | uri %]" target="_blank" >Print label</a></li> |
121 |
<li><a class="delete" href="/cgi-bin/koha/cataloguing/additem.pl?op=delitem&biblionumber=[% item.biblionumber | html %]&itemnumber=[% item.itemnumber | html %]&searchid=[% searchid | html %]" onclick="return confirm_deletion();">Delete</a></li> |
122 |
[% END %] |
138 |
[% END %] |
123 |
[% IF ( OPACBaseURL ) %] |
|
|
124 |
<li class="view-in-opac"><a target="_blank" href="[% Koha.Preference('OPACBaseURL') | url %]/cgi-bin/koha/opac-detail.pl?biblionumber=[% item.biblionumber | uri %]">OPAC view</a></li> |
125 |
[% END %] |
126 |
</ul> |
127 |
</div> |
128 |
</td> |
129 |
[% END %] |
139 |
[% END %] |
130 |
[% FOREACH header IN item_header_loop %] |
140 |
</tr> |
131 |
[% SET attribute = header.attribute %] |
|
|
132 |
[% IF header.attribute AND date_fields.grep('^' _ attribute _ '$').size %] |
133 |
<td data-order="[% item.$attribute | html %]">[% item.$attribute | $KohaDates %]</td> |
134 |
[% ELSIF ( item.$attribute && ( attribute == 'price' || attribute == 'replacementprice' ) ) %] |
135 |
<td data-order="[% item.$attribute | html %]">[% item.$attribute | $Price %]</td> |
136 |
[% ELSE %] |
137 |
<td>[% item.$attribute | html %]</td> |
138 |
[% END %] |
141 |
[% END %] |
139 |
[% END %] |
142 |
</tbody> |
140 |
</tr> |
143 |
</table> |
141 |
[% END %] |
144 |
</div> <!-- /.page-section --> |
142 |
</tbody> |
|
|
143 |
</table> |
144 |
</div> |
145 |
[% END %] |
145 |
[% END %] |
146 |
|
146 |
|
147 |
<div class="row"> |
147 |
<div class="row"> |
Lines 150-156
Link Here
|
150 |
</div> |
150 |
</div> |
151 |
<div class="col-sm-10"> |
151 |
<div class="col-sm-10"> |
152 |
|
152 |
|
153 |
<div id="cataloguing_additem_newitem" class="item_edit_form"> |
153 |
<div id="cataloguing_additem_newitem" class="item_edit_form page-section"> |
154 |
<form id="f" method="post" action="/cgi-bin/koha/cataloguing/additem.pl?biblionumber=[% biblio.biblionumber | html %]" name="f"> |
154 |
<form id="f" method="post" action="/cgi-bin/koha/cataloguing/additem.pl?biblionumber=[% biblio.biblionumber | html %]" name="f"> |
155 |
<input type="hidden" name="op" value="[% op | html %]" /> |
155 |
<input type="hidden" name="op" value="[% op | html %]" /> |
156 |
[% IF (popup) %] |
156 |
[% IF (popup) %] |
157 |
- |
|
|