Bug 10904: Limit patron update request management by branch
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / serials / routing.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha &rsaquo; Serials &rsaquo; [% title |html %] &rsaquo; [% IF ( op ) %]Create Routing List[% ELSE %]Edit routing list[% END %]</title>
3 [% INCLUDE 'doc-head-close.inc' %]
4 <script type="text/javascript">
5 <!--
6
7 function reorder_item(sid,rid,rank){
8     var mylocation = 'reorder_members.pl?subscriptionid='+sid+'&routingid='+rid+'&rank='+rank;
9     window.location.href=mylocation; 
10 }
11
12     function userPopup() {
13         window.open("/cgi-bin/koha/serials/add_user_search.pl",
14             'PatronPopup',
15             'width=740,height=450,location=yes,toolbar=no,'
16             + 'scrollbars=yes,resize=yes'
17         );
18     }
19
20     function add_user(borrowernumber) {
21         var myurl = "routing.pl?subscriptionid="+[% subscriptionid %]+"&borrowernumber="+borrowernumber+"&op=add";
22         window.location.href = myurl;
23     }
24
25 //-->
26 </script>
27 </head>
28 <body id="ser_routing" class="ser">
29 [% INCLUDE 'header.inc' %]
30 [% INCLUDE 'serials-search.inc' %]
31
32 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/serials/serials-home.pl">Serials</a> &rsaquo; <a href="/cgi-bin/koha/serials/subscription-detail.pl?subscriptionid=[% subscriptionid %]"><i>[% title |html %]</i></a> &rsaquo; [% IF ( op ) %]Create Routing List[% ELSE %]Edit routing list[% END %]</div>
33
34 <div id="doc3" class="yui-t2">
35    
36    <div id="bd">
37         <div id="yui-main">
38         <div class="yui-b">
39
40
41 [% IF ( op ) %]
42 <h1>Create routing list for <i>[% title |html %]</i></h1>
43 [% ELSE %]
44 <h1>Edit routing list for <i>[% title |html %]</i></h1>
45 [% END %]
46
47 <form method="post" action="routing.pl">
48 <input type="hidden" name="op" value="save" />
49 <input type="hidden" name="subscriptionid" value="[% subscriptionid %]" />
50 <fieldset class="rows">
51         <ol>
52                 <li><label for="date_selected">Issue: </label>
53 <select name="date_selected" id="date_selected">
54 [% FOREACH date IN dates %]
55 [% IF ( date.selected ) %]<option value="[% date.serialseq %] ([% date.publisheddate %])" selected="selected">[% date.serialseq %] ([% date.publisheddate %])</option>[% ELSE %]<option value="[% date.serialseq %] ([% date.publisheddate %])">[% date.serialseq %] ([% date.publisheddate %])</option>[% END %]
56 [% END %]
57 </select> [% issue %]</li>
58
59 <li>
60     <span class="label">Recipients:</span>
61     [% IF memberloop %]
62         <table style="clear:none;margin:0;">
63             <tr><th>Name</th>
64                 <th>Rank</th>
65                 <th>Delete</th>
66             </tr>
67             [% USE m_loop = iterator(memberloop) %]
68             [% FOREACH member IN m_loop %]
69             <tr><td>[% member.name %]</td>
70                 <td>
71                     <select name="itemrank" onchange="reorder_item([%- subscriptionid -%], [%- member.routingid -%], this.value)">
72                     [% rankings = [1 .. m_loop.size] %]
73                     [% FOREACH r IN rankings %]
74                         [% IF r == member.ranking %]
75                           <option selected="selected" value="[% r %]">[% r %]</option>
76                         [% ELSE %]
77                           <option value="[% r %]">[% r %]</option>
78                         [% END %]
79                     [% END %]
80                     </select>
81                 </td>
82                 <td><a href="/cgi-bin/koha/serials/routing.pl?routingid=[% member.routingid %]&amp;subscriptionid=[% subscriptionid %]&amp;op=delete">Delete</a></td>
83             </tr>
84             [% END %]
85         </table>
86     [% END %]
87
88     <p style="margin-left:10em;">
89         <input type="button" onclick="userPopup()" value="Add recipients" />
90         [% IF memberloop %]
91             <a href="/cgi-bin/koha/serials/routing.pl?subscriptionid=[% subscriptionid %]&amp;op=delete" class="button">Delete all</a>
92         [% END %]
93     </p>
94 </li>
95
96         <li><label for="notes">Notes:</label><textarea name="notes" id="notes" rows="3" cols="50">[% routingnotes %]</textarea></li>
97         </ol>
98
99 </fieldset>
100 <fieldset class="action"><input type="submit" name="submit" value="Save" /></fieldset>
101 </form>
102
103
104 </div>
105 </div>
106
107 <div class="yui-b">
108 [% INCLUDE 'serials-menu.inc' %]
109 </div>
110 </div>
111 [% INCLUDE 'intranet-bottom.inc' %]