1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha › Administration › Libraries and Groups
3 [% IF ( editcategory ) %]
4 ›[% IF ( categorycode ) %]Edit Group [% categorycode %][% ELSE %]New Group[% END %]
5 [% ELSIF ( delete_category ) %]
6 › Confirm Deletion of Group [% categorycode %]
8 ›[% IF ( heading_branches_add_branch_p ) %]New library[% ELSE %]Modify library [% branchcode %][% END %]
9 [% ELSIF ( delete_confirm ) %]
10 › Confirm deletion of library '[% branchcode %]'
13 [% INCLUDE 'doc-head-close.inc' %]
14 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
15 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.pager.js"></script>
18 [% INCLUDE 'header.inc' %]
19 [% INCLUDE 'cat-search.inc' %]
21 <div id="breadcrumbs">
22 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
23 › <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a>
24 › <a href="/cgi-bin/koha/admin/branches.pl">Libraries and Groups</a>
25 [% IF ( editcategory ) %]
26 › [% IF ( categorycode ) %]Edit Group [% categorycode %][% ELSE %]New Group[% END %]
27 [% ELSIF ( delete_category ) %]
28 › Confirm Deletion of Group [% categorycode %]
30 › [% IF ( heading_branches_add_branch_p ) %]New library[% ELSE %]Modify library [% branchcode %][% END %]
31 [% ELSIF ( delete_confirm ) %]
32 › Confirm deletion of library '[% branchcode %]'
36 <div id="doc3" class="yui-t2">
43 <script type="text/javascript">
46 // prepare DOM for YUI Toolbar
48 $(document).ready(function() {
50 $.tablesorter.defaults.widgets = ['zebra'];
51 $("#branchest").tablesorter({
53 headers: { 3:{sorter:false},4:{sorter:false},5:{sorter:false},6:{sorter:false}}
54 }).tablesorterPager({container: $("#pagerbranchest"),positionFixed: false,size: 10});
56 // YUI Toolbar Functions
58 function yuiToolbar() {
59 new YAHOO.widget.Button("newbranch");
60 new YAHOO.widget.Button("newcategory");
66 <li><a id="newbranch" href="/cgi-bin/koha/admin/branches.pl?op=add">New Library</a></li>
67 <li><a id="newcategory" href="/cgi-bin/koha/admin/branches.pl?op=editcategory">New Group</a></li>
72 [% IF ( ERROR1 ) %]<div class="dialog message">Library with that code already exists — Please enter a unique code</div>[% END %]
73 <h3>[% IF ( heading_branches_add_branch_p ) %]New library[% ELSE %]Modify library[% END %]</h3>
74 <form action="[% action %]" name="Aform" method="post">
75 <fieldset class="rows">
76 <input type="hidden" name="op" value="add_validate" />
77 [% IF ( heading_branches_add_branch_p ) %]
78 <input type="hidden" name="add" value="1" />
80 <input type="hidden" name="add" value="0" />
83 [% IF ( heading_branches_add_branch_p ) %]
84 <label for="branchcode">Library code</label>
85 <input type="text" name="branchcode" id="branchcode" size="10" maxlength="10" value="[% branchcode |html %]" />
87 <label for="branchcode">Library code</label>
88 <input type="hidden" name="branchcode" value="[% branchcode |html %]" />
93 <label for="branchname">Name</label>
94 <input type="text" name="branchname" id="branchname" size="80" value="[% branch_name |html %]" />
98 [% IF ( categoryloop ) %]<fieldset class="rows"><legend>Group(s):</legend>
100 [% FOREACH categoryloo IN categoryloop %]
101 <li><label for="[% categoryloo.categorycode %]">[% categoryloo.categoryname %]</label>
102 [% IF ( categoryloo.checked ) %]
103 <input type="checkbox" id="[% categoryloo.categorycode %]" name="[% categoryloo.categorycode %]" checked="checked" />
105 <input type="checkbox" id="[% categoryloo.categorycode %]" name="[% categoryloo.categorycode %]" />
107 <span class="hint">[% categoryloo.codedescription %]</span>
112 <fieldset class="rows">
114 <li><label for="branchaddress1">Address Line 1</label><input type="text" name="branchaddress1" id="branchaddress1" value="[% branchaddress1 |html %]" /></li>
115 <li><label for="branchaddress2">Address Line 2</label><input type="text" name="branchaddress2" id="branchaddress2" value="[% branchaddress2 |html %]" /></li>
116 <li><label for="branchaddress3">Address Line 3</label><input type="text" name="branchaddress3" id="branchaddress3" value="[% branchaddress3 |html %]" /></li>
117 <li><label for="branchcity">City</label><input type="text" name="branchcity" id="branchcity" value="[% branchcity |html %]" /></li>
118 <li><label for="branchstate">State</label><input type="text" name="branchstate" id="branchstate" value="[% branchstate |html %]" /></li>
119 <li><label for="branchzip">Zip/Postal Code</label><input type="text" name="branchzip" id="branchzip" value="[% branchzip |html %]" /></li>
120 <li><label for="branchcountry">Country</label><input type="text" name="branchcountry" id="branchcountry" value="[% branchcountry |html %]" /></li>
121 <li><label for="branchphone">Phone</label><input type="text" name="branchphone" id="branchphone" value="[% branchphone |html %]" /></li>
122 <li><label for="branchfax">Fax</label><input type="text" name="branchfax" id="branchfax" value="[% branchfax |html %]" /></li>
123 <li><label for="branchemail">Email</label><input type="text" name="branchemail" id="branchemail" value="[% branchemail |html %]" /></li>
124 <li><label for="branchurl">url</label><input type="text" name="branchurl" id="branchurl" value="[% branchurl |html %]" /></li>
125 <li><label for="branchip">IP</label><input type="text" name="branchip" id="branchip" value="[% branchip |html %]" /> <span class="hint">Can be entered as a single IP, or a subnet such as 192.168.1.*</span></li>
127 <li><label for="branchprinter">Library Printer</label>
128 <select id="branchprinter" name="branchprinter">
129 <option value="">None</option>
130 [% FOREACH printerloo IN printerloop %]
131 [% IF ( printerloo.selected ) %]
132 <option value="[% printerloo.value %]" selected="selected">[% printerloo.branchprinter %]</option>
134 <option value="[% printerloo.value %]">[% printerloo.branchprinter %]</option>
139 <li><label for="branchnotes">Notes</label><input type="text" name="branchnotes" id="branchnotes" value="[% branchnotes |html %]" /></li>
142 <fieldset class="action"><input type="submit" value="Submit" /> <a class="cancel" href="/cgi-bin/koha/admin/branches.pl">Cancel</a></fieldset>
146 [% IF ( delete_confirm ) %]
147 <form action="[% action %]" method="post">
148 <fieldset><legend>Confirm deletion of [% branchname %] ([% branchcode %])?</legend><input type="hidden" name="op" value="delete_confirmed" />
149 <input type="hidden" name="branchcode" value="[% branchcode |html %]" />
150 <input type="hidden" name="branchname" value="[% branchname |html %]">
151 <fieldset class="action"><input type="submit" value="Delete Library" /> <a class="cancel" href="/cgi-bin/koha/admin/branches.pl">Cancel</a></fieldset>
157 [% IF ( message ) %]<div class="dialog message">
158 [% message %]</div>[% END %]
159 [% IF ( MESSAGE1 ) %]<div class="dialog message">Library not saved — code and/or name missing</div>[% END %]
160 [% IF ( MESSAGE2 ) %]<div class="dialog message">Library saved</div>[% END %]
161 [% IF ( MESSAGE3 ) %]<div class="dialog message">Library deleted</div>[% END %]
162 [% IF ( MESSAGE4 ) %]<div class="dialog message">Library category added</div>[% END %]
163 [% IF ( MESSAGE5 ) %]<div class="dialog message">Library category modified</div>[% END %]
164 [% IF ( MESSAGE6 ) %]<div class="dialog message">Library category deleted</div>[% END %]
165 [% IF ( MESSAGE7 ) %]<div class="dialog message">Library cannot be deleted because there are patrons and items using that library</div>[% END %]
166 [% IF ( MESSAGE8 ) %]<div class="dialog message">Category cannot be deleted because there are libraries using that category</div>[% END %]
167 [% IF ( MESSAGE9 ) %]<div class="dialog message">Category cannot be added, categorycode already exists</div>[% END %]
168 [% IF ( MESSAGE10 ) %]<div class="dialog message">Library cannot be deleted because there are items held by that library</div>[% END %]
169 [% IF ( MESSAGE11 ) %]<div class="dialog message">Library cannot be deleted because there are patrons registered at that library</div>[% END %]
170 [% IF ( branches ) %]
171 <span id="pagerbranchest" class="pager">
172 <form class="formpager"> <strong>page(s)</strong> :
173 <img src="[% interface %]/prog/img/first.png" class="first"/>
174 <img src="[% interface %]/prog/img/prev.png" class="prev"/>
175 <input type="text" size="5" class="pagedisplay"/>
176 <img src="[% interface %]/prog/img/next.png" class="next"/>
177 <img src="[% interface %]/prog/img/last.png" class="last"/>
179 <select class="pagesize">
180 <option selected="selected" value="10">10</option>
181 <option value="20">20</option>
182 <option value="30">30</option>
183 <option value="40">40</option>
184 <option value="50">50</option>
185 <option value="100">100</option>
189 <table id="branchest">
196 <!-- <th>Printer</th> -->
197 <th colspan="2"> </th>
199 [% FOREACH branche IN branches %]
200 [% IF ( loop.odd ) %]
203 <tr class="highlight">
205 <td>[% branche.branch_name |html %]</td>
206 <td>[% branche.branch_code |html %]</td>
208 [% IF ( branche.address_empty_p ) %]
211 [% IF ( branche.branchaddress1 ) %]
212 [% branche.branchaddress1 |html %][% END %]
213 [% IF ( branche.branchaddress2 ) %]
214 <br />[% branche.branchaddress2 |html %][% END %]
215 [% IF ( branche.branchaddress3 ) %]
216 <br />[% branche.branchaddress3 |html %][% END %]
217 [% IF ( branche.branchcity ) %]
218 <br />[% branche.branchcity |html %][% END %][% IF ( branche.branchstate ) %],
219 [% branche.branchstate |html %][% END %]
220 [% IF ( branche.branchzip ) %]
221 [% branche.branchzip |html %][% END %]
222 [% IF ( branche.branchcountry ) %]
223 <br />[% branche.branchcountry |html %][% END %]
224 [% IF ( branche.branchphone ) %]
225 <br />Ph: [% branche.branchphone |html %][% END %]
226 [% IF ( branche.branchfax ) %]
227 <br />Fax: [% branche.branchfax |html %][% END %]
228 [% IF ( branche.branchemail ) %]
229 <br /><a href="mailto:[% branche.branchemail %]">[% branche.branchemail |html %]</a>[% END %]
230 [% IF ( branche.branchurl ) %]
231 <br /><a href="[% branche.branchurl %]">[% branche.branchurl |html %]</a>[% END %]
232 [% IF ( branche.branchnotes ) %]
233 <br />Notes: [% branche.branchnotes |html %][% END %]
237 [% UNLESS ( branche.no_categories_p ) %]
238 [% FOREACH category_lis IN branche.category_list %]
239 [% category_lis.categoryname %]<br />
244 [% branche.branchip %]
247 [% branche.branchprinter %]
250 <a href="[% branche.action %]?op=edit&branchcode=[% branche.value |url %]">Edit</a>
253 <a href="[% branche.action %]?branchcode=[% branche.value |url %]&branchname=[% branche.branch_name |url %]&op=delete">Delete</a>
259 <div class="dialog message">There are no libraries defined. <a href="/cgi-bin/koha/admin/branches.pl?op=add">Start defining libraries</a>.</div>
262 [% IF ( branchcategories ) %]
263 [% FOREACH branchcategorie IN branchcategories %]
264 <h3>Group(s): [% IF ( branchcategorie.properties ) %]Properties[% ELSE %][% IF ( branchcategorie.searchdomain ) %]Search Domain[% END %][% END %]</h3>
273 [% IF ( branchcategorie.catloop ) %][% FOREACH catloo IN branchcategorie.catloop %]
275 <td>[% catloo.categoryname %]</td>
276 <td>[% catloo.categorycode %]</td>
277 <td>[% catloo.codedescription %]</td>
278 <td><a href="[% catloo.action %]?op=editcategory&categorycode=[% catloo.categorycode |url %]">Edit</a>
280 <td><a href="[% catloo.action %]?op=delete_category&categorycode=[% catloo.categorycode |url %]">Delete</a>
283 [% END %][% ELSE %]<tr><td colspan="5">No [% IF ( branchcategorie.properties ) %]Properties[% ELSIF ( branchcategorie.searchdomain ) %]Search Domain[% END %] Defined</td></tr>[% END %]
287 <p>No Groups defined.</p>
288 [% END %] <!-- NAME="branchcategories" -->
291 [% IF ( editcategory ) %]
292 <h3>[% IF ( categorycode ) %]Edit Group [% categorycode %][% ELSE %]Add Group[% END %]</h3>
293 <form action="[% action %]" name="Aform" method="post">
294 <input type="hidden" name="op" value="addcategory_validate" />
295 [% IF ( categorycode ) %]
296 <input type="hidden" name="add" value="0">
298 <input type="hidden" name="add" value="1">
300 <fieldset class="rows">
303 [% IF ( categorycode ) %]
304 <span class="label">Category code: </span>
305 <input type="hidden" name="categorycode" id="categorycode" value="[% categorycode |html %]" />
308 <label for="categorycode">Category code:</label>
309 <input type="text" name="categorycode" id="categorycode" size="10" maxlength="10" value="[% categorycode |html %]" />
313 <label for="categoryname">Name: </label>
314 <input type="text" name="categoryname" id="categoryname" size="32" maxlength="32" value="[% categoryname |html %]" />
317 <label for="codedescription">Description: </label>
318 <input type="text" name="codedescription" id="codedescription" size="70" value="[% codedescription |html %]" />
321 <label for="categorytype">Category Type: </label>
322 <select id="categorytype" name="categorytype">
323 [% FOREACH categorytyp IN categorytype %]
324 [% IF ( categorytyp.selected ) %]
325 <option value="[% categorytyp.type %]" selected="selected">
327 <option value="[% categorytyp.type %]">
328 [% END %] [% categorytyp.type %]</option>
334 <fieldset class="action"><input type="submit" value="Update" /></fieldset>
338 [% IF ( delete_category ) %]
339 [% UNLESS ( MESSAGE8 ) %]
340 <div class="dialog message">
342 <form action="[% action %]" method="post">
343 <input type="hidden" name="op" value="categorydelete_confirmed" />
344 <input type="hidden" name="categorycode" value="[% categorycode |html %]" />
345 <input type="submit" value="YES" />
347 <form action="[% action %]" method="post"><input type="hidden" name="op" value="">
348 <input type="submit" value="NO" />
357 [% INCLUDE 'admin-menu.inc' %]
360 [% INCLUDE 'intranet-bottom.inc' %]