summaryrefslogtreecommitdiff
path: root/share/www/database.html
diff options
context:
space:
mode:
Diffstat (limited to 'share/www/database.html')
-rw-r--r--share/www/database.html15
1 files changed, 14 insertions, 1 deletions
diff --git a/share/www/database.html b/share/www/database.html
index 400081b0..3609cc7b 100644
--- a/share/www/database.html
+++ b/share/www/database.html
@@ -73,6 +73,8 @@ specific language governing permissions and limitations under the License.
// Restore preferences/state from cookies
var desc = $.cookies.get(page.db.name + ".desc");
if (desc) $("#documents thead th.key").addClass("desc");
+ var reduce = $.cookies.get(page.db.name + ".doreduce");
+ $("#reduce :checkbox")[0].checked = reduce;
var rowsPerPage = $.cookies.get(page.db.name + ".perpage");
if (rowsPerPage) $("#perpage").val(rowsPerPage);
@@ -93,6 +95,14 @@ specific language governing permissions and limitations under the License.
$(this).toggleClass("desc");
page.updateDocumentListing();
});
+ $("#documents thead th.value #reduce :checkbox").click(function() {
+ page.updateDocumentListing();
+ if (this.checked) {
+ $.cookies.set(page.db.name + ".doreduce", "1");
+ } else {
+ $.cookies.remove(page.db.name + ".doreduce");
+ }
+ });
$("#perpage").change(function() {
page.updateDocumentListing();
$.cookies.set(page.db.name + ".perpage", this.value);
@@ -187,7 +197,10 @@ specific language governing permissions and limitations under the License.
<thead>
<tr>
<th class="key"><div>Key</div></th>
- <th class="value">Value</th>
+ <th class="value">
+ <label id="reduce"><input type="checkbox" autocomplete="off" checked> Reduce</label>
+ Value
+ </th>
</tr>
</thead>
<tbody class="content">