summaryrefslogtreecommitdiff
path: root/share/www/script
diff options
context:
space:
mode:
authorChristopher Lenz <cmlenz@apache.org>2008-08-01 22:37:50 +0000
committerChristopher Lenz <cmlenz@apache.org>2008-08-01 22:37:50 +0000
commitb218a0e7d425f7b3660433a17c6558f676524730 (patch)
treeb60120c38ee6381d5aa4847e939d71be21418b45 /share/www/script
parentdf0efb26244d27f55f2a40bffc740c127b3a50a6 (diff)
Experimental tabbed interface in Futon document view to switch between tabular fields display and a raw JSON display.
git-svn-id: https://svn.apache.org/repos/asf/incubator/couchdb/trunk@681878 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'share/www/script')
-rw-r--r--share/www/script/browse.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/share/www/script/browse.js b/share/www/script/browse.js
index 8ef8ccfb..8291d914 100644
--- a/share/www/script/browse.js
+++ b/share/www/script/browse.js
@@ -507,6 +507,9 @@ function CouchDocumentPage() {
page = this;
this.addField = function() {
+ if (!$("#fields tbody.content:visible").length) {
+ $("#tabs li.tabular a").click(); // switch to tabular view
+ }
var fieldName = "unnamed";
var fieldIdx = 1;
while (page.doc.hasOwnProperty(fieldName)) {