Bug 15758: Koha::Libraries - Remove GetBranchesLoop
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / course_reserves / add_items-step2.tt
1 [% USE Branches %]
2 [% INCLUDE 'doc-head-open.inc' %]
3 <title>Koha &rsaquo; Course reserves &rsaquo; Add items</title>
4 [% INCLUDE 'doc-head-close.inc' %]
5 </head>
6
7 <body id="courses_add_items_step2" class="course">
8
9 [% INCLUDE 'header.inc' %]
10 [% INCLUDE 'cat-search.inc' %]
11
12 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/course_reserves/course-reserves.pl">Course reserves</a> &rsaquo; Reserve <i><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% item.biblionumber %]">[% item.title %]</a></i> for <i><a href="/cgi-bin/koha/course_reserves/course-details.pl?course_id=[% course.course_id %]">[% course.course_name %]</a></i></div>
13
14 <div id="doc" class="yui-t7">
15     <div id="bd">
16
17         [% IF course_reserve %]<div class="dialog message" id="already_on_reserve_this">This course already has this item on reserve.</div>[% END %]
18         [% IF course_item %]<div class="dialog message" id="already_on_reserve">Number of courses reserving this item: [% course_item.course_reserves.size %]</div>[% END %]
19
20         <form method="post" action="/cgi-bin/koha/course_reserves/add_items.pl">
21             <input type="hidden" name="course_id" value="[% course.course_id %]" />
22             <input type="hidden" name="return" value="[% return %]" />
23             <input type="hidden" name="action" value="add" />
24
25             <fieldset class="rows">
26                 <legend>Add <i>[% item.title %]</i> to <i>[% course.course_name %]</i></legend>
27                 <ol>
28                     <li>
29                         <span class="label">Barcode:</span>
30                         <span id="barcode">[% item.barcode %]</span>
31                         <input type="hidden" name="itemnumber" value="[% item.itemnumber %]" />
32                     </li>
33
34                     [% IF item_level_itypes %]
35                     <li>
36                         <label class="required" for="itype">Item type:</label>
37                         <select id="itype" name="itype">
38                             <option value="">LEAVE UNCHANGED</option>
39
40                             [% FOREACH it IN itypes %]
41                                 [% IF course_item.itype && ( ( course.enabled == 'yes' && it.itemtype == item.itype ) || ( course.enabled == 'no' && it.itemtype == course_item.itype ) ) %]
42                                     <option value="[% it.itemtype %]" selected="selected">[% it.description %]</option>
43                                 [% ELSE %]
44                                     <option value="[% it.itemtype %]">[% it.description %]</option>
45                                 [% END %]
46                             [% END %]
47                         </select>
48                     </li>
49                     [% END %]
50
51                     <li>
52                         <label class="required" for="ccode">Collection code:</label>
53                         <select id="ccode" name="ccode">
54                             <option value="">LEAVE UNCHANGED</option>
55
56                             [% FOREACH c IN ccodes %]
57                                 [% IF course_item.ccode && ( ( course.enabled == 'yes' && c.authorised_value == item.ccode ) || ( course.enabled == 'no' && c.authorised_value == course_item.ccode ) ) %]
58                                     <option value="[% c.authorised_value %]" selected="selected">[% c.lib %]</option>
59                                 [% ELSE %]
60                                     <option value="[% c.authorised_value %]">[% c.lib %]</option>
61                                 [% END %]
62                             [% END %]
63                         </select>
64                     </li>
65
66                     <li>
67                         <label class="required" for="location">Shelving location:</label>
68                         <select id="location" name="location">
69                             <option value="">LEAVE UNCHANGED</option>
70
71                             [% FOREACH s IN locations %]
72                                 [% IF course_item.location && ( ( course.enabled == 'yes' && s.authorised_value == item.location ) || ( course.enabled == 'no' && s.authorised_value == course_item.location ) ) %]
73                                     <option value="[% s.authorised_value %]" selected="selected">[% s.lib %]</option>
74                                 [% ELSE %]
75                                     <option value="[% s.authorised_value %]">[% s.lib %]</option>
76                                 [% END %]
77                             [% END %]
78                         </select>
79                     </li>
80
81                     <li>
82                         <label class="required" for="holdingbranch">Holding library:</label>
83                         <select id="holdingbranch" name="holdingbranch">
84                             <option value="">LEAVE UNCHANGED</option>
85                             [% FOREACH b IN Branches.all() %]
86                                 [% IF course_item.holdingbranch && ( ( course.enabled == 'yes' && b.value == item.holdingbranch ) || ( course.enabled == 'no' && b.value == course_item.holdingbranch ) ) %]
87                                     <option value="[% b.branchcode %]" selected="selected">[% b.branchname %]</option>
88                                 [% ELSE %]
89                                     <option value="[% b.branchcode %]">[% b.branchname %]</option>
90                                 [% END %]
91                             [% END %]
92                         </select>
93                     </li>
94
95                     <li>
96                         <label for="staff_note">Staff note:</label>
97                         <textarea name="staff_note" id="staff_note">[% course_reserve.staff_note %]</textarea>
98                     </li>
99
100                     <li>
101                         <label for="public_note">Public note:</label>
102                         <textarea name="public_note" id="public_note">[% course_reserve.public_note %]</textarea>
103                     </li>
104
105                 </ol>
106             </fieldset>
107
108             <fieldset class="action">
109                 <input type="submit" id="submit" value="Save" class="submit focus" />
110
111                 <a href="/cgi-bin/koha/course_reserves/course-details.pl?course_id=[% course.course_id %]" class="cancel">Cancel</a>
112             </fieldset>
113         </form>
114     </div>
115
116 [% INCLUDE 'intranet-bottom.inc' %]