mirror of https://gitee.com/bigwinds/arangodb
Strating with '_' is no longer defined as 'isSystem'
This commit is contained in:
parent
9b3f22e2da
commit
89e85926cd
|
@ -119,8 +119,22 @@
|
||||||
},
|
},
|
||||||
|
|
||||||
isSystemCollection: function (val) {
|
isSystemCollection: function (val) {
|
||||||
//return val && val.name && val.name.substr(0, 1) === '_';
|
var returnVal = false;
|
||||||
return val.substr(0, 1) === '_';
|
$.ajax({
|
||||||
|
type: "GET",
|
||||||
|
cache: false,
|
||||||
|
url: "/_api/collection/"+encodeURIComponent(val)+"/properties",
|
||||||
|
contentType: "application/json",
|
||||||
|
processData: false,
|
||||||
|
async: false,
|
||||||
|
success: function(data) {
|
||||||
|
returnVal = data.isSystem;
|
||||||
|
},
|
||||||
|
error: function(data) {
|
||||||
|
returnVal = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return returnVal;
|
||||||
},
|
},
|
||||||
|
|
||||||
collectionApiType: function (identifier, refresh) {
|
collectionApiType: function (identifier, refresh) {
|
||||||
|
@ -150,7 +164,7 @@
|
||||||
type = "unknown";
|
type = "unknown";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (val.name.substr(0, 1) === '_') {
|
if (this.isSystemCollection(val.name)) {
|
||||||
type += " (system)";
|
type += " (system)";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -258,7 +258,13 @@
|
||||||
shardBy.push("_key");
|
shardBy.push("_key");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var isSystem = (collName.substr(0, 1) === '_');
|
//no new system collections via webinterface
|
||||||
|
//var isSystem = (collName.substr(0, 1) === '_');
|
||||||
|
if (collName.substr(0, 1) === '_') {
|
||||||
|
arangoHelper.arangoError('No "_" allowed as first character!');
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
var isSystem = false;
|
||||||
var wfs = (collSync === "true");
|
var wfs = (collSync === "true");
|
||||||
if (collSize > 0) {
|
if (collSize > 0) {
|
||||||
try {
|
try {
|
||||||
|
|
Loading…
Reference in New Issue