bug 2000 - fix order of issuingrule lookup
[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>Amount</th>
68                 <th>Grace Period</th>
69                 <th>Charging Interval</th>
70                 <th>Amoun Loanable</th>
71                 <th>Loan time</th><th>&nbsp;</th>
72             </tr>
73             <!-- TMPL_LOOP NAME="rules" -->
74                 <tr>
75                     <td><!-- TMPL_IF NAME="default_humancategorycode" -->
76                             <em>Default</em>
77                         <!-- TMPL_ELSE -->
78                             <!-- TMPL_VAR NAME="humancategorycode" -->
79                         <!-- /TMPL_IF -->
80                     </td>
81                     <td><!-- TMPL_IF NAME="default_humanitemtype" -->
82                             <em>Default</em>
83                         <!-- TMPL_ELSE -->
84                             <!-- TMPL_VAR NAME="humanitemtype" -->
85                         <!-- /TMPL_IF -->
86                     </td>
87                     <td>$<!-- TMPL_VAR NAME="fine" --></td>
88                     <td><!-- TMPL_IF NAME="firstremind" --><!-- TMPL_VAR NAME="firstremind" --> day(s)<!-- /TMPL_IF --></td>
89                     <td><!-- TMPL_IF NAME="chargeperiod" --><!-- TMPL_VAR NAME="chargeperiod" --> day(s)<!-- /TMPL_IF --></td>
90                     <td><!-- TMPL_VAR NAME="maxissueqty" --></td>
91                     <td><!-- TMPL_IF NAME="issuelength" --><!-- TMPL_VAR NAME="issuelength" --> day(s)<!-- /TMPL_IF --></td>
92                     <td>
93                         <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>
94                     </td>
95                 </tr>
96             <!-- /TMPL_LOOP -->
97                 <tr>
98                     <td>
99                         <select name="categorycode">
100                             <option value="*">Default</option>
101                         <!-- TMPL_LOOP NAME="categoryloop" -->
102                             <option value="<!-- TMPL_VAR NAME="categorycode" -->"><!-- TMPL_VAR NAME="description" --></option>
103                         <!-- /TMPL_LOOP -->
104                         </select>
105                     </td>
106                     <td>
107                         <select name="itemtype" style="width:13em;">
108                             <option value="*">Default</option>
109                         <!-- TMPL_LOOP NAME="itemtypeloop" -->
110                             <option value="<!-- TMPL_VAR NAME="itemtype" -->"><!-- TMPL_VAR NAME="description" --></option>
111                         <!-- /TMPL_LOOP -->
112                         </select>
113                     </td>
114                     <td>$<input name="fine" size="4" /></td>
115                     <td><input name="firstremind" size="2" /> day(s)</td>
116                     <td><input name="chargeperiod" size="2" /> day(s)</td>
117                     <td><input name="maxissueqty" size="3" /></td>
118                     <td><input name="issuelength" size="3" /> day(s)</td>
119                     <td><input type="hidden" name="branch" value="<!-- TMPL_VAR NAME="branch" -->"/><input type="submit" value="Add" class="submit" /></td>
120                 </tr>
121             </table>
122         </form>
123     </div>
124 </div>
125
126 </div>
127 <div class="yui-b">
128 <!-- TMPL_INCLUDE NAME="admin-menu.inc" -->
129 </div>
130 </div>
131 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->