ca7ed318fb3a63f99753f48befa04612f7942262
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / smart-rules.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha &rsaquo; Administration &rsaquo; Issuing Rules</title>
3 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4
5 <script type="text/javascript">
6 //<![CDATA[
7 $(document).ready(function() {
8         $('#selectlibrary').find("input:submit").hide();
9         $('#branch').change(function() {
10                 $('#selectlibrary').submit();
11         });
12 });
13 //]]>
14 </script>
15
16 </head>
17 <body>
18 <!-- TMPL_INCLUDE NAME="header.inc" -->
19 <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
20
21 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> &rsaquo;  Issuing Rules</div>
22
23 <div id="doc3" class="yui-t1">
24
25 <div id="bd">
26     <div id="yui-main">
27     <div class="yui-b">
28     <h1 class="parameters">
29         <!-- TMPL_IF NAME="humanbranch" -->
30             Defining issuing rules for "<!-- TMPL_VAR NAME="humanbranch" -->"
31         <!-- TMPL_ELSE -->
32             Defining default issuing rules
33         <!-- /TMPL_IF -->
34     </h1>
35     <div class="help">
36         <p>The rules are applied from most specific to less specific, using the first found in this order:</p>
37         <ul>
38             <li>same library, same patron type, same item type</li>
39             <li>same library, same patron type, default item type</li>
40             <li>same library, default patron type, same item type</li>
41             <li>same library, default patron type, default item type</li>
42             <li>default library, same patron type, same item type</li>
43             <li>default library, same patron type, default item type</li>
44             <li>default library, default patron type, same item type</li>
45             <li>default library, default patron type, default item type</li>
46         </ul>
47         <p>To modify a rule, create a new one with the same patron type and item type.</p>
48     </div>
49     <div id="bloc100">
50         <form method="get" action="/cgi-bin/koha/admin/smart-rules.pl" id="selectlibrary">
51         Select a library :
52             <select name="branch" id="branch" style="width:20em;">
53                 <option value="*">Default</option>
54             <!-- TMPL_LOOP NAME="branchloop" -->
55                                 <!-- TMPL_IF NAME="selected" --><option value="<!-- TMPL_VAR NAME="value" -->" selected="selected"><!-- TMPL_VAR NAME="branchname" --></option><!-- TMPL_ELSE --><option value="<!-- TMPL_VAR NAME="value" -->"><!-- TMPL_VAR NAME="branchname" --></option><!-- /TMPL_IF -->
56             <!-- /TMPL_LOOP -->
57             </select>
58         </form>
59                 <br />
60                 <br />
61         <form method="post" action="/cgi-bin/koha/admin/smart-rules.pl">
62             <input type="hidden" name="op" value="add" />
63             <table>
64             <tr>
65                 <th>Patron Category</th>
66                 <th>Item Type</th>
67                 <th>Fine Amount</th>
68                 <th>Fine Days</th>
69                 <th>Fine Grace Period</th>
70                 <th>Fine Charging Interval</th>
71                 <th>Current Checkouts Allowed</th>
72                 <th>Loan Period</th><th>&nbsp;</th>
73             </tr>
74             <!-- TMPL_LOOP NAME="rules" -->
75                 <!-- TMPL_UNLESS NAME="__odd__" -->
76                 <tr class="highlight">
77                 <!-- TMPL_ELSE -->
78                 <tr>
79                 <!-- /TMPL_UNLESS -->
80                     <td><!-- TMPL_IF NAME="default_humancategorycode" -->
81                             <em>Default</em>
82                         <!-- TMPL_ELSE -->
83                             <!-- TMPL_VAR NAME="humancategorycode" -->
84                         <!-- /TMPL_IF -->
85                     </td>
86                     <td><!-- TMPL_IF NAME="default_humanitemtype" -->
87                             <em>Default</em>
88                         <!-- TMPL_ELSE -->
89                             <!-- TMPL_VAR NAME="humanitemtype" -->
90                         <!-- /TMPL_IF -->
91                     </td>
92                     <td><!-- TMPL_VAR NAME="fine" --></td>
93                     <td>
94                         <!-- TMPL_IF NAME="finedays" -->
95                             <!-- TMPL_VAR NAME="finedays" --> day(s)
96                         <!-- /TMPL_IF -->
97                     </td>
98                     <td><!-- TMPL_IF NAME="firstremind" --><!-- TMPL_VAR NAME="firstremind" --> day(s)<!-- /TMPL_IF --></td>
99                     <td><!-- TMPL_IF NAME="chargeperiod" --><!-- TMPL_VAR NAME="chargeperiod" --> day(s)<!-- /TMPL_IF --></td>
100                     <td><!-- TMPL_IF NAME="unlimited_maxissueqty" -->
101                             Unlimited
102                         <!-- TMPL_ELSE -->
103                             <!-- TMPL_VAR NAME="maxissueqty" -->
104                         <!-- /TMPL_IF -->
105                     </td>
106                     <td><!-- TMPL_IF NAME="issuelength" --><!-- TMPL_VAR NAME="issuelength" --> day(s)<!-- /TMPL_IF --></td>
107                     <td>
108                         <a class="button" href="/cgi-bin/koha/admin/smart-rules.pl?op=delete&amp;itemtype=<!-- TMPL_VAR NAME="itemtype" -->&amp;categorycode=<!-- TMPL_VAR NAME="categorycode" -->&amp;branch=<!-- TMPL_VAR NAME="branch" -->">Delete</a>
109                     </td>
110                 </tr>
111             <!-- /TMPL_LOOP -->
112                 <tr>
113                     <td>
114                         <select name="categorycode">
115                             <option value="*">Default</option>
116                         <!-- TMPL_LOOP NAME="categoryloop" -->
117                             <option value="<!-- TMPL_VAR NAME="categorycode" -->"><!-- TMPL_VAR NAME="description" --></option>
118                         <!-- /TMPL_LOOP -->
119                         </select>
120                     </td>
121                     <td>
122                         <select name="itemtype" style="width:13em;">
123                             <option value="*">Default</option>
124                         <!-- TMPL_LOOP NAME="itemtypeloop" -->
125                             <option value="<!-- TMPL_VAR NAME="itemtype" -->"><!-- TMPL_VAR NAME="description" --></option>
126                         <!-- /TMPL_LOOP -->
127                         </select>
128                     </td>
129                     <td><input name="fine" size="4" /></td>
130                     <td><input name="finedays" size="2" /> day(s)</td>
131                     <td><input name="firstremind" size="2" /> day(s)</td>
132                     <td><input name="chargeperiod" size="2" /> day(s)</td>
133                     <td><input name="maxissueqty" size="3" /></td>
134                     <td><input name="issuelength" size="3" /> day(s)</td>
135                     <td><input type="hidden" name="branch" value="<!-- TMPL_VAR NAME="branch" -->"/><input type="submit" value="Add" class="submit" /></td>
136                 </tr>
137             </table>
138         </form>
139     </div>
140     <div class="help">
141         <h4>Defaults for this library</h4>
142         <p>You can set a default maximum number of checkouts and hold policy that will be used if none is defined below for a particular item type or category.</p>
143     </div>
144     <div>
145         <form method="post" action="/cgi-bin/koha/admin/smart-rules.pl">
146             <input type="hidden" name="op" value="set-branch-defaults" />
147             <input type="hidden" name="branch" value="<!-- TMPL_VAR NAME="branch" -->"/>
148             <table>
149                 <tr>
150                     <th>&nbsp;</th>
151                     <th>Total Current Checkouts Allowed</th>
152                     <th>Hold Policy</th>
153                     <th>&nbsp;</th>
154                 </tr>
155                 <tr>
156                     <td><em>Defaults<!-- TMPL_UNLESS NAME="default_rules" --> (not set)<!-- /TMPL_IF --></em></td>
157                     <td><input name="maxissueqty" size="3" value="<!-- TMPL_VAR NAME="default_maxissueqty" -->"/></td>
158                     <td>
159                         <select name="holdallowed">
160                             <!-- TMPL_IF NAME="default_holdallowed_any" -->
161                             <option value="2" selected="selected">
162                             <!-- TMPL_ELSE -->
163                             <option value="2">
164                             <!-- /TMPL_IF -->
165                                 From Any Library
166                             </option>
167                             <!-- TMPL_IF NAME="default_holdallowed_same" -->
168                             <option value="1" selected="selected">
169                             <!-- TMPL_ELSE -->
170                             <option value="1">
171                             <!-- /TMPL_IF -->
172                                 From Home Library
173                             </option>
174                             <!-- TMPL_IF NAME="default_holdallowed_none" -->
175                             <option value="0" selected="selected">
176                             <!-- TMPL_ELSE -->
177                             <option value="0">
178                             <!-- /TMPL_IF -->
179                                 No Holds Allowed
180                             </option>
181                         </select>
182                     </td>
183                     <td><input type="submit" value="Save" class="submit" /></td>
184                     <td>
185                         <a class="button" href="/cgi-bin/koha/admin/smart-rules.pl?op=delete-branch-cat&amp;categorycode=*&amp;branch=<!-- TMPL_VAR NAME="branch" -->">Unset</a>
186                     </td>
187                 </tr>
188             </table>
189         </form>
190     </div>
191     <!-- TMPL_IF NAME="show_branch_cat_rule_form" -->
192     <div class="help">
193         <p>For this library, you can specify the maximum number of loans that 
194             a patron of a given category can make, regardless of the item type.
195         </p>
196         <p>If the total amount loanable for a given patron category is left blank,
197            no limit applies, except possibly for a limit you define for a specific item type.
198         </p>
199     </div>
200     <div>
201         <form method="post" action="/cgi-bin/koha/admin/smart-rules.pl">
202             <input type="hidden" name="op" value="add-branch-cat" />
203             <input type="hidden" name="branch" value="<!-- TMPL_VAR NAME="branch" -->"/>
204             <table>
205                 <tr>
206                     <th>Patron Category</th>
207                     <th>Total Current Checkouts Allowed</th>
208                     <th>&nbsp;</th>
209                 </tr>
210                 <!-- TMPL_LOOP NAME="branch_cat_rule_loop" -->
211                     <!-- TMPL_UNLESS NAME="__odd__" -->
212                     <tr class="highlight">
213                     <!-- TMPL_ELSE -->
214                     <tr>
215                     <!-- /TMPL_UNLESS -->
216                         <td><!-- TMPL_IF NAME="default_humancategorycode" -->
217                                 <em>Default</em>
218                             <!-- TMPL_ELSE -->
219                                 <!-- TMPL_VAR NAME="humancategorycode" -->
220                             <!-- /TMPL_IF -->
221                         </td>
222                         <td><!-- TMPL_IF NAME="unlimited_maxissueqty" -->
223                                 Unlimited
224                             <!-- TMPL_ELSE -->
225                                 <!-- TMPL_VAR NAME="maxissueqty" -->
226                             <!-- /TMPL_IF -->
227                         </td>
228                         <td>
229                             <a class="button" href="/cgi-bin/koha/admin/smart-rules.pl?op=delete-branch-cat&amp;categorycode=<!-- TMPL_VAR NAME="categorycode" -->&amp;branch=<!-- TMPL_VAR NAME="branch" -->">Delete</a>
230                         </td>
231                     </tr>
232                 <!-- /TMPL_LOOP -->
233                 <tr>
234                     <td>
235                         <select name="categorycode">
236                         <!-- TMPL_LOOP NAME="categoryloop" -->
237                             <option value="<!-- TMPL_VAR NAME="categorycode" -->"><!-- TMPL_VAR NAME="description" --></option>
238                         <!-- /TMPL_LOOP -->
239                         </select>
240                     </td>
241                     <td><input name="maxissueqty" size="3" /></td>
242                     <td><input type="submit" value="Add" class="submit" /></td>
243                 </tr>
244             </table>
245         </form>
246     </div>
247     <!-- /TMPL_IF -->
248     <div class="help">
249         <p>
250             For this library, you can edit rules for given itemtypes, regardless
251             of the patron's category.
252         </p>
253         <p>
254             Currently, this means hold policies.
255             The various policies have the following effects:
256         </p>
257         <ul>
258             <li><strong>From Any Library:</strong> Patrons from any library may put this item on hold. <cite>(default if none is defined)</cite></li>
259             <li><strong>From Home Library:</strong> Only patrons from the item's home library may put this book on hold.</li>
260             <li><strong>No Holds Allowed:</strong> No patron may put this book on hold.</li>
261         </ul>
262         <p>
263             Note that if the system preference
264             <code>AllowHoldPolicyOverride</code> is enabled, these policies can
265             be overridden by your circulation staff. Also, these policies are
266             based on the patron's home branch, <em>not</em> the branch that
267             the reserving staff member is from.
268         </p>
269     </div>
270     <div>
271         <form method="post" action="/cgi-bin/koha/admin/smart-rules.pl">
272             <input type="hidden" name="op" value="add-branch-item" />
273             <input type="hidden" name="branch" value="<!-- TMPL_VAR NAME="branch" -->"/>
274             <table>
275                 <tr>
276                     <th>Item Type</th>
277                     <th>Hold Policy</th>
278                     <th>&nbsp;</th>
279                 </tr>
280                 <!-- TMPL_LOOP NAME="branch_item_rule_loop" -->
281                     <!-- TMPL_UNLESS NAME="__odd__" -->
282                     <tr class="highlight">
283                     <!-- TMPL_ELSE -->
284                     <tr>
285                     <!-- /TMPL_UNLESS -->
286                         <td><!-- TMPL_IF NAME="default_humanitemtype" -->
287                                 <em>Default</em>
288                             <!-- TMPL_ELSE -->
289                                 <!-- TMPL_VAR NAME="humanitemtype" -->
290                             <!-- /TMPL_IF -->
291                         </td>
292                         <td><!-- TMPL_IF NAME="holdallowed_any" -->
293                                 From Any Library
294                             <!-- TMPL_ELSIF NAME="holdallowed_same" -->
295                                 From Home Library
296                             <!-- TMPL_ELSE -->
297                                 No Holds Allowed
298                             <!-- /TMPL_IF -->
299                         </td>
300                         <td>
301                             <a class="button" href="/cgi-bin/koha/admin/smart-rules.pl?op=delete-branch-item&amp;itemtype=<!-- TMPL_VAR NAME="itemtype" -->&amp;branch=<!-- TMPL_VAR NAME="branch" -->">Delete</a>
302                         </td>
303                     </tr>
304                 <!-- /TMPL_LOOP -->
305                 <tr>
306                     <td>
307                         <select name="itemtype">
308                         <!-- TMPL_LOOP NAME="itemtypeloop" -->
309                             <option value="<!-- TMPL_VAR NAME="itemtype" -->"><!-- TMPL_VAR NAME="description" --></option>
310                         <!-- /TMPL_LOOP -->
311                         </select>
312                     </td>
313                     <td>
314                         <select name="holdallowed">
315                             <option value="2">From Any Library</option>
316                             <option value="1">From Home Library</option>
317                             <option value="0">No Holds Allowed</option>
318                         </select>
319                     </td>
320                     <td><input type="submit" value="Add" class="submit" /></td>
321                 </tr>
322             </table>
323         </form>
324     </div>
325 </div>
326
327 </div>
328 <div class="yui-b">
329 <!-- TMPL_INCLUDE NAME="admin-menu.inc" -->
330 </div>
331 </div>
332 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->