1
0
Fork 0

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

This commit is contained in:
Willi Goesgens 2014-11-06 17:49:38 +01:00
commit 69d52670d5
7 changed files with 46 additions and 9 deletions

View File

@ -147,7 +147,8 @@
},
getDocuments: function (callback) {
window.progressView.show("Fetching documents...");
// window.progressView.show("Fetching documents...");
window.progressView.showWithDelay(3000, "Fetching documents...");
var self = this,
query,
bindVars,
@ -201,6 +202,7 @@
data: JSON.stringify(queryObj),
contentType: "application/json",
success: function(data) {
window.progressView.toShow = false;
self.clearDocuments();
if (data.extra && data.extra.fullCount !== undefined) {
self.setTotal(data.extra.fullCount);
@ -254,7 +256,7 @@
return queryObj;
},
updloadDocuments : function (file) {
uploadDocuments : function (file) {
var result;
$.ajax({
type: "POST",

View File

@ -22,12 +22,12 @@
</li>
<li class="enabled">
<a id="importCollection" class="headerButton">
<span class="icon_arangodb_import" title="Upload documents from JSON file"></span>
<span title="Upload documents from JSON file"><i class="fa fa-upload"></i></span>
</a>
</li>
<li class="enabled">
<a id="exportCollection" class="headerButton">
<span class="icon_arangodb_export" title="Download documents as JSON file"></span>
<span title="Download documents as JSON file"><i class="fa fa-download"></i></span>
</a>
</li>
<li class="enabled">

View File

@ -81,7 +81,7 @@
"keyup #createEdge" : "listenKey",
"click .key" : "nop",
"keyup" : "returnPressedHandler",
"keydown .filterValue" : "filterValueKeydown",
"keydown .queryline input" : "filterValueKeydown",
"click #importModal" : "showImportModal",
"click #resetView" : "resetView",
"click #confirmDocImport" : "startUpload",
@ -184,7 +184,7 @@
var result;
if (this.allowUpload === true) {
this.showSpinner();
result = this.collection.updloadDocuments(this.file);
result = this.collection.uploadDocuments(this.file);
if (result !== true) {
this.hideSpinner();
if (result.substr(0, 5 ) === "Error") {
@ -300,7 +300,7 @@
$('#importCollection').removeClass('activated');
$('#filterHeader').removeClass('activated');
$('#markDocuments').removeClass('activated'); this.changeEditMode(false);
$('#exportCollection').addClass('activated');
$('#exportCollection').toggleClass('activated');
this.markFilterToggle();
$('#exportHeader').slideToggle(200);
$('#importHeader').hide();

View File

@ -14,6 +14,8 @@
el2: "#progressPlaceholderIcon",
toShow: false,
action: function(){},
events: {
@ -27,6 +29,17 @@
initialize: function() {
},
showWithDelay: function(delay, msg, action, button) {
var self = this;
self.toShow = true;
setTimeout(function(delay) {
if (self.toShow === true) {
self.show(msg, action, button);
}
}, delay);
},
show: function(msg, action, button) {
$(this.el).html(this.template.render({}));
$(".progress-text").text(msg);

View File

@ -170,6 +170,20 @@ a.headerButton {
}
}
#exportCollection {
i {
margin-left: -3px !important;
}
}
#importCollection {
i {
margin-left: -3px !important;
position: relative;
top: -1px;
}
}
//Graph Viewer
div.toolbox {

View File

@ -64,7 +64,7 @@
background: $c-neutral;
border: 0;
color: $c-black;
height: 20px;
height: 21px;
position: relative;
width: 14px;
}

View File

@ -1760,6 +1760,14 @@ a.headerButton {
background-color: #fff;
color: #788f3d; }
#exportCollection i {
margin-left: -3px !important; }
#importCollection i {
margin-left: -3px !important;
position: relative;
top: -1px; }
div.toolbox {
-moz-border-radius: 2px;
-webkit-border-radius: 2px;
@ -5320,7 +5328,7 @@ pre.gv-object-view {
background: #8f8d8c;
border: 0;
color: #000;
height: 20px;
height: 21px;
position: relative;
width: 14px; }
.pagination-line li.disabled:last-child a,