]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/web/vandelay/vandelay.html
finished overlay select. overlay selected records on import
[Evergreen.git] / Open-ILS / web / vandelay / vandelay.html
1 <!--
2 # Copyright (C) 2008  Georgia Public Library Service
3 # Bill Erickson <erickson@esilibrary.com>
4 # This program is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU General Public License
6 # as published by the Free Software Foundation; either version 2
7 # of the License, or (at your option) any later version.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13 -->
14 <html>
15     <head>
16         <title>Vandelay</title>
17         <style type="text/css">
18             @import "/js/dojo/dojo/resources/dojo.css";
19             @import "/js/dojo/dijit/themes/tundra/tundra.css";
20             @import "/js/dojo/dijit/tests/css/dijitTests.css"; 
21             @import "/js/dojo/dojox/grid/_grid/Grid.css";
22             td { padding: 6px; }
23             .match_div {
24                 height: 95%;
25                 width: 95%;
26             }
27             .match_div a {
28                 color: red;
29                 font-weight:bold;
30             }
31             .match_div a:visited {
32                 color: red;
33                 font-weight:bold;
34             }
35             .tall { height:100%; }
36             .hidden { display: none; }
37         </style>
38         <script type="text/javascript" djConfig="parseOnLoad: true,isDebug:true" src="/js/dojo/dojo/dojo.js"></script>
39         <script type="text/javascript" src='vandelay.js'></script>
40     </head>
41     <body class="tundra" class='tall'>
42         <div id="vl-generic-progress" style='width:100%;text-align:center'>
43             <div dojoType="dijit.ProgressBar" style="width:200px" indeterminate="true"></div>
44         </div>
45         <div id="vl-generic-progress-with-total" class='hidden' style='width:100%;text-align:center;'>
46             <div dojoType="dijit.ProgressBar" jsId='vlControlledProgressBar' style="width:200px"></div>
47         </div>
48
49         <!-- MARC upload form -->
50         <div id='vl-marc-upload-div' class='hidden'>
51             <h1>Evergreen MARC File Upload</h1><br/>
52             <form id="vl-marc-upload-form" enctype="multipart/form-data">
53                 <input type='hidden' name='ses' id='vl-ses-input'/>
54                 <br>
55                 <table>
56                     <tr>
57                         <td>Queue Name</td>
58                         <td>
59                             <input type='text' dojoType='dijit.form.TextBox' id='vl-queue-name' size='32'></input>
60                         </td>
61                     </tr>
62                     <tr>
63                         <td>Record Type</td>
64                         <td>
65                             <select id='vl-record-type' dojoType='dijit.form.FilteringSelect'>
66                                 <option value='bib'>Bibliographic Records</option>
67                                 <option value='auth'>Authority Records</option>
68                             </select>
69                         </td>
70                     </tr>
71                     <tr>
72                         <td>Purpose</td>
73                         <td>
74                             <select name='purpose' dojoType='dijit.form.FilteringSelect'>
75                                 <option value='import'>Import</option>
76                                 <option value='overlay'>Overlay</option>
77                             </select>
78                         </td>
79                     </tr>
80                     <tr>
81                         <td>
82                             <span id="vl-file-label">File to Upload:</span><br>
83                             <span id="vl-file-uploading" class='hidden'>Uploading...</span><br>
84                         </td>
85                         <td id='vl-input-td'>
86                             <input size='48' type="file" name="marc_upload">
87                         </td>
88                     </tr>
89                     <tr>
90                         <td colspan='2'>
91                             <span id="vl-upload-progress-span" class='hidden'>
92                                 <div dojoType="dijit.ProgressBar" style="width:200px" indeterminate="true"></div>
93                             </span>
94                         </td>
95                     </tr>
96                     <tr>
97                         <td colspan='2' align='center'>
98                             <button dojoType="dijit.form.Button" onclick="batchUpload()">Upload</button>
99                         </td>
100                     </tr>
101                 </table>
102             </form>
103         </div>
104
105         <!-- record queue grid -->
106         <div id='vl-queue-div' class='tall hidden'>
107             <h1>Record Queue</h1><br/>
108             <script>
109                 var vlQueueGridLayout;
110                 function resetVlQueueGridLayout() {
111                     vlQueueGridLayout = [{
112                         defaultCell: {styles: 'text-align: center;'},
113                         cells : [[
114                             {name: 'Selected', get: vlQueueGridDrawSelectBox },
115                             {name: 'Import Time', field:'import_time', get:vlGetDateTimeField}
116                         ]]
117                     }];
118                 }
119             </script>
120             <button dojoType='dijit.form.Button' onclick='vlSelectAllGridRecords();'>Select All</button>
121             <button dojoType='dijit.form.Button' onclick='vlSelectNoGridRecords();'>Select None</button>
122             <button dojoType='dijit.form.Button' onclick='vlImportSelectedRecords();'>Import Selected</button>
123             <div class='tall'>
124                 <div dojoType='dojox.Grid' jsId='vlQueueGrid'> </div>
125             </div>
126         </div>
127
128         <!-- Grid of record matches -->
129         <div id='vl-match-div' class='tall hidden'>
130             <script>
131                 var vlMatchGridLayout;
132                 function resetVlMatchGridLayout() {
133                     vlMatchGridLayout = [{
134                         defaultCell: {styles: 'text-align: center;'},
135                         cells : [[
136                             {
137                                 name: 'Overlay Target', 
138                                 get: vlGetOverlayTargetSelector,
139                                 value: '<input type="radio" name="overlay_target" onclick="vlHandleOverlayTargetSelected();" id="vl-overlay-target-ID"/>'
140                             },
141                             {name:'Match Point', field:'field_type'},
142                             {name: 'ID', field:'id'},
143                             {   name: 'View MARC', 
144                                 get: vlGetViewMARC, 
145                                 value:'<a href="javascript:void(0);" onclick="vlLoadMARCHtml(RECID);">View MARC</a>'
146                             },
147                             {name: 'Creator', get: vlGetCreator},
148                             {name: 'Create Date', field:'create_date', get: vlGetDateTimeField},
149                             {name: 'Last Edit Date', field:'edit_date', get: vlGetDateTimeField},
150                             {name: 'Source', field:'source'},
151                             {name: 'TCN Source', field:'tcn_source'},
152                             {name: 'TCN Value', field:'tcn_value'}
153                         ]]
154                     }];
155                 }
156             </script>
157             <h1>Import Matches</h1></br>
158             <div>
159                 <button dojoType='dijit.form.Button' 
160                     onclick='displayGlobalDiv("vl-queue-div");'>Back To Import Queue...</button>
161                 <span style='padding-left:20px;'>
162                     <input dojoType='dijit.form.CheckBox' jsId='vlOverlayTargetEnable' onclick='vlHandleOverlayTargetSelected'/> 
163                     Overlay selected record with imported record
164                 </span>
165             </div>
166             <div class='tall'>
167                 <div dojoType='dojox.Grid' jsId='vlMatchGrid'> </div>
168             </div>
169         </div>
170
171
172         <!-- MARC as HTML for matched records -->
173         <div id='vl-match-html-div' class='tall hidden'>
174             <h1>MARC Record</h1><br/>
175             <div>
176                 <button dojoType='dijit.form.Button' 
177                     onclick='displayGlobalDiv("vl-match-div");'>Back To Matches...</button>
178             </div>
179             <div>
180                 <style>#vl-match-record-html td {padding:0px;}</style>
181                 <div id='vl-match-record-html'/>
182             </div>
183         </div>
184
185     </body>
186 </html>