You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by de...@apache.org on 2014/04/01 22:50:35 UTC
[1/7] couchdb commit: updated refs/heads/Update-Sidebar-Ui to eb1c7c0
Repository: couchdb
Updated Branches:
refs/heads/Update-Sidebar-Ui c1e142377 -> eb1c7c0fc (forced update)
Increase mochiweb socket buffers up to 256KiB
This dramatically improves replication speed for large documents and
attachments and resolves replication test timeout for FreeBSD 10 and
OSX 10.9.2
Fixes COUCHDB-1986
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/9a0e561b
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/9a0e561b
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/9a0e561b
Branch: refs/heads/Update-Sidebar-Ui
Commit: 9a0e561b1f3bc34810dd9112ab0a3fe3722c9a54
Parents: ce352c8
Author: Alexander Shorin <kx...@apache.org>
Authored: Tue Apr 1 15:45:57 2014 +0400
Committer: Alexander Shorin <kx...@apache.org>
Committed: Tue Apr 1 15:45:57 2014 +0400
----------------------------------------------------------------------
etc/couchdb/default.ini.tpl.in | 1 +
1 file changed, 1 insertion(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9a0e561b/etc/couchdb/default.ini.tpl.in
----------------------------------------------------------------------
diff --git a/etc/couchdb/default.ini.tpl.in b/etc/couchdb/default.ini.tpl.in
index 32537e0..a0dd7db 100644
--- a/etc/couchdb/default.ini.tpl.in
+++ b/etc/couchdb/default.ini.tpl.in
@@ -50,6 +50,7 @@ allow_jsonp = false
;server_options = [{backlog, 128}, {acceptor_pool_size, 16}]
; For more socket options, consult Erlang's module 'inet' man page.
;socket_options = [{recbuf, 262144}, {sndbuf, 262144}, {nodelay, true}]
+socket_options = [{recbuf, 262144}, {sndbuf, 262144}]
log_max_chunk_size = 1000000
enable_cors = false
; CouchDB can optionally enforce a maximum uri length;
[4/7] couchdb commit: updated refs/heads/Update-Sidebar-Ui to eb1c7c0
Posted by de...@apache.org.
Describe HTTP 403 response reasons for /_uuids resource
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/027ffa44
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/027ffa44
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/027ffa44
Branch: refs/heads/Update-Sidebar-Ui
Commit: 027ffa44a71f84a0978930e826f0ba2194eb4efa
Parents: 5a4ee5f
Author: Alexander Shorin <kx...@apache.org>
Authored: Thu Mar 27 17:19:06 2014 +0400
Committer: Dirkjan Ochtman <di...@ochtman.nl>
Committed: Tue Apr 1 19:35:44 2014 +0200
----------------------------------------------------------------------
share/doc/src/api/server/common.rst | 4 ++++
1 file changed, 4 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/027ffa44/share/doc/src/api/server/common.rst
----------------------------------------------------------------------
diff --git a/share/doc/src/api/server/common.rst b/share/doc/src/api/server/common.rst
index 4e5614c..6327dc0 100644
--- a/share/doc/src/api/server/common.rst
+++ b/share/doc/src/api/server/common.rst
@@ -916,6 +916,8 @@ structure is as follows:
``/_uuids``
===========
+.. versionchanged:: 1.5.1
+
.. http:get:: /_uuids
:synopsis: Generates a list of UUIDs from the server
@@ -930,6 +932,8 @@ structure is as follows:
- :mimetype:`text/plain; charset=utf-8`
:>header ETag: Response hash
:code 200: Request completed successfully
+ :code 403: Requested more UUIDs than is :config:option:`allowed
+ <uuids/max_count>` to retrieve
**Request**:
[5/7] couchdb commit: updated refs/heads/Update-Sidebar-Ui to eb1c7c0
Posted by de...@apache.org.
Update template helpers with utils methods for encoding and removing special characters
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/50382cad
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/50382cad
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/50382cad
Branch: refs/heads/Update-Sidebar-Ui
Commit: 50382cadc00b292ae74d0e976b88dbc3b0392871
Parents: 027ffa4
Author: suelockwood <de...@apache.org>
Authored: Tue Apr 1 13:40:35 2014 -0400
Committer: suelockwood <de...@apache.org>
Committed: Tue Apr 1 13:40:43 2014 -0400
----------------------------------------------------------------------
src/fauxton/app/helpers.js | 17 +++++++++++------
1 file changed, 11 insertions(+), 6 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/50382cad/src/fauxton/app/helpers.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/helpers.js b/src/fauxton/app/helpers.js
index d4836b9..a58cc20 100644
--- a/src/fauxton/app/helpers.js
+++ b/src/fauxton/app/helpers.js
@@ -12,20 +12,25 @@
// This file creates a set of helper functions that will be loaded for all html
-// templates. These functions should be self contained and not rely on any
+// templates. These functions should be self contained and not rely on any
// external dependencies as they are loaded prior to the application. We may
// want to change this later, but for now this should be thought of as a
// "purely functional" helper system.
define([
+ "core/utils",
"d3"
],
-function() {
+function(utils) {
var Helpers = {};
+ Helpers.removeSpecialCharacters = utils.removeSpecialCharacters;
+
+ Helpers.safeURL = utils.safeURLName;
+
Helpers.imageUrl = function(path) {
// TODO: add dynamic path for different deploy targets
return path;
@@ -33,7 +38,7 @@ function() {
// Get the URL for documentation, wiki, wherever we store it.
- // update the URLs in documentation_urls.js
+ // update the URLs in documentation_urls.js
Helpers.docs = {
"docs": "http://docs.couchdb.org/en/latest/intro/api.html#documents",
"all_dbs": "http://docs.couchdb.org/en/latest/api/server/common.html?highlight=all_dbs#get--_all_dbs",
@@ -50,8 +55,8 @@ function() {
"config": "http://docs.couchdb.org/en/latest/config/index.html",
"views": "http://docs.couchdb.org/en/latest/intro/overview.html#views",
"changes": "http://docs.couchdb.org/en/latest/api/database/changes.html?highlight=changes#post--db-_changes"
- };
-
+ };
+
Helpers.getDocUrl = function(docKey){
return Helpers.docs[docKey] || '#';
};
@@ -70,7 +75,7 @@ function() {
};
Helpers.formatDate = function(timestamp){
- format = d3.time.format("%b. %e at %H:%M%p");
+ format = d3.time.format("%b. %e at %H:%M%p");
return format(new Date(timestamp*1000));
};
[3/7] couchdb commit: updated refs/heads/Update-Sidebar-Ui to eb1c7c0
Posted by de...@apache.org.
Add What's New item about uuids.max_count option
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/5a4ee5f2
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/5a4ee5f2
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/5a4ee5f2
Branch: refs/heads/Update-Sidebar-Ui
Commit: 5a4ee5f2a34a9ba720da9e6196150848f0deb241
Parents: 5155801
Author: Dirkjan Ochtman <di...@ochtman.nl>
Authored: Thu Mar 27 13:51:40 2014 +0100
Committer: Dirkjan Ochtman <di...@ochtman.nl>
Committed: Tue Apr 1 19:35:20 2014 +0200
----------------------------------------------------------------------
share/doc/src/whatsnew/1.5.rst | 9 +++++++++
1 file changed, 9 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/5a4ee5f2/share/doc/src/whatsnew/1.5.rst
----------------------------------------------------------------------
diff --git a/share/doc/src/whatsnew/1.5.rst b/share/doc/src/whatsnew/1.5.rst
index 0672bc8..7f2d750 100644
--- a/share/doc/src/whatsnew/1.5.rst
+++ b/share/doc/src/whatsnew/1.5.rst
@@ -21,6 +21,15 @@
:depth: 1
:local:
+.. _release/1.5.1:
+
+Version 1.5.1
+=============
+
+* Add the ``max_count`` option (:ref:`config/uuids`) to allow rate-limiting
+ the amount of UUIDs that can be requested from the :ref:`api/server/uuids`
+ handler in a single request.
+
.. _release/1.5.0:
Version 1.5.0
[6/7] couchdb commit: updated refs/heads/Update-Sidebar-Ui to eb1c7c0
Posted by de...@apache.org.
remove filter by in active tasks
Fix Active Tasks sidebar
dom cleanup
sidebar ui
Make Sidebar show all design doc functions
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/8995cac4
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/8995cac4
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/8995cac4
Branch: refs/heads/Update-Sidebar-Ui
Commit: 8995cac4ad50b4fbafa6f03940a4f3a4186c3cd1
Parents: 50382ca
Author: suelockwood <de...@apache.org>
Authored: Mon Mar 31 14:56:07 2014 -0400
Committer: suelockwood <de...@apache.org>
Committed: Tue Apr 1 14:35:13 2014 -0400
----------------------------------------------------------------------
.../app/addons/activetasks/templates/tabs.html | 11 +-
src/fauxton/app/addons/activetasks/views.js | 2 +
.../addons/documents/assets/less/documents.less | 47 +++++-
src/fauxton/app/addons/documents/routes.js | 56 +++++--
.../templates/add_new_ddoc_fn_dropdown.html | 28 ++++
.../documents/templates/attachments_footer.html | 20 +++
.../documents/templates/design_doc_menu.html | 24 +++
.../templates/design_doc_selector.html | 3 +
.../documents/templates/index_menu_item.html | 4 +-
.../app/addons/documents/templates/sidebar.html | 41 ++---
src/fauxton/app/addons/documents/views.js | 151 +++++++++++++-----
src/fauxton/app/templates/layouts/two_pane.html | 1 -
.../assets/less/bootstrap/dropdowns.less | 33 +++-
src/fauxton/assets/less/bootstrap/navs.less | 3 -
.../assets/less/bootstrap/variables.less | 8 +-
src/fauxton/assets/less/fauxton.less | 157 ++++++++++---------
src/fauxton/assets/less/variables.less | 1 +
17 files changed, 407 insertions(+), 183 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/activetasks/templates/tabs.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/activetasks/templates/tabs.html b/src/fauxton/app/addons/activetasks/templates/tabs.html
index 5869748..624c386 100644
--- a/src/fauxton/app/addons/activetasks/templates/tabs.html
+++ b/src/fauxton/app/addons/activetasks/templates/tabs.html
@@ -14,14 +14,6 @@ the License.
-
-
-<div id="sidenav">
- <header class="row-fluid">
- <h3>Filter by: </h3>
- </header>
-
- <nav>
<ul class="task-tabs nav nav-list">
<% for (var filter in filters) { %>
<li data-type="<%=filter%>">
@@ -42,5 +34,4 @@ the License.
<label for="pollingRange"><span>5</span> second(s)</label>
</li>
</ul>
- </nav>
-</div>
+
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/activetasks/views.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/activetasks/views.js b/src/fauxton/app/addons/activetasks/views.js
index b0940bf..453069f 100644
--- a/src/fauxton/app/addons/activetasks/views.js
+++ b/src/fauxton/app/addons/activetasks/views.js
@@ -29,6 +29,8 @@ function (app, FauxtonAPI, activetasks) {
Views.Events = _.extend(Events, Backbone.Events);
Views.TabMenu = FauxtonAPI.View.extend({
+ tagName: "nav",
+ className: "sidenav",
template: "addons/activetasks/templates/tabs",
events: {
"click .task-tabs li": "requestByType",
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/assets/less/documents.less
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/assets/less/documents.less b/src/fauxton/app/addons/documents/assets/less/documents.less
index 36429ff..f00b674 100644
--- a/src/fauxton/app/addons/documents/assets/less/documents.less
+++ b/src/fauxton/app/addons/documents/assets/less/documents.less
@@ -35,7 +35,7 @@ button.beautify {
#select-per-page {
margin-top: 10px;
}
-
+
}
@@ -112,4 +112,49 @@ button.beautify {
}
+.sidenav{
+ margin-bottom: 40px;
+ li.nav-header {
+ position: relative;
+ .accordion-body{
+ color: #eee;
+ margin-left: 0;
+ li a{
+ padding-left: 55px;
+ }
+ }
+ > span{
+ display: block;
+ padding: 10px 13px 10px 30px;
+ color: #333333;
+ border-bottom: 1px solid #989898;
+ &:before{
+ font-size: 12px;
+ padding-right: 10px;
+ }
+ &.down:before {
+ transform:rotate(90deg);
+ -ms-transform:rotate(90deg); /* IE 9 */
+ -webkit-transform:rotate(90deg); /* Opera, Chrome, and Safari */
+ }
+ }
+ div.new-button {
+ position: absolute;
+ top: 2px;
+ right: 15px;
+ .dropdown-menu{
+ left: -57px;
+ padding-bottom: 0;
+ }
+ .dropdown-toggle{
+ text-decoration: none;
+ }
+ > a {
+ border-bottom: none;
+ text-decoration: none;
+ font-size: 16px;
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/routes.js b/src/fauxton/app/addons/documents/routes.js
index 699a496..90cf8b2 100644
--- a/src/fauxton/app/addons/documents/routes.js
+++ b/src/fauxton/app/addons/documents/routes.js
@@ -90,7 +90,7 @@ function(app, FauxtonAPI, Documents, Databases) {
database = this.database;
doc.copy(newId).then(function () {
- doc.set({_id: newId});
+ doc.set({_id: newId});
docView.forceRender();
FauxtonAPI.navigate('/database/' + database.safeID() + '/' + app.utils.safeURLName(newId), {trigger: true});
FauxtonAPI.addNotification({
@@ -143,12 +143,25 @@ function(app, FauxtonAPI, Documents, Databases) {
layout: "with_tabs_sidebar",
selectedHeader: "Databases",
routes: {
- "database/:database/_all_docs(:extra)": "allDocs",
- "database/:database/_design/:ddoc/_view/:view": {
+ "database/:database/_all_docs(:extra)": "allDocs",
+ "database/:database/_design/:ddoc/_views/:view": {
route: "viewFn",
roles: ['_admin']
},
- "database/:database/new_view": "newViewEditor"
+ "database/:database/_design/:ddoc/_lists/:fn": {
+ route: "tempFn",
+ roles: ['_admin']
+ },
+ "database/:database/_design/:ddoc/_filters/:fn": {
+ route: "tempFn",
+ roles: ['_admin']
+ },
+ "database/:database/_design/:ddoc/_show/:fn": {
+ route: "tempFn",
+ roles: ['_admin']
+ },
+ "database/:database/new_view": "newViewEditor",
+ "database/:database/new_view/:designDoc": "newViewEditor"
},
events: {
@@ -181,6 +194,16 @@ function(app, FauxtonAPI, Documents, Databases) {
}));
},
+ tempFn: function(databaseName, ddoc, fn){
+ this.setView("#dashboard-upper-content", new Documents.Views.temp({}));
+ this.crumbs = function () {
+ return [
+ {"name": this.data.database.id, "link": Databases.databaseUrl(this.data.database)},
+ ];
+ };
+
+ },
+
establish: function () {
return this.data.designDocs.fetch();
},
@@ -194,7 +217,7 @@ function(app, FauxtonAPI, Documents, Databases) {
},
/*
- * docParams are the options collection uses to fetch from the server
+ * docParams are the options collection uses to fetch from the server
* urlParams are what are shown in the url and to the user
* They are not the same when paginating
*/
@@ -259,7 +282,7 @@ function(app, FauxtonAPI, Documents, Databases) {
view: view,
params: docParams
});
-
+
this.viewEditor = this.setView("#dashboard-upper-content", new Documents.Views.ViewEditor({
model: this.data.database,
ddocs: this.data.designDocs,
@@ -274,7 +297,7 @@ function(app, FauxtonAPI, Documents, Databases) {
this.documentsView = this.createViewDocumentsView({
designDoc: decodeDdoc,
- docParams: docParams,
+ docParams: docParams,
urlParams: urlParams,
database: this.data.database,
indexedDocs: this.data.indexedDocs,
@@ -302,7 +325,7 @@ function(app, FauxtonAPI, Documents, Databases) {
};
},
- createViewDocumentsView: function (options) {
+ createViewDocumentsView: function (options) {
return this.setView("#dashboard-lower-content", new Documents.Views.AllDocsList({
database: options.database,
@@ -315,13 +338,14 @@ function(app, FauxtonAPI, Documents, Databases) {
}));
},
- newViewEditor: function () {
+ newViewEditor: function (database, designDoc) {
var params = app.getParams();
this.toolsView && this.toolsView.remove();
this.documentsView && this.documentsView.remove();
this.viewEditor = this.setView("#dashboard-upper-content", new Documents.Views.ViewEditor({
+ currentddoc: "_design/"+designDoc || "",
ddocs: this.data.designDocs,
params: params,
database: this.data.database,
@@ -365,7 +389,7 @@ function(app, FauxtonAPI, Documents, Databases) {
if (!this.documentsView) {
this.documentsView = this.createViewDocumentsView({
designDoc: ddoc,
- docParams: docParams,
+ docParams: docParams,
urlParams: urlParams,
database: this.data.database,
indexedDocs: this.indexedDocs,
@@ -427,14 +451,14 @@ function(app, FauxtonAPI, Documents, Databases) {
urlParams = Documents.QueryParams.parse(urlParams);
if (options.direction === 'next') {
- params = Documents.paginate.next(collection.toJSON(),
+ params = Documents.paginate.next(collection.toJSON(),
collection.params,
- options.perPage,
+ options.perPage,
!!collection.isAllDocs);
} else {
- params = Documents.paginate.previous(collection.toJSON(),
- collection.params,
- options.perPage,
+ params = Documents.paginate.previous(collection.toJSON(),
+ collection.params,
+ options.perPage,
!!collection.isAllDocs);
}
@@ -473,7 +497,7 @@ function(app, FauxtonAPI, Documents, Databases) {
} else {
storedPerPage = parseInt(storedPerPage, 10);
}
- }
+ }
if (!urlParams.limit || urlParams.limit > storedPerPage) {
return storedPerPage;
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/templates/add_new_ddoc_fn_dropdown.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/templates/add_new_ddoc_fn_dropdown.html b/src/fauxton/app/addons/documents/templates/add_new_ddoc_fn_dropdown.html
new file mode 100644
index 0000000..daf3864
--- /dev/null
+++ b/src/fauxton/app/addons/documents/templates/add_new_ddoc_fn_dropdown.html
@@ -0,0 +1,28 @@
+<!--
+Licensed under the Apache License, Version 2.0 (the "License"); you may not
+use this file except in compliance with the License. You may obtain a copy of
+the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+License for the specific language governing permissions and limitations under
+the License.
+-->
+
+<div class="dropdown">
+ <a class="dropdown-toggle icon fonticon-circle-plus" data-toggle="dropdown" href="#" data-bypass="true"></a>
+ <ul class="dropdown-menu arrow" role="menu" aria-labelledby="dLabel">
+ <% if (full){ %>
+ <li><a class="icon fonticon-replication" href="#replicate/<%=database.id%>">Replicate</a><li>
+ <li><a class="icon fonticon-trash" href="#" data-bypass="true">Delete</a><li>
+ <%}%>
+ <li class="header-label">Add new</li>
+ <li><a class="icon fonticon-circle-plus" href="#<%= database.url('app') %>/new_view/<%=ddocSafe%>">Secondary View</a><li>
+ <li><a class="icon fonticon-circle-plus" href="#<%= database.url('app') %>/new_filter/<%=ddocSafe%>">Filter Function</a><li>
+ <li><a class="icon fonticon-circle-plus" href="#<%= database.url('app') %>/new_show/<%=ddocSafe%>">Show Function</a><li>
+ <li><a class="icon fonticon-circle-plus" href="#<%= database.url('app') %>/new_list/<%=ddocSafe%>">List function</a><li>
+ </ul>
+</div>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/templates/attachments_footer.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/templates/attachments_footer.html b/src/fauxton/app/addons/documents/templates/attachments_footer.html
new file mode 100644
index 0000000..31bd5a5
--- /dev/null
+++ b/src/fauxton/app/addons/documents/templates/attachments_footer.html
@@ -0,0 +1,20 @@
+<!--
+Licensed under the Apache License, Version 2.0 (the "License"); you may not
+use this file except in compliance with the License. You may obtain a copy of
+the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+License for the specific language governing permissions and limitations under
+the License.
+-->
+
+<ul>
+ <li> attachment 1</li>
+ <li> attachment 2 </li>
+ <li> attachment 3</li>
+ <li> attachment 4</li>
+</ul>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/templates/design_doc_menu.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/templates/design_doc_menu.html b/src/fauxton/app/addons/documents/templates/design_doc_menu.html
new file mode 100644
index 0000000..ee45ed6
--- /dev/null
+++ b/src/fauxton/app/addons/documents/templates/design_doc_menu.html
@@ -0,0 +1,24 @@
+<!--
+Licensed under the Apache License, Version 2.0 (the "License"); you may not
+use this file except in compliance with the License. You may obtain a copy of
+the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+License for the specific language governing permissions and limitations under
+the License.
+-->
+<li class="nav-header">
+ <span class="fonticon-play js-collapse-toggle" data-toggle="collapse" data-target="#<%=designDoc%>">
+ <%= designDoc%>
+ </span>
+ <div class="new-button">
+
+ </div>
+
+ <ul class="accordion-body collapse" id="<%=designDoc%>">
+ </ul>
+</li>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/templates/design_doc_selector.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/templates/design_doc_selector.html b/src/fauxton/app/addons/documents/templates/design_doc_selector.html
index 7bbe310..0a5bee2 100644
--- a/src/fauxton/app/addons/documents/templates/design_doc_selector.html
+++ b/src/fauxton/app/addons/documents/templates/design_doc_selector.html
@@ -16,7 +16,10 @@ the License.
<select id="ddoc">
<optgroup label="Select a document">
<option value="new-doc">New document</option>
+
<% ddocs.each(function(ddoc) { %>
+ <%= ddoc.id %>
+ <%= ddocName %>
<% if (ddoc.id === ddocName) { %>
<option selected="selected" value="<%= ddoc.id %>"><%= ddoc.id %></option>
<% } else { %>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/templates/index_menu_item.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/templates/index_menu_item.html b/src/fauxton/app/addons/documents/templates/index_menu_item.html
index 7ca9012..77b51d0 100644
--- a/src/fauxton/app/addons/documents/templates/index_menu_item.html
+++ b/src/fauxton/app/addons/documents/templates/index_menu_item.html
@@ -12,6 +12,6 @@ License for the specific language governing permissions and limitations under
the License.
-->
-<a id="<%= ddoc_clean %>_<%= index_clean %>" href="#database/<%= database_encoded %>/_design/<%= ddoc_encoded %>/_view/<%= index_encoded %>" class="toggle-view">
- <%= ddoc %><span class="divider">/</span><%= index %>
+<a id="<%= ddoc_clean %>_<%= index_clean %>" href="#database/<%= database_encoded %>/_design/<%= ddoc_encoded %>/_<%=type%>/<%= index_encoded %>" class="toggle-view">
+ <%= index %>
</a>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/templates/sidebar.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/templates/sidebar.html b/src/fauxton/app/addons/documents/templates/sidebar.html
index 750cd30..59d76e1 100644
--- a/src/fauxton/app/addons/documents/templates/sidebar.html
+++ b/src/fauxton/app/addons/documents/templates/sidebar.html
@@ -11,34 +11,17 @@ WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
License for the specific language governing permissions and limitations under
the License.
-->
-
-<div id="sidenav">
- <header class="row-fluid">
+<!-- <header class="row-fluid">
<div class="span12">
- <div class="btn-group">
- <button class="btn dropdown-toggle dropdown-toggle-btn" data-toggle="dropdown">
- Docs
- <span class="caret"></span>
- </button>
- <ul class="dropdown-menu">
- <!-- dropdown menu links -->
- <li><a href="<%= db_url %>"><i class="icon icon-file"></i> Docs</a></li>
- <li><a href="<%= permissions_url %>"><i class="icon icon-lock"></i> Permissions</a></li>
- <li><a href="<%= changes_url %>"><i class="icon icon-forward"></i> Changes</a></li>
- <% _.each(docLinks, function (link) { %>
- <li><a href="<%= database_url + '/' + link.url %>"><i class="icon <%= link.icon %>"></i> <%= link.title %></a></li>
- <% }); %>
- </ul>
- </div>
<div class="btn-group">
<button class="btn dropdown-toggle dropdown-toggle-btn" data-toggle="dropdown">
- New
+ Create New
<span class="caret"></span>
</button>
<ul class="dropdown-menu">
<!-- dropdown menu links -->
- <li>
+<!-- <li>
<a id="doc" href="#<%= database.url('app') %>/new">Document</a>
</li>
<li>
@@ -51,18 +34,18 @@ the License.
</div>
<button id="delete-database" class="btn pull-right"><i class="icon-trash"></i> Database</button>
</div>
- </header>
+ </header> -->
+
- <nav>
<ul class="nav nav-list">
+ <li><a id="changes" href="<%= permissions_url %>">Permissions</a><li>
+ <li><a id="changes" href="<%= changes_url %>">Changes</a><li>
+ <% _.each(docLinks, function (link) { %>
+ <li><a href="<%= database_url + '/' + link.url %>"><%= link.title %></a></li>
+ <% }); %>
+
<li class="active"><a id="all-docs" href="#<%= database.url('index') %>" class="toggle-view"> All documents</a></li>
<li><a id="design-docs" href='#<%= database.url("index") %>?startkey="_design"&endkey="_e"' class="toggle-view"> All design docs</a></li>
</ul>
- <ul class="nav nav-list views">
- <li class="nav-header">Secondary Indexes</li>
- <li><a id="new-view" href="#<%= database.url('app') %>/new_view" class="new"><i class="icon-plus"></i> New</a></li>
- </ul>
- <div id="extension-navs"></div>
- </nav>
+
<div id="delete-db-modal"> </div>
-</div>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/addons/documents/views.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/views.js b/src/fauxton/app/addons/documents/views.js
index cc23e19..6153e40 100644
--- a/src/fauxton/app/addons/documents/views.js
+++ b/src/fauxton/app/addons/documents/views.js
@@ -387,10 +387,12 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
this.ddoc = options.ddoc;
this.database = options.database;
this.selected = !! options.selected;
+ this.selector = options.selector;
},
serialize: function() {
return {
+ type: this.selector,
index: this.index,
ddoc: this.ddoc,
database: this.database,
@@ -405,7 +407,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
afterRender: function() {
if (this.selected) {
- $("#sidenav ul.nav-list li").removeClass("active");
+ $(".sidenav ul.nav-list li").removeClass("active");
this.$el.addClass("active");
}
}
@@ -418,7 +420,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
this.newView = options.newView || false;
this.pagination = options.pagination;
_.bindAll(this);
-
+
this._perPage = options.perPageDefault || 20;
this.listenTo(this.collection, 'totalRows:decrement', this.render);
},
@@ -1098,7 +1100,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
//highlight current
this.$(".toggle-btns > label").removeClass('active');
this.$(e.currentTarget).addClass("active");
-
+
this.$("[id^='js-show']").hide();
//show section & disable what needs to be disabled
@@ -1148,7 +1150,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
if (_.isUndefined(parsedValue)) {
errorMsg = "Keys must be valid json.";
} else if (!_.isArray(parsedValue)) {
- errorMsg = "Keys values must be in an array. E.g [1,2,3]";
+ errorMsg = "Keys values must be in an array. E.g [1,2,3]";
}
if (errorMsg) {
@@ -1162,7 +1164,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
return false;
}
- return true;
+ return true;
},
queryParams: function () {
var $form = this.$(".js-view-query-update"),
@@ -1251,8 +1253,8 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
}
this.updateFiltersFor(key, $ele);
break;
- case "key":
- case "keys":
+ case "key":
+ case "keys":
$form.find("textarea[name='"+key+"']").val(val);
break;
default:
@@ -1373,6 +1375,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
this.ddocs = options.ddocs;
this.params = options.params;
this.database = options.database;
+ this.currentDdoc = options.currentddoc;
if (this.newView) {
this.viewName = 'newView';
} else {
@@ -1653,7 +1656,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
toggleIndexNav: function (event) {
$('#dashboard-content').scrollTop(0); //scroll up
-
+
var $targetId = this.$(event.target).attr('id'),
$previousTab = this.$(this.$('li.active a').attr('href')),
$targetTab = this.$(this.$(event.target).attr('href'));
@@ -1662,7 +1665,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
$previousTab.removeAttr('style');
}
//stop polling
- this.ddocInfoView.stopRefreshInterval();
+ this.ddocInfoView.stopRefreshInterval();
if ($targetId === 'index-nav') {
if (this.newView) { return; }
@@ -1674,8 +1677,8 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
} else if ($targetId === "meta-nav"){
if (!$("#ddoc-info").is(":visible")){
this.ddocInfoView.startRefreshInterval();
- }
- $targetTab.toggle('slow');
+ }
+ $targetTab.toggle('slow');
} else {
$targetTab.toggle('slow');
}
@@ -1722,7 +1725,7 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
renderDdocInfo: function(){
if(this.ddocInfoView){
this.ddocInfoView.remove();
- }
+ }
if (this.newView) { return; }
this.ddocInfoView = this.setView('#ddoc-info', new Views.DdocInfo({model: this.ddocInfo }));
@@ -1743,12 +1746,12 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
var ddocDecode = decodeURIComponent(this.ddocID);
this.model = this.ddocs.get(ddocDecode).dDocModel();
this.reduceFunStr = this.model.viewHasReduce(this.viewName);
-
+
}
this.designDocSelector = this.setView('.design-doc-group', new Views.DesignDocSelector({
collection: this.ddocs,
- ddocName: this.model.id,
+ ddocName: this.currentDdoc || this.model.id,
database: this.database
}));
@@ -1852,6 +1855,8 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
Views.Sidebar = FauxtonAPI.View.extend({
template: "addons/documents/templates/sidebar",
+ className: "sidenav",
+ tagName: "nav",
events: {
"click button#delete-database": "showDeleteDatabaseModal"
},
@@ -1885,17 +1890,6 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
};
},
- buildIndexList: function(collection, selector, design){
- _.each(_.keys(collection), function(key){
- var selected = this.ddocID == "_design/"+design;
- this.insertView("ul.nav." + selector, new Views.IndexItem({
- ddoc: design,
- index: key,
- database: this.collection.database.id,
- selected: selected && key == this.currView
- }));
- }, this);
- },
beforeRender: function(manage) {
this.deleteDBModal = this.setView(
@@ -1903,21 +1897,14 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
new Views.DeleteDBModal({database: this.database})
);
- var sidebarListViews = FauxtonAPI.getExtensions('sidebar:list');
- _.each(sidebarListViews, function (view) {
- var extension = this.insertView('#extension-navs', view);
- extension.update(this.database, this.collection, this.viewName);
- extension.render();
- }, this);
-
this.collection.each(function(design) {
if (design.has('doc')){
- var ddoc = design.id.replace(/^_design\//,"");
- if (design.get('doc').views){
- this.buildIndexList(design.get('doc').views, "views", ddoc);
- }
+ this.insertView(new Views.DdocSidenav({
+ model: design,
+ collection: this.collection
+ }));
}
- }, this);
+ },this);
},
@@ -1934,6 +1921,72 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
}
});
+
+ Views.DdocSidenav = FauxtonAPI.View.extend({
+ tagName: "ul",
+ className: "nav nav-list",
+ template: "addons/documents/templates/design_doc_menu",
+ events: {
+ "click button": "no",
+ "click .js-collapse-toggle": "toggleArrow"
+ },
+ initialize: function(){
+
+ },
+ toggleArrow: function(e){
+ this.$(e.currentTarget).toggleClass("down");
+ },
+ no: function(event){
+ event.preventDefault();
+ alert("no");
+ },
+ buildIndexList: function(collection, selector){
+ var design = this.model.id.replace(/^_design\//,"");
+ _.each(_.keys(collection[selector]), function(key){
+ this.insertView(".accordion-body", new Views.IndexItem({
+ selector: selector,
+ ddoc: design,
+ index: key,
+ database: this.model.collection.database.id
+ }));
+ }, this);
+ },
+
+ serialize: function(){
+ var ddocName = this.model.id.replace(/^_design\//,"");
+ return{
+ database: this.collection.database,
+ designDoc: ddocName
+ };
+ },
+ beforeRender: function(manage) {
+ var ddocDocs = this.model.get("doc");
+ var ddocName = this.model.id.replace(/^_design\//,"");
+
+ var sidebarListTypes = FauxtonAPI.getExtensions('sidebar:list');
+ if (ddocDocs){
+ //Views
+ this.buildIndexList(ddocDocs, "views");
+ //lists
+ this.buildIndexList(ddocDocs, "lists");
+ //show
+ this.buildIndexList(ddocDocs, "show");
+ //filters
+ this.buildIndexList(ddocDocs, "filters");
+ //extensions
+ _.each(sidebarListTypes, function (type) {
+ this.buildIndexList(ddocDocs, type);
+ },this);
+ }
+ this.insertView(".new-button", new Views.newMenuDropdown({
+ database: this.collection.database,
+ ddocSafeName: app.utils.safeURLName(ddocName),
+ fullMenu: false
+ }));
+
+ }
+ });
+
Views.Indexed = FauxtonAPI.View.extend({});
Views.Changes = FauxtonAPI.View.extend({
@@ -1960,6 +2013,30 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
}
});
+
+ Views.newMenuDropdown = FauxtonAPI.View.extend({
+ template: "addons/documents/templates/add_new_ddoc_fn_dropdown",
+ tagName: "div",
+ className: "dropdown",
+ initialize: function(options){
+ this.database = options.database;
+ this.fullMenu = options.fullMenu;
+ this.ddocSafeName = options.ddocSafeName || "";
+ },
+ serialize: function(){
+ return {
+ database: this.database,
+ ddocSafe: this.ddocSafeName,
+ full: this.fullMenu
+ };
+ }
+ });
+
+
+
+ Views.temp = FauxtonAPI.View.extend({
+ });
+
Views.DdocInfo = FauxtonAPI.View.extend({
template: "addons/documents/templates/ddoc_info",
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/app/templates/layouts/two_pane.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/templates/layouts/two_pane.html b/src/fauxton/app/templates/layouts/two_pane.html
index 0c3165e..031ad12 100644
--- a/src/fauxton/app/templates/layouts/two_pane.html
+++ b/src/fauxton/app/templates/layouts/two_pane.html
@@ -22,7 +22,6 @@ the License.
<div class="row-fluid content-area">
- <div id="tabs" class="row"></div>
<div id="left-content" class="span6"></div>
<div id="right-content" class="span6"></div>
</div>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/assets/less/bootstrap/dropdowns.less
----------------------------------------------------------------------
diff --git a/src/fauxton/assets/less/bootstrap/dropdowns.less b/src/fauxton/assets/less/bootstrap/dropdowns.less
index 9e47b47..0425077 100644
--- a/src/fauxton/assets/less/bootstrap/dropdowns.less
+++ b/src/fauxton/assets/less/bootstrap/dropdowns.less
@@ -39,6 +39,7 @@
// The dropdown menu (ul)
// ----------------------
.dropdown-menu {
+
position: absolute;
top: 100%;
left: 0;
@@ -46,7 +47,6 @@
display: none; // none by default, but block on "open" of the menu
float: left;
min-width: 160px;
- padding: 5px 0;
margin: 2px 0 0; // override default ul
list-style: none;
background-color: @dropdownBackground;
@@ -54,8 +54,6 @@
border: 1px solid @dropdownBorder;
*border-right-width: 2px;
*border-bottom-width: 2px;
- .border-radius(6px);
- .box-shadow(0 5px 10px rgba(0,0,0,.2));
-webkit-background-clip: padding-box;
-moz-background-clip: padding;
background-clip: padding-box;
@@ -65,7 +63,29 @@
right: 0;
left: auto;
}
-
+ li.header-label{
+ background-color: #1A1A1A;
+ color: #676767;
+ padding: 3px 20px;
+ font-size: 13px;
+ }
+ &.arrow {
+ &:before{
+ content: "";
+ display: block;
+ position: absolute;
+ border-style: solid;
+ top: -20px;
+ left: 50%;
+ width: 0;
+ height: 0;
+ margin-left: -10px;
+ border-left: 10px solid transparent;
+ border-right: 10px solid transparent;
+ border-bottom: 10px solid #2b2f33;
+ border-top: 10px solid transparent;
+ }
+ }
// Dividers (basically an hr) within the dropdown
.divider {
.nav-divider(@dropdownDividerTop, @dropdownDividerBottom);
@@ -73,6 +93,10 @@
// Links within the dropdown menu
> li > a {
+ &.icon:before{
+ padding-right: 5px;
+ }
+ font-size: 12px;
display: block;
padding: 3px 20px;
clear: both;
@@ -80,6 +104,7 @@
line-height: @baseLineHeight;
color: @dropdownLinkColor;
white-space: nowrap;
+ border-bottom: 1px solid #1A1A1A;
}
}
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/assets/less/bootstrap/navs.less
----------------------------------------------------------------------
diff --git a/src/fauxton/assets/less/bootstrap/navs.less b/src/fauxton/assets/less/bootstrap/navs.less
index 01cd805..0013179 100644
--- a/src/fauxton/assets/less/bootstrap/navs.less
+++ b/src/fauxton/assets/less/bootstrap/navs.less
@@ -37,12 +37,9 @@
.nav-header {
display: block;
padding: 3px 15px;
- font-size: 11px;
- font-weight: bold;
line-height: @baseLineHeight;
color: @grayLight;
text-shadow: 0 1px 0 rgba(255,255,255,.5);
- text-transform: uppercase;
}
// Space them out when they follow another list item (link)
.nav li + .nav-header {
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/assets/less/bootstrap/variables.less
----------------------------------------------------------------------
diff --git a/src/fauxton/assets/less/bootstrap/variables.less b/src/fauxton/assets/less/bootstrap/variables.less
index 31c131b..f52b2cb 100644
--- a/src/fauxton/assets/less/bootstrap/variables.less
+++ b/src/fauxton/assets/less/bootstrap/variables.less
@@ -119,12 +119,12 @@
// Dropdowns
// -------------------------
-@dropdownBackground: @white;
+@dropdownBackground: #2B2F33;
@dropdownBorder: rgba(0,0,0,.2);
-@dropdownDividerTop: #e5e5e5;
-@dropdownDividerBottom: @white;
+@dropdownDividerTop: #1A1A1A;
+@dropdownDividerBottom: #1A1A1A;
-@dropdownLinkColor: @grayDark;
+@dropdownLinkColor: #D9D9D9;
@dropdownLinkColorHover: @white;
@dropdownLinkColorActive: @white;
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/assets/less/fauxton.less
----------------------------------------------------------------------
diff --git a/src/fauxton/assets/less/fauxton.less b/src/fauxton/assets/less/fauxton.less
index 229075b..2fba9df 100644
--- a/src/fauxton/assets/less/fauxton.less
+++ b/src/fauxton/assets/less/fauxton.less
@@ -357,7 +357,7 @@ table.databases {
background: url(../img/couchdb-site.png) no-repeat 0 0;
display: block;
height: 100%;
- width: 100%;
+ width: 100%;
}
.burger{
.transition(all @transitionSpeed @transitionEaseType);
@@ -468,7 +468,7 @@ table.databases {
background-color: @bottomNav;
&.active{
background-color:@linkRed;
- }
+ }
&:hover{
background-color: @navBGHover;
}
@@ -527,12 +527,15 @@ table.databases {
padding: 0px;
bottom: 0px;
top: 60px;
- position: absolute;
+ position: fixed;
overflow-x: hidden;
overflow-y: auto;
- left: @sidebarWidth;
+ left: @sidebarWidth+@navWidth;
right: 0;
.box-sizing(border-box);
+ .closeMenu & {
+ left: @sidebarWidth+@collapsedNavWidth;
+ }
}
> div.inner {
display: block;
@@ -636,7 +639,7 @@ table.databases {
}
}
-#sidenav{
+.sidenav{
padding: 0;
header {
width: @sidebarWidth;
@@ -644,46 +647,48 @@ table.databases {
background: transparent url('../img/linen.png') repeat 0 0;
.topmenu-defaults;
}
- nav {
- .nav-list{
- .divider {
- border: none;
- }
- li.active a {
- background-color: @darkRed;
- color: #fff;
- }
- a{
- display: block;
- padding: 10px 5px 10px 15px;
- color: #333333;
- border-bottom: 1px solid #989898;
- .divider {
- background: none;
- color: #ccc;
- padding: 0 2px;
- }
- }
- .nav-header{
- background-color: #B2B2B2;
- padding: 5px;
- text-shadow: none;
- color: #333333;
- border-bottom: 1px solid #989898;
+ .nav-list{
+ .divider {
+ border: none;
+ }
+ li.active a {
+ background-color: @darkRed;
+ color: #fff;
+ }
+ > li > a{
+ padding: 10px 13px 10px 30px;
+ border-bottom: 1px solid #989898;
+ }
+ .dropdown-menu {
+ a {
+ color: #d9d9d9;
}
+ }
+ a{
+ display: block;
+ padding: 10px 5px 10px 15px;
+ color: #333333;
+ .divider {
+ background: none;
+ color: #ccc;
+ padding: 0 2px;
+ }
+ }
+ .nav-header{
+ padding: 0px;
+ text-shadow: none;
+ color: #333333;
+ margin-bottom: -4px;
}
}
}
+
#sidebar-content {
-.box-shadow(-7px 0 15px -6px #000);
position: absolute;
- bottom: 0px;
top: 60px;
width: @sidebarWidth;
left: 0;
- overflow-x: hidden;
- overflow-y: auto;
background-color: @secondarySidebar;
> div.inner {
display: block;
@@ -749,14 +754,14 @@ table.databases {
.custom-inputs{
- input[type=radio],
- input[type=checkbox] {
- display: none;
- }
+ input[type=radio],
+ input[type=checkbox] {
+ display: none;
+ }
- .checkbox label:before {
- border-radius: 3px;
- }
+ .checkbox label:before {
+ border-radius: 3px;
+ }
.controls > .radio:first-child, .controls > .checkbox:first-child {
padding-top: 15px;
@@ -769,42 +774,42 @@ table.databases {
vertical-align: middle;
}
- input[type=checkbox]:checked + label:before {
+ input[type=checkbox]:checked + label:before {
/*content: "\2713"; */
- content: "\00d7";
- text-shadow: 1px 1px 1px rgba(0, 0, 0, .2);
+ content: "\00d7";
+ text-shadow: 1px 1px 1px rgba(0, 0, 0, .2);
font-size: 16px;
- background-color: @red;
- color: white;
- text-align: center;
- line-height: 15px;
- }
-
- label:before {
- content: "";
- display: inline-block;
-
- width: 16px;
- height: 16px;
-
- margin-right: 10px;
- position: absolute;
- left: 0;
- bottom: 1px;
- background-color: #aaa;
- box-shadow: inset 0px 2px 3px 0px rgba(0, 0, 0, .3), 0px 1px 0px 0px rgba(255, 255, 255, .8);
- }
-
- .radio label:before {
- border-radius: 8px;
- }
-
- input[type=radio]:checked + label:before {
- content: "\2022";
- color: #f3f3f3;
- font-size: 30px;
- text-align: center;
- line-height: 18px;
+ background-color: @red;
+ color: white;
+ text-align: center;
+ line-height: 15px;
+ }
+
+ label:before {
+ content: "";
+ display: inline-block;
+
+ width: 16px;
+ height: 16px;
+
+ margin-right: 10px;
+ position: absolute;
+ left: 0;
+ bottom: 1px;
+ background-color: #aaa;
+ box-shadow: inset 0px 2px 3px 0px rgba(0, 0, 0, .3), 0px 1px 0px 0px rgba(255, 255, 255, .8);
+ }
+
+ .radio label:before {
+ border-radius: 8px;
+ }
+
+ input[type=radio]:checked + label:before {
+ content: "\2022";
+ color: #f3f3f3;
+ font-size: 30px;
+ text-align: center;
+ line-height: 18px;
}
label.drop-down{
http://git-wip-us.apache.org/repos/asf/couchdb/blob/8995cac4/src/fauxton/assets/less/variables.less
----------------------------------------------------------------------
diff --git a/src/fauxton/assets/less/variables.less b/src/fauxton/assets/less/variables.less
index 34f8b90..ab479a8 100644
--- a/src/fauxton/assets/less/variables.less
+++ b/src/fauxton/assets/less/variables.less
@@ -54,6 +54,7 @@
@sidebarBG: #F2F2F2;
@sidebarWidth: 330px;
+
@NavIconActive: #ffffff;
@NavIcon: @brown;
[7/7] couchdb commit: updated refs/heads/Update-Sidebar-Ui to eb1c7c0
Posted by de...@apache.org.
add metadata as a sidebar option
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/eb1c7c0f
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/eb1c7c0f
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/eb1c7c0f
Branch: refs/heads/Update-Sidebar-Ui
Commit: eb1c7c0fca5014f1dc17df4768d09582a4766b54
Parents: 8995cac
Author: suelockwood <de...@apache.org>
Authored: Tue Apr 1 10:51:21 2014 -0400
Committer: suelockwood <de...@apache.org>
Committed: Tue Apr 1 14:35:13 2014 -0400
----------------------------------------------------------------------
src/fauxton/app/addons/documents/routes.js | 16 +++++++++++++---
.../addons/documents/templates/design_doc_menu.html | 13 ++++++++-----
.../app/addons/documents/templates/sidebar.html | 3 +--
src/fauxton/app/addons/documents/views.js | 5 ++++-
4 files changed, 26 insertions(+), 11 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/eb1c7c0f/src/fauxton/app/addons/documents/routes.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/routes.js b/src/fauxton/app/addons/documents/routes.js
index 90cf8b2..1924644 100644
--- a/src/fauxton/app/addons/documents/routes.js
+++ b/src/fauxton/app/addons/documents/routes.js
@@ -17,10 +17,11 @@ define([
// Modules
"addons/documents/views",
- "addons/databases/base"
+ "addons/databases/base",
+ "addons/documents/resources"
],
-function(app, FauxtonAPI, Documents, Databases) {
+function(app, FauxtonAPI, Documents, Databases, Resources) {
var DocEditorRouteObject = FauxtonAPI.RouteObject.extend({
layout: "one_pane",
@@ -160,6 +161,10 @@ function(app, FauxtonAPI, Documents, Databases) {
route: "tempFn",
roles: ['_admin']
},
+ "database/:database/_design/:ddoc/metadata": {
+ route: "designDocMetadata",
+ roles: ['_admin']
+ },
"database/:database/new_view": "newViewEditor",
"database/:database/new_view/:designDoc": "newViewEditor"
},
@@ -193,7 +198,12 @@ function(app, FauxtonAPI, Documents, Databases) {
database: this.data.database
}));
},
-
+ designDocMetadata: function(database, ddoc){
+ var DesignDocInfo = new Resources.DdocInfo({_id: "_design/"+ddoc},{database: this.data.database });
+ this.setView("#dashboard-lower-content", new Documents.Views.DdocInfo({
+ model: DesignDocInfo
+ }));
+ },
tempFn: function(databaseName, ddoc, fn){
this.setView("#dashboard-upper-content", new Documents.Views.temp({}));
this.crumbs = function () {
http://git-wip-us.apache.org/repos/asf/couchdb/blob/eb1c7c0f/src/fauxton/app/addons/documents/templates/design_doc_menu.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/templates/design_doc_menu.html b/src/fauxton/app/addons/documents/templates/design_doc_menu.html
index ee45ed6..c5bd392 100644
--- a/src/fauxton/app/addons/documents/templates/design_doc_menu.html
+++ b/src/fauxton/app/addons/documents/templates/design_doc_menu.html
@@ -12,13 +12,16 @@ License for the specific language governing permissions and limitations under
the License.
-->
<li class="nav-header">
- <span class="fonticon-play js-collapse-toggle" data-toggle="collapse" data-target="#<%=designDoc%>">
+ <span class="fonticon-play js-collapse-toggle" data-toggle="collapse" data-target="#<%= ddoc_clean %>">
<%= designDoc%>
</span>
- <div class="new-button">
+ <div class="new-button"></div>
+ <ul class="accordion-body collapse" id="<%= ddoc_clean %>">
+ <li>
+ <a id="<%= ddoc_clean %>_metadata" href="#database/<%= database_encoded %>/_design/<%= ddoc_encoded %>/metadata" class="toggle-view">
+ Design Doc Metadata
+ </a>
+ </li>
- </div>
-
- <ul class="accordion-body collapse" id="<%=designDoc%>">
</ul>
</li>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/eb1c7c0f/src/fauxton/app/addons/documents/templates/sidebar.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/templates/sidebar.html b/src/fauxton/app/addons/documents/templates/sidebar.html
index 59d76e1..f276c5e 100644
--- a/src/fauxton/app/addons/documents/templates/sidebar.html
+++ b/src/fauxton/app/addons/documents/templates/sidebar.html
@@ -34,7 +34,7 @@ the License.
</div>
<button id="delete-database" class="btn pull-right"><i class="icon-trash"></i> Database</button>
</div>
- </header> -->
+ </header> -->
<ul class="nav nav-list">
@@ -43,7 +43,6 @@ the License.
<% _.each(docLinks, function (link) { %>
<li><a href="<%= database_url + '/' + link.url %>"><%= link.title %></a></li>
<% }); %>
-
<li class="active"><a id="all-docs" href="#<%= database.url('index') %>" class="toggle-view"> All documents</a></li>
<li><a id="design-docs" href='#<%= database.url("index") %>?startkey="_design"&endkey="_e"' class="toggle-view"> All design docs</a></li>
</ul>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/eb1c7c0f/src/fauxton/app/addons/documents/views.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/addons/documents/views.js b/src/fauxton/app/addons/documents/views.js
index 6153e40..abac4db 100644
--- a/src/fauxton/app/addons/documents/views.js
+++ b/src/fauxton/app/addons/documents/views.js
@@ -1956,7 +1956,10 @@ function(app, FauxtonAPI, Components, Documents, Databases, pouchdb, resizeColum
var ddocName = this.model.id.replace(/^_design\//,"");
return{
database: this.collection.database,
- designDoc: ddocName
+ designDoc: ddocName,
+ ddoc_clean: app.utils.removeSpecialCharacters(ddocName),
+ ddoc_encoded: app.utils.safeURLName(ddocName),
+ database_encoded: app.utils.safeURLName(this.model.collection.database.id),
};
},
beforeRender: function(manage) {
[2/7] couchdb commit: updated refs/heads/Update-Sidebar-Ui to eb1c7c0
Posted by de...@apache.org.
Add documentation for new uuids.max_count option
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/5155801f
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/5155801f
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/5155801f
Branch: refs/heads/Update-Sidebar-Ui
Commit: 5155801f8d263da1b40a9070a9deb8ae16428710
Parents: 9a0e561
Author: Dirkjan Ochtman <di...@ochtman.nl>
Authored: Thu Mar 27 13:51:19 2014 +0100
Committer: Dirkjan Ochtman <di...@ochtman.nl>
Committed: Tue Apr 1 19:35:11 2014 +0200
----------------------------------------------------------------------
share/doc/src/config/misc.rst | 11 +++++++++++
1 file changed, 11 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/5155801f/share/doc/src/config/misc.rst
----------------------------------------------------------------------
diff --git a/share/doc/src/config/misc.rst b/share/doc/src/config/misc.rst
index 753d0e2..58d079c 100644
--- a/share/doc/src/config/misc.rst
+++ b/share/doc/src/config/misc.rst
@@ -202,6 +202,17 @@ UUIDs Configuration
[uuid]
utc_id_suffix = my-awesome-suffix
+ .. config:option:: max_count :: Per-Request UUID Limit
+
+ .. versionadded:: 1.5.1
+
+ No more than this number of UUIDs will be sent in a single request. If
+ more UUIDs are requested, an HTTP error response will be thrown.
+
+ ::
+
+ [uuid]
+ max_count = 1000
.. _config/vendor: