mirror of https://gitee.com/bigwinds/arangodb
Merge branch 'devel' of https://github.com/arangodb/arangodb into devel
This commit is contained in:
commit
360a24f65d
|
@ -103,13 +103,28 @@ endif()
|
||||||
# TODO: Exclude non-supported?
|
# TODO: Exclude non-supported?
|
||||||
|
|
||||||
## Compiler flags --------------------------------------------------------------
|
## Compiler flags --------------------------------------------------------------
|
||||||
|
|
||||||
|
# Build types
|
||||||
|
string(TOLOWER ${CMAKE_BUILD_TYPE} CMAKE_BUILD_TYPE_TL)
|
||||||
|
message (${CMAKE_BUILD_TYPE_TL})
|
||||||
|
if(CMAKE_BUILD_TYPE_TL MATCHES debug)
|
||||||
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O0 -g")
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O0 -g")
|
||||||
|
elseif(CMAKE_BUILD_TYPE_TL MATCHES relwithdebinfo)
|
||||||
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O2 -g")
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O2 -g")
|
||||||
|
elseif(CMAKE_BUILD_TYPE_TL MATCHES release)
|
||||||
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O3")
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3")
|
||||||
|
endif()
|
||||||
|
|
||||||
# GCC
|
# GCC
|
||||||
if (CMAKE_COMPILER_IS_GNUCC)
|
if (CMAKE_COMPILER_IS_GNUCC)
|
||||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu89 -g -O2")
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu89")
|
||||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -g -O2")
|
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS}")
|
||||||
endif ()
|
endif ()
|
||||||
if (CMAKE_COMPILER_IS_GNUCXX)
|
if (CMAKE_COMPILER_IS_GNUCXX)
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -g -O2")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||||
|
@ -122,7 +137,7 @@ endif()
|
||||||
|
|
||||||
# OSX
|
# OSX
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O2 -std=c++11")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
|
||||||
if (CMAKE_COMPILER_IS_CLANG)
|
if (CMAKE_COMPILER_IS_CLANG)
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
|
||||||
add_definitions("-Wno-deprecated-declarations")
|
add_definitions("-Wno-deprecated-declarations")
|
||||||
|
@ -198,13 +213,6 @@ if (USE_MAINTAINER_MODE)
|
||||||
add_definitions("-DTRI_ENABLE_MAINTAINER_MODE=1")
|
add_definitions("-DTRI_ENABLE_MAINTAINER_MODE=1")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Maintainer mode (Failure Tests) ----------------------------------------------
|
|
||||||
option(USE_FAILURE_TESTS
|
|
||||||
"whether we want to have failure tests compiled in" OFF)
|
|
||||||
if (USE_FAILURE_TESTS)
|
|
||||||
add_definitions("-DTRI_ENABLE_FAILURE_TESTS=1")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# Enable relative paths to binaries --------------------------------------------
|
# Enable relative paths to binaries --------------------------------------------
|
||||||
option(USE_RELATIVE "Do you want to have all path are relative to the binary" OFF)
|
option(USE_RELATIVE "Do you want to have all path are relative to the binary" OFF)
|
||||||
|
|
||||||
|
@ -766,3 +774,4 @@ endif ()
|
||||||
|
|
||||||
# Finally: user cpack
|
# Finally: user cpack
|
||||||
include(CPack)
|
include(CPack)
|
||||||
|
|
||||||
|
|
|
@ -406,15 +406,15 @@
|
||||||
});
|
});
|
||||||
|
|
||||||
if (found) {
|
if (found) {
|
||||||
this.deleteAardvarkJob(aardvark.id);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
array.push({
|
array.push({
|
||||||
collection: aardvark.collection,
|
collection: aardvark.collection,
|
||||||
id: aardvark.id,
|
id: aardvark.id,
|
||||||
type: aardvark.type
|
type: aardvark.type
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
window.arangoHelper.deleteAardvarkJob(aardvark.id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
File diff suppressed because one or more lines are too long
Binary file not shown.
|
@ -2907,8 +2907,33 @@ div .tile, div .bigtile {
|
||||||
position: relative;
|
position: relative;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
z-index: 1; }
|
z-index: 1; }
|
||||||
|
div .tile progress[value], div .bigtile progress[value] {
|
||||||
|
color: #5bc0de; }
|
||||||
|
div .tile progress::-webkit-progress-bar-value, div .bigtile progress::-webkit-progress-bar-value {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress::-webkit-progress-value, div .bigtile progress::-webkit-progress-value {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress::-moz-progress-bar, div .bigtile progress::-moz-progress-bar {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress, div .bigtile progress {
|
||||||
|
-webkit-appearance: none;
|
||||||
|
border-radius: 0;
|
||||||
|
height: 2px;
|
||||||
|
margin-top: 16px;
|
||||||
|
position: relative;
|
||||||
|
width: 100%;
|
||||||
|
z-index: 10; }
|
||||||
div .tile:hover, div .bigtile:hover {
|
div .tile:hover, div .bigtile:hover {
|
||||||
cursor: pointer; }
|
cursor: pointer; }
|
||||||
|
div .locked.tile, div .locked.bigtile {
|
||||||
|
cursor: not-allowed;
|
||||||
|
opacity: .5; }
|
||||||
|
div .locked.tile .iconSet span:hover, div .locked.bigtile .iconSet span:hover {
|
||||||
|
background-color: #fff !important;
|
||||||
|
color: #000;
|
||||||
|
cursor: not-allowed !important; }
|
||||||
|
div .locked.tile .iconSet:hover, div .locked.bigtile .iconSet:hover {
|
||||||
|
cursor: not-allowed !important; }
|
||||||
div .tile .warning-icons, div .bigtile .warning-icons {
|
div .tile .warning-icons, div .bigtile .warning-icons {
|
||||||
background-color: #da4f49;
|
background-color: #da4f49;
|
||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
|
@ -2980,6 +3005,8 @@ div .tile, div .bigtile {
|
||||||
padding: 4px 8px;
|
padding: 4px 8px;
|
||||||
text-overflow: ellipsis !important;
|
text-overflow: ellipsis !important;
|
||||||
white-space: nowrap !important; }
|
white-space: nowrap !important; }
|
||||||
|
div .tile h5.inProgress, div .bigtile h5.inProgress {
|
||||||
|
color: #5bc0de; }
|
||||||
div .tile .tileSelects, div .bigtile .tileSelects {
|
div .tile .tileSelects, div .bigtile .tileSelects {
|
||||||
margin-left: 40px;
|
margin-left: 40px;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
@ -5498,7 +5525,7 @@ div.headerBar {
|
||||||
z-index: 9999999; }
|
z-index: 9999999; }
|
||||||
|
|
||||||
.modal-tabbar {
|
.modal-tabbar {
|
||||||
border-bottom: 1px solid #000; }
|
border-bottom: 1px solid #666; }
|
||||||
|
|
||||||
.modal-body {
|
.modal-body {
|
||||||
color: #736b68;
|
color: #736b68;
|
||||||
|
@ -5923,8 +5950,33 @@ div .tile, div .bigtile {
|
||||||
position: relative;
|
position: relative;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
z-index: 1; }
|
z-index: 1; }
|
||||||
|
div .tile progress[value], div .bigtile progress[value] {
|
||||||
|
color: #5bc0de; }
|
||||||
|
div .tile progress::-webkit-progress-bar-value, div .bigtile progress::-webkit-progress-bar-value {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress::-webkit-progress-value, div .bigtile progress::-webkit-progress-value {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress::-moz-progress-bar, div .bigtile progress::-moz-progress-bar {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress, div .bigtile progress {
|
||||||
|
-webkit-appearance: none;
|
||||||
|
border-radius: 0;
|
||||||
|
height: 2px;
|
||||||
|
margin-top: 16px;
|
||||||
|
position: relative;
|
||||||
|
width: 100%;
|
||||||
|
z-index: 10; }
|
||||||
div .tile:hover, div .bigtile:hover {
|
div .tile:hover, div .bigtile:hover {
|
||||||
cursor: pointer; }
|
cursor: pointer; }
|
||||||
|
div .locked.tile, div .locked.bigtile {
|
||||||
|
cursor: not-allowed;
|
||||||
|
opacity: .5; }
|
||||||
|
div .locked.tile .iconSet span:hover, div .locked.bigtile .iconSet span:hover {
|
||||||
|
background-color: #fff !important;
|
||||||
|
color: #000;
|
||||||
|
cursor: not-allowed !important; }
|
||||||
|
div .locked.tile .iconSet:hover, div .locked.bigtile .iconSet:hover {
|
||||||
|
cursor: not-allowed !important; }
|
||||||
div .tile .warning-icons, div .bigtile .warning-icons {
|
div .tile .warning-icons, div .bigtile .warning-icons {
|
||||||
background-color: #da4f49;
|
background-color: #da4f49;
|
||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
|
@ -5996,6 +6048,8 @@ div .tile, div .bigtile {
|
||||||
padding: 4px 8px;
|
padding: 4px 8px;
|
||||||
text-overflow: ellipsis !important;
|
text-overflow: ellipsis !important;
|
||||||
white-space: nowrap !important; }
|
white-space: nowrap !important; }
|
||||||
|
div .tile h5.inProgress, div .bigtile h5.inProgress {
|
||||||
|
color: #5bc0de; }
|
||||||
div .tile .tileSelects, div .bigtile .tileSelects {
|
div .tile .tileSelects, div .bigtile .tileSelects {
|
||||||
margin-left: 40px;
|
margin-left: 40px;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
Binary file not shown.
|
@ -10756,15 +10756,15 @@ function GraphViewer(svg, width, height, adapterConfig, config) {
|
||||||
});
|
});
|
||||||
|
|
||||||
if (found) {
|
if (found) {
|
||||||
this.deleteAardvarkJob(aardvark.id);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
array.push({
|
array.push({
|
||||||
collection: aardvark.collection,
|
collection: aardvark.collection,
|
||||||
id: aardvark.id,
|
id: aardvark.id,
|
||||||
type: aardvark.type
|
type: aardvark.type
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
window.arangoHelper.deleteAardvarkJob(aardvark.id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -16435,7 +16435,8 @@ var __fs__=require("fs");var __rcf__=__fs__.join(__fs__.home(),".arangosh.rc");i
|
||||||
status: "",
|
status: "",
|
||||||
type: "",
|
type: "",
|
||||||
isSystem: false,
|
isSystem: false,
|
||||||
picture: ""
|
picture: "",
|
||||||
|
locked: false
|
||||||
},
|
},
|
||||||
|
|
||||||
getProperties: function () {
|
getProperties: function () {
|
||||||
|
@ -16553,14 +16554,14 @@ var __fs__=require("fs");var __rcf__=__fs__.join(__fs__.home(),".arangosh.rc");i
|
||||||
cache: false,
|
cache: false,
|
||||||
type: 'DELETE',
|
type: 'DELETE',
|
||||||
url: "/_api/index/"+ this.get("name") +"/"+encodeURIComponent(id),
|
url: "/_api/index/"+ this.get("name") +"/"+encodeURIComponent(id),
|
||||||
async: false,
|
async: true,
|
||||||
success: function () {
|
success: function () {
|
||||||
callback(false);
|
callback(false);
|
||||||
},
|
},
|
||||||
error: function (data) {
|
error: function (data) {
|
||||||
callback(true, data);
|
callback(true, data);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
callback();
|
callback();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -19530,19 +19531,29 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
},
|
},
|
||||||
|
|
||||||
render: function () {
|
render: function () {
|
||||||
|
if (this.model.get("locked")) {
|
||||||
|
$(this.el).addClass('locked');
|
||||||
|
}
|
||||||
$(this.el).html(this.template.render({
|
$(this.el).html(this.template.render({
|
||||||
model: this.model
|
model: this.model
|
||||||
}));
|
}));
|
||||||
$(this.el).attr('id', 'collection_' + this.model.get('name'));
|
$(this.el).attr('id', 'collection_' + this.model.get('name'));
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
editProperties: function (event) {
|
editProperties: function (event) {
|
||||||
|
if (this.model.get("locked")) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
this.createEditPropertiesModal();
|
this.createEditPropertiesModal();
|
||||||
},
|
},
|
||||||
|
|
||||||
showProperties: function(event) {
|
showProperties: function(event) {
|
||||||
|
if (this.model.get("locked")) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
this.createInfoModal();
|
this.createInfoModal();
|
||||||
},
|
},
|
||||||
|
@ -19553,6 +19564,9 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
if ($(event.target).hasClass("disabled")) {
|
if ($(event.target).hasClass("disabled")) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
if (this.model.get("locked")) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
window.App.navigate(
|
window.App.navigate(
|
||||||
"collection/" + encodeURIComponent(this.model.get("name")) + "/documents/1", {trigger: true}
|
"collection/" + encodeURIComponent(this.model.get("name")) + "/documents/1", {trigger: true}
|
||||||
|
@ -19863,7 +19877,12 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
this.events, null,
|
this.events, null,
|
||||||
tabBar
|
tabBar
|
||||||
);
|
);
|
||||||
this.getIndex();
|
if (this.model.get("status") === 'loaded') {
|
||||||
|
this.getIndex();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$($('#infoTab').children()[1]).remove();
|
||||||
|
}
|
||||||
this.bindIndexEvents();
|
this.bindIndexEvents();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -19895,6 +19914,7 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
});
|
});
|
||||||
|
|
||||||
$('#infoTab a').bind('click', function(e) {
|
$('#infoTab a').bind('click', function(e) {
|
||||||
|
$('#indexDeleteModal').remove();
|
||||||
if ($(e.currentTarget).html() === 'Indices' && !$(e.currentTarget).parent().hasClass('active')) {
|
if ($(e.currentTarget).html() === 'Indices' && !$(e.currentTarget).parent().hasClass('active')) {
|
||||||
|
|
||||||
$('#newIndexView').hide();
|
$('#newIndexView').hide();
|
||||||
|
@ -20019,7 +20039,6 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
var callback = function(error, msg){
|
var callback = function(error, msg){
|
||||||
|
|
||||||
if (error) {
|
if (error) {
|
||||||
if (msg) {
|
if (msg) {
|
||||||
var message = JSON.parse(msg.responseText);
|
var message = JSON.parse(msg.responseText);
|
||||||
|
@ -20032,10 +20051,15 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
};
|
};
|
||||||
|
|
||||||
window.modalView.hide();
|
window.modalView.hide();
|
||||||
this.getIndex();
|
//this.getIndex();
|
||||||
this.createEditPropertiesModal();
|
//this.createEditPropertiesModal();
|
||||||
$($('#infoTab').children()[1]).find('a').click();
|
//$($('#infoTab').children()[1]).find('a').click();
|
||||||
self.model.createIndex(postParameter, callback);
|
self.model.createIndex(postParameter, callback);
|
||||||
|
window.App.arangoCollectionsStore.fetch({
|
||||||
|
success: function () {
|
||||||
|
self.collectionsView.render();
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
lastTarget: null,
|
lastTarget: null,
|
||||||
|
@ -20051,27 +20075,47 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
children().
|
children().
|
||||||
first().
|
first().
|
||||||
text();
|
text();
|
||||||
window.modalView.hide();
|
//window.modalView.hide();
|
||||||
|
|
||||||
//delete modal
|
//delete modal
|
||||||
$("#indexDeleteModal").modal('show');
|
$("#modal-dialog .modal-footer").after(
|
||||||
$('#confirmDeleteIndexBtn').unbind('click');
|
'<div id="indexDeleteModal" style="display:block;" class="alert alert-error modal-delete-confirmation">' +
|
||||||
$('#confirmDeleteIndexBtn').bind('click', function() {
|
'<strong>Really delete?</strong>' +
|
||||||
|
'<button id="indexConfirmDelete" class="button-danger pull-right modal-confirm-delete">Yes</button>' +
|
||||||
|
'<button id="indexAbortDelete" class="button-neutral pull-right">No</button>' +
|
||||||
|
'</div>');
|
||||||
|
$('#indexConfirmDelete').unbind('click');
|
||||||
|
$('#indexConfirmDelete').bind('click', function() {
|
||||||
|
$('#indexDeleteModal').remove();
|
||||||
self.deleteIndex();
|
self.deleteIndex();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
$('#indexAbortDelete').unbind('click');
|
||||||
|
$('#indexAbortDelete').bind('click', function() {
|
||||||
|
$('#indexDeleteModal').remove();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
deleteIndex: function () {
|
deleteIndex: function () {
|
||||||
var callback = function(error) {
|
var callback = function(error) {
|
||||||
if (error) {
|
if (error) {
|
||||||
arangoHelper.arangoError("Could not delete index");
|
arangoHelper.arangoError("Could not delete index");
|
||||||
|
$("tr th:contains('"+ this.lastId+"')").parent().children().last().html(
|
||||||
|
'<span class="deleteIndex icon_arangodb_roundminus"' +
|
||||||
|
' data-original-title="Delete index" title="Delete index"></span>'
|
||||||
|
);
|
||||||
}
|
}
|
||||||
};
|
else {
|
||||||
|
$("tr th:contains('"+ this.lastId+"')").parent().remove();
|
||||||
|
}
|
||||||
|
}.bind(this);
|
||||||
|
|
||||||
$("#indexDeleteModal").modal('hide');
|
|
||||||
this.model.deleteIndex(this.lastId, callback);
|
this.model.deleteIndex(this.lastId, callback);
|
||||||
this.createEditPropertiesModal();
|
$("tr th:contains('"+ this.lastId+"')").parent().children().last().html(
|
||||||
$($('#infoTab').children()[1]).find('a').click();
|
'<i class="fa fa-circle-o-notch fa-spin"></i>'
|
||||||
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
selectIndexType: function () {
|
selectIndexType: function () {
|
||||||
|
@ -20138,7 +20182,6 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
console.log("toggle else");
|
|
||||||
$('#indexEditView').show();
|
$('#indexEditView').show();
|
||||||
$('#newIndexView').hide();
|
$('#newIndexView').hide();
|
||||||
$('#addIndex').detach().appendTo('#modal-dialog .modal-footer');
|
$('#addIndex').detach().appendTo('#modal-dialog .modal-footer');
|
||||||
|
@ -20179,13 +20222,51 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
el2: '#collectionsThumbnailsIn',
|
el2: '#collectionsThumbnailsIn',
|
||||||
|
|
||||||
searchTimeout: null,
|
searchTimeout: null,
|
||||||
|
refreshRate: 2000,
|
||||||
|
|
||||||
template: templateEngine.createTemplate("collectionsView.ejs"),
|
template: templateEngine.createTemplate("collectionsView.ejs"),
|
||||||
|
|
||||||
|
checkLockedCollections: function() {
|
||||||
|
|
||||||
|
var self = this,
|
||||||
|
lockedCollections = window.arangoHelper.syncAndReturnUninishedAardvarkJobs('index');
|
||||||
|
|
||||||
|
this.collection.each(function(model) {
|
||||||
|
model.set('locked', false);
|
||||||
|
});
|
||||||
|
|
||||||
|
_.each(lockedCollections, function(locked) {
|
||||||
|
var model = self.collection.findWhere({
|
||||||
|
id: locked.collection
|
||||||
|
});
|
||||||
|
model.set('locked', true);
|
||||||
|
model.set('lockType', locked.type);
|
||||||
|
});
|
||||||
|
|
||||||
|
this.collection.each(function(model) {
|
||||||
|
if (model.get("locked")) {
|
||||||
|
$('#collection_' + model.get("name")).addClass('locked');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$('#collection_' + model.get("name")).removeClass('locked');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
initialize: function() {
|
||||||
|
var self = this;
|
||||||
|
|
||||||
|
window.setInterval(function() {
|
||||||
|
self.checkLockedCollections();
|
||||||
|
}, self.refreshRate);
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
render: function () {
|
render: function () {
|
||||||
|
|
||||||
var dropdownVisible = false,
|
this.checkLockedCollections();
|
||||||
lockedCollections = window.arangoHelper.syncAndReturnUninishedAardvarkJobs('index');
|
var dropdownVisible = false;
|
||||||
|
|
||||||
if ($('#collectionsDropdown').is(':visible')) {
|
if ($('#collectionsDropdown').is(':visible')) {
|
||||||
dropdownVisible = true;
|
dropdownVisible = true;
|
||||||
|
@ -20231,6 +20312,7 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
|
|
||||||
arangoHelper.fixTooltips(".icon_arangodb, .arangoicon", "left");
|
arangoHelper.fixTooltips(".icon_arangodb, .arangoicon", "left");
|
||||||
|
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -20457,7 +20539,7 @@ window.ArangoUsers = Backbone.Collection.extend({
|
||||||
var returnobj = this.collection.newCollection(
|
var returnobj = this.collection.newCollection(
|
||||||
collName, wfs, isSystem, collSize, collType, shards, shardBy
|
collName, wfs, isSystem, collSize, collType, shards, shardBy
|
||||||
);
|
);
|
||||||
if (returnobj.status !== true) {console.log(returnobj);
|
if (returnobj.status !== true) {
|
||||||
arangoHelper.arangoError("Collection error", returnobj.errorMessage);
|
arangoHelper.arangoError("Collection error", returnobj.errorMessage);
|
||||||
}
|
}
|
||||||
this.updateCollectionsView();
|
this.updateCollectionsView();
|
||||||
|
|
Binary file not shown.
|
@ -264,7 +264,13 @@
|
||||||
</div>
|
</div>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<h5 class="collectionName"><%= model.get('name') %></h5></script><script id="collectionsView.ejs" type="text/template"><div class="headerBar">
|
|
||||||
|
<% if(model.get('lockType') === "index") { %>
|
||||||
|
<!-- <progress max="100" value="80"></progress>-->
|
||||||
|
<h5 class="collectionName"><%= model.get('name') %></h5>
|
||||||
|
<% } else { %>
|
||||||
|
<h5 class="collectionName"><%= model.get('name') %></h5>
|
||||||
|
<% } %></script><script id="collectionsView.ejs" type="text/template"><div class="headerBar">
|
||||||
<div class="search-field">
|
<div class="search-field">
|
||||||
<input type="text" id="searchInput" class="search-input" placeholder="Search..."/>
|
<input type="text" id="searchInput" class="search-input" placeholder="Search..."/>
|
||||||
<!-- <img id="searchSubmit" class="search-submit-icon"/> -->
|
<!-- <img id="searchSubmit" class="search-submit-icon"/> -->
|
||||||
|
@ -378,21 +384,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Delete Index Modal -->
|
|
||||||
<div id="indexDeleteModal" style="display:none" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
|
|
||||||
<div class="modal-header">
|
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
|
||||||
<a class="arangoHeader">Delete Index?</a>
|
|
||||||
</div>
|
|
||||||
<div class="modal-body" id="deleteIndex">
|
|
||||||
<p>There is no way back…</p>
|
|
||||||
</div>
|
|
||||||
<div class="modal-footer">
|
|
||||||
<button class="button-close" data-dismiss="modal" aria-hidden="true">Close</button>
|
|
||||||
<button id="confirmDeleteIndexBtn" class="button-danger" style="float:right">Delete</button>
|
|
||||||
</div>
|
|
||||||
</div></script><script id="dashboardView.ejs" type="text/template"><% var subBar = function(title) { %>
|
</div></script><script id="dashboardView.ejs" type="text/template"><% var subBar = function(title) { %>
|
||||||
<div class="dashboard-sub-bar">
|
<div class="dashboard-sub-bar">
|
||||||
<div class="dashboard-sub-bar-title"><%= title %></div>
|
<div class="dashboard-sub-bar-title"><%= title %></div>
|
||||||
|
|
Binary file not shown.
|
@ -300,7 +300,13 @@
|
||||||
</div>
|
</div>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<h5 class="collectionName"><%= model.get('name') %></h5>
|
|
||||||
|
<% if(model.get('lockType') === "index") { %>
|
||||||
|
<!-- <progress max="100" value="80"></progress>-->
|
||||||
|
<h5 class="collectionName"><%= model.get('name') %></h5>
|
||||||
|
<% } else { %>
|
||||||
|
<h5 class="collectionName"><%= model.get('name') %></h5>
|
||||||
|
<% } %>
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<script id="collectionsView.ejs" type="text/template">
|
<script id="collectionsView.ejs" type="text/template">
|
||||||
|
@ -420,21 +426,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- Delete Index Modal -->
|
|
||||||
<div id="indexDeleteModal" style="display:none" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
|
|
||||||
<div class="modal-header">
|
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
|
||||||
<a class="arangoHeader">Delete Index?</a>
|
|
||||||
</div>
|
|
||||||
<div class="modal-body" id="deleteIndex">
|
|
||||||
<p>There is no way back…</p>
|
|
||||||
</div>
|
|
||||||
<div class="modal-footer">
|
|
||||||
<button class="button-close" data-dismiss="modal" aria-hidden="true">Close</button>
|
|
||||||
<button id="confirmDeleteIndexBtn" class="button-danger" style="float:right">Delete</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<script id="dashboardView.ejs" type="text/template">
|
<script id="dashboardView.ejs" type="text/template">
|
||||||
|
|
File diff suppressed because one or more lines are too long
Binary file not shown.
|
@ -2897,8 +2897,33 @@ div .tile, div .bigtile {
|
||||||
position: relative;
|
position: relative;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
z-index: 1; }
|
z-index: 1; }
|
||||||
|
div .tile progress[value], div .bigtile progress[value] {
|
||||||
|
color: #5bc0de; }
|
||||||
|
div .tile progress::-webkit-progress-bar-value, div .bigtile progress::-webkit-progress-bar-value {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress::-webkit-progress-value, div .bigtile progress::-webkit-progress-value {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress::-moz-progress-bar, div .bigtile progress::-moz-progress-bar {
|
||||||
|
background: #5bc0de; }
|
||||||
|
div .tile progress, div .bigtile progress {
|
||||||
|
-webkit-appearance: none;
|
||||||
|
border-radius: 0;
|
||||||
|
height: 2px;
|
||||||
|
margin-top: 16px;
|
||||||
|
position: relative;
|
||||||
|
width: 100%;
|
||||||
|
z-index: 10; }
|
||||||
div .tile:hover, div .bigtile:hover {
|
div .tile:hover, div .bigtile:hover {
|
||||||
cursor: pointer; }
|
cursor: pointer; }
|
||||||
|
div .locked.tile, div .locked.bigtile {
|
||||||
|
cursor: not-allowed;
|
||||||
|
opacity: .5; }
|
||||||
|
div .locked.tile .iconSet span:hover, div .locked.bigtile .iconSet span:hover {
|
||||||
|
background-color: #fff !important;
|
||||||
|
color: #000;
|
||||||
|
cursor: not-allowed !important; }
|
||||||
|
div .locked.tile .iconSet:hover, div .locked.bigtile .iconSet:hover {
|
||||||
|
cursor: not-allowed !important; }
|
||||||
div .tile .warning-icons, div .bigtile .warning-icons {
|
div .tile .warning-icons, div .bigtile .warning-icons {
|
||||||
background-color: #da4f49;
|
background-color: #da4f49;
|
||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
|
@ -2970,6 +2995,8 @@ div .tile, div .bigtile {
|
||||||
padding: 4px 8px;
|
padding: 4px 8px;
|
||||||
text-overflow: ellipsis !important;
|
text-overflow: ellipsis !important;
|
||||||
white-space: nowrap !important; }
|
white-space: nowrap !important; }
|
||||||
|
div .tile h5.inProgress, div .bigtile h5.inProgress {
|
||||||
|
color: #5bc0de; }
|
||||||
div .tile .tileSelects, div .bigtile .tileSelects {
|
div .tile .tileSelects, div .bigtile .tileSelects {
|
||||||
margin-left: 40px;
|
margin-left: 40px;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
@ -5488,7 +5515,7 @@ div.headerBar {
|
||||||
z-index: 9999999; }
|
z-index: 9999999; }
|
||||||
|
|
||||||
.modal-tabbar {
|
.modal-tabbar {
|
||||||
border-bottom: 1px solid #000; }
|
border-bottom: 1px solid #666; }
|
||||||
|
|
||||||
.modal-body {
|
.modal-body {
|
||||||
color: #736b68;
|
color: #736b68;
|
||||||
|
@ -7292,6 +7319,10 @@ input.gv-radio-button {
|
||||||
#graphTab li,
|
#graphTab li,
|
||||||
#collectionTab li {
|
#collectionTab li {
|
||||||
float: right; }
|
float: right; }
|
||||||
|
#infoTab li.disabled a,
|
||||||
|
#graphTab li.disabled a,
|
||||||
|
#collectionTab li.disabled a {
|
||||||
|
cursor: not-allowed; }
|
||||||
|
|
||||||
#infoTab a,
|
#infoTab a,
|
||||||
#graphTab a,
|
#graphTab a,
|
||||||
|
@ -8034,8 +8065,7 @@ table .sorting {
|
||||||
margin-top: 20px; }
|
margin-top: 20px; }
|
||||||
|
|
||||||
.new-index-view input[type='checkbox'] {
|
.new-index-view input[type='checkbox'] {
|
||||||
float: left;
|
float: left; }
|
||||||
margin-top: -9px; }
|
|
||||||
|
|
||||||
.new-index-view table tr {
|
.new-index-view table tr {
|
||||||
width: 600px !important; }
|
width: 600px !important; }
|
||||||
|
@ -8071,7 +8101,14 @@ table .sorting {
|
||||||
border-bottom: 1px solid #e5e5e5; }
|
border-bottom: 1px solid #e5e5e5; }
|
||||||
|
|
||||||
.newIndexClass table {
|
.newIndexClass table {
|
||||||
|
border-top: 1px solid #f7f3f2;
|
||||||
margin-bottom: 60px; }
|
margin-bottom: 60px; }
|
||||||
|
.newIndexClass table select {
|
||||||
|
margin-right: 7px; }
|
||||||
|
.newIndexClass table .arangoicon {
|
||||||
|
float: right;
|
||||||
|
margin-right: -12px;
|
||||||
|
margin-top: 5px; }
|
||||||
|
|
||||||
.index-button-bar {
|
.index-button-bar {
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
|
|
Binary file not shown.
|
@ -406,15 +406,15 @@
|
||||||
});
|
});
|
||||||
|
|
||||||
if (found) {
|
if (found) {
|
||||||
this.deleteAardvarkJob(aardvark.id);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
array.push({
|
array.push({
|
||||||
collection: aardvark.collection,
|
collection: aardvark.collection,
|
||||||
id: aardvark.id,
|
id: aardvark.id,
|
||||||
type: aardvark.type
|
type: aardvark.type
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
window.arangoHelper.deleteAardvarkJob(aardvark.id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,7 +14,8 @@
|
||||||
status: "",
|
status: "",
|
||||||
type: "",
|
type: "",
|
||||||
isSystem: false,
|
isSystem: false,
|
||||||
picture: ""
|
picture: "",
|
||||||
|
locked: false
|
||||||
},
|
},
|
||||||
|
|
||||||
getProperties: function () {
|
getProperties: function () {
|
||||||
|
@ -132,14 +133,14 @@
|
||||||
cache: false,
|
cache: false,
|
||||||
type: 'DELETE',
|
type: 'DELETE',
|
||||||
url: "/_api/index/"+ this.get("name") +"/"+encodeURIComponent(id),
|
url: "/_api/index/"+ this.get("name") +"/"+encodeURIComponent(id),
|
||||||
async: false,
|
async: true,
|
||||||
success: function () {
|
success: function () {
|
||||||
callback(false);
|
callback(false);
|
||||||
},
|
},
|
||||||
error: function (data) {
|
error: function (data) {
|
||||||
callback(true, data);
|
callback(true, data);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
callback();
|
callback();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -18,5 +18,11 @@
|
||||||
</div>
|
</div>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<h5 class="collectionName"><%= model.get('name') %></h5>
|
|
||||||
|
<% if(model.get('lockType') === "index") { %>
|
||||||
|
<!-- <progress max="100" value="80"></progress>-->
|
||||||
|
<h5 class="collectionName"><%= model.get('name') %></h5>
|
||||||
|
<% } else { %>
|
||||||
|
<h5 class="collectionName"><%= model.get('name') %></h5>
|
||||||
|
<% } %>
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -115,19 +115,4 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- Delete Index Modal -->
|
|
||||||
<div id="indexDeleteModal" style="display:none" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
|
|
||||||
<div class="modal-header">
|
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
|
||||||
<a class="arangoHeader">Delete Index?</a>
|
|
||||||
</div>
|
|
||||||
<div class="modal-body" id="deleteIndex">
|
|
||||||
<p>There is no way back…</p>
|
|
||||||
</div>
|
|
||||||
<div class="modal-footer">
|
|
||||||
<button class="button-close" data-dismiss="modal" aria-hidden="true">Close</button>
|
|
||||||
<button id="confirmDeleteIndexBtn" class="button-danger" style="float:right">Delete</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -24,19 +24,29 @@
|
||||||
},
|
},
|
||||||
|
|
||||||
render: function () {
|
render: function () {
|
||||||
|
if (this.model.get("locked")) {
|
||||||
|
$(this.el).addClass('locked');
|
||||||
|
}
|
||||||
$(this.el).html(this.template.render({
|
$(this.el).html(this.template.render({
|
||||||
model: this.model
|
model: this.model
|
||||||
}));
|
}));
|
||||||
$(this.el).attr('id', 'collection_' + this.model.get('name'));
|
$(this.el).attr('id', 'collection_' + this.model.get('name'));
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
editProperties: function (event) {
|
editProperties: function (event) {
|
||||||
|
if (this.model.get("locked")) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
this.createEditPropertiesModal();
|
this.createEditPropertiesModal();
|
||||||
},
|
},
|
||||||
|
|
||||||
showProperties: function(event) {
|
showProperties: function(event) {
|
||||||
|
if (this.model.get("locked")) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
this.createInfoModal();
|
this.createInfoModal();
|
||||||
},
|
},
|
||||||
|
@ -47,6 +57,9 @@
|
||||||
if ($(event.target).hasClass("disabled")) {
|
if ($(event.target).hasClass("disabled")) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
if (this.model.get("locked")) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
window.App.navigate(
|
window.App.navigate(
|
||||||
"collection/" + encodeURIComponent(this.model.get("name")) + "/documents/1", {trigger: true}
|
"collection/" + encodeURIComponent(this.model.get("name")) + "/documents/1", {trigger: true}
|
||||||
|
@ -357,7 +370,12 @@
|
||||||
this.events, null,
|
this.events, null,
|
||||||
tabBar
|
tabBar
|
||||||
);
|
);
|
||||||
this.getIndex();
|
if (this.model.get("status") === 'loaded') {
|
||||||
|
this.getIndex();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$($('#infoTab').children()[1]).remove();
|
||||||
|
}
|
||||||
this.bindIndexEvents();
|
this.bindIndexEvents();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -389,6 +407,7 @@
|
||||||
});
|
});
|
||||||
|
|
||||||
$('#infoTab a').bind('click', function(e) {
|
$('#infoTab a').bind('click', function(e) {
|
||||||
|
$('#indexDeleteModal').remove();
|
||||||
if ($(e.currentTarget).html() === 'Indices' && !$(e.currentTarget).parent().hasClass('active')) {
|
if ($(e.currentTarget).html() === 'Indices' && !$(e.currentTarget).parent().hasClass('active')) {
|
||||||
|
|
||||||
$('#newIndexView').hide();
|
$('#newIndexView').hide();
|
||||||
|
@ -513,7 +532,6 @@
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
var callback = function(error, msg){
|
var callback = function(error, msg){
|
||||||
|
|
||||||
if (error) {
|
if (error) {
|
||||||
if (msg) {
|
if (msg) {
|
||||||
var message = JSON.parse(msg.responseText);
|
var message = JSON.parse(msg.responseText);
|
||||||
|
@ -526,10 +544,15 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
window.modalView.hide();
|
window.modalView.hide();
|
||||||
this.getIndex();
|
//this.getIndex();
|
||||||
this.createEditPropertiesModal();
|
//this.createEditPropertiesModal();
|
||||||
$($('#infoTab').children()[1]).find('a').click();
|
//$($('#infoTab').children()[1]).find('a').click();
|
||||||
self.model.createIndex(postParameter, callback);
|
self.model.createIndex(postParameter, callback);
|
||||||
|
window.App.arangoCollectionsStore.fetch({
|
||||||
|
success: function () {
|
||||||
|
self.collectionsView.render();
|
||||||
|
}
|
||||||
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
lastTarget: null,
|
lastTarget: null,
|
||||||
|
@ -545,27 +568,47 @@
|
||||||
children().
|
children().
|
||||||
first().
|
first().
|
||||||
text();
|
text();
|
||||||
window.modalView.hide();
|
//window.modalView.hide();
|
||||||
|
|
||||||
//delete modal
|
//delete modal
|
||||||
$("#indexDeleteModal").modal('show');
|
$("#modal-dialog .modal-footer").after(
|
||||||
$('#confirmDeleteIndexBtn').unbind('click');
|
'<div id="indexDeleteModal" style="display:block;" class="alert alert-error modal-delete-confirmation">' +
|
||||||
$('#confirmDeleteIndexBtn').bind('click', function() {
|
'<strong>Really delete?</strong>' +
|
||||||
|
'<button id="indexConfirmDelete" class="button-danger pull-right modal-confirm-delete">Yes</button>' +
|
||||||
|
'<button id="indexAbortDelete" class="button-neutral pull-right">No</button>' +
|
||||||
|
'</div>');
|
||||||
|
$('#indexConfirmDelete').unbind('click');
|
||||||
|
$('#indexConfirmDelete').bind('click', function() {
|
||||||
|
$('#indexDeleteModal').remove();
|
||||||
self.deleteIndex();
|
self.deleteIndex();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
$('#indexAbortDelete').unbind('click');
|
||||||
|
$('#indexAbortDelete').bind('click', function() {
|
||||||
|
$('#indexDeleteModal').remove();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
deleteIndex: function () {
|
deleteIndex: function () {
|
||||||
var callback = function(error) {
|
var callback = function(error) {
|
||||||
if (error) {
|
if (error) {
|
||||||
arangoHelper.arangoError("Could not delete index");
|
arangoHelper.arangoError("Could not delete index");
|
||||||
|
$("tr th:contains('"+ this.lastId+"')").parent().children().last().html(
|
||||||
|
'<span class="deleteIndex icon_arangodb_roundminus"' +
|
||||||
|
' data-original-title="Delete index" title="Delete index"></span>'
|
||||||
|
);
|
||||||
}
|
}
|
||||||
};
|
else {
|
||||||
|
$("tr th:contains('"+ this.lastId+"')").parent().remove();
|
||||||
|
}
|
||||||
|
}.bind(this);
|
||||||
|
|
||||||
$("#indexDeleteModal").modal('hide');
|
|
||||||
this.model.deleteIndex(this.lastId, callback);
|
this.model.deleteIndex(this.lastId, callback);
|
||||||
this.createEditPropertiesModal();
|
$("tr th:contains('"+ this.lastId+"')").parent().children().last().html(
|
||||||
$($('#infoTab').children()[1]).find('a').click();
|
'<i class="fa fa-circle-o-notch fa-spin"></i>'
|
||||||
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
selectIndexType: function () {
|
selectIndexType: function () {
|
||||||
|
@ -632,7 +675,6 @@
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
console.log("toggle else");
|
|
||||||
$('#indexEditView').show();
|
$('#indexEditView').show();
|
||||||
$('#newIndexView').hide();
|
$('#newIndexView').hide();
|
||||||
$('#addIndex').detach().appendTo('#modal-dialog .modal-footer');
|
$('#addIndex').detach().appendTo('#modal-dialog .modal-footer');
|
||||||
|
|
|
@ -9,13 +9,51 @@
|
||||||
el2: '#collectionsThumbnailsIn',
|
el2: '#collectionsThumbnailsIn',
|
||||||
|
|
||||||
searchTimeout: null,
|
searchTimeout: null,
|
||||||
|
refreshRate: 2000,
|
||||||
|
|
||||||
template: templateEngine.createTemplate("collectionsView.ejs"),
|
template: templateEngine.createTemplate("collectionsView.ejs"),
|
||||||
|
|
||||||
|
checkLockedCollections: function() {
|
||||||
|
|
||||||
|
var self = this,
|
||||||
|
lockedCollections = window.arangoHelper.syncAndReturnUninishedAardvarkJobs('index');
|
||||||
|
|
||||||
|
this.collection.each(function(model) {
|
||||||
|
model.set('locked', false);
|
||||||
|
});
|
||||||
|
|
||||||
|
_.each(lockedCollections, function(locked) {
|
||||||
|
var model = self.collection.findWhere({
|
||||||
|
id: locked.collection
|
||||||
|
});
|
||||||
|
model.set('locked', true);
|
||||||
|
model.set('lockType', locked.type);
|
||||||
|
});
|
||||||
|
|
||||||
|
this.collection.each(function(model) {
|
||||||
|
if (model.get("locked")) {
|
||||||
|
$('#collection_' + model.get("name")).addClass('locked');
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$('#collection_' + model.get("name")).removeClass('locked');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
initialize: function() {
|
||||||
|
var self = this;
|
||||||
|
|
||||||
|
window.setInterval(function() {
|
||||||
|
self.checkLockedCollections();
|
||||||
|
}, self.refreshRate);
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
render: function () {
|
render: function () {
|
||||||
|
|
||||||
var dropdownVisible = false,
|
this.checkLockedCollections();
|
||||||
lockedCollections = window.arangoHelper.syncAndReturnUninishedAardvarkJobs('index');
|
var dropdownVisible = false;
|
||||||
|
|
||||||
if ($('#collectionsDropdown').is(':visible')) {
|
if ($('#collectionsDropdown').is(':visible')) {
|
||||||
dropdownVisible = true;
|
dropdownVisible = true;
|
||||||
|
@ -61,6 +99,7 @@
|
||||||
|
|
||||||
arangoHelper.fixTooltips(".icon_arangodb, .arangoicon", "left");
|
arangoHelper.fixTooltips(".icon_arangodb, .arangoicon", "left");
|
||||||
|
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -287,7 +326,7 @@
|
||||||
var returnobj = this.collection.newCollection(
|
var returnobj = this.collection.newCollection(
|
||||||
collName, wfs, isSystem, collSize, collType, shards, shardBy
|
collName, wfs, isSystem, collSize, collType, shards, shardBy
|
||||||
);
|
);
|
||||||
if (returnobj.status !== true) {console.log(returnobj);
|
if (returnobj.status !== true) {
|
||||||
arangoHelper.arangoError("Collection error", returnobj.errorMessage);
|
arangoHelper.arangoError("Collection error", returnobj.errorMessage);
|
||||||
}
|
}
|
||||||
this.updateCollectionsView();
|
this.updateCollectionsView();
|
||||||
|
|
|
@ -117,12 +117,19 @@
|
||||||
margin-bottom: 1px;
|
margin-bottom: 1px;
|
||||||
padding-bottom: 0;
|
padding-bottom: 0;
|
||||||
padding-right: 10px;
|
padding-right: 10px;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#infoTab li,
|
#infoTab li,
|
||||||
#graphTab li,
|
#graphTab li,
|
||||||
#collectionTab li {
|
#collectionTab li {
|
||||||
float: right;
|
float: right;
|
||||||
|
|
||||||
|
&.disabled {
|
||||||
|
a {
|
||||||
|
cursor: not-allowed;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#infoTab a,
|
#infoTab a,
|
||||||
|
|
|
@ -148,6 +148,7 @@ $c-sh-string: #ce2f30;
|
||||||
$c-sh-object: #00f;
|
$c-sh-object: #00f;
|
||||||
$c-sh-array: #00f;
|
$c-sh-array: #00f;
|
||||||
|
|
||||||
|
$c-progress-bar: #5bc0de;
|
||||||
$c-progress-shadow: #353c39;
|
$c-progress-shadow: #353c39;
|
||||||
$c-progress-shadow-2: #8cdb8b;
|
$c-progress-shadow-2: #8cdb8b;
|
||||||
$c-progress-bg: #363c39;
|
$c-progress-bg: #363c39;
|
||||||
|
|
|
@ -5,7 +5,6 @@
|
||||||
.new-index-view {
|
.new-index-view {
|
||||||
input[type='checkbox'] {
|
input[type='checkbox'] {
|
||||||
float: left;
|
float: left;
|
||||||
margin-top: -9px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
table {
|
table {
|
||||||
|
@ -67,7 +66,18 @@
|
||||||
|
|
||||||
.newIndexClass {
|
.newIndexClass {
|
||||||
table {
|
table {
|
||||||
|
border-top: 1px solid $c-modal-table-border-bottom;
|
||||||
margin-bottom: 60px;
|
margin-bottom: 60px;
|
||||||
|
|
||||||
|
select {
|
||||||
|
margin-right: 7px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.arangoicon {
|
||||||
|
float: right;
|
||||||
|
margin-right: -12px;
|
||||||
|
margin-top: 5px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.modal-tabbar {
|
.modal-tabbar {
|
||||||
border-bottom: 1px solid $c-black;
|
border-bottom: 1px solid $c-darker-grey;
|
||||||
}
|
}
|
||||||
|
|
||||||
.modal-body {
|
.modal-body {
|
||||||
|
|
|
@ -39,10 +39,53 @@ $iconsize: 50px;
|
||||||
|
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
|
||||||
|
progress[value] {
|
||||||
|
color: $c-progress-bar;
|
||||||
|
}
|
||||||
|
|
||||||
|
progress::-webkit-progress-bar-value {
|
||||||
|
background: $c-progress-bar;
|
||||||
|
}
|
||||||
|
|
||||||
|
progress::-webkit-progress-value {
|
||||||
|
background: $c-progress-bar;
|
||||||
|
}
|
||||||
|
|
||||||
|
progress::-moz-progress-bar {
|
||||||
|
background: $c-progress-bar;
|
||||||
|
}
|
||||||
|
|
||||||
|
progress {
|
||||||
|
-webkit-appearance: none;
|
||||||
|
border-radius: 0;
|
||||||
|
height: 2px;
|
||||||
|
margin-top: 16px;
|
||||||
|
position: relative;
|
||||||
|
width: 100%;
|
||||||
|
z-index: 10;
|
||||||
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&.locked {
|
||||||
|
cursor: not-allowed;
|
||||||
|
opacity: .5;
|
||||||
|
|
||||||
|
.iconSet {
|
||||||
|
span:hover {
|
||||||
|
background-color: $c-white !important;
|
||||||
|
color: $c-black;
|
||||||
|
cursor: not-allowed !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.iconSet:hover {
|
||||||
|
cursor: not-allowed !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.warning-icons {
|
.warning-icons {
|
||||||
background-color: $c-negative;
|
background-color: $c-negative;
|
||||||
border-radius: 3px;
|
border-radius: 3px;
|
||||||
|
@ -153,6 +196,10 @@ $iconsize: 50px;
|
||||||
padding: 4px 8px;
|
padding: 4px 8px;
|
||||||
text-overflow: ellipsis !important;
|
text-overflow: ellipsis !important;
|
||||||
white-space: nowrap !important;
|
white-space: nowrap !important;
|
||||||
|
|
||||||
|
&.inProgress {
|
||||||
|
color: $c-progress-bar;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.tileSelects {
|
.tileSelects {
|
||||||
|
|
Loading…
Reference in New Issue