Bug 6181: Remove CGI Scolling lists from C4::Budgets
[wip/koha-chris_n.git] / koha-tmpl / intranet-tmpl / prog / en / modules / acqui / addorderiso2709.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha &rsaquo; Acquisitions &rsaquo; Order Staged MARC Records
3 [% IF ( batch_details ) %]
4  &rsaquo; Batch [% import_batch_id %]
5 [% ELSE %]
6  &rsaquo; Batch List
7 [% END %]
8 </title>
9 [% INCLUDE 'doc-head-close.inc' %]
10 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
11 <script type="text/javascript" src="[% themelang %]/js/acq.js"></script>
12 <script type="text/JavaScript">
13 //<![CDATA[
14     $(document).ready(function() {
15         $("#files").tablesorter({
16             headers: {
17                 5: { sorter: false },
18             }
19         });
20     });
21 //]]>
22 </script>
23 </head>
24 <body>
25 [% INCLUDE 'header.inc' %]
26 [% INCLUDE 'acquisitions-search.inc' %]
27 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> &rsaquo; <a href="/cgi-bin/koha/acqui/supplier.pl?supplierid=[% booksellerid %]">[% booksellername %]</a> &rsaquo; <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basketno %]">Basket [% basketno %]</a> &rsaquo;  Add orders from iso2709 file</div>
28 <div id="doc3" class="yui-t2">
29    <div id="bd">
30        <div id="yui-main">
31            <div class="yui-b">
32              [% IF ( batch_details ) %]
33                   <h1>Add orders from [% comments %]
34                     ([% file_name %] staged on [% upload_timestamp %])
35                   </h1>
36                <div>
37                    <form action="[% scriptname %]" method="post" name="import_biblios">
38                      <table>
39                      <tr>
40                          <th>Citation</th>
41                          <th>Match?</th>
42                          <th>Order</th>
43                        </tr>
44                        [% FOREACH biblio_lis IN biblio_list %]
45                          <tr>
46                              <td>
47                                 [% biblio_lis.citation %]
48
49                              </td>
50                              <td>[% biblio_lis.overlay_status %]</td>
51                              <td><a href="/cgi-bin/koha/acqui/neworderempty.pl?booksellerid=[% booksellerid %]&amp;basketno=[% basketno %]&amp;booksellerid=[% booksellerid %]&amp;breedingid=[% biblio_lis.import_record_id %]&amp;import_batch_id=[% biblio_lis.import_batch_id %]&amp;biblionumber=[% biblio_lis.match_biblionumber %]">Add order</a></td>
52                          </tr>
53      [% IF ( biblio_lis.match_biblionumber ) %]
54     <tr>
55       <td class="highlight" colspan="3">&nbsp;&nbsp;&nbsp;Matches biblio [% biblio_lis.match_biblionumber %] (score = [% biblio_lis.match_score %]): <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% biblio_lis.match_biblionumber %]">[% biblio_lis.match_citation %]</a></td>
56     </tr>
57     [% END %]
58                       [% END %]
59                      </table>
60                    </form>
61                </div>
62               [% IF ( pages ) %]
63                 <div class="pages">
64                 Page 
65                   [% FOREACH page IN pages %]
66                     [% IF ( page.current_page ) %]
67                       <span class="current">[% page.page_number %]</span>
68                     [% ELSE %]
69                       <a class="nav" href="[% page.script_name %]?import_batch_id=[% page.import_batch_id %]&amp;offset=[% page.offset %]">[% page.page_number %]</a>
70                     [% END %]
71                   [% END %]
72               [% END %]
73              [% ELSE %]
74                <div>
75                 <h1>Choose the file to add to the basket</h1>
76                    <table id="files">
77                      <thead>
78                      <tr>
79                        <th>File name</th>
80                        <th>Comments</th>
81                        <th>Status</th>
82                        <th>Staged</th>
83                        <th># Bibs</th>
84                        <th>&nbsp;</th>
85                      </tr>
86                      </thead>
87                      <tbody>
88                      [% FOREACH batch_lis IN batch_list %]
89                      <tr>
90                         <td>[% batch_lis.file_name %]</td>
91                        <td>[% batch_lis.comments %]</td>
92                        <td>[% batch_lis.import_status %]</td>
93                        <td>[% batch_lis.upload_timestamp %]</td>
94                        <td>[% batch_lis.num_biblios %]</td>
95                        <td><a href="[% batch_lis.scriptname %]?import_batch_id=[% batch_lis.import_batch_id %]&amp;basketno=[% basketno %]&amp;booksellerid=[% booksellerid %]">Add orders</a></td>
96                      </tr>
97                      [% END %]
98                      </tbody>
99                    </table>
100                </div>
101              [% END %]
102            </div>
103         [% IF ( import_batch_id ) %]
104             <div class="yui-b">
105             <h2>Import All</h2>
106             <p>Import all the lines in the basket with the following parameters:</p>
107             <form action="/cgi-bin/koha/acqui/addorderiso2709.pl" method="post" id="Aform">
108                     <input type="hidden" name="op" value="import_records"/>
109                     <input type="hidden" name="ordernumber" value="[% ordernumber %]" />
110                     <input type="hidden" name="basketno" value="[% basketno %]" />
111                     <input type="hidden" name="booksellerid" value="[% booksellerid %]" />
112                     <input type="hidden" name="import_batch_id" value="[% import_batch_id %]" />
113
114                     [% FOREACH loop_currencie IN loop_currencies %]
115                         <input type="hidden" name="[% loop_currencie.currency %]" value="[% loop_currencie.rate %]" />
116                     [% END %]
117
118                 [% IF ( items ) %]
119                 <fieldset class="rows">
120                     <legend>Item</legend>
121                     [% IF ( NoACQframework ) %]
122                         <div class="dialog message">No ACQ framework, using default. You should create a framework with code ACQ, the items framework would be used</div>
123                     [% END %]
124
125                     [% FOREACH item IN items %]
126                     <div id="outeritemblock">
127                     <div id="itemblock">
128                         <ol>[% FOREACH iteminformatio IN item.iteminformation %]<li>
129                             <div class="subfield_line" style="[% iteminformatio.hidden %];" id="subfield[% iteminformatio.serialid %][% iteminformatio.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]">
130
131                                 <label>[% iteminformatio.subfield %] - [% IF ( iteminformatio.mandatory ) %]<b>[% END %][% iteminformatio.marc_lib %][% IF ( iteminformatio.mandatory ) %] *</b>[% END %]</label>
132                                 [% iteminformatio.marc_value %]
133                                 <input type="hidden" name="itemid" value="1" />
134                                 <input type="hidden" name="kohafield" value="[% iteminformatio.kohafield %]" />
135                                 <input type="hidden" name="tag" value="[% iteminformatio.tag %]" />
136                                 <input type="hidden" name="subfield" value="[% iteminformatio.subfield %]" />
137                                 <input type="hidden" name="mandatory" value="[% iteminformatio.mandatory %]" />
138                             </div></li>
139                         [% END %]
140                         </ol>
141                     </div><!-- /iteminformation -->
142                     </div>
143
144                     [% END %] <!-- /items -->
145                 </fieldset>
146                 [% END %] <!-- items -->
147                 <fieldset class="rows">
148                     <legend>Accounting Details</legend>
149                     <ol>
150                         <li>
151                             <!-- origquantityrec only here for javascript compatibility (additem.js needs it, useless here, usefull when receiveing an order -->
152                             <input id="origquantityrec" readonly="readonly" type="hidden" name="origquantityrec" value="1" />
153                         </li>
154                         <li>
155                             [% IF ( close ) %]
156                         <span class="label">Budget: </span>
157                                 <input type="hidden" size="20" name="budget_id" id="budget_id" value="[% budget_id %]" />[% Budget_name %]
158                             [% ELSE %]
159                             <li>
160                             <label for="currency">Currency:</label>
161                             <select name="currency" id="currency" onchange="calcNeworderTotal();">
162                             [% FOREACH loop_currencie IN loop_currencies %]
163                                     [% IF ( loop_currencie.selected ) %]<option value="[% loop_currencie.currcode %]" selected="selected">[% loop_currencie.currcode %]</option>[% ELSE %]<option value="[% loop_currencie.currcode %]">[% loop_currencie.currcode %]</option>[% END %][% END %]
164                             </select>
165                             </li>
166                             <li>
167                             <label for="budget_id">Budget: </label>
168                             <select id="budget_id" onchange="fetchSortDropbox(this.form)" size="1" name="budget_id">
169                             [% FOREACH budget_loo IN budget_loop %]
170                                 [% IF ( budget_loo.b_sel ) %]
171                                     <option value="[% budget_loo.b_id %]" selected="selected">[% budget_loo.b_txt %]</option>
172                                 [% ELSE %]
173                                     <option value="[% budget_loo.b_id %]">[% budget_loo.b_txt %]</option>
174                                 [% END %]
175                             [% END %]
176                             </select>
177                             </li>
178                             [% END %]
179                         </li>
180                         <li>
181                             <label for="notes">Notes: </label>
182                             <textarea id="notes" cols="30" rows="3" name="notes"></textarea>
183                         </li>
184                         <li><div class="hint">The 2 following fields are available for your own usage. They can be useful for statistical purposes</div>
185                             <label for="sort1">Planning value1: </label>
186
187                             [% IF CGIsort1 %]
188                                 <select id="sort1" size="1" name="sort1">
189                                 [% FOREACH sort_opt IN CGIsort1 %]
190                                     [% IF sort_opt.default %]
191                                         <option value="[% sort_opt.id %]" selected="selected">[% sort_opt.label %]</option>
192                                     [% ELSE %]
193                                         <option value="[% sort_opt.id %]">[% sort_opt.label %]</option>
194                                     [% END %]
195                                 [% END %]
196                                 </select>
197                             [% ELSE %]
198                                 <input type="text" id="sort1" size="20" name="sort1" value="[% sort1 %]" />
199                             [% END %]
200                         </li>
201                         <li>
202                             <label for="sort2">Planning value2: </label>
203
204                         [% IF CGIsort2 %]
205                             <select id="sort2" size="1" name="sort1">
206                             [% FOREACH sort_opt IN CGIsort2 %]
207                                 [% IF sort_opt.default %]
208                                     <option value="[% sort_opt.id %]" selected="selected">[% sort_opt.label %]</option>
209                                 [% ELSE %]
210                                     <option value="[% sort_opt.id %]">[% sort_opt.label %]</option>
211                                 [% END %]
212                             [% END %]
213                             </select>
214                         [% ELSE %]
215                              <input type="text" id="sort2" size="20" name="sort2" value="[% sort2 %]" />
216                         [% END %]
217                         </li>
218                         <li>
219                             
220                         </li>
221             </ol>
222                 </fieldset>
223                 <fieldset class="action">
224                     <input type="submit" value="Save" /><a class="cancel" href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basketno %]">Cancel</a>
225                 </fieldset>
226             </form>
227             </div>
228         [% END %]
229        </div>
230    </div>
231 </div>
232 </body>
233 </html>