1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
|
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<div id="schema" class="loaded">
<div class="clearfix">
<div id="frame">
<div id="actions" class="actions clearfix" ng-show="isSchemaUpdatable">
<button id="addField" class="action" ng-click="toggleAddField()"><span>Add Field</span></button>
<button id="addDynamicField" class="action" ng-click="toggleAddDynamicField()"><span>Add Dynamic Field</span></button>
<button id="addCopyField" class="action" ng-click="toggleAddCopyField()"><span>Add Copy Field</span></button>
<div class="action add" data-rel="add" ng-show="showAddField" escape-pressed="hideAll()">
<p class="clearfix"><label for="add_name">name:</label>
<input type="text" id="add_name" ng-model="newField.name" focus-when="showAddField" placeholder="enter a field name"></p>
<p class="clearfix"><label for="add_type">field type:</label>
<select chosen type="text" id="add_type" ng-model="newField.type" ng-options="type for type in types"></select>
</p>
<p class="clearfix" ng-show="adding=='field'"><label for="add_default">default:</label>
<input type="text" id="add_default" ng-model="newField.default" placeholder="enter a default value if needed"></p>
<p class="clearfix">
<label class="checkbox" for="add_stored">
<input type="checkbox" ng-model="newField.stored" id="add_stored" title="Full field should be stored in index." ng-true-value="'true'" ng-false-value="'false'">
stored
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_indexed">
<input type="checkbox" ng-model="newField.indexed" id="add_indexed" title="Field should be indexed." ng-true-value="'true'" ng-false-value="'false'">
indexed
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_uninvertible">
<input type="checkbox" ng-model="newField.uninvertible" id="add_uninvertible" title="Field should be uninvertible, it is generally recomended to use docValues instead." ng-true-value="'true'" ng-false-value="'false'">
uninvertible
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_docValues">
<input type="checkbox" ng-model="newField.docValues" id="add_docValues" title="DocValues should be stored for the field." ng-true-value="'true'" ng-false-value="'false'">
docValues
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_multiValued">
<input type="checkbox" ng-model="newField.multiValued" id="add_multiValued" title="Multiple values are allowed for this field." ng-true-value="'true'" ng-false-value="'false'">
multiValued
</label>
</p>
<p class="clearfix" ng-show="adding=='field'">
<label class="checkbox" for="add_required">
<input type="checkbox" ng-model="newField.required" id="add_required" title="Field must be provided for all documents." ng-true-value="'true'" ng-false-value="'false'">
required
</label>
</p>
<p class="clearfix">
<a ng-click="showOmit=!showOmit">
<span class="add_showhide" ng-hide="showOmit">Show omit options</span>
<span class="add_showhide open" ng-show="showOmit">Hide omit options</span>
</a>
</p>
<div ng-show="showOmit">
<p class="clearfix">
<label class="checkbox" for="add_omitNorms">
<input type="checkbox" ng-model="newField.omitNorms" id="add_omitNorms" title="Full field should be omitNorms in index." ng-true-value="'true'" ng-false-value="'false'">
omitNorms
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_omitTermFreqAndPositions">
<input type="checkbox" ng-model="newField.omitTermFreqAndPositions" id="add_omitTermFreqAndPositions" title="Full field should be omitTermFreqAndPositions in index." ng-true-value="'true'" ng-false-value="'false'">
omitTermFreqAndPositions
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_omitPositions">
<input type="checkbox" ng-model="newField.omitPositions" id="add_omitPositions" title="Full field should be omitPositions in index." ng-true-value="'true'" ng-false-value="'false'">
omitPositions
</label>
</p>
</div>
<p class="clearfix">
<a ng-click="showTermVectors=!showTermVectors">
<span class="add_showhide" ng-hide="showTermVectors">Show term vector options</span>
<span class="add_showhide open" ng-show="showTermVectors">Hide term vector options</span>
</a>
</p>
<div ng-show="showTermVectors">
<p class="clearfix">
<label class="checkbox" for="add_termVectors">
<input type="checkbox" ng-model="newField.termVectors" id="add_termVectors" title="Full field should be termVectors in index." ng-true-value="'true'" ng-false-value="'false'">
termVectors
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_termPositions">
<input type="checkbox" ng-model="newField.termPositions" id="add_termPositions" title="Full field should be termPositions in index." ng-true-value="'true'" ng-false-value="'false'">
termPositions
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_termOffsets">
<input type="checkbox" ng-model="newField.termOffsets" id="add_termOffsets" title="Full field should be termOffsets in index." ng-true-value="'true'" ng-false-value="'false'">
termOffsets
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_termPayloads">
<input type="checkbox" ng-model="newField.termPayloads" id="add_termPayloads" title="Full field should be termPayloads in index." ng-true-value="'true'" ng-false-value="'false'">
termPayloads
</label>
</p>
</div>
<p class="clearfix">
<a ng-click="showSort=!showSort">
<span class="add_showhide" ng-hide="showSort">Show sort options</span>
<span class="add_showhide open" ng-show="showSort">Show sort options</span>
</a>
</p>
<div ng-show="showSort">
<p class="clearfix">
<label class="checkbox" for="add_sortMissingFirst">
<input type="checkbox" ng-model="newField.sortMissingFirst" id="add_sortMissingFirst" title="Full field should be sortMissingFirst in index." ng-true-value="'true'" ng-false-value="'false'">
sortMissingFirst
</label>
</p>
<p class="clearfix">
<label class="checkbox" for="add_sortMissingLast">
<input type="checkbox" ng-model="newField.sortMissingLast" id="add_sortMissingLast" title="Full field should be sortMissingLast in index." ng-true-value="'true'" ng-false-value="'false'">
sortMissingLast
</label>
</p>
</div>
<div ng-repeat="error in addErrors" ng-show="addErrors" class="clearfix note error">
<span>{{error}}</span></div>
<p class="clearfix buttons">
<button ng-show="adding=='field'" type="submit" class="submit" ng-class="{success: added}" ng-click="addField()"><span>Add Field</span></button>
<button ng-show="adding=='dynamicField'" type="submit" class="submit" ng-class="{success: added}" ng-click="addDynamicField()"><span>Add Dynamic Field</span></button>
<button type="reset" class="reset" ng-click="hideAll()"><span>Cancel</span></button>
</p>
</div>
<div class="action add" data-rel="add" ng-show="showAddCopyField" escape-pressed="hideAll()">
<form>
<p class="clearfix"><label for="add_source">source:</label>
<input type="text" id="add_source" ng-model="copyField.source" focus-when="showAddCopyField" placeholder="specify your source field or pattern"></p>
<p class="clearfix"><label for="add_dest">destination:</label>
<input type="text" id="add_dest" ng-model="copyField.dest" placeholder="specify your destination field or pattern"></p>
<div ng-repeat="error in addCopyFieldErrors" ng-show="addCopyFieldErrors" class="clearfix note error">
<span>{{error}}</span></div>
<p class="clearfix buttons">
<button type="submit" class="submit" ng-class="{success: added}" ng-click="addCopyField()"><span>Add CopyField</span></button>
<button type="reset" class="reset" ng-click="hideAll()"><span>Cancel</span></button>
</p>
</form>
</div>
</div>
<div id="data">
<div id="field">
<div class="field-options" ng-show="showing">
<div class="block head">
<h2>
<span class="type">{{selectedType}}</span>:
<span class="name">{{name}}</span>
</h2>
</div>
<div class="partial" ng-show="display.partialState">
<p>Because your Index is empty, we do not have enough Information about this Field</p>
</div>
<dl class="options clearfix">
<dt class="field-type" ng-show="analysis.data.className">Field-Type:</dt>
<dd class="field-type" ng-show="analysis.data.className">{{analysis.data.className}}</dd>
<dt class="similarity" ng-show="display.similarity.className">Similarity:</dt>
<dd class="similarity" ng-show="display.similarity.className" data-tip="{{ display.similarity.className }}">{{ display.similarity.details }}</dd>
<dt class="position-increment-gap" ng-show="display.positionIncrementGap"><abbr title="Position Increment Gap">PI Gap</abbr>:</dt>
<dd class="position-increment-gap" ng-show="display.positionIncrementGap">{{ display.positionIncrementGap }}</dd>
<dt class="docs" ng-show="display.docs">Docs:</dt>
<dd class="docs" ng-show="display.docs"><a href="{{display.docsUrl}}">{{display.docs | number}}</a></dd>
<dt class="distinct" ng-show="display.distinct">Distinct:</dt>
<dd class="distinct" ng-show="display.distinct">{{display.distinct}}</dd>
</dl>
<table class="flags" cellspacing="0" cellpadding="0" border="0" ng-show="display.columns.length!=0">
<thead>
<tr>
<td>Flags:</td>
<th ng-repeat="key in display.columns">{{key.name}}</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="row in display.rows track by row.name">
<th>{{row.name}}</th>
<td colspan="2" class="text" ng-show="row.comment">{{row.comment}}</td>
<td ng-repeat="cell in row.cells"
ng-class="{'check':cell.value}">
<span ng-show="cell.value">√</span>
<span ng-show="!cell.value"> </span>
</td>
</tr>
</tbody>
</table>
<ul class="analyzer">
<li class="clearfix {{analyzer.key}}" ng-class="{open: analyzer.show}" ng-repeat="analyzer in analysis.analyzers">
<p><a class="analysis" ng-href="#/{{core}}/analysis?{{analysis.query}}"><span>{{analyzer.name}} Analyzer:</span></a></p>
<dl>
<dt><a ng-click="toggleAnalyzer(analyzer)" class="toggle">{{analyzer.detail.className}}</a></dt>
</dl>
<ul ng-show="analyzer.show">
<li class="clearfix {{componentType.key}} data" ng-repeat="componentType in analyzer.detail.componentTypes" ng-show="componentType.components">
<p>{{componentType.label}}:</p>
<dl>
<dt ng-repeat-start="component in componentType.components">{{component.className}}</dt>
<dd ng-repeat-end ng-repeat="arg in component.args"
ng-class="{'ico-1': arg.booleanValue, 'ico-0': arg.booleanValue==false}">
{{arg.name}}<span ng-show="arg.value">: {{arg.value}}</span>
</dd>
</dl>
</li>
</ul>
</li>
</ul>
</div>
<div class="terminfo-holder loaded clearfix" ng-class="{disabled: noTermData}" ng-show="is.field && !display.partialState">
<div class="trigger">
<button class="submit" ng-click="toggleTerms()"><span ng-class="{loader:isLoadingTerms}">Load Term Info</span></button>
<br/>
<span ng-show="isCloudEnabled">N.B. Loaded from a single core - not from the whole collection.</span>
<a ng-show="showTerms" ng-click="toggleAutoload()" ng-class="{on:isAutoload}" class="autoload" title="Automatically load Term Info?"><span>Autoload</span></a>
</div>
<p ng-show="showTerms && noTerms" class="status">Sorry, no Term Info available :(</p>
<div ng-show="showTerms && termInfo.topTerms" class="topterms-holder">
<form>
<p class="head">
<input type="text" ng-model="topTermsCount" ng-change="loadTermInfo()">
<a class="max-holder" ng-click="loadAllTopTerms()" title="Load all Top-Terms">/<span class="max">{{termInfo.maxTerms | number}}</span></a> Top-Terms:
<a id="query_link" href="#/{{core}}/query?q={{name}}:[* TO *]"><span>Query</span> </a>
</p>
</form>
<ul>
<li class="clearfix" ng-repeat="countGroup in termInfo.topTerms">
<p><span>{{countGroup.count}}</span></p>
<ul>
<li ng-repeat="term in countGroup.terms" ng-class="{odd:$odd}"><a ng-href="#/{{core}}/query?q=%7B!term+f%3D{{name | uriencode}}%7D{{term | uriencode}}">{{term}}</a></li>
</ul>
</li>
</ul>
</div>
<div ng-show="showTerms && termInfo.histogram" class="histogram-holder">
<p class="head">Histogram:</p>
<ul>
<li ng-repeat="row in termInfo.histogram" ng-class="{odd:$odd}">
<dl class="clearfix" style="width: {{(( row.value / termInfo.histogramMax ) * 100 )}}%;">
<dt><span>{{ row.key | number}}</span></dt>
<dd><span>{{ row.value | number }}</span></dd>
</dl>
</li>
</ul>
</div>
</div>
</div>
</div>
<div id="related">
<select id="type_or_name"
ng-model="fieldOrType"
chosen
data-placeholder="Please select ..."
ng-change="selectFieldOrType()"
ng-options="f.value as f.label group by f.group for f in fieldsAndTypes"></select>
<dl id="f-df-t">
<dt class="field" ng-class="{active: selectedType=='Field'}" ng-show="leftbar.fields">Field</dt>
<dd class="field" ng-class="{active: selectedType=='Field'}" ng-repeat="field in leftbar.fields"><a href="#/{{core}}/schema?field={{field}}">{{field}}</a></dd>
<dt class="copyfield" ng-show="leftbar.copyFieldSources">Copied from</dt>
<dd class="copyfield" ng-repeat="field in leftbar.copyFieldSources">
<div class="clearfix" ng-hide="isSchemaUpdatable">
<a href="#/{{core}}/schema?field={{field.name}}">{{field.name}}</a>
</div>
<div class="clearfix updatable" ng-show="isSchemaUpdatable">
<a style="float:left;width:80%" href="#/{{core}}/schema?field={{field.name}}">{{field.name}}</a>
<span ng-click="toggleDeleteCopyField(field)" class="rem"> </span>
</div>
<div class="action delete" ng-show="field.show">
<form class="delete">
<p class="clearfix"><em>Are you sure you want to delete this CopyField?</em></p>
<div ng-repeat="error in field.errors" ng-show="field.errors" class="clearfix note error">
<span>{{error}}</span></div>
<p class="clearfix buttons">
<button class="submit" ng-class="{success: field.deleted}" ng-click="deleteCopyField(field, field.name, name)"><span>Delete</span></button>
<button type="reset" class="reset" ng-click="toggleDeleteCopyField(field)"><span>Cancel</span></button>
</p>
</form>
</div>
</dd>
<dt class="copyfield" ng-show="leftbar.copyFieldDests">Copied to</dt>
<dd class="copyfield" ng-repeat="field in leftbar.copyFieldDests">
<div class="clearfix" ng-hide="isSchemaUpdatable">
<a href="#/{{core}}/schema?field={{field.name}}">{{field.name}}</a>
</div>
<div class="clearfix updatable" ng-show="isSchemaUpdatable">
<a href="#/{{core}}/schema?field={{field.name}}">{{field.name}}</a>
<span ng-click="toggleDeleteCopyField(field)" class="rem"> </span>
</div>
<div class="action delete" ng-show="field.show">
<form class="delete">
<p class="clearfix"><em>Are you sure you want to delete this CopyField?</em></p>
<div ng-repeat="error in field.errors" ng-show="field.errors" class="clearfix note error">
<span>{{error}}</span></div>
<p class="clearfix buttons">
<button class="submit" ng-class="{success: field.deleted}" ng-click="deleteCopyField(field, name, field.name)"><span>Delete</span></button>
<button type="reset" class="reset" ng-click="toggleDeleteCopyField(field)"><span>Cancel</span></button>
</p>
</form>
</div>
</dd>
<dt class="dynamic-field" ng-class="{active: selectedType=='Dynamic Field'}" ng-show="leftbar.dynamicFields">Dynamic Field {{dynamicFields}} / {{dynamicFields.length()}}</dt>
<dd class="dynamic-field" ng-class="{active: selectedType=='Dynamic Field'}" ng-repeat="field in leftbar.dynamicFields"><a href="#/{{core}}/schema?dynamic-field={{field}}">{{field}}</a></dd>
<dt class="type" ng-class="{active: selectedType=='Type'}" ng-show="leftbar.types">Type</dt>
<dd class="type" ng-class="{active: selectedType=='Type'}" ng-repeat="type in leftbar.types"><a href="#/{{core}}/schema?type={{type}}">{{type}}</a></dd>
<dt></dt>
<dd class="active delete-field" ng-show="isSchemaUpdatable && leftbar.fields &&!showDelete"><button ng-click="toggleDelete()"><span>delete field</span></button></dd>
<dd class="active delete-field" ng-show="isSchemaUpdatable && leftbar.dynamicFields &&!showDelete"><button ng-click="toggleDelete()"><span>delete dynamic field</span></button></dd>
<div class="action delete" ng-show="showDelete">
<form class="delete">
<p class="clearfix"><em>Are you sure you want to delete this {{selectedType}}?</em></p>
<div ng-repeat="error in deleteErrors" ng-show="deleteErrors" class="clearfix note error">
<span>{{error}}</span></div>
<p class="clearfix buttons">
<button class="submit" ng-class="{success: deleted}" ng-click="delete()"><span>Delete</span></button>
<button type="reset" class="reset" ng-click="toggleDelete()"><span>Cancel</span></button>
</p>
</form>
</div>
</dl>
<dl class="ukf-dsf">
<dt class="unique-key-field" ng-class="{active: isUniqueKeyField}" ng-show="uniqueKeyField">Unique Key Field</dt>
<dd class="unique-key-field" ng-class="{active: isUniqueKeyField}"><a ng-href="#/{{core}}/schema?field={{uniqueKeyField}}">{{uniqueKeyField}}</a></dd>
<dt class="similarity" ng-class="{active: similarity.className}">Global Similarity:</dt>
<dd class="similarity" ng-class="{active: similarity.className}" data-tip="{{ similarity.className }}">{{ similarity.details }}</dd>
</dl>
</div>
</div>
</div>
</div>
|