00c27273ce201f449cda40f44f729d21e96e73b7
[working/Evergreen.git] / Open-ILS / src / templates / acq / common / li_table.tt2
1 <script type="text/javascript" src="[% ctx.media_prefix %]/js/ui/default/acq/common/base64.js"> </script>
2 <script type="text/javascript" src='[% ctx.media_prefix %]/js/ui/default/acq/common/vlagent.js'> </script>
3 <script type="text/javascript" src='[% ctx.media_prefix %]/js/ui/default/acq/common/li_table.js'> </script>
4 <script type="text/javascript" src='[% ctx.media_prefix %]/js/ui/default/acq/financial/claim_voucher.js'> </script>
5 <div id='acq-lit-table-container'>
6     <div id='acq-lit-table-div' class='hidden'>
7
8         <!-- Lineitem (bib record) list -->
9         <table id='acq-lit-table' class='oils-generic-table'>
10             <thead>
11                 <tr>
12                     <th colspan='0'>
13                         <table style='width:100%;'>
14                             <tr>
15                                 <td>
16                                     <span>
17                                         <select id="acq-lit-li-actions-selector">
18                                             <option mask='*'  value='_'>--Actions--</option>
19                                             <option mask='sr' value='save_picklist'>Save Items To Selection List</option>
20                                             <option mask='pl' value='selector_ready'>Mark Ready for Selector</option>
21                                             <option mask='pl' value='order_ready'>Mark Ready for Order</option>
22                                             <option mask='*'  value='delete_selected'>Delete Selected Items</option>
23                                             <option mask='*'  value='add_brief_record'>Add Brief Record</option>
24                                             <option mask='*'  value='export_attr_list'>Export Single Attribute List</option>
25                                             <option mask='*'  value='batch_apply_funds'>Apply Funds to Selected Items</option>
26                                             <option mask='po' value='' disabled='disabled'>----PO----</option>
27                                             <option mask='sr|pl' value='create_order'>Create Purchase Order</option>
28                                             <option mask='po' value='create_assets'>Load Bibs and Items</option>
29                                             <option mask='po' value='cancel_lineitems'>Cancel Selected Lineitems</option>
30                                             <option mask='po' value='change_claim_policy'>Change Claim Policy</option>
31                                             <option mask='po' value='receive_po'>Mark Purchase Order as Received</option>
32                                             <option mask='po' value='rollback_receive_po'>Un-Receive Purchase Order</option>
33                                             <option mask='po' value='print_po'>Print Purchase Order</option>
34                                             <option mask='po' value='po_history'>View PO History</option>
35                                             <option mask='po' value='batch_create_invoice'>[% l('Create Invoice From Selected Lineitems') %]</option>
36                                             <option mask='po' value='batch_link_invoice'>[% l('Link To Invoice for Selected Lineitems') %]</option>
37                                         </select>
38                                         <span id="acq-lit-export-attr-holder" class="hidden">
39                                             <input dojoType="dijit.form.FilteringSelect" id="acq-lit-export-attr" jsId="acqLitExportAttrSelector" labelAttr="description" searchAttr="description" />
40                                             <span dojoType="dijit.form.Button" jsId="acqLitExportAttrButton">Export List</span>
41                                         </span>
42                                         <span id="acq-lit-cancel-reason" class="hidden">
43                                             <span id="acq-lit-cancel-reason-selector"></span>
44                                             <span dojoType="dijit.form.Button" jsId="acqLitCancelLineitemsButton">Cancel Line Items</span>
45                                         </span>
46                                     </span>
47                                     <span id='acq-lit-generic-progress' class='hidden'>
48                                         <span dojoType="dijit.ProgressBar" style="width:300px" jsId="litGenericProgress"></span>
49                                     </span>
50                                 </td>
51                                 <td>
52                                     <div style='width:100%;text-align:right;'>
53                                         <span style='padding-right:15px;'>
54                                             <a href='javascript:void(0);' id='acq-lit-prev' style='visibility:hidden'>&#171; Previous</a>
55                                             <a href='javascript:void(0);' id='acq-lit-next' style='visibility:hidden'>Next &#187;</a>
56                                         </span>
57                                     </div>
58                                 </td>
59                             </tr>
60                         </table>
61                     </th>
62                 </tr>
63             </thead>
64             <tbody><tr><td colspan='0' style='height:20px;'/></tr></tbody>
65             <tbody style='font-weight:bold;border:1px solid #aaa;'>
66                 <tr>
67                     <td><span><a id='acq-lit-select-toggle' href='javascript:void(0);'>&#x2713</a></span></td>
68                     <td>Line Items</td>
69                     <td>Items</td>
70                     <td>Notes</td>
71                     <td>Actions</td>
72                     <td>Status</td>
73                     <td>Estimated Price</td>
74                 </tr>
75             </tbody>
76             <tbody id='acq-lit-tbody'>
77                 <tr id='acq-lit-row' class='acq-lit-row'>
78                     <td name='selector'><input type='checkbox' name='selectbox'/></td>
79                     <td style='width:75%;' name='bib-info-cell'>
80                         <table style='width:100%;'>
81                             <tbody>
82                                 <tr>
83                                     <td rowspan='3' style='width:43px;'><img style='width:40px;height:65px;' name='jacket'></td>
84                                     <td style='width:70%;font-weight:bold;'>
85                                         <span name="bib_origin" class="hidden">
86                                             <img src="/opac/images/book-icon.png" />
87                                         </span><a attr='title' href='javascript:void(0);'></a>
88                                     </td>
89                                     <td rowspan='2' style='text-align:right'>
90                                     </td>
91                                 </tr>
92                                 <tr class='acq-lit-alt-row'>
93                                     <td colspan='0'>
94                                         <span attr='author'></span>
95                                         <span attr='isbn'></span>
96                                         <span attr='issn'></span>
97                                         <span attr='edition'></span>
98                                         <span attr='pubdate'></span>
99                                         <span attr='publisher'></span>
100                                         <span name='source_label'></span>
101                                     </td>
102                                 </tr>
103                                 <tr>
104                                     <td colspan='0'>
105                                         <span name="liid"># </span> 
106                                         <span name="catalog" class='hidden'> | <a title='Show In Catalog' name="catalog_link" href="javascript:void(0);">&#x279F; catalog</a></span> 
107                                         <span name="link_to_catalog" class='hidden'> | <a title='Link To Catalog Record' name="link_to_catalog_link" href="javascript:void(0);">&#x27BE; link to catalog</a></span> 
108                                         <span name="worksheet"> | <a title='Generate Worksheet' name="worksheet_link" href="javascript:void(0);">&#x270D; worksheet</a></span>
109                                         <span name='pl' class='hidden'> | <a title='Select List' name='pl_link' href='javascript:void(0);'>&#x2756; </a></span>
110                                         <span name='po' class='hidden'> | <a title='Purchase Order' name='po_link' href='javascript:void(0);'>&#x2318; </a></span>
111                                         <span name="show_requests"> | <a title='Patron Requests' name="show_requests_link" href="javascript:void(0);">requests</a></span> 
112                                         <span name='pro' class='hidden'> | <a title='[% l('Provider') %]' name='pro_link' href='javascript:void(0);'>&#x235F; </a></span>
113                                         <span name='queue' class='hidden'> | <a title='[% l('Import Queue') %]' name='queue_link' href='javascript:void(0);'>[% l('&#x27AC; queue') %]</a></span>
114                                     </td>
115                                 </tr>
116                             </tbody>
117                         </table>
118                     </td>
119                     <td><a title='FOOOBAR' name='copieslink' href='javascript:void(0);'>Copies(<span name='count'>0</span>)</a></td>
120                     <td>
121                         <a name='noteslink' href='javascript:void(0);'>Notes(<span name='notes_count'>0</span>)</a><span name="notes_alert_flag"></span>
122                     </td>
123                     <td>
124                         <select name='actions'>
125                             <option name='action_none'>-- Actions --</option>
126                             <option name='action_mark_recv' disabled='disabled'>Mark Received</option>
127                             <option name='action_mark_unrecv' disabled='disabled'>Un-Receive</option>
128                             <option name='action_update_barcodes'>Update Barcodes</option>
129                             <option name='action_holdings_maint'>Holdings Maint.</option>
130                             <option name='action_new_invoice' disabled='disabled'>New Invoice</option>
131                             <option name='action_link_invoice' disabled='disabled'>Link to Invoice</option>
132                             <option name='action_view_invoice' disabled='disabled'>View Invoice(s)</option>
133                             <option name='action_view_claim_policy'>Apply Claim Policy</option>
134                             <option name='action_manage_claims'>Claims</option>
135                             <option name='action_view_history'>View History</option>
136                         </select>
137                     </td>
138                     <td><span name='li_state'></span></td>
139                     <td><input type='text' size='8' name='price'/></td>
140                 </tr>
141             </tbody>
142         </table>
143     </div>
144
145     <!-- Bib record / Lineitem info table -->
146     [% INCLUDE "acq/common/info.tt2" which = "Lit" %]
147
148     <!-- Lineitem notes table -->
149     [% INCLUDE "acq/common/notes.tt2" which = "Lit" %]
150
151     <!-- Copies table -->
152     <div id='acq-lit-li-details' class='hidden'>
153
154         <div id='acq-lit-copies-li-summary'></div>
155
156         <h3>Add/Edit Items</h3>
157         <hr/>
158
159         <div class='acq-lit-li-menu-bar'>
160             <table style='width:100%'>
161                 <tr>
162                     <td class="acq-lit-li-menu-left">
163                         <span class='hidden' id='acq-lit-copies-back-to-invoice-button-wrapper'>
164                             <button dojoType='dijit.form.Button' id='acq-lit-copies-back-to-invoice-button' 
165                                 scrollOnFocus='false'>[% l('&#x2196; Return To Invoice') %]</button>
166                         </span>
167                         <div dojoType='dijit.form.Button' id='acq-lit-copies-back-button' scrollOnFocus='false'>&#x2196; Return</div>
168                         <span style='margin-left:10px;padding-left:10px;border-left:2px solid #aaa;'>
169                             Item Count: 
170                             <input dojoType='dijit.form.NumberTextBox' jsId='acqLitCopyCountInput'  
171                                 constraints="{min:0,max:1000,places:0}" style='width:40px' value='0'></input> 
172                             <div dojoType='dijit.form.Button' jsId='acqLitAddCopyCount' scrollOnFocus='false'>Go</div>
173                         </span>
174                         <span style='margin-left:10px;padding-left:10px;border-left:2px solid #aaa;'>
175                             <div dojoType='dijit.form.Button' jsId='acqLitSaveCopies' scrollOnFocus='false'>Save Changes</div>
176                         </span>
177                         <span id='acq-lit-update-copies-progress' class='hidden'>
178                             <span dojoType="dijit.ProgressBar" style="width:300px" jsId="litUpdateCopiesProgress"></span>
179                         </span>
180                     </td>
181                 </tr>
182             </table>
183         </div>
184
185         <hr/>
186         <table id='acq-lit-distrib-formula-table'>
187             <tbody id='acq-lit-distrib-formula-tbody'>
188                 <tr id='acq-lit-distrib-form-row'>
189                     <td colspan='0'>
190                         <span>Distribution Formulas</span>
191                         <div name='selector'></div>
192                         <div name='set_button'></div>
193                         <div name="reset_button"></div>
194                     </td>
195                 </tr>
196             </tbody>
197             <tbody id="acq-lit-distrib-applied-tbody" class="hidden">
198                 <tr>
199                     <td colspan="5" id="acq-lit-distrib-applied-heading">
200                         Distribution formulas applied to this lineitem:
201                     </td>
202                 </tr>
203                 <tr id="acq-lit-distrib-applied-row" class="acq-lit-distrib-applied-row">
204                     <th></th>
205                     <td colspan="4"></td>
206                 </tr>
207             </tbody>
208         <table>
209
210         <table id='acq-lit-li-details-table'>
211             <tbody><tr><td class='acq-lit-table-spacer' colspan='0'/></tr></tbody>
212             <tbody style='font-weight:bold;'>
213                 <tr>
214                     <td style='margin-top:30px;'>Owning Branch</td>
215                     <td>Shelving Location</td>
216                     <td>Collection Code</td>
217                     <td>Fund</td>
218                     <td>Circ Modifier</td>
219                     <td>Callnumber</td>
220                     <td colspan='0'></td>
221                 </tr>
222             </tbody>
223             <tbody style='background-color:#ddd;'>
224                 <tr id='acq-lit-li-details-batch-row'>
225                     <td><div name='owning_lib'></div></td>
226                     <td><div name='location'></div></td>
227                     <td><div name='collection_code'></div></td>
228                     <td><div name='fund'></div></td>
229                     <td><div name='circ_modifier'></div></td>
230                     <td><div name='cn_label'></div></td>
231                     <td colspan='3' style='text-align:left;'>
232                         <div dojoType='dijit.form.Button' jsId='acqLitBatchUpdateCopies' scrollOnFocus='false'>Batch Update</div>
233                     </td>
234                 </tr>
235             </tbody>
236
237
238             <tbody><tr><td class='acq-lit-table-spacer' colspan='0'></td></tr></tbody>
239             <tbody style='font-weight:bold;'>
240                 <tr>
241                     <td style='margin-top:30px;'>Owning Branch</td>
242                     <td>Shelving Location</td>
243                     <td>Collection Code</td>
244                     <td>Fund</td>
245                     <td>Circ Modifier</td>
246                     <td>Callnumber</td>
247                     <td>Barcode</td>
248                     <td>Notes</td>
249                     <td>Receiver</td>
250                     <td colspan='0'></td>
251                 </tr>
252             </tbody>
253             <tbody id='acq-lit-li-details-tbody' class='oils-generic-table'>
254                 <tr id='acq-lit-li-details-row'>
255                     <td><div name='owning_lib'></div></td>
256                     <td><div name='location'></div></td>
257                     <td><div name='collection_code'></div></td>
258                     <td><div name='fund'></div></td>
259                     <td><div name='circ_modifier'></div></td>
260                     <td><div name='cn_label'></div></td>
261                     <td><div name='barcode'></div></td>
262                     <td><div name='note'></div></td>
263                     <td><div name='receiver'></div></td>
264                     <td><a href="javascript:void(0);" name="receive">Mark&nbsp;Received</a><a href="javascript:void(0);" name="unreceive">Un-Receive</a>&nbsp;<a href="javascript:void(0);" name="cancel">Cancel</a><span class="hidden" name="cancel_reason"></span>&nbsp;<a href="javascript:void(0);" name="claim">Claim</a></td>
265                     <td><div name='delete' dojoType='dijit.form.Button' style='color:red;' scrollOnFocus='false'>X</div></td>
266                 </tr>
267             </tbody>
268         </table>
269     </div>
270
271
272     <!-- Copies table -->
273     <div id='acq-lit-real-copies-div' class='hidden'>
274         <h2>Copies</h2>
275
276         <div class='acq-lit-li-menu-bar'>
277             <table style='width:100%'>
278                 <tr>
279                     <td style='text-align:left;'>
280                         <div dojoType='dijit.form.Button' id='acq-lit-real-copies-back-button' scrollOnFocus='false'>&#x2196; Return</div>
281                     </td>
282                     <td style='text-align:right;'>
283                         <span>
284                             <div dojoType='dijit.form.Button' jsId='acqLitSaveRealCopies' scrollOnFocus='false'>Save Changes</div>
285                         </span>
286                     </td>
287                 </tr>
288             </table>
289         </div>
290
291         <table id='acq-lit-real-copies-table'>
292             <tbody style='font-weight:bold;'>
293                 <tr>
294                     <td style='margin-top:30px;'>Owning Branch</td>
295                     <td>Shelving Location</td>
296                     <td>Circ Modifier</td>
297                     <td>Callnumber</td>
298                     <td>Barcode</td>
299                     <td colspan='0'></td>
300                 </tr>
301             </tbody>
302             <tbody id='acq-lit-real-copies-tbody' class='oils-generic-table'>
303                 <tr id='acq-lit-real-copies-row'>
304                     <td><div name='owning_lib'></div></td>
305                     <td><div name='location'></div></td>
306                     <td><div name='circ_modifier'></div></td>
307                     <td><div name='label'></div></td>
308                     <td><div name='barcode'></div></td>
309                 </tr>
310             </tbody>
311         </table>
312     </div>
313
314     <div class="hidden">
315         <div jsId="acqLitLinkInvoiceDialog" dojoType="dijit.Dialog">
316             [% INCLUDE "acq/common/inv_dialog.tt2" which = "li" %]
317         </div>
318     </div>
319
320
321     [% PROCESS 'acq/common/vlagent.tt2' %]
322     <div class='hidden' id='acq-lit-asset-creator'>
323         <table class='oils-generic-table'>
324             <tbody>
325                 [% PROCESS vlagent_form %]
326                 <tr>
327                     <td>
328                         <span style='margin-left:10px;'>
329                             <button dojoType="dijit.form.Button" jsId='assetCreatorButton'>[% l('Submit') %]</button>
330                         </span>
331                     </td>
332                 </tr>
333             </tbody>
334         </table>
335     </div>
336
337     <div class='hidden' id='acq-lit-progress-numbers'>
338         [% PROCESS vlagent_results %]
339     </div>
340
341     <div class='hidden'>
342         <div dojoType='dijit.Dialog' jsId='acqLitPoCreateDialog'>
343             <table class='oils-generic-table'>
344                 <tr>
345                     <td>Ordering Agency</td>
346                     <td><div name='ordering_agency' id='acq-lit-po-agency'></div></td>
347                 </tr>
348                 <tr>
349                     <td>Provider</td>
350                     <td><div name='provider' id='acq-lit-po-provider'></div></td>
351                 </tr>
352                 <tr>
353                     <td>Prepayment Required</td>
354                     <td><input id="acq-lit-po-prepay" name="prepayment_required" dojoType="dijit.form.CheckBox"/></td>
355                 </tr>
356                 <tr>
357                     <td>All Lineitems</td>
358                     <td><input checked='checked' name='create_from' value='all' dojoType='dijit.form.RadioButton'/></td>
359                 </tr>
360                 <tr>
361                     <td>Selected Lineitems</td>
362                     <td><input name='create_from' value='selected' dojoType='dijit.form.RadioButton'/></td>
363                 </tr>
364                 <tr>
365                     <td>Import Bibs and Create Copies</td>
366                     <td><input name='create_assets' dojoType='dijit.form.CheckBox'/></td>
367                 </tr>
368                 <tr>
369                     <td colspan='2'>
370                         <div dojoType='dijit.form.Button' type='submit' jsId='acqLitCreatePoSubmit'>Submit</div>
371                     </td>
372                 </tr>
373             </table>
374         </div>
375     </div>
376
377     <div class="hidden">
378         <div dojoType="dijit.Dialog" jsId='acqLitSavePlDialog'>
379             <table class='dijitTooltipTable'>
380                 <tr>
381                     <td colspan='2'>
382                         <input dojoType="dijit.form.RadioButton" name="which" type='radio' checked='checked' value='selected'/>
383                         <label for="name">Save selected</label>
384                         <input dojoType="dijit.form.RadioButton" name="which" type='radio' value='all'/>
385                         <label for="name">Save all</label>
386                     </td>
387                 </tr>
388                 <tr><td colspan='2'><hr/></td></tr>
389                 <tr>
390                     <td><label for="new_name">Save as Selection List: </label></td>
391                     <td><input dojoType="dijit.form.TextBox" name="new_name"/></td>
392                 </tr>
393                 <tr>
394                     <td><label for="existing_pl">Add to Selection List: </label></td>
395                     <td>
396                         <input jsId="acqLitAddExistingSelect" dojoType="openils.widget.PCrudAutocompleteBox" fmclass="acqpl" searchAttr="name" name="existing_pl" />
397                     </td>
398                 </tr>
399                 <tr>
400                     <td colspan='2' align='center'>
401                         <button dojoType='dijit.form.Button' type="submit" jsId='acqLitSavePlButton'>Save</button>
402                     </td>
403                 </tr>
404             </table>
405         </div>
406
407         <div dojoType="dijit.Dialog" jsId="lidCancelDialog">
408             <label for="acq-lit-lid-cancel-reason">Reason:</label>
409             <span id="acq-lit-lid-cancel-reason"></span>
410             <span dojoType="dijit.form.Button"
411                 jsId="acqLidCancelButton">Cancel Copy</span>
412         </div>
413         <div dojoType="dijit.Dialog" jsId="liClaimPolicyDialog">
414             <label for="acq-lit-li-claim-policy">Claim policy:</label>
415             <span id="acq-lit-li-claim-policy"></span> &nbsp;
416             <span dojoType="dijit.form.Button"
417                 jsId="liClaimPolicySave">Save</span>
418         </div>
419         <div dojoType="dijit.Dialog" jsId="liClaimDialog">
420             [% INCLUDE "acq/common/claim_dialog.tt2" %]
421         </div>
422         <div dojoType="dijit.Dialog" jsId="finalClaimDialog">
423             [% INCLUDE "acq/common/final_claim_dialog.tt2" %]
424         </div>
425         <div dojoType="dijit.Dialog" jsId="batchFundUpdateDialog" title="Batch Update Funds">
426             <div>
427                 This will update the fund for all copies attached to these lineitems.<br/>
428                 This will also update any existing encumbered or spent debits.
429             </div>
430             <br/>
431             <table class='oils-generic-table'>
432                 <tr>
433                     <td>
434                         <span>Select a new fund:</span>
435                     </td>
436                     <td>
437                         <div id='acq-lit-batch-fund-selector'></div>
438                     </td>
439                 </tr>
440                 <tr>
441                     <td><button dojoType='dijit.form.Button' jsId='batchFundUpdateCancel'>Cancel</button></td>
442                     <td><button dojoType='dijit.form.Button' jsId='batchFundUpdateSubmit'>Submit</button></td>
443                 </tr>
444             </table>
445         </div>
446     </div>
447
448     <div dojoType="dijit.Dialog" jsId='acqLitChangeLiStateDialog'>
449         <table class='dijitTooltipTable'>
450             <tr>
451                 <td>
452                     <input dojoType="dijit.form.RadioButton" name="which" type='radio' checked='checked' value='selected'/>
453                     <label for="name">Mark selected</label>
454                     <input dojoType="dijit.form.RadioButton" name="which" type='radio' value='all'/>
455                     <label for="name">Mark all</label>
456                 </td>
457             </tr>
458             <tr>
459                 <td colspan='2' align='center'>
460                     <button dojoType='dijit.form.Button' type="submit" jsId='acqLitCancelLiStateButton'>Cancel</button>
461                     <button dojoType='dijit.form.Button' type="submit" jsId='acqLitSaveLiStateButton'>Go</button>
462                 </td>
463             </tr>
464         </table>
465     </div>
466
467
468     <div class='hidden'>
469         <div dojoType='openils.widget.ProgressDialog' jsId='progressDialog'></div>
470     </div>
471
472 </div>
473