]> git.evergreen-ils.org Git - working/Evergreen.git/blob - Open-ILS/src/templates/conify/global/vandelay/match_set_tree.tt2
LP#1171984 Vandelay authority record matching
[working/Evergreen.git] / Open-ILS / src / templates / conify / global / vandelay / match_set_tree.tt2
1 [% WRAPPER 'base.tt2' %]
2 [% ctx.page_title = l('Vandelay Match Set Editor') %]
3 <style type="text/css">
4     h1 { margin: 1ex 0; }
5     .outer { clear: both; margin-bottom: 1ex; }
6     .space-me input { margin: 0 1em; }
7     button { margin: 0 0.5em; }
8     input[type=submit] { padding: 0 0.5em; }
9     #tree-here { margin-bottom: 1.5em; }
10     #vms-table { padding-bottom: 2ex; }
11     #vms-table th { text-align: right; }
12     #vms-table td { padding-left: 1em; }
13     #src-pane { float: left; width: 49%; }
14     #tree-pane { float: right; width: 50%; }
15     #submit-row { clear: both; text-align: center; padding-top: 1.5ex; }
16     #submit-row hr { margin: 1.5ex 0; }
17     #expr-preview-row { margin: 2ex 0; }
18     #expr-preview {
19         font-family: monospace;
20         font-size: 125%;
21         font-weight: bold;
22         background-color: #000066;
23         color: white;
24     }
25     .node-editor { margin-bottom: 1.5ex; }
26     .node-editor td { padding: 0.5ex; }
27     li { background-color: #ddd; }
28     .replace-mode { background-color: #990; color: #fff; }
29 </style>
30 <h1>[% ctx.page_title %]</h1>
31 <table id="vms-table">
32     <tbody>
33         <tr>
34             <th>[% l('Match set name:') %]</th>
35             <td><strong id="vms-name"></strong></td>
36         </tr>
37         <tr>
38             <th>[% l('Owning Library:') %]</th>
39             <td id="vms-owner"></td>
40         </tr>
41         <tr>
42             <th>[% l('Type:') %]</th>
43             <td id="vms-mtype"></td>
44         </tr>
45     </tbody>
46 </table>
47 <hr />
48 <!-- XXX TODO
49     give some indication of which match set we're editing the tree for
50     -->
51 <table class="hidden">
52     <tr quality-controls="1">
53         <td>
54             <label for="value-input">[% l('Value:') %]</label>
55         </td>
56         <td>
57             <input id="value-input" type="text" fmfield="value" />
58         </td>
59     </tr>
60     <tr consistent-controls="1">
61         <td>
62             <label for="quality-input"
63                 title="[% l('A relative number representing the impact of this expression on the score of the overall record match') %]"><!-- XXX tooltipize -->
64                 [% l('Match Score') %]
65             </label>
66         </td>
67         <td>
68             <input id="quality-input" type="text" value="1"
69                 size="4" maxlength="3" fmfield="quality" />
70         </td>
71     </tr>
72     <tr point-controls="1">
73         <td>
74             <label for="negate-input">[% l('Negate?') %]</label>
75         </td>
76         <td>
77             <input id="negate-input" type="checkbox" fmfield="negate" />
78         </td>
79     </tr>
80 </table>
81 <div class="outer">
82     <div id="expr-preview-row">
83         <em>[% l('Your Expression:') %]</em>
84         <span id="expr-preview"></span>
85     </div>
86     <div id="vmsp-buttons">
87         [% l('Add new') %]
88         <button id='record-attr-btn' onclick="node_editor.add('svf');">[% l('Record Attribute') %]</button>
89         <button onclick="node_editor.add('tag');">[% l('MARC Tag and Subfield') %]</button>
90         <button id='heading-match-btn' onclick="node_editor.add('heading');">[% l('Normalized Authority Heading') %]</button>
91         <button onclick="node_editor.add('bool_op');">[% l('Boolean Operator') %]</button>
92     </div>
93 </div>
94 <div class="outer" style="margin-top: 2ex;">
95     <div id="src-pane">
96         <div><big>[% l('Working Match Point') %]</big></div>
97         <div>
98             <form id="node-editor-container" onsubmit="return false;"></form>
99         </div>
100         <ul id="src-here"></ul>
101     </div>
102
103     <div id="tree-pane">
104         <div><big>[% l('Your Expression') %]</big></div>
105         <div id="tree-here"></div>
106         <div>
107             <button id="deleter" onclick="delete_selected_in_tree()">
108                 [% l('Delete Selected Node') %]
109             </button>
110             <button id="replacer" onclick="replace_mode()"></button>
111         </div>
112     </div>
113 </div>
114 <div id="submit-row">
115     <button onclick="save_tree()">[% l('Save Changes To Expression') %]</button>
116 </div>
117 <hr />
118 <div id="quality-editor-wrapper">
119     <div>
120         <div style="float: left; width: 50%;">
121             <big>[% l('Quality Metrics for this Match Set') %]</big>
122         </div>
123         <div style="float: right; width: 49%; text-align: right;">
124             <button onclick="qnode_editor.add('svf')">
125                 [% l('Record Attribute') %]
126             </button>
127             <button onclick="qnode_editor.add('tag')">
128                 [% l('MARC Tag and Subfield') %]
129             </button>
130             <button onclick="vmsq_grid.deleteSelected()">
131                 [% l('Delete Selected Metrics') %]
132             </button>
133         </div>
134     </div>
135     <br style="clear: both;" />
136     <table id="qnode-editor-container"></table>
137     <table jsId="vmsq_grid"
138         dojoType="openils.widget.AutoGrid"
139         query="{id: '*'}"
140         defaultCellWidth="'17%'"
141         fmClass="vmsq"
142         fieldOrder="['quality','svf','tag','subfield','value']"
143         suppressFields="['match_set']"
144         showPaginator="true"
145         editOnEnter="false">
146     </table>
147 </div>
148 <div jsId="progress_dialog" dojoType="openils.widget.ProgressDialog"></div>
149 <script type="text/javascript"
150     src="[% ctx.media_prefix %]/js/ui/default/conify/global/vandelay/match_set.js"></script>
151 [% END %]