couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j..@apache.org
Subject [15/50] [abbrv] git commit: updated refs/heads/1867-feature-plugins to 95d6e35
Date Thu, 03 Oct 2013 14:11:15 GMT
hook up futon to /_plugins


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

Branch: refs/heads/1867-feature-plugins
Commit: 4f8a2b4a280c3d462dbd48f6a47f98dc1be46d8e
Parents: 26875db
Author: Jan Lehnardt <jan@apache.org>
Authored: Wed Jul 31 18:49:32 2013 +0200
Committer: Jan Lehnardt <jan@apache.org>
Committed: Thu Oct 3 16:04:51 2013 +0200

----------------------------------------------------------------------
 share/www/_sidebar.html |  1 +
 share/www/plugins.html  | 82 ++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 83 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb/blob/4f8a2b4a/share/www/_sidebar.html
----------------------------------------------------------------------
diff --git a/share/www/_sidebar.html b/share/www/_sidebar.html
index e68bf73..26a1bc8 100644
--- a/share/www/_sidebar.html
+++ b/share/www/_sidebar.html
@@ -23,6 +23,7 @@ specific language governing permissions and limitations under the License.
       <li><a href="config.html">Configuration</a></li>
       <li><a href="replicator.html">Replicator</a></li>
       <li><a href="status.html">Status</a></li>
+      <li><a href="plugins.html">Plugins</a></li>
     </ul></li>
     <li><span>Documentation</span><ul>
       <li><a href="docs/">Manual</a></li>

http://git-wip-us.apache.org/repos/asf/couchdb/blob/4f8a2b4a/share/www/plugins.html
----------------------------------------------------------------------
diff --git a/share/www/plugins.html b/share/www/plugins.html
new file mode 100644
index 0000000..a99826c
--- /dev/null
+++ b/share/www/plugins.html
@@ -0,0 +1,82 @@
+<!DOCTYPE html>
+<!--
+
+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.
+
+-->
+<html lang="en">
+  <head>
+    <title>Plugins</title>
+    <meta http-equiv="Content-Type" content="text/html;charset=utf-8">
+    <link rel="stylesheet" href="style/layout.css?0.11.0" type="text/css">
+    <script src="script/json2.js"></script>
+    <script src="script/sha1.js"></script>
+    <script src="script/jquery.js"></script>
+    <script src="script/jquery.couch.js"></script>
+    <script src="script/jquery.dialog.js"></script>
+    <script src="script/futon.js"></script>
+  </head>
+  <body><div id="wrap">
+    <h1>
+      <a href="index.html">Overview</a>
+      <strong>Plugins</strong>
+    </h1>
+    <div id="content">
+      <div class="row">
+        <h2>GeoCouch</h2>
+        <p>Version: <strong>couchdb1.2.x_v0.3.0-11-gd83ba22</strong></p>
+        <p>
+          Available Erlang Versions:
+          <ul>
+            <li>R15B01</li>
+          </ul>
+        </p>
+        <p>
+          <button href="#" id="install_plugin" data-url="http://people.apache.org/~jan"
data-checksums='{"R15B03":"mw7RWJtbt7WMOF/ypwpgkRHT0Wo="}' data-name="geocouch" data-version="couchdb1.2.x_v0.3.0-12-g4ea0bea">Install
GeoCouch Now</button>
+        </p>
+      </div>
+
+    </div>
+  </div></body>
+  <script>
+    $('#install_plugin').click(function(event) {
+      var button = $(this);
+      var plugin_spec = JSON.stringify({
+        name: button.data('name'),
+        url: button.data('url'),
+        version: button.data('version'),
+        checksums: button.data('checksums')
+      });
+      var url = '/_plugins'
+      $.ajax({
+        url: url,
+        type: 'POST',
+        data: plugin_spec,
+        contentType: 'application/json', // what we send to the server
+        dataType: 'json', // expected from the server
+        processData: false, // keep our precious JSON
+        success: function(data, textStatus, jqXhr) {
+          button.html(textStatus);
+        },
+        beforeSend: function(xhr) {
+          xhr.setRequestHeader('Accept', 'application/json');
+        },
+      });
+    });
+  </script>
+  <style type="text/css">
+  .row {
+    background-color: #EEE;
+    padding:1em;
+  }
+  </style>
+</html>


Mime
View raw message