couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gar...@apache.org
Subject fauxton commit: updated refs/heads/master to 86d2f20
Date Tue, 03 Mar 2015 16:11:56 GMT
Repository: couchdb-fauxton
Updated Branches:
  refs/heads/master 4b3b73f44 -> 86d2f20de


Change View Save/Delete to use FauxtonAPI.urls()


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

Branch: refs/heads/master
Commit: 86d2f20de57f3a4bf67ae02247eb777db72702f6
Parents: 4b3b73f
Author: michellephung@gmail.com <michellephung@gmail.com>
Authored: Tue Mar 3 11:03:45 2015 -0500
Committer: michellephung@gmail.com <michellephung@gmail.com>
Committed: Tue Mar 3 11:06:19 2015 -0500

----------------------------------------------------------------------
 app/addons/documents/index-editor/actions.js | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/86d2f20d/app/addons/documents/index-editor/actions.js
----------------------------------------------------------------------
diff --git a/app/addons/documents/index-editor/actions.js b/app/addons/documents/index-editor/actions.js
index 2dc320f..263849b 100644
--- a/app/addons/documents/index-editor/actions.js
+++ b/app/addons/documents/index-editor/actions.js
@@ -121,12 +121,7 @@ function (app, FauxtonAPI, Documents, ActionTypes) {
             FauxtonAPI.dispatch({
               type: ActionTypes.VIEW_SAVED
             });
-            var fragment = '/database/' +
-                viewInfo.database.safeID() +
-                '/' + designDoc.safeID() +
-                '/_view/' +
-                app.utils.safeURLName(viewInfo.viewName);
-
+            var fragment = FauxtonAPI.urls('view', 'showNewlySavedView', viewInfo.database.safeID(),
designDoc.safeID(), app.utils.safeURLName(viewInfo.viewName));
             FauxtonAPI.navigate(fragment, {trigger: true});
           }
 
@@ -150,7 +145,8 @@ function (app, FauxtonAPI, Documents, ActionTypes) {
       }
 
       promise.then(function () {
-        FauxtonAPI.navigate('/database/' + database.safeID() + '/_all_docs?limit=' + FauxtonAPI.constants.DATABASES.DOCUMENT_LIMIT);
+        var url = FauxtonAPI.urls('allDocs', 'app', database.safeID(), '?limit=' + FauxtonAPI.constants.DATABASES.DOCUMENT_LIMIT);
+        FauxtonAPI.navigate(url);
         FauxtonAPI.triggerRouteEvent('reloadDesignDocs');
       });
 


Mime
View raw message