couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From deathb...@apache.org
Subject fauxton commit: updated refs/heads/secondary-indexes to e28feff
Date Tue, 19 Aug 2014 18:06:45 GMT
Repository: couchdb-fauxton
Updated Branches:
  refs/heads/secondary-indexes fb4fc1083 -> e28feffd0


Fixed on On Save and Build Index


Project: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/commit/e28feffd
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/tree/e28feffd
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/diff/e28feffd

Branch: refs/heads/secondary-indexes
Commit: e28feffd073af888b935f46322555353fd5ff590
Parents: fb4fc10
Author: deathbearbrown <deathbearbrown@gmail.com>
Authored: Tue Aug 19 14:06:43 2014 -0400
Committer: deathbearbrown <deathbearbrown@gmail.com>
Committed: Tue Aug 19 14:06:43 2014 -0400

----------------------------------------------------------------------
 app/addons/indexes/routes-core.js | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/e28feffd/app/addons/indexes/routes-core.js
----------------------------------------------------------------------
diff --git a/app/addons/indexes/routes-core.js b/app/addons/indexes/routes-core.js
index 402ae99..5695b81 100644
--- a/app/addons/indexes/routes-core.js
+++ b/app/addons/indexes/routes-core.js
@@ -174,6 +174,28 @@ function (app, FauxtonAPI, Databases, Views, Documents, Resources) {
         collection = this.data.database.allDocs;
         collection.paging.pageSize = pageSize;
 
+      } else {
+        collection = this.data.indexedDocs = new Resources.IndexCollection(null, {
+          database: this.data.database,
+          design: ddoc,
+          view: view,
+          params: docParams,
+          paging: {
+            pageSize: pageSize
+          }
+        });
+
+        if (!this.documentsView) {
+          this.documentsView = this.createViewDocumentsView({
+            designDoc: ddoc,
+            docParams: docParams,
+            urlParams: urlParams,
+            database: this.data.database,
+            indexedDocs: this.indexedDocs,
+            designDocs: this.data.designDocs,
+            view: view
+          });
+        }
       }
 
       this.documentsView.setCollection(collection);


Mime
View raw message