1
0
Fork 0

Merge branch 'devel' of github.com:triAGENS/ArangoDB into devel

This commit is contained in:
Michael Hackstein 2013-08-07 13:58:55 +02:00
commit 4ec5fe71eb
12 changed files with 132 additions and 40 deletions

View File

@ -172,7 +172,7 @@ HttpHandler::status_e RestDocumentHandler::execute () {
/// @RESTHEADER{POST /_api/document,creates a document}
///
/// @RESTBODYPARAM{document,json,required}
/// A JSON representation of document.
/// A JSON representation of the document.
///
/// @RESTQUERYPARAMETERS
///
@ -839,6 +839,9 @@ bool RestDocumentHandler::checkDocument () {
///
/// @RESTHEADER{PUT /_api/document/`document-handle`,replaces a document}
///
/// @RESTBODYPARAM{document,json,required}
/// A JSON representation of the new document.
///
/// @RESTURLPARAMETERS
///
/// @RESTURLPARAM{document-handle,string,required}
@ -1054,6 +1057,9 @@ bool RestDocumentHandler::replaceDocument () {
///
/// @RESTHEADER{PATCH /_api/document/`document-handle`,patches a document}
///
/// @RESTBODYPARAM{document,json,required}
/// A JSON representation of the new document.
///
/// @RESTURLPARAMETERS
///
/// @RESTURLPARAM{document-handle,string,required}

View File

@ -1,6 +1,6 @@
.span3 {
min-height:100px;
width: 280px;
width: 230px;
margin-left: 8px !important;
margin-bottom: 8px !important;
border: 0px;
@ -20,7 +20,7 @@
white-space: nowrap !important;
overflow: hidden !important;
text-overflow: ellipsis !important;
width: 264px;
width: 214px;
color: #fff;
border: 0;
background:#676665;

View File

@ -22,8 +22,8 @@
.group-close, .group-open {
float:right;
margin-top: 17px !important;
margin-right: 7px !important;
margin-top: 18px !important;
margin-right: 25px !important;
}
.db-zoom, .db-minimize, .db-hide, .db-info, #detailReplicationMinimize{
@ -42,9 +42,10 @@
}
.statGroups {
margin-top: 10px !important;
margin-left: 0px;
float:left;
width: 100%;
width: 100% !important;
margin-bottom: -15px !important;
}
@ -61,21 +62,20 @@
.statSingleClient {
height: 300px;
width: 99.7%;
width: 100% !important;
margin-top: 10px;
margin-left: 10px !important;
margin-right: 11px;
margin-right: 11px !important;
margin-bottom: 0px !important;
border: 1px solid black;
background-color: #F4F3F3;
}
.statClient {
float: left;
height: 70px;
width: 203px;
margin-left: 9px;
margin-bottom: 12px;
width: 230px;
margin-left: 8px !important;
margin-bottom: 4px !important;
border: 1px solid black;
background-color: #F4F3F3;
}
@ -106,8 +106,7 @@
margin-top: 0 !important;
padding-top: 0 !important;
height: 140px;
/*width: 255px;*/
width: 272px;
width: 300px;
}
.svgDetailClass {
@ -136,16 +135,23 @@
margin-bottom: -15px !important;
}
.statsHeader {
#statsHeaderDiv {
margin-bottom: 16px;
margin-top: 12px;
margin-left: 10px;
margin-right: 10px;
width: 100%;
background-color: #686766;
margin-right: 20px !important;
margin-left: 8px !important;
padding: 0 !important;
height: 24px !important;
width: auto !important;
color: white;
height: 36px;
}
.statsHeader {
width: 100%;
background-color: #686766 !important;
}
#dashboardHeader {
background-color: #686766;
border-bottom: 1px solid #A0A0A0;
@ -278,6 +284,7 @@
#detailReplicationDiv {
padding-top: 26px;
padding-right: 20px;
}
#detailReplicationDiv table {
@ -319,9 +326,15 @@
#leftReplicationDiv table, #rightReplicationDiv table {
width: 100%;
padding-right: 10px !important;
}
#leftReplicationDiv table tr, #rightReplicationDiv table tr{
#leftReplicationDiv table td, #rightReplicationDiv table td {
padding-top: 4px;
padding-bottom: 5px;
}
#leftReplicationDiv table tr, #rightReplicationDiv table tr {
background-color: #F9F9F9 !important;
padding-top: 3px;
padding-bottom: 3px;
@ -335,11 +348,12 @@
width: 100%;
min-height: 150px;
margin-bottom: 8px;
margin-right: 10px;
margin-top: -20px;
}
.alignLeft {
width: 200px !important;
width: 240px !important;
text-align:left !important;
padding-left: 7px;
}
@ -405,7 +419,11 @@
}
#detailReplication {
background-color: #D9D5D1 !important;
margin-right: 20px;
background-color: transparent !important;
border: 0 !important;
}
#detailGraphPadding {
padding-right: 33px !important;
}

View File

@ -11,12 +11,19 @@
}
.foxxDescription {
width:170px;
margin-top: -15px;
width:140px;
height: 90px;
float: left;
text-align: left;
word-wrap: break-word;
}
#availableList .foxxDescription {
margin-top: 8px !important;
height: 60px !important;
}
.foxxIcon {
width:64px;
height:64px;

View File

@ -242,7 +242,10 @@ table .sorting {
}
.marginRight10 {
padding-right: 33px !important;
padding-left: 10px !important;
padding-top: 10px !important;
padding-bottom: 10px !important;
padding-right: 0px !important;
}
.form-actions {

View File

@ -8,7 +8,7 @@
<meta name="description" content="ArangoDB Admin Web Interface">
<meta name="author" content="Heiko Kernbach">
<link href='http://fonts.googleapis.com/css?family=Lato:300,400,700' rel='stylesheet' type='text/css'>
<!-- NO EXTERNAL LINKS link href='http://fonts.googleapis.com/css?family=Lato:300,400,700' rel='stylesheet' type='text/css' -->
<link href='css/droidsans.css' rel='stylesheet' type='text/css'/>
<link href='css/swagger/hightlight.default.css' media='screen' rel='stylesheet' type='text/css'/>

View File

@ -127,6 +127,7 @@
<h4 class="">Detail Chart</h4>
</li>
<div id="detailGraphPadding">
<li id="detailGraph" class="statSingleClient">
<div class="boxHeader">
<h6 id="detailGraphHeader" class="dashboardH6">User Time</h6>
@ -135,5 +136,6 @@
<svg class="svgDetailClass"/>
</div>
</li>
</div>
</ul>

View File

@ -211,7 +211,7 @@ var dashboardView = Backbone.View.extend({
$('.thumbnails').append(
'<ul class="statGroups" id="' + this.group + '">' +
'<i class="group-close icon-minus icon-white"></i>' +
'<h4 class="statsHeader">' + this.name + '</h4>' +
'<div id="statsHeaderDiv"><h4 class="statsHeader">' + this.name + '</h4></div>' +
'</ul>');
//group

View File

@ -24,7 +24,9 @@ var navigationView = Backbone.View.extend({
//padding row 40px
var containerWidth = $(window).width() - 70;
//var spanWidth = $('.span3').outerWidth(true);
var spanWidth = 292;
var test = $('.span3').outerWidth(true);
console.log(test);
var spanWidth = 242;
var divider = containerWidth / spanWidth;
var roundDiv = parseInt(divider, 10);

View File

@ -88,7 +88,7 @@ exports.Foxxes = function () {
// Define the functionality to display all foxxes
this.viewAll = function () {
return aal.toArray();
return aal.toArray().concat(foxxmanager.developmentMounts());
};
// Define the functionality to update one foxx.

View File

@ -66,17 +66,27 @@ exports.Swagger = function () {
this.listOne = function(basePath, key) {
var result = {},
res = _aal.document(key);
res;
if (key.substr(0, 4) === "dev:") {
res = "/dev/" + key.split(":")[2];
}
else {
res = _aal.document(key).mount;
}
result.swaggerVersion = "1.1";
result.basePath = basePath;
result.apis = [
{path: res.mount}
{path: res}
];
return result;
},
// Get details of one specific installed foxx.
this.show = function(appname) {
this.show = function(mount) {
var result = {},
apis = [],
pathes,
@ -85,25 +95,22 @@ exports.Swagger = function () {
url,
api,
ops,
foxxApp = _aal.firstExample({"mount": appname}),
app,
list;
if (!foxxApp.development) {
list = foxx_manager.appRoutes();
} else {
list = foxx_manager.developmentRoutes();
}
list = foxx_manager.appRoutes().concat(foxx_manager.developmentRoutes());
_.each(list, function(r) {
var ac = r.appContext;
if (ac.appId === foxxApp.app && ac.mount === foxxApp.mount) {
if (ac.mount === mount) {
app = r;
return;
}
});
result.swaggerVersion = "1.1";
result.basePath = app.urlPrefix;
result.apis = apis;
pathes = app.routes;
for (i in pathes) {
if (pathes[i].url.methods !== undefined) {
url = pathes[i].url.match;
@ -116,6 +123,7 @@ exports.Swagger = function () {
apis.push(api);
}
}
return result;
}
};

View File

@ -37,6 +37,16 @@ var executeGlobalContextFunction = require("internal").executeGlobalContextFunct
var checkParameter = arangodb.checkParameter;
var transformScript = require("org/arangodb/foxx/transformer").transform;
// -----------------------------------------------------------------------------
// --SECTION-- private variables
// -----------------------------------------------------------------------------
////////////////////////////////////////////////////////////////////////////////
/// @brief development mounts
////////////////////////////////////////////////////////////////////////////////
var DEVELOPMENTMOUNTS = null;
// -----------------------------------------------------------------------------
// --SECTION-- private functions
// -----------------------------------------------------------------------------
@ -1013,6 +1023,7 @@ exports.appRoutes = function () {
exports.developmentRoutes = function () {
'use strict';
var mounts = [];
var routes = [];
var root = module.devAppPath();
@ -1029,7 +1040,7 @@ exports.developmentRoutes = function () {
var appId = "dev:" + mf.name + ":" + files[j];
var mount = "/dev/" + files[j];
var options = {
prefix : prefixFromMount(mount) || undefined
prefix : prefixFromMount(mount)
};
var app = module.createApp(appId, options);
@ -1050,6 +1061,23 @@ exports.developmentRoutes = function () {
routes.push(r);
console.log("Mounted dev app '%s' on '%s'", appId, mount);
var desc = {
_id: "dev/" + app._id,
_key: app._id,
type: "mount",
app: app._id,
name: app._name,
description: app._manifest.description,
author: app._manifest.author,
mount: mount,
active: true,
collectionPrefix: options.prefix,
isSystem: app._manifest.isSystem || false,
options: options
};
mounts.push(desc);
}
catch (err) {
console.error("Cannot read app manifest '%s': %s", m, String(err.stack || err));
@ -1057,9 +1085,27 @@ exports.developmentRoutes = function () {
}
}
DEVELOPMENTMOUNTS = mounts;
return routes;
};
////////////////////////////////////////////////////////////////////////////////
/// @brief returns the development mounts
///
/// Must be called after developmentRoutes.
////////////////////////////////////////////////////////////////////////////////
exports.developmentMounts = function () {
'use strict';
if (DEVELOPMENTMOUNTS === null) {
exports.developmentRoutes();
}
return DEVELOPMENTMOUNTS;
};
// -----------------------------------------------------------------------------
// --SECTION-- END-OF-FILE
// -----------------------------------------------------------------------------