summaryrefslogtreecommitdiff
path: root/src/fauxton/app/addons/documents/templates/advanced_options.html
blob: 439e8648c7ebc4583fdeb5d125531e70270a324d (plain)
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
<!--
Licensed 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 class="errors-container"></div>
<form class="js-view-query-update custom-inputs">

<!-- tabs for choosing Keys or Start & end -->

  <div class="btn-group toggle-btns row-fluid">
    <label for="showKeys" class="drop-down btn span6">
     By Key(s)
    </label>
    <label for="showStartEnd" class="drop-down btn span6">
      Between Keys
    </label>
  </div>

  <div class="controls-group well hide js-query-keys-wrapper">
    <div class="row-fluid" id="js-showKeys">
      <div class="controls controls-row">
        <label for="keys-input" class="drop-down">A key, or an array of keys.</label>
        <textarea id="keys-input" name="keys" class="input-xxlarge" rows="5" type="text" placeholder='Enter valid JSON; e.g., ["1234"] or ["1234","2345"]'></textarea>
        <div id="keys-error" class="inline-block js-keys-error"></div>
      </div>
    </div>
    <div class="row-fluid hide" id="js-showStartEnd">
      <div class="controls controls-row">
        <div class="span6">
          <label for="startkey" class="drop-down">Start key</label>
          <input name="startkey" id="startkey" type="text" placeholder='e.g., "1234"' disabled>
        </div>
        <div class="span6">
          <label for="endkey" class="drop-down">End key</label>
          <input id="endkey" name="endkey" type="text" placeholder='e.g., "1234"'>
          <div class="controls controls-row checkbox inline">
            <input id="check5" name="inclusive_end" type="checkbox" value="true" checked disabled>
            <label for="check5">Include End Key in results</label>
          </div>
        </div>

      </div>

    </div>
  </div>

<!-- Limit and Skip are conditional -->

  <div class="controls-group">

    <div class="row-fluid">
      <div class="span6">
        <label class="drop-down inline">
          Limit:
          <select name="limit" class="input-medium">
            <option selected="selected">None</option>
            <option>5</option>
            <option>10</option>
            <option>20</option>
            <option>30</option>
            <option>50</option>
            <option>100</option>
  		      <option>500</option>
          </select>
        </label>
      </div>
      <div class="span6">
        <label for="skipRows" class="inline drop-down">
          # of rows to skip
          <input name="skip" class="input-small" type="text" id="skipRows" placeholder="0">
        </label>
      </div>
    </div>
    <div class="row-fluid">
      <div class="span6">
        <label id="select2" class="drop-down inline">
          Order:
          <select id="select2" name="descending" class="input-medium">
            <option value="false">Ascending</option>
            <option value="true">Descending</option>
          </select>
        </label>
      </div>
      <div class="span6">
        <label id="select2" class="drop-down inline">
          Docs:
          <select id="select2" name="include_docs" class="input-medium">
            <option value="false">Exclude</option>
            <option value="true">Include</option>
          </select>
        </label>
      </div>
    </div>
    <div class="row-fluid">
      <% if (showPreview) { %>
        <div class="span6">
          <div class="checkbox inline">
            <input id="check7" name="stale" type="checkbox" value="true">
            <label for="check7">Stale</label>
          </div>
        </div>
      <% } %>
      <div class="span6 update-seq">
        <div class="checkbox inline">
          <input id="check6" name="update_seq" type="checkbox" value="true">
          <label for="check6">Update Sequence</label>
        </div>
      </div>

    </div>
  <% if (hasReduce) { %>
    <div class="row-fluid">
      <div class="span6">
        <div class="checkbox inline">
          <input id="check2" name="reduce" type="checkbox" value="true">
          <label for="check2">Reduce</label>
        </div>
      </div>
      <div class="span6">
        <label id="select1" class="drop-down inline">
          Group Level:
          <select id="select1" disabled name="group_level" class="input-small">
            <option value="0">None</option>
            <option value="1">1</option>
            <option value="2">2</option>
            <option value="3">3</option>
            <option value="4">4</option>
            <option value="5">5</option>
            <option value="6">6</option>
            <option value="7">7</option>
            <option value="8">8</option>
            <option value="9">9</option>
            <option value="999" selected="selected">Exact</option>
          </select>
        </label>
      </div>
    </div>
  <% } %>
  </div>





  <div class="controls-group">
    <div id="button-options" class="controls controls-row">
      <button type="submit" class="btn btn-success">Query</button>
    </div>
  </div>
</form>
</div>