diff options
author | Garren Smith <garren.smith@gmail.com> | 2013-12-12 17:35:19 +0200 |
---|---|---|
committer | Garren Smith <garren.smith@gmail.com> | 2013-12-12 17:35:19 +0200 |
commit | 6bb810f4a50ae8015b717d61c91073becde547dc (patch) | |
tree | 07c16b8db481294ee7aa63b53e2cfe3faccd223d | |
parent | 936edf85f362715f4fda5a3706799686b38cda68 (diff) | |
download | couchdb-6bb810f4a50ae8015b717d61c91073becde547dc.tar.gz |
Fauxton: Add extension to new doc/index section
-rw-r--r-- | src/fauxton/app/modules/documents/views.js | 2 | ||||
-rw-r--r-- | src/fauxton/app/templates/documents/sidebar.html | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/fauxton/app/modules/documents/views.js b/src/fauxton/app/modules/documents/views.js index 49c443d34..cac4f48e8 100644 --- a/src/fauxton/app/modules/documents/views.js +++ b/src/fauxton/app/modules/documents/views.js @@ -1657,6 +1657,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum serialize: function() { var docLinks = FauxtonAPI.getExtensions('docLinks'), + newLinks = FauxtonAPI.getExtensions('sidebar:newLinks'), addLinks = FauxtonAPI.getExtensions('sidebar:links'), extensionList = FauxtonAPI.getExtensions('sidebar:list'); return { @@ -1668,6 +1669,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum docLinks: docLinks, docLimit: Databases.DocLimit, addLinks: addLinks, + newLinks: newLinks, extensionList: extensionList > 0 }; }, diff --git a/src/fauxton/app/templates/documents/sidebar.html b/src/fauxton/app/templates/documents/sidebar.html index 156398d32..8a73ae9a3 100644 --- a/src/fauxton/app/templates/documents/sidebar.html +++ b/src/fauxton/app/templates/documents/sidebar.html @@ -43,6 +43,9 @@ the License. </li> <li> <a href="#<%= database.url('app') %>/new_view">Secondary Index</a> + <% _.each(newLinks, function (item) { %> + <a href="#<%= database.url('app') %>/<%=item.url%>"> <%= item.name %></a> + <% }); %> </li> </ul> </div> |