diff --git a/js/apps/system/_admin/aardvark/APP/aardvark.js b/js/apps/system/_admin/aardvark/APP/aardvark.js index 05154e74ef..2eeb96aea8 100644 --- a/js/apps/system/_admin/aardvark/APP/aardvark.js +++ b/js/apps/system/_admin/aardvark/APP/aardvark.js @@ -323,13 +323,14 @@ controller.post("/graph-examples/create/:name", function(req, res) { controller.post("/job", function(req, res) { - if (req.body().id && req.body().collection && req.body().type) { + if (req.body().id && req.body().collection && req.body().type && req.body().desc) { //store id in _system db.aardvark.save({ id: req.body().id, collection: req.body().collection, - type: req.body().type + type: req.body().type, + desc: req.body().desc }); res.json(true); diff --git a/js/apps/system/_admin/aardvark/APP/clusterFrontend/build/cluster.min.js b/js/apps/system/_admin/aardvark/APP/clusterFrontend/build/cluster.min.js index 8cfae539ec..61998f6b40 100644 --- a/js/apps/system/_admin/aardvark/APP/clusterFrontend/build/cluster.min.js +++ b/js/apps/system/_admin/aardvark/APP/clusterFrontend/build/cluster.min.js @@ -1,3 +1,3 @@ -!function(){"use strict";var a;window.isCoordinator=function(){return void 0===a&&$.ajax("cluster/amICoordinator",{async:!1,success:function(b){a=b}}),a},window.versionHelper={fromString:function(a){var b=a.replace(/-[a-zA-Z0-9_\-]*$/g,"").split(".");return{major:parseInt(b[0],10)||0,minor:parseInt(b[1],10)||0,patch:parseInt(b[2],10)||0,toString:function(){return this.major+"."+this.minor+"."+this.patch}}},toString:function(a){return a.major+"."+a.minor+"."+a.patch}},window.arangoHelper={lastNotificationMessage:null,CollectionTypes:{},systemAttributes:function(){return{_id:!0,_rev:!0,_key:!0,_bidirectional:!0,_vertices:!0,_from:!0,_to:!0,$id:!0}},setCheckboxStatus:function(a){$.each($(a).find("ul").find("li"),function(a,b){$(b).hasClass("nav-header")||($(b).find("input").attr("checked")?$(b).find("i").hasClass("css-round-label")?$(b).find("i").addClass("fa-dot-circle-o"):$(b).find("i").addClass("fa-check-square-o"):$(b).find("i").hasClass("css-round-label")?$(b).find("i").addClass("fa-circle-o"):$(b).find("i").addClass("fa-square-o"))})},calculateCenterDivHeight:function(){var a=$(".navbar").height(),b=$(".footer").height(),c=$(window).height();return c-b-a-110},fixTooltips:function(a,b){$(a).tooltip({placement:b,hide:!1,show:!1})},currentDatabase:function(){var a=!1;return $.ajax({type:"GET",cache:!1,url:"/_api/database/current",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b.result.name},error:function(){a=!1}}),a},allHotkeys:{global:{name:"Site wide",content:[{label:"scroll up",letter:"j"},{label:"scroll down",letter:"k"}]},jsoneditor:{name:"AQL editor",content:[{label:"Submit",letter:"Ctrl + Return"},{label:"Toggle comments",letter:"Ctrl + Shift + C"},{label:"Undo",letter:"Ctrl + Z"},{label:"Redo",letter:"Ctrl + Shift + Z"}]},doceditor:{name:"Document editor",content:[{label:"Insert",letter:"Ctrl + Insert"},{label:"Save",letter:"Ctrl + Return, CMD + Return"},{label:"Append",letter:"Ctrl + Shift + Insert"},{label:"Duplicate",letter:"Ctrl + D"},{label:"Remove",letter:"Ctrl + Delete"}]},modals:{name:"Modal",content:[{label:"Submit",letter:"Return"},{label:"Close",letter:"Esc"},{label:"Navigate buttons",letter:"Arrow keys"},{label:"Navigate content",letter:"Tab"}]}},hotkeysFunctions:{scrollDown:function(){window.scrollBy(0,180)},scrollUp:function(){window.scrollBy(0,-180)},showHotkeysModal:function(){var a=[],b=window.arangoHelper.allHotkeys;window.modalView.show("modalHotkeys.ejs","Keyboard Shortcuts",a,b)}},enableKeyboardHotkeys:function(a){var b=window.arangoHelper.hotkeysFunctions;a===!0&&($(document).on("keydown",null,"j",b.scrollDown),$(document).on("keydown",null,"k",b.scrollUp))},databaseAllowed:function(){var a=this.currentDatabase(),b=!1;return $.ajax({type:"GET",cache:!1,url:"/_db/"+encodeURIComponent(a)+"/_api/database/",contentType:"application/json",processData:!1,async:!1,success:function(){b=!0},error:function(){b=!1}}),b},arangoNotification:function(a,b,c){window.App.notificationList.add({title:a,content:b,info:c,type:"success"})},arangoError:function(a,b,c){window.App.notificationList.add({title:a,content:b,info:c,type:"error"})},openDocEditor:function(a,b,c){var d=a.split("/"),e=this,f=new window.DocumentView({collection:window.App.arangoDocumentStore});f.breadcrumb=function(){},f.colid=d[0],f.docid=d[1],f.el=".arangoFrame .innerDiv",f.render(),f.setType(b),$(".arangoFrame .headerBar").remove(),$(".arangoFrame .outerDiv").prepend(''),$(".arangoFrame .outerDiv").click(function(){e.closeDocEditor()}),$(".arangoFrame .innerDiv").click(function(a){a.stopPropagation()}),$(".fa-times").click(function(){e.closeDocEditor()}),$(".arangoFrame").show(),f.customView=!0,f.customDeleteFunction=function(){window.modalView.hide(),$(".arangoFrame").hide()},$(".arangoFrame #deleteDocumentButton").click(function(){f.deleteDocumentModal()}),$(".arangoFrame #saveDocumentButton").click(function(){f.saveDocument()}),$(".arangoFrame #deleteDocumentButton").css("display","none")},closeDocEditor:function(){$(".arangoFrame .outerDiv .fa-times").remove(),$(".arangoFrame").hide()},getRandomToken:function(){return Math.round((new Date).getTime())},isSystemAttribute:function(a){var b=this.systemAttributes();return b[a]},isSystemCollection:function(a){return"_"===a.name.substr(0,1)},setDocumentStore:function(a){this.arangoDocumentStore=a},collectionApiType:function(a,b){return(b||void 0===this.CollectionTypes[a])&&(this.CollectionTypes[a]=this.arangoDocumentStore.getCollectionInfo(a).type),3===this.CollectionTypes[a]?"edge":"document"},collectionType:function(a){if(!a||""===a.name)return"-";var b;return b=2===a.type?"document":3===a.type?"edge":"unknown",this.isSystemCollection(a)&&(b+=" (system)"),b},formatDT:function(a){var b=function(a){return 10>a?"0"+a:a};return a.getUTCFullYear()+"-"+b(a.getUTCMonth()+1)+"-"+b(a.getUTCDate())+" "+b(a.getUTCHours())+":"+b(a.getUTCMinutes())+":"+b(a.getUTCSeconds())},escapeHtml:function(a){return String(a).replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}}}(),function(){"use strict";window.ClusterCollection=Backbone.Model.extend({defaults:{name:"",status:"ok"},idAttribute:"name",forList:function(){return{name:this.get("name"),status:this.get("status")}}})}(),function(){"use strict";window.ClusterCoordinator=Backbone.Model.extend({defaults:{name:"",url:"",status:"ok"},idAttribute:"name",forList:function(){return{name:this.get("name"),status:this.get("status"),url:this.get("url")}}})}(),function(){"use strict";window.ClusterDatabase=Backbone.Model.extend({defaults:{name:"",status:"ok"},idAttribute:"name",forList:function(){return{name:this.get("name"),status:this.get("status")}}})}(),function(){"use strict";window.ClusterPlan=Backbone.Model.extend({defaults:{},url:"cluster/plan",idAttribute:"config",getVersion:function(){var a=this.get("version");return a||"2.0"},getCoordinator:function(){if(this._coord)return this._coord[this._lastStableCoord];var a,b,c,d,e=[];if(c=this.get("runInfo")){for(b=c.length-1;b>0;){if(c[b].isStartServers&&(d=c[b],d.endpoints))for(a=0;a1){do a=Math.floor(Math.random()*this._coord.length);while(a===b);this._lastStableCoord=a}},isAlive:function(){var a=!1;return $.ajax({cache:!1,type:"GET",async:!1,url:"cluster/healthcheck",success:function(b){a=b},error:function(a){}}),a},storeCredentials:function(a,b){var c=this;$.ajax({url:"cluster/plan/credentials",type:"PUT",data:JSON.stringify({user:a,passwd:b}),async:!1}).done(function(){c.fetch()})},isSymmetricSetup:function(){var a=this.get("config"),b=_.size(a.dispatchers);return b===a.numberOfCoordinators&&b===a.numberOfDBservers},isTestSetup:function(){return 1===_.size(this.get("config").dispatchers)},cleanUp:function(){$.ajax({url:"cluster/plan/cleanUp",type:"DELETE",async:!1})}})}(),function(){"use strict";window.ClusterServer=Backbone.Model.extend({defaults:{name:"",address:"",role:"",status:"ok"},idAttribute:"name",forList:function(){return{name:this.get("name"),address:this.get("address"),status:this.get("status")}}})}(),function(){"use strict";window.ClusterShard=Backbone.Model.extend({defaults:{},idAttribute:"name",forList:function(){return{server:this.get("name"),shards:this.get("shards")}}})}(),function(){"use strict";window.ClusterType=Backbone.Model.extend({defaults:{type:"testPlan"}})}(),function(){"use strict";window.AutomaticRetryCollection=Backbone.Collection.extend({_retryCount:0,checkRetries:function(){var a=this;return this.updateUrl(),this._retryCount>10?(window.setTimeout(function(){a._retryCount=0},1e4),window.App.clusterUnreachable(),!1):!0},successFullTry:function(){this._retryCount=0},failureTry:function(a,b,c){401===c.status?window.App.requestAuth():(window.App.clusterPlan.rotateCoordinator(),this._retryCount++,a())}})}(),window.ClusterStatisticsCollection=Backbone.Collection.extend({model:window.Statistics,url:"/_admin/statistics",updateUrl:function(){this.url=window.App.getNewRoute("statistics")},initialize:function(){window.App.registerForUpdate(this)},fetch:function(a,b){this.forEach(function(c){c.fetch({beforeSend:window.App.addAuth.bind(window.App),error:function(){b(c)}}).done(function(){a(c)})})}}),function(){"use strict";window.ClusterCollections=window.AutomaticRetryCollection.extend({model:window.ClusterCollection,updateUrl:function(){this.url=window.App.getNewRoute(this.dbname+"/Collections")},url:function(){return"/_admin/aardvark/cluster/"+this.dbname+"/Collections"},initialize:function(){this.isUpdating=!1,this.timer=null,this.interval=1e3,window.App.registerForUpdate(this)},getList:function(a,b){if(void 0!==a&&(this.dbname=a,this.checkRetries())){var c=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:c.failureTry.bind(c,c.getList.bind(c,a,b))}).done(function(){b(c.map(function(a){return a.forList()}))})}},stopUpdating:function(){window.clearTimeout(this.timer),this.isUpdating=!1},startUpdating:function(){if(!this.isUpdating){this.isUpdating=!0;var a=this;this.timer=window.setInterval(function(){a.updateUrl(),a.fetch({beforeSend:window.App.addAuth.bind(window.App)})},this.interval)}}})}(),function(){"use strict";window.ClusterCoordinators=window.AutomaticRetryCollection.extend({model:window.ClusterCoordinator,url:"/_admin/aardvark/cluster/Coordinators",updateUrl:function(){this.url=window.App.getNewRoute("Coordinators")},initialize:function(){window.App.registerForUpdate(this)},statusClass:function(a){switch(a){case"ok":return"success";case"warning":return"warning";case"critical":return"danger";case"missing":return"inactive";default:return"danger"}},getStatuses:function(a,b){if(this.checkRetries()){var c=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:c.failureTry.bind(c,c.getStatuses.bind(c,a,b))}).done(function(){c.successFullTry(),c.forEach(function(b){a(c.statusClass(b.get("status")),b.get("address"))}),b()})}},byAddress:function(a,b){if(this.checkRetries()){var c=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:c.failureTry.bind(c,c.byAddress.bind(c,a,b))}).done(function(){c.successFullTry(),a=a||{},c.forEach(function(b){var c=b.get("address");c=c.split(":")[0],a[c]=a[c]||{},a[c].coords=a[c].coords||[],a[c].coords.push(b)}),b(a)})}},checkConnection:function(a){var b=this;this.checkRetries()&&this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:b.failureTry.bind(b,b.checkConnection.bind(b,a))}).done(function(){b.successFullTry(),a()})},getList:function(){throw"Do not use coordinator.getList"},getOverview:function(){throw"Do not use coordinator.getOverview"}})}(),function(){"use strict";window.ClusterDatabases=window.AutomaticRetryCollection.extend({model:window.ClusterDatabase,url:"/_admin/aardvark/cluster/Databases",updateUrl:function(){this.url=window.App.getNewRoute("Databases")},initialize:function(){window.App.registerForUpdate(this)},getList:function(a){if(this.checkRetries()){var b=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:b.failureTry.bind(b,b.getList.bind(b,a))}).done(function(){b.successFullTry(),a(b.map(function(a){return a.forList()}))})}}})}(),function(){"use strict";window.ClusterServers=window.AutomaticRetryCollection.extend({model:window.ClusterServer,url:"/_admin/aardvark/cluster/DBServers",updateUrl:function(){this.url=window.App.getNewRoute("DBServers")},initialize:function(){window.App.registerForUpdate(this)},statusClass:function(a){switch(a){case"ok":return"success";case"warning":return"warning";case"critical":return"danger";case"missing":return"inactive";default:return"danger"}},getStatuses:function(a){if(this.checkRetries()){var b=this,c=function(){b.successFullTry(),b._retryCount=0,b.forEach(function(c){a(b.statusClass(c.get("status")),c.get("address"))})};this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:b.failureTry.bind(b,b.getStatuses.bind(b,a))}).done(c)}},byAddress:function(a,b){if(this.checkRetries()){var c=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:c.failureTry.bind(c,c.byAddress.bind(c,a,b))}).done(function(){c.successFullTry(),a=a||{},c.forEach(function(b){var c=b.get("address");c=c.split(":")[0],a[c]=a[c]||{},a[c].dbs=a[c].dbs||[],a[c].dbs.push(b)}),b(a)})}},getList:function(a){throw"Do not use"},getOverview:function(){throw"Do not use DbServer.getOverview"}})}(),function(){"use strict";window.ClusterShards=window.AutomaticRetryCollection.extend({model:window.ClusterShard,updateUrl:function(){this.url=window.App.getNewRoute(this.dbname+"/"+this.colname+"/Shards")},url:function(){return"/_admin/aardvark/cluster/"+this.dbname+"/"+this.colname+"/Shards"},initialize:function(){this.isUpdating=!1,this.timer=null,this.interval=1e3,window.App.registerForUpdate(this)},getList:function(a,b,c){if(void 0!==a&&void 0!==b&&(this.dbname=a,this.colname=b,this.checkRetries())){var d=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:d.failureTry.bind(d,d.getList.bind(d,a,b,c))}).done(function(){c(d.map(function(a){return a.forList()}))})}},stopUpdating:function(){window.clearTimeout(this.timer),this.isUpdating=!1},startUpdating:function(){if(!this.isUpdating){this.isUpdating=!0;var a=this;this.timer=window.setInterval(function(){a.updateUrl(),a.fetch({beforeSend:window.App.addAuth.bind(window.App)})},this.interval)}}})}(),window.arangoDocumentModel=Backbone.Model.extend({initialize:function(){"use strict"},urlRoot:"/_api/document",defaults:{_id:"",_rev:"",_key:""},getSorted:function(){"use strict";var a=this,b=Object.keys(a.attributes).sort(function(a,b){var c=arangoHelper.isSystemAttribute(a),d=arangoHelper.isSystemAttribute(b);return c!==d?c?-1:1:b>a?-1:1}),c={};return _.each(b,function(b){c[b]=a.attributes[b]}),c}}),window.Statistics=Backbone.Model.extend({defaults:{},url:function(){"use strict";return"/_admin/statistics"}}),window.StatisticsDescription=Backbone.Model.extend({defaults:{figures:"",groups:""},url:function(){"use strict";return"/_admin/statistics-description"}}),function(){"use strict";window.PaginatedCollection=Backbone.Collection.extend({page:0,pagesize:10,totalAmount:0,getPage:function(){return this.page+1},setPage:function(a){return a>=this.getLastPageNumber()?void(this.page=this.getLastPageNumber()-1):1>a?void(this.page=0):void(this.page=a-1)},getLastPageNumber:function(){return Math.max(Math.ceil(this.totalAmount/this.pagesize),1)},getOffset:function(){return this.page*this.pagesize},getPageSize:function(){return this.pagesize},setPageSize:function(a){if("all"===a)this.pagesize="all";else try{a=parseInt(a,10),this.pagesize=a}catch(b){}},setToFirst:function(){this.page=0},setToLast:function(){this.setPage(this.getLastPageNumber())},setToPrev:function(){this.setPage(this.getPage()-1)},setToNext:function(){this.setPage(this.getPage()+1)},setTotal:function(a){this.totalAmount=a},getTotal:function(){return this.totalAmount},setTotalMinusOne:function(){this.totalAmount--}})}(),window.StatisticsCollection=Backbone.Collection.extend({model:window.Statistics,url:"/_admin/statistics"}),function(){"use strict";window.arangoDocuments=window.PaginatedCollection.extend({collectionID:1,filters:[],MAX_SORT:12e3,lastQuery:{},sortAttribute:"_key",url:"/_api/documents",model:window.arangoDocumentModel,loadTotal:function(){var a=this;$.ajax({cache:!1,type:"GET",url:"/_api/collection/"+this.collectionID+"/count",contentType:"application/json",processData:!1,async:!1,success:function(b){a.setTotal(b.count)}})},setCollection:function(a){this.resetFilter(),this.collectionID=a,this.setPage(1),this.loadTotal()},setSort:function(a){this.sortAttribute=a},getSort:function(){return this.sortAttribute},addFilter:function(a,b,c){this.filters.push({attr:a,op:b,val:c})},setFiltersForQuery:function(a){if(0===this.filters.length)return"";var b=" FILTER",c="",d=_.map(this.filters,function(b,d){return"LIKE"===b.op?(c=" "+b.op+"(x.`"+b.attr+"`, @param",c+=d,c+=")"):(c="IN"===b.op||"NOT IN"===b.op?" ":" x.`",c+=b.attr,c+="IN"===b.op||"NOT IN"===b.op?" ":"` ",c+=b.op,c+="IN"===b.op||"NOT IN"===b.op?" x.@param":" @param",c+=d),a["param"+d]=b.val,c});return b+d.join(" &&")},setPagesize:function(a){this.setPageSize(a)},resetFilter:function(){this.filters=[]},moveDocument:function(a,b,c,d){var e,f,g,h,i={"@collection":b,filterid:a};e="FOR x IN @@collection",e+=" FILTER x._key == @filterid",e+=" INSERT x IN ",e+=c,f="FOR x in @@collection",f+=" FILTER x._key == @filterid",f+=" REMOVE x IN @@collection",g={query:e,bindVars:i},h={query:f,bindVars:i},window.progressView.show(),$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(g),contentType:"application/json",success:function(a){$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(h),contentType:"application/json",success:function(a){d&&d(),window.progressView.hide()},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Documents inserted, but could not be removed.")}})},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not move selected documents.")}})},getDocuments:function(a){window.progressView.showWithDelay(300,"Fetching documents...");var b,c,d,e,f=this;c={"@collection":this.collectionID,offset:this.getOffset(),count:this.getPageSize()},b="FOR x IN @@collection LET att = SLICE(ATTRIBUTES(x), 0, 25)",b+=this.setFiltersForQuery(c),this.getTotal()0)&&(e.options={fullCount:!0}),$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(e),contentType:"application/json",success:function(b){window.progressView.toShow=!1,f.clearDocuments(),b.extra&&void 0!==b.extra.stats.fullCount&&f.setTotal(b.extra.stats.fullCount),0!==f.getTotal()&&_.each(b.result,function(a){f.add({id:a._id,rev:a._rev,key:a._key,content:a})}),f.lastQuery=e,a(),window.progressView.hide()},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not fetch requested documents.")}})},clearDocuments:function(){this.reset()},buildDownloadDocumentQuery:function(){var a,b,c;return c={"@collection":this.collectionID},a="FOR x in @@collection",a+=this.setFiltersForQuery(c),this.getTotal()0&&(b="At least one error occurred during upload")}catch(d){}}}),b}})}(),function(){"use strict";if(!window.hasOwnProperty("TEST_BUILD")){var a=function(){var a={};return a.createTemplate=function(a){var b=$("#"+a.replace(".","\\.")).html();return{render:function(a){return _.template(b,a)}}},a};window.templateEngine=new a}}(),function(){"use strict";window.FooterView=Backbone.View.extend({el:"#footerBar",system:{},isOffline:!0,isOfflineCounter:0,firstLogin:!0,events:{"click .footer-center p":"showShortcutModal"},initialize:function(){var a=this;window.setInterval(function(){a.getVersion()},15e3),a.getVersion()},template:templateEngine.createTemplate("footerView.ejs"),showServerStatus:function(a){a===!0?($(".serverStatusIndicator").addClass("isOnline"),$(".serverStatusIndicator").addClass("fa-check-circle-o"),$(".serverStatusIndicator").removeClass("fa-times-circle-o")):($(".serverStatusIndicator").removeClass("isOnline"),$(".serverStatusIndicator").removeClass("fa-check-circle-o"),$(".serverStatusIndicator").addClass("fa-times-circle-o"))},showShortcutModal:function(){window.arangoHelper.hotkeysFunctions.showHotkeysModal()},getVersion:function(){var a=this;$.ajax({type:"GET",cache:!1,url:"/_api/version",contentType:"application/json",processData:!1,async:!0,success:function(b){a.showServerStatus(!0),a.isOffline===!0&&(a.isOffline=!1,a.isOfflineCounter=0,a.firstLogin?a.firstLogin=!1:window.setTimeout(function(){a.showServerStatus(!0)},1e3),a.system.name=b.server,a.system.version=b.version,a.render())},error:function(b){a.isOffline=!0,a.isOfflineCounter++,a.isOfflineCounter>=1&&a.showServerStatus(!1)}}),a.system.hasOwnProperty("database")||$.ajax({type:"GET",cache:!1,url:"/_api/database/current",contentType:"application/json",processData:!1,async:!0,success:function(b){var c=b.result.name;a.system.database=c;var d=window.setInterval(function(){var b=$("#databaseNavi");b&&(window.clearTimeout(d),d=null,"_system"===c?($(".logs-menu").css("visibility","visible"),$(".logs-menu").css("display","inline"),$("#databaseNavi").css("display","inline")):($(".logs-menu").css("visibility","hidden"),$(".logs-menu").css("display","none")),a.render())},50)}})},renderVersion:function(){this.system.hasOwnProperty("database")&&this.system.hasOwnProperty("name")&&$(this.el).html(this.template.render({name:this.system.name,version:this.system.version,database:this.system.database}))},render:function(){return this.system.version||this.getVersion(),$(this.el).html(this.template.render({name:this.system.name,version:this.system.version})),this}})}(),function(){"use strict";function a(a,b){return(void 0===a||null===a)&&(a=0),a.toFixed(b)}window.DashboardView=Backbone.View.extend({el:"#content",interval:1e4,defaultTimeFrame:12e5,defaultDetailFrame:1728e5,history:{},graphs:{},events:{},tendencies:{asyncPerSecondCurrent:["asyncPerSecondCurrent","asyncPerSecondPercentChange"],syncPerSecondCurrent:["syncPerSecondCurrent","syncPerSecondPercentChange"],clientConnectionsCurrent:["clientConnectionsCurrent","clientConnectionsPercentChange"],clientConnectionsAverage:["clientConnections15M","clientConnections15MPercentChange"],numberOfThreadsCurrent:["numberOfThreadsCurrent","numberOfThreadsPercentChange"],numberOfThreadsAverage:["numberOfThreads15M","numberOfThreads15MPercentChange"],virtualSizeCurrent:["virtualSizeCurrent","virtualSizePercentChange"],virtualSizeAverage:["virtualSize15M","virtualSize15MPercentChange"]},barCharts:{totalTimeDistribution:["queueTimeDistributionPercent","requestTimeDistributionPercent"],dataTransferDistribution:["bytesSentDistributionPercent","bytesReceivedDistributionPercent"]},barChartsElementNames:{queueTimeDistributionPercent:"Queue",requestTimeDistributionPercent:"Computation",bytesSentDistributionPercent:"Bytes sent",bytesReceivedDistributionPercent:"Bytes received"},getDetailFigure:function(a){var b=$(a.currentTarget).attr("id").replace(/ChartButton/g,"");return b},showDetail:function(a){var b,c=this,d=this.getDetailFigure(a);b=this.dygraphConfig.getDetailChartConfig(d),this.getHistoryStatistics(d),this.detailGraphFigure=d,window.modalView.hideFooter=!0,window.modalView.hide(),window.modalView.show("modalGraph.ejs",b.header,void 0,void 0,void 0,void 0,this.events),window.modalView.hideFooter=!1,$("#modal-dialog").on("hidden",function(){c.hidden()}),$("#modal-dialog").toggleClass("modal-chart-detail",!0),b.height=.7*$(window).height(),b.width=$(".modal-inner-detail").width(),b.labelsDiv=$(b.labelsDiv)[0],this.detailGraph=new Dygraph(document.getElementById("lineChartDetail"),this.history[this.server][d],b)},hidden:function(){this.detailGraph.destroy(),delete this.detailGraph,delete this.detailGraphFigure},getCurrentSize:function(a){"#"!==a.substr(0,1)&&(a="#"+a);var b,c;return $(a).attr("style",""),b=$(a).height(),c=$(a).width(),{height:b,width:c}},prepareDygraphs:function(){var a,b=this;this.dygraphConfig.getDashBoardFigures().forEach(function(c){a=b.dygraphConfig.getDefaultConfig(c);var d=b.getCurrentSize(a.div);a.height=d.height,a.width=d.width,b.graphs[c]=new Dygraph(document.getElementById(a.div),b.history[b.server][c]||[],a)})},initialize:function(){this.dygraphConfig=this.options.dygraphConfig,this.d3NotInitialized=!0,this.events["click .dashboard-sub-bar-menu-sign"]=this.showDetail.bind(this),this.events["mousedown .dygraph-rangesel-zoomhandle"]=this.stopUpdating.bind(this),this.events["mouseup .dygraph-rangesel-zoomhandle"]=this.startUpdating.bind(this),this.serverInfo=this.options.serverToShow,this.serverInfo?this.server=this.serverInfo.target:this.server="-local-",this.history[this.server]={}},updateCharts:function(){var a=this;return this.detailGraph?void this.updateLineChart(this.detailGraphFigure,!0):(this.prepareD3Charts(this.isUpdating),this.prepareResidentSize(this.isUpdating),this.updateTendencies(),void Object.keys(this.graphs).forEach(function(b){a.updateLineChart(b,!1)}))},updateTendencies:function(){var a=this,b=this.tendencies,c="";Object.keys(b).forEach(function(b){var d="",e=0;a.history.hasOwnProperty(a.server)&&a.history[a.server].hasOwnProperty(b)&&(e=a.history[a.server][b][1]),0>e?c="#d05448":(c="#7da817",d="+"),a.history.hasOwnProperty(a.server)&&a.history[a.server].hasOwnProperty(b)?$("#"+b).html(a.history[a.server][b][0]+'
'+d+e+"%"):$("#"+b).html('
data not ready yet')})},updateDateWindow:function(a,b){var c,d,e=(new Date).getTime();return b&&a.dateWindow_?(c=a.dateWindow_[0],d=e-a.dateWindow_[1]-5*this.interval>0?a.dateWindow_[1]:e,[c,d]):[e-this.defaultTimeFrame,e]},updateLineChart:function(a,b){var c=b?this.detailGraph:this.graphs[a],d={file:this.history[this.server][a],dateWindow:this.updateDateWindow(c,b)},e=0,f=[];_.each(d.file,function(a){var b=a[0].getSeconds()-a[0].getSeconds()%10;d.file[e][0].setSeconds(b),f.push(d.file[e][0]),e++});for(var g=new Date(Math.max.apply(null,f)),h=new Date(Math.min.apply(null,f)),i=new Date(h.getTime()),j=[],k=[];g>i;)i=new Date(i.setSeconds(i.getSeconds()+10)),k.push(i);_.each(k,function(a){var b=!1;_.each(d.file,function(c){Math.floor(a.getTime()/1e3)===Math.floor(c[0].getTime()/1e3)&&(b=!0)}),b===!1&&a1&&d.history[d.server][e].push(c))})},cutOffHistory:function(a,b){for(var c=this;0!==c.history[c.server][a].length;){var d=c.history[c.server][a][0][0];if(d>=b)break;c.history[c.server][a].shift()}},cutOffDygraphHistory:function(a){var b=this,c=new Date(a);this.dygraphConfig.getDashBoardFigures(!0).forEach(function(a){b.dygraphConfig.mapStatToFigure[a]&&b.history[b.server][a]&&b.cutOffHistory(a,c)})},mergeHistory:function(b){var c,d=this;for(c=0;c=0;--c)d.values.push({label:this.getLabel(b[a[0]].cuts,c),value:b[a[0]].values[c]}),e.values.push({label:this.getLabel(b[a[1]].cuts,c),value:b[a[1]].values[c]});return[d,e]},getLabel:function(a,b){return a[b]?0===b?"0 - "+a[b]:a[b-1]+" - "+a[b]:">"+a[b-1]},renderReplicationStatistics:function(a){$("#repl-numbers table tr:nth-child(1) > td:nth-child(2)").html(a.state.totalEvents),$("#repl-numbers table tr:nth-child(2) > td:nth-child(2)").html(a.state.totalRequests),$("#repl-numbers table tr:nth-child(3) > td:nth-child(2)").html(a.state.totalFailedConnects),a.state.lastAppliedContinuousTick?$("#repl-ticks table tr:nth-child(1) > td:nth-child(2)").html(a.state.lastAppliedContinuousTick):$("#repl-ticks table tr:nth-child(1) > td:nth-child(2)").html("no data available").addClass("no-data"),a.state.lastProcessedContinuousTick?$("#repl-ticks table tr:nth-child(2) > td:nth-child(2)").html(a.state.lastProcessedContinuousTick):$("#repl-ticks table tr:nth-child(2) > td:nth-child(2)").html("no data available").addClass("no-data"),a.state.lastAvailableContinuousTick?$("#repl-ticks table tr:nth-child(3) > td:nth-child(2)").html(a.state.lastAvailableContinuousTick):$("#repl-ticks table tr:nth-child(3) > td:nth-child(2)").html("no data available").addClass("no-data"),$("#repl-progress table tr:nth-child(1) > td:nth-child(2)").html(a.state.progress.message),$("#repl-progress table tr:nth-child(2) > td:nth-child(2)").html(a.state.progress.time),$("#repl-progress table tr:nth-child(3) > td:nth-child(2)").html(a.state.progress.failedConnects)},getReplicationStatistics:function(){var a=this;$.ajax("/_api/replication/applier-state",{async:!0}).done(function(b){if(b.hasOwnProperty("state")){var c;c=b.state.running?"active":"inactive",c=''+c+"",$("#replication-chart .dashboard-sub-bar").html("Replication "+c),a.renderReplicationStatistics(b)}})},getStatistics:function(a){var b=this,c="/_db/_system/_admin/aardvark/statistics/short",d="?start=";d+=b.nextStart?b.nextStart:((new Date).getTime()-b.defaultTimeFrame)/1e3,"-local-"!==b.server&&(c=b.serverInfo.endpoint+"/_admin/aardvark/statistics/cluster",d+="&type=short&DBserver="+b.serverInfo.target,b.history.hasOwnProperty(b.server)||(b.history[b.server]={})),$.ajax(c+d,{async:!0}).done(function(c){c.times.length>0&&(b.isUpdating=!0,b.mergeHistory(c)),b.isUpdating!==!1&&(a&&a(),b.updateCharts())}),this.getReplicationStatistics()},getHistoryStatistics:function(a){var b=this,c="statistics/long",d="?filter="+this.dygraphConfig.mapStatToFigure[a].join();"-local-"!==b.server&&(c=b.server.endpoint+"/_admin/aardvark/statistics/cluster",d+="&type=long&DBserver="+b.server.target,b.history.hasOwnProperty(b.server)||(b.history[b.server]={}));var e=window.location.href.split("/"),f=e[0]+"//"+e[2]+"/"+e[3]+"/_system/"+e[5]+"/"+e[6]+"/";$.ajax(f+c+d,{async:!0}).done(function(c){var d;for(b.history[b.server][a]=[],d=0;d data not ready yet

'),$("#totalTimeDistribution").prepend('

data not ready yet

'),$(".dashboard-bar-chart-title").prepend('

data not ready yet

')); -},removeEmptyDataLabels:function(){$(".dataNotReadyYet").remove()},prepareResidentSize:function(b){var c=this,d=this.getCurrentSize("#residentSizeChartContainer"),e=c.history[c.server].residentSizeCurrent/1024/1024,f="";f=1025>e?a(e,2)+" MB":a(e/1024,2)+" GB";var g=a(100*c.history[c.server].residentSizePercent,2),h=[a(c.history[c.server].physicalMemory/1024/1024/1024,0)+" GB"];return void 0===c.history[c.server].residentSizeChart?void this.addEmptyDataLabels():(this.removeEmptyDataLabels(),void nv.addGraph(function(){var a=nv.models.multiBarHorizontalChart().x(function(a){return a.label}).y(function(a){return a.value}).width(d.width).height(d.height).margin({top:($("residentSizeChartContainer").outerHeight()-$("residentSizeChartContainer").height())/2,right:1,bottom:($("residentSizeChartContainer").outerHeight()-$("residentSizeChartContainer").height())/2,left:1}).showValues(!1).showYAxis(!1).showXAxis(!1).transitionDuration(100).tooltips(!1).showLegend(!1).showControls(!1).stacked(!0);return a.yAxis.tickFormat(function(a){return a+"%"}).showMaxMin(!1),a.xAxis.showMaxMin(!1),d3.select("#residentSizeChart svg").datum(c.history[c.server].residentSizeChart).call(a),d3.select("#residentSizeChart svg").select(".nv-zeroLine").remove(),b&&(d3.select("#residentSizeChart svg").select("#total").remove(),d3.select("#residentSizeChart svg").select("#percentage").remove()),d3.select(".dashboard-bar-chart-title .percentage").html(f+" ("+g+" %)"),d3.select(".dashboard-bar-chart-title .absolut").html(h[0]),nv.utils.windowResize(a.update),a},function(){d3.selectAll("#residentSizeChart .nv-bar").on("click",function(){})}))},prepareD3Charts:function(b){var c=this,d={totalTimeDistribution:["queueTimeDistributionPercent","requestTimeDistributionPercent"],dataTransferDistribution:["bytesSentDistributionPercent","bytesReceivedDistributionPercent"]};this.d3NotInitialized&&(b=!1,this.d3NotInitialized=!1),_.each(Object.keys(d),function(b){var d=c.getCurrentSize("#"+b+"Container .dashboard-interior-chart"),e="#"+b+"Container svg";return void 0===c.history[c.server].residentSizeChart?void c.addEmptyDataLabels():(c.removeEmptyDataLabels(),void nv.addGraph(function(){var f=[0,.25,.5,.75,1],g=75,h=23,i=6;d.width<219?(f=[0,.5,1],g=72,h=21,i=5):d.width<299?(f=[0,.3334,.6667,1],g=77):d.width<379?g=87:d.width<459?g=95:d.width<539?g=100:d.width<619&&(g=105);var j=nv.models.multiBarHorizontalChart().x(function(a){return a.label}).y(function(a){return a.value}).width(d.width).height(d.height).margin({top:5,right:20,bottom:h,left:g}).showValues(!1).showYAxis(!0).showXAxis(!0).transitionDuration(100).tooltips(!1).showLegend(!1).showControls(!1).forceY([0,1]);j.yAxis.showMaxMin(!1);d3.select(".nv-y.nv-axis").selectAll("text").attr("transform","translate (0, "+i+")");return j.yAxis.tickValues(f).tickFormat(function(b){return a(100*b*100/100,0)+"%"}),d3.select(e).datum(c.history[c.server][b]).call(j),nv.utils.windowResize(j.update),j},function(){d3.selectAll(e+" .nv-bar").on("click",function(){})}))})},stopUpdating:function(){this.isUpdating=!1},startUpdating:function(){var a=this;a.timer||(a.timer=window.setInterval(function(){a.getStatistics()},a.interval))},resize:function(){if(this.isUpdating){var a,b=this;_.each(this.graphs,function(c){a=b.getCurrentSize(c.maindiv_.id),c.resize(a.width,a.height)}),this.detailGraph&&(a=this.getCurrentSize(this.detailGraph.maindiv_.id),this.detailGraph.resize(a.width,a.height)),this.prepareD3Charts(!0),this.prepareResidentSize(!0)}},template:templateEngine.createTemplate("dashboardView.ejs"),render:function(a){a||$(this.el).html(this.template.render());var b=function(){this.prepareDygraphs(),this.isUpdating&&(this.prepareD3Charts(),this.prepareResidentSize(),this.updateTendencies()),this.startUpdating()}.bind(this),c=this.options.database.hasSystemAccess();c?this.getStatistics(b):($(".contentDiv").remove(),$(".headerBar").remove(),$(".dashboard-headerbar").remove(),$(".dashboard-row").remove(),$("#content").append('
You do not have permission to view this page.
'),$("#content").append("
You can switch to '_system' to see the dashboard.
"))}})}(),function(){"use strict";var a=function(a,b,c,d){return{type:a,title:b,callback:c,confirm:d}},b=function(a,b,c,d,e,f,g,h,i,j,k){var l={type:a,label:b};return void 0!==c&&(l.value=c),void 0!==d&&(l.info=d),void 0!==e&&(l.placeholder=e),void 0!==f&&(l.mandatory=f),void 0!==h&&(l.addDelete=h),void 0!==i&&(l.addAdd=i),void 0!==j&&(l.maxEntrySize=j),void 0!==k&&(l.tags=k),g&&(l.validateInput=function(){return g}),l};window.ModalView=Backbone.View.extend({_validators:[],_validateWatchers:[],baseTemplate:templateEngine.createTemplate("modalBase.ejs"),tableTemplate:templateEngine.createTemplate("modalTable.ejs"),el:"#modalPlaceholder",contentEl:"#modalContent",hideFooter:!1,confirm:{list:"#modal-delete-confirmation",yes:"#modal-confirm-delete",no:"#modal-abort-delete"},enabledHotkey:!1,enableHotKeys:!0,buttons:{SUCCESS:"success",NOTIFICATION:"notification",DELETE:"danger",NEUTRAL:"neutral",CLOSE:"close"},tables:{READONLY:"readonly",TEXT:"text",BLOB:"blob",PASSWORD:"password",SELECT:"select",SELECT2:"select2",CHECKBOX:"checkbox"},initialize:function(){Object.freeze(this.buttons),Object.freeze(this.tables)},createModalHotkeys:function(){$(this.el).unbind("keydown"),$(this.el).unbind("return"),$(this.el).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()}),$(".modal-body input").unbind("keydown"),$(".modal-body input").unbind("return"),$(".modal-body input",$(this.el)).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()}),$(".modal-body select").unbind("keydown"),$(".modal-body select").unbind("return"),$(".modal-body select",$(this.el)).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()})},createInitModalHotkeys:function(){var a=this;$(this.el).bind("keydown","left",function(){a.navigateThroughButtons("left")}),$(this.el).bind("keydown","right",function(){a.navigateThroughButtons("right")})},navigateThroughButtons:function(a){var b=$(".createModalDialog .modal-footer button").is(":focus");b===!1?"left"===a?$(".createModalDialog .modal-footer button").first().focus():"right"===a&&$("..createModalDialog .modal-footer button").last().focus():b===!0&&("left"===a?$(":focus").prev().focus():"right"===a&&$(":focus").next().focus())},createCloseButton:function(b,c){var d=this;return a(this.buttons.CLOSE,b,function(){d.hide(),c&&c()})},createSuccessButton:function(b,c){return a(this.buttons.SUCCESS,b,c)},createNotificationButton:function(b,c){return a(this.buttons.NOTIFICATION,b,c)},createDeleteButton:function(b,c,d){return a(this.buttons.DELETE,b,c,d)},createNeutralButton:function(b,c){return a(this.buttons.NEUTRAL,b,c)},createDisabledButton:function(b){var c=a(this.buttons.NEUTRAL,b);return c.disabled=!0,c},createReadOnlyEntry:function(a,c,d,e,f,g){var h=b(this.tables.READONLY,c,d,e,void 0,void 0,void 0,f,g);return h.id=a,h},createTextEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.TEXT,c,d,e,f,g,h);return i.id=a,i},createBlobEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.BLOB,c,d,e,f,g,h);return i.id=a,i},createSelect2Entry:function(a,c,d,e,f,g,h,i,j,k){var l=b(this.tables.SELECT2,c,d,e,f,g,void 0,h,i,j,k);return l.id=a,l},createPasswordEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.PASSWORD,c,d,e,f,g,h);return i.id=a,i},createCheckboxEntry:function(a,c,d,e,f){var g=b(this.tables.CHECKBOX,c,d,e);return g.id=a,f&&(g.checked=f),g},createSelectEntry:function(a,c,d,e,f){var g=b(this.tables.SELECT,c,null,e);return g.id=a,d&&(g.selected=d),g.options=f,g},createOptionEntry:function(a,b){return{label:a,value:b||a}},show:function(a,b,c,d,e,f,g,h,i){var j,k,l=this,m=!1;c=c||[],h=Boolean(h),this.clearValidators(),c.length>0?(c.forEach(function(a){a.type===l.buttons.CLOSE&&(m=!0),a.type===l.buttons.DELETE&&(k=k||a.confirm)}),m||(j=c.pop(),c.push(l.createCloseButton("Cancel")),c.push(j))):c.push(l.createCloseButton("Close")),$(this.el).html(this.baseTemplate.render({title:b,buttons:c,hideFooter:this.hideFooter,confirm:k,tabBar:i})),_.each(c,function(a,b){return!a.disabled&&a.callback?a.type!==l.buttons.DELETE||h?void $("#modalButton"+b).bind("click",a.callback):void $("#modalButton"+b).bind("click",function(){$(l.confirm.yes).unbind("click"),$(l.confirm.yes).bind("click",a.callback),$(l.confirm.list).css("display","block")}):void 0}),$(this.confirm.no).bind("click",function(){$(l.confirm.list).css("display","none")});var n;if("string"==typeof a)n=templateEngine.createTemplate(a),$(".createModalDialog .modal-body").html(n.render({content:d,advancedContent:e,info:f}));else{var o=0;_.each(a,function(a){n=templateEngine.createTemplate(a),$(".createModalDialog .modal-body .tab-content #"+i[o]).html(n.render({content:d,advancedContent:e,info:f})),o++})}$(".createModalDialog .modalTooltips").tooltip({position:{my:"left top",at:"right+55 top-1"}});var p=d||[];e&&e.content&&(p=p.concat(e.content)),_.each(p,function(a){l.modalBindValidation(a),a.type===l.tables.SELECT2&&$("#"+a.id).select2({tags:a.tags||[],showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:a.maxEntrySize||8})}),g&&(this.events=g,this.delegateEvents()),$("#accordion2")&&($("#accordion2 .accordion-toggle").bind("click",function(){$("#collapseOne").is(":visible")?($("#collapseOne").hide(),setTimeout(function(){$(".accordion-toggle").addClass("collapsed")},100)):($("#collapseOne").show(),setTimeout(function(){$(".accordion-toggle").removeClass("collapsed")},100))}),$("#collapseOne").hide(),setTimeout(function(){$(".accordion-toggle").addClass("collapsed")},100)),$("#modal-dialog").modal("show"),this.enabledHotkey===!1&&(this.createInitModalHotkeys(),this.enabledHotkey=!0),this.enableHotKeys&&this.createModalHotkeys();var q=$("#modal-dialog").find("input");q&&setTimeout(function(){var a=$("#modal-dialog");a.length>0&&(a=a.find("input"),a.length>0&&$(a[0]).focus())},800)},modalBindValidation:function(a){var b=this;if(a.hasOwnProperty("id")&&a.hasOwnProperty("validateInput")){var c=function(){var b=$("#"+a.id),c=a.validateInput(b),d=!1;return _.each(c,function(a){var c=b.val();if(a.rule||(a={rule:a}),"function"==typeof a.rule)try{a.rule(c)}catch(e){d=a.msg||e.message}else{var f=Joi.validate(c,a.rule);f.error&&(d=a.msg||f.error.message)}return d?!1:void 0}),d?d:void 0},d=$("#"+a.id);d.on("keyup focusout",function(){var a=c(),e=d.next()[0];a?(d.addClass("invalid-input"),e?$(e).text(a):d.after('

'+a+"

"),$(".createModalDialog .modal-footer .button-success").prop("disabled",!0).addClass("disabled")):(d.removeClass("invalid-input"),e&&$(e).remove(),b.modalTestAll())}),this._validators.push(c),this._validateWatchers.push(d)}},modalTestAll:function(){var a=_.map(this._validators,function(a){return a()}),b=_.any(a);return b?$(".createModalDialog .modal-footer .button-success").prop("disabled",!0).addClass("disabled"):$(".createModalDialog .modal-footer .button-success").prop("disabled",!1).removeClass("disabled"),!b},clearValidators:function(){this._validators=[],_.each(this._validateWatchers,function(a){a.unbind("keyup focusout")}),this._validateWatchers=[]},hide:function(){this.clearValidators(),$("#modal-dialog").modal("hide")}})}(),window.StatisticsDescriptionCollection=Backbone.Collection.extend({model:window.StatisticsDescription,url:"/_admin/statistics-description",parse:function(a){return a}}),function(){"use strict";window.ClusterDownView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("clusterDown.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),events:{"click #relaunchCluster":"relaunchCluster","click #upgradeCluster":"upgradeCluster","click #editPlan":"editPlan","click #submitEditPlan":"submitEditPlan","click #deletePlan":"deletePlan","click #submitDeletePlan":"submitDeletePlan"},render:function(){var a,b=window.versionHelper.fromString(window.App.clusterPlan.getVersion());$.ajax({type:"GET",cache:!1,url:"/_admin/database/target-version",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b.version}}),a=window.versionHelper.fromString(a);var c=!1;(a.major>b.major||a.major===b.major&&a.minor>b.minor)&&(c=!0),$(this.el).html(this.template.render({canUpgrade:c})),$(this.el).append(this.modal.render({}))},relaunchCluster:function(){$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster will be relaunched"),$.ajax({cache:!1,type:"GET",url:"cluster/relaunch",success:function(){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.navigate("showCluster",{trigger:!0})}})},upgradeCluster:function(){$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster will be upgraded"),$.ajax({cache:!1,type:"GET",url:"cluster/upgrade",success:function(){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.clusterPlan.fetch(),window.App.navigate("showCluster",{trigger:!0})}})},editPlan:function(){$("#deletePlanModal").modal("hide"),$("#editPlanModal").modal("show")},submitEditPlan:function(){$("#editPlanModal").modal("hide"),window.App.clusterPlan.cleanUp();var a=window.App.clusterPlan;return a.isTestSetup()?void window.App.navigate("planTest",{trigger:!0}):void window.App.navigate("planAsymmetrical",{trigger:!0})},deletePlan:function(){$("#editPlanModal").modal("hide"),$("#deletePlanModal").modal("show")},submitDeletePlan:function(){$("#deletePlanModal").modal("hide"),window.App.clusterPlan.cleanUp(),window.App.clusterPlan.destroy(),window.App.clusterPlan=new window.ClusterPlan,window.App.planScenario()}})}(),function(){"use strict";window.ClusterUnreachableView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("clusterUnreachable.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),events:{"click #clusterShutdown":"shutdown"},initialize:function(){this.coordinators=new window.ClusterCoordinators([],{})},retryCounter:0,retryNavigation:function(){var a=this;if(10===this.retryCounter){this.retryCounter=0;var b=new XMLHttpRequest;b.open("GET",window.location.origin+window.location.pathname,!1),b.send(),200===b.status?window.location.reload():window.setTimeout(function(){a.retryCounter++,a.retryNavigation()},1e3)}else this.retryCounter++,window.setTimeout(function(){a.retryNavigation()},1e3)},retryConnection:function(){this.coordinators.checkConnection(function(){window.App.showCluster()}),this.retryNavigation()},shutdown:function(){window.clearTimeout(this.timer),window.App.shutdownView.clusterShutdown()},render:function(){var a=window.App.clusterPlan,b=[];if(a&&a.has("runInfo")){var c=_.where(a.get("runInfo"),{isStartServers:!0});_.each(_.filter(c,function(a){return _.contains(a.roles,"Coordinator")}),function(a){var c=a.endpoints[0].split("://")[1];c=c.split(":")[0],b.push(c)})}$(this.el).html(this.template.render({coordinators:b})),$(this.el).append(this.modal.render({})),this.timer=window.setTimeout(this.retryConnection.bind(this),1e4)}})}(),function(){"use strict";window.ServerDashboardView=window.DashboardView.extend({modal:!0,hide:function(){window.App.showClusterView.startUpdating(),this.stopUpdating()},render:function(){var a=this;window.modalView.hideFooter=!0,window.modalView.show("dashboardView.ejs",null,void 0,void 0,void 0,this.events),$("#modal-dialog").toggleClass("modal-chart-detail",!0),window.DashboardView.prototype.render.bind(this)(!0),window.modalView.hideFooter=!1,$("#modal-dialog").on("hidden",function(){a.hide()});var b=document.createElement("button");b.className="close",b.appendChild(document.createTextNode("×")),b=$(b),b.attr("data-dismiss","modal"),b.attr("aria-hidden","true"),b.attr("type","button"),$(".modal-body .headerBar:first-child").toggleClass("headerBar",!1).toggleClass("modal-dashboard-header",!0).append(b)}})}(),function(){"use strict";window.LoginModalView=Backbone.View.extend({template:templateEngine.createTemplate("loginModal.ejs"),el:"#modalPlaceholder",events:{"click #confirmLogin":"confirmLogin","hidden #loginModalLayer":"hidden"},hidden:function(){this.undelegateEvents(),window.App.isCheckingUser=!1,$(this.el).html("")},confirmLogin:function(){var a=$("#username").val(),b=$("#password").val();window.App.clusterPlan.storeCredentials(a,b),this.hideModal()},hideModal:function(){$("#loginModalLayer").modal("hide")},render:function(){$(this.el).html(this.template.render({})),$("#loginModalLayer").modal("show")}})}(),function(){"use strict";window.PlanScenarioSelectorView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("planScenarioSelector.ejs","planner"),events:{"click #multiServerAsymmetrical":"multiServerAsymmetrical","click #singleServer":"singleServer"},render:function(){$(this.el).html(this.template.render({}))},multiServerAsymmetrical:function(){window.App.navigate("planAsymmetrical",{trigger:!0})},singleServer:function(){window.App.navigate("planTest",{trigger:!0})}})}(),function(){"use strict";window.PlanSymmetricView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("symmetricPlan.ejs"),entryTemplate:templateEngine.createTemplate("serverEntry.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),connectionValidationKey:null,events:{"click #startSymmetricPlan":"startPlan","click .add":"addEntry","click .delete":"removeEntry","click #cancel":"cancel","click #test-all-connections":"checkAllConnections","focusout .host":"checkAllConnections","focusout .port":"checkAllConnections","focusout .user":"checkAllConnections","focusout .passwd":"checkAllConnections"},cancel:function(){window.App.clusterPlan.get("plan")?window.App.navigate("handleClusterDown",{trigger:!0}):window.App.navigate("planScenario",{trigger:!0})},startPlan:function(){var a=this,b={dispatchers:[]},c=!1,d=!1;if(b.useSSLonDBservers=!!$(".useSSLonDBservers").prop("checked"),b.useSSLonCoordinators=!!$(".useSSLonCoordinators").prop("checked"),$(".dispatcher").each(function(e,f){var g=$(".host",f).val(),h=$(".port",f).val(),i=$(".user",f).val(),j=$(".passwd",f).val();if(!g||0===g.length||!h||0===h.length)return!0;var k={host:g+":"+h};a.isSymmetric?(k.isDBServer=!0,k.isCoordinator=!0):(k.isDBServer=!!$(".isDBServer",f).prop("checked"),k.isCoordinator=!!$(".isCoordinator",f).prop("checked")),k.username=i,k.passwd=j,c=c||k.isCoordinator,d=d||k.isDBServer,b.dispatchers.push(k)}),a.isSymmetric){if(0===b.dispatchers.length)return void alert("Please provide at least one host")}else{if(!d)return void alert("Please provide at least one database server");if(!c)return void alert("Please provide at least one coordinator")}b.type=this.isSymmetric?"symmetricalSetup":"asymmetricalSetup",$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster is being launched"),delete window.App.clusterPlan._coord,window.App.clusterPlan.save(b,{success:function(){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.updateAllUrls(),window.App.navigate("showCluster",{trigger:!0})},error:function(a,b){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),alert("Error while starting the cluster: "+b.statusText)}})},addEntry:function(){this.disableLaunchButton();var a=$("#server_list div.control-group.dispatcher:last .user").val(),b=$("#server_list div.control-group.dispatcher:last .passwd").val();$("#server_list").append(this.entryTemplate.render({isSymmetric:this.isSymmetric,isFirst:!1,isCoordinator:!0,isDBServer:!0,host:"",port:"",user:a,passwd:b}))},removeEntry:function(a){$(a.currentTarget).closest(".control-group").remove(),this.checkAllConnections()},render:function(a){var b={},c=!0,d=window.App.clusterPlan.get("config");if(this.isSymmetric=a,$(this.el).html(this.template.render({isSymmetric:a,params:b,useSSLonDBservers:d&&d.useSSLonDBservers?d.useSSLonDBservers:!1,useSSLonCoordinators:d&&d.useSSLonCoordinators?d.useSSLonCoordinators:!1})),d){var e=this,f=!1,g=!1;_.each(d.dispatchers,function(b){g=void 0===b.allowDBservers?!0:b.allowDBservers,f=void 0===b.allowCoordinators?!0:b.allowCoordinators;var d=b.endpoint;d=d.split("//")[1],d=d.split(":"),"localhost"===d&&(d="127.0.0.1");var h=b.username,i=b.passwd,j=e.entryTemplate.render({isSymmetric:a,isFirst:c,host:d[0],port:d[1],isCoordinator:f,isDBServer:g,user:h,passwd:i});$("#server_list").append(j),c=!1})}else $("#server_list").append(this.entryTemplate.render({isSymmetric:a,isFirst:!0,isCoordinator:!0,isDBServer:!0,host:"",port:"",user:"",passwd:""}));this.disableLaunchButton(),$(this.el).append(this.modal.render({}))},readAllConnections:function(){var a=[];return $(".dispatcher").each(function(b,c){var d={host:$(".host",c).val(),port:$(".port",c).val(),user:$(".user",c).val(),passwd:$(".passwd",c).val()};d.host&&d.port&&a.push(d)}),a},checkAllConnections:function(){var a=this,b=Math.random();this.connectionValidationKey=b,$(".cluster-connection-check-success").remove(),$(".cluster-connection-check-fail").remove();var c=this.readAllConnections();if(c.length)try{$.ajax({async:!0,cache:!1,type:"POST",url:"/_admin/aardvark/cluster/communicationCheck",data:JSON.stringify(c),success:function(c){if(b===a.connectionValidationKey){var d=$(".dispatcher"),e=0;d.each(function(a,b){var d=$(".host",b).val(),f=$(".port",b).val();d&&f&&(c[e]?$(".controls:first",b).append('Connection: ok'):$(".controls:first",b).append('Connection: fail'),e++)}),a.checkDispatcherArray(c,b)}}})}catch(d){this.disableLaunchButton()}},checkDispatcherArray:function(a,b){_.every(a,function(a){return a})&&b===this.connectionValidationKey&&this.enableLaunchButton()},disableLaunchButton:function(){$("#startSymmetricPlan").attr("disabled","disabled"),$("#startSymmetricPlan").removeClass("button-success"),$("#startSymmetricPlan").addClass("button-neutral")},enableLaunchButton:function(){$("#startSymmetricPlan").attr("disabled",!1),$("#startSymmetricPlan").removeClass("button-neutral"),$("#startSymmetricPlan").addClass("button-success")}})}(),function(){"use strict";window.PlanTestView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("testPlan.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),events:{"click #startTestPlan":"startPlan","click #cancel":"cancel"},cancel:function(){window.App.clusterPlan.get("plan")?window.App.navigate("handleClusterDown",{trigger:!0}):window.App.navigate("planScenario",{trigger:!0})},startPlan:function(){$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster is being launched");var a=$("#host").val(),b=$("#port").val(),c=$("#coordinators").val(),d=$("#dbs").val();return a?b?!c||0>c?void alert("Please define a number of coordinators"):!d||0>d?void alert("Please define a number of database servers"):(delete window.App.clusterPlan._coord,void window.App.clusterPlan.save({type:"testSetup",dispatchers:a+":"+b,numberDBServers:parseInt(d,10),numberCoordinators:parseInt(c,10)},{success:function(){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.updateAllUrls(),window.App.navigate("showCluster",{trigger:!0})},error:function(a,b){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),alert("Error while starting the cluster: "+b.statusText)}})):void alert("Please define a port"):void alert("Please define a host")},render:function(){var a={},b=window.App.clusterPlan.get("config");if(b){a.dbs=b.numberOfDBservers,a.coords=b.numberOfCoordinators;var c=b.dispatchers.d1.endpoint;c=c.split("://")[1],c=c.split(":"),"localhost"===c&&(c="127.0.0.1"),a.hostname=c[0],a.port=c[1]}else a.dbs=3,a.coords=2,a.hostname=window.location.hostname,"localhost"===a.hostname&&(a.hostname="127.0.0.1"),a.port=window.location.port;$(this.el).html(this.template.render(a)),$(this.el).append(this.modal.render({}))}})}(),function(){"use strict";window.ShowClusterView=Backbone.View.extend({detailEl:"#modalPlaceholder",el:"#content",defaultFrame:12e5,template:templateEngine.createTemplate("showCluster.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),detailTemplate:templateEngine.createTemplate("detailView.ejs"),events:{"change #selectDB":"updateCollections","change #selectCol":"updateShards","click .dbserver.success":"dashboard","click .coordinator.success":"dashboard"},replaceSVGs:function(){$(".svgToReplace").each(function(){var a=$(this),b=a.attr("id"),c=a.attr("src");$.get(c,function(c){var d=$(c).find("svg");d.attr("id",b).attr("class","icon").removeAttr("xmlns:a"),a.replaceWith(d)},"xml")})},updateServerTime:function(){this.serverTime=(new Date).getTime()},setShowAll:function(){this.graphShowAll=!0},resetShowAll:function(){this.graphShowAll=!1,this.renderLineChart()},initialize:function(){this.interval=1e4,this.isUpdating=!1,this.timer=null,this.knownServers=[],this.graph=void 0,this.graphShowAll=!1,this.updateServerTime(),this.dygraphConfig=this.options.dygraphConfig,this.dbservers=new window.ClusterServers([],{interval:this.interval}),this.coordinators=new window.ClusterCoordinators([],{interval:this.interval}),this.documentStore=new window.arangoDocuments,this.statisticsDescription=new window.StatisticsDescription,this.statisticsDescription.fetch({async:!1}),this.dbs=new window.ClusterDatabases([],{interval:this.interval}),this.cols=new window.ClusterCollections,this.shards=new window.ClusterShards,this.startUpdating()},listByAddress:function(a){var b={},c=this;this.dbservers.byAddress(b,function(b){c.coordinators.byAddress(b,a)})},updateCollections:function(){var a=this,b=$("#selectCol"),c=$("#selectDB").find(":selected").attr("id");if(c){var d=b.find(":selected").attr("id");b.html(""),this.cols.getList(c,function(c){_.each(_.pluck(c,"name"),function(a){b.append('")});var e=$("#"+d,b);1===e.length&&e.prop("selected",!0),a.updateShards()})}},updateShards:function(){var a=$("#selectDB").find(":selected").attr("id"),b=$("#selectCol").find(":selected").attr("id");this.shards.getList(a,b,function(a){$(".shardCounter").html("0"),_.each(a,function(a){$("#"+a.server+"Shards").html(a.shards.length)})})},updateServerStatus:function(a){var b=this,c=function(a,b,c){var d,e,f=c;f=f.replace(/\./g,"-"),f=f.replace(/\:/g,"_"),e=$("#id"+f),e.length<1||(d=e.attr("class").split(/\s+/)[1],e.attr("class",a+" "+d+" "+b),"coordinator"===a&&("success"===b?$(".button-gui",e.closest(".tile")).toggleClass("button-gui-disabled",!1):$(".button-gui",e.closest(".tile")).toggleClass("button-gui-disabled",!0)))};this.coordinators.getStatuses(c.bind(this,"coordinator"),function(){b.dbservers.getStatuses(c.bind(b,"dbserver")),a()})},updateDBDetailList:function(){var a=this,b=$("#selectDB"),c=b.find(":selected").attr("id");b.html(""),this.dbs.getList(function(d){_.each(_.pluck(d,"name"),function(a){b.append('")});var e=$("#"+c,b);1===e.length&&e.prop("selected",!0),a.updateCollections()})},rerender:function(){var a=this;this.updateServerStatus(function(){a.getServerStatistics(function(){a.updateServerTime(),a.data=a.generatePieData(),a.renderPieChart(a.data),a.renderLineChart(),a.updateDBDetailList()})})},render:function(){this.knownServers=[],delete this.hist;var a=this;this.listByAddress(function(b){1===Object.keys(b).length?a.type="testPlan":a.type="other",a.updateDBDetailList(),a.dbs.getList(function(c){$(a.el).html(a.template.render({dbs:_.pluck(c,"name"),byAddress:b,type:a.type})),$(a.el).append(a.modal.render({})),a.replaceSVGs(),a.getServerStatistics(function(){a.data=a.generatePieData(),a.renderPieChart(a.data),a.renderLineChart(),a.updateDBDetailList(),a.startUpdating()})})})},generatePieData:function(){var a=[],b=this;return this.data.forEach(function(c){a.push({key:c.get("name"),value:c.get("system").virtualSize,time:b.serverTime})}),a},addStatisticsItem:function(a,b,c,d){var e=this;e.hasOwnProperty("hist")||(e.hist={}),e.hist.hasOwnProperty(a)||(e.hist[a]=[]);var f=e.hist[a],g=f.length;if(0===g)f.push({time:b,snap:d,requests:c,requestsPerSecond:0});else{var h=f[g-1].time,i=f[g-1].requests;if(c>i){var j=b-h,k=0;j>0&&(k=(c-i)/j),f.push({time:b,snap:d,requests:c,requestsPerSecond:k})}}},getServerStatistics:function(a){var b=this,c=Math.round(b.serverTime/1e3);this.data=void 0;var d=new window.ClusterStatisticsCollection,e=this.coordinators.first();this.dbservers.forEach(function(a){if("ok"===a.get("status")){-1===b.knownServers.indexOf(a.id)&&b.knownServers.push(a.id);var c=new window.Statistics({name:a.id});c.url=e.get("protocol")+"://"+e.get("address")+"/_admin/clusterStatistics?DBserver="+a.get("name"),d.add(c)}}),this.coordinators.forEach(function(a){if("ok"===a.get("status")){-1===b.knownServers.indexOf(a.id)&&b.knownServers.push(a.id);var c=new window.Statistics({name:a.id});c.url=a.get("protocol")+"://"+a.get("address")+"/_admin/statistics",d.add(c)}});var f=d.size();this.data=[];var g=function(d){f--;var e=d.get("time"),g=d.get("name"),h=d.get("http").requestsTotal;b.addStatisticsItem(g,e,h,c),b.data.push(d),0===f&&a()},h=function(){f--,0===f&&a()};d.fetch(g,h)},renderPieChart:function(a){var b=$("#clusterGraphs svg").width(),c=$("#clusterGraphs svg").height(),d=Math.min(b,c)/2,e=this.dygraphConfig.colors,f=d3.svg.arc().outerRadius(d-20).innerRadius(0),g=d3.layout.pie().sort(function(a){return a.value}).value(function(a){return a.value});d3.select("#clusterGraphs").select("svg").remove();var h=d3.select("#clusterGraphs").append("svg").attr("class","clusterChart").append("g").attr("transform","translate("+b/2+","+(c/2-10)+")"),i=d3.svg.arc().outerRadius(d-2).innerRadius(d-2),j=h.selectAll(".arc").data(g(a)).enter().append("g").attr("class","slice");j.append("path").attr("d",f).style("fill",function(a,b){return e[b%e.length]}).style("stroke",function(a,b){return e[b%e.length]}),j.append("text").attr("transform",function(a){return"translate("+f.centroid(a)+")"}).style("text-anchor","middle").text(function(a){var b=a.data.value/1024/1024/1024;return b.toFixed(2)}),j.append("text").attr("transform",function(a){return"translate("+i.centroid(a)+")"}).style("text-anchor","middle").text(function(a){return a.data.key})},renderLineChart:function(){var a,b,c,d,e,f,g=this,h=1200,i=[],j=[],k=Math.round((new Date).getTime()/1e3)-h,l=g.knownServers,m=function(){return null};for(c=0;cf||(j.hasOwnProperty(f)?a=j[f]:(e=new Date(1e3*f),a=j[f]=[e].concat(l.map(m))),a[c+1]=b[d].requestsPerSecond);i=[],Object.keys(j).sort().forEach(function(a){i.push(j[a])});var n=this.dygraphConfig.getDefaultConfig("clusterRequestsPerSecond");n.labelsDiv=$("#lineGraphLegend")[0],n.labels=["datetime"].concat(l),g.graph=new Dygraph(document.getElementById("lineGraph"),i,n)},stopUpdating:function(){window.clearTimeout(this.timer),delete this.graph,this.isUpdating=!1},startUpdating:function(){if(!this.isUpdating){this.isUpdating=!0;var a=this;this.timer=window.setInterval(function(){a.rerender()},this.interval)}},dashboard:function(a){this.stopUpdating();var b,c,d=$(a.currentTarget),e={},f=d.attr("id");f=f.replace(/\-/g,"."),f=f.replace(/\_/g,":"),f=f.substr(2),e.raw=f,e.isDBServer=d.hasClass("dbserver"),e.isDBServer?(b=this.dbservers.findWhere({address:e.raw}),c=this.coordinators.findWhere({status:"ok"}),e.endpoint=c.get("protocol")+"://"+c.get("address")):(b=this.coordinators.findWhere({address:e.raw}),e.endpoint=b.get("protocol")+"://"+b.get("address")), -e.target=encodeURIComponent(b.get("name")),window.App.serverToShow=e,window.App.dashboard()},getCurrentSize:function(a){"#"!==a.substr(0,1)&&(a="#"+a);var b,c;return $(a).attr("style",""),b=$(a).height(),c=$(a).width(),{height:b,width:c}},resize:function(){var a;this.graph&&(a=this.getCurrentSize(this.graph.maindiv_.id),this.graph.resize(a.width,a.height))}})}(),function(){"use strict";window.ShowShardsView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("showShards.ejs"),events:{"change #selectDB":"updateCollections","change #selectCol":"updateShards"},initialize:function(){this.dbservers=new window.ClusterServers([],{interval:1e4}),this.dbservers.fetch({async:!1,beforeSend:window.App.addAuth.bind(window.App)}),this.dbs=new window.ClusterDatabases([],{interval:1e4}),this.cols=new window.ClusterCollections,this.shards=new window.ClusterShards},updateCollections:function(){var a=$("#selectDB").find(":selected").attr("id");$("#selectCol").html(""),_.each(_.pluck(this.cols.getList(a),"name"),function(a){$("#selectCol").append('")}),this.updateShards()},updateShards:function(){var a=$("#selectDB").find(":selected").attr("id"),b=$("#selectCol").find(":selected").attr("id"),c=this.shards.getList(a,b);$(".shardContainer").empty(),_.each(c,function(a){var b=$("#"+a.server+"Shards");$(".collectionName",b).html(a.server+": "+a.shards.length)})},render:function(){$(this.el).html(this.template.render({names:this.dbservers.pluck("name"),dbs:_.pluck(this.dbs.getList(),"name")})),this.updateCollections()}})}(),function(){"use strict";window.ShutdownButtonView=Backbone.View.extend({el:"#navigationBar",events:{"click #clusterShutdown":"clusterShutdown"},initialize:function(){this.overview=this.options.overview},template:templateEngine.createTemplate("shutdownButtonView.ejs"),clusterShutdown:function(){this.overview.stopUpdating(),$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster is shutting down"),$.ajax({cache:!1,type:"GET",url:"cluster/shutdown",success:function(a){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.navigate("handleClusterDown",{trigger:!0})}})},render:function(){return $(this.el).html(this.template.render({})),this},unrender:function(){$(this.el).html("")}})}(),function(){"use strict";window.ClusterRouter=Backbone.Router.extend({routes:{"":"initialRoute",planScenario:"planScenario",planTest:"planTest",planAsymmetrical:"planAsymmetric",shards:"showShards",showCluster:"showCluster",handleClusterDown:"handleClusterDown"},addAuth:function(a){var b=this.clusterPlan.get("user");if(!b)return a.abort(),void(this.isCheckingUser||this.requestAuth());var c=b.name,d=b.passwd,e=c.concat(":",d);a.setRequestHeader("Authorization","Basic "+btoa(e))},requestAuth:function(){this.isCheckingUser=!0,this.clusterPlan.set({user:null});var a=new window.LoginModalView;a.render()},getNewRoute:function(a){return"statistics"===a?this.clusterPlan.getCoordinator()+"/_admin/"+a:this.clusterPlan.getCoordinator()+"/_admin/aardvark/cluster/"+a},initialRoute:function(){this.initial()},updateAllUrls:function(){_.each(this.toUpdate,function(a){a.updateUrl()})},registerForUpdate:function(a){this.toUpdate.push(a),a.updateUrl()},initialize:function(){this.footerView=new window.FooterView,this.footerView.render();var a=this;this.dygraphConfig=window.dygraphConfig,window.modalView=new window.ModalView,this.initial=this.planScenario,this.isCheckingUser=!1,this.bind("all",function(b,c){b.split(":");"route"===b&&"showCluster"!==c&&(a.showClusterView&&(a.showClusterView.stopUpdating(),a.shutdownView.unrender()),a.dashboardView&&a.dashboardView.stopUpdating())}),this.toUpdate=[],this.clusterPlan=new window.ClusterPlan,this.clusterPlan.fetch({async:!1}),$(window).resize(function(){a.handleResize()})},showCluster:function(){this.showClusterView||(this.showClusterView=new window.ShowClusterView({dygraphConfig:this.dygraphConfig})),this.shutdownView||(this.shutdownView=new window.ShutdownButtonView({overview:this.showClusterView})),this.shutdownView.render(),this.showClusterView.render()},showShards:function(){this.showShardsView||(this.showShardsView=new window.ShowShardsView),this.showShardsView.render()},handleResize:function(){this.dashboardView&&this.dashboardView.resize(),this.showClusterView&&this.showClusterView.resize()},planTest:function(){this.planTestView||(this.planTestView=new window.PlanTestView({model:this.clusterPlan})),this.planTestView.render()},planAsymmetric:function(){this.planSymmetricView||(this.planSymmetricView=new window.PlanSymmetricView({model:this.clusterPlan})),this.planSymmetricView.render(!1)},planScenario:function(){this.planScenarioSelector||(this.planScenarioSelector=new window.PlanScenarioSelectorView),this.planScenarioSelector.render()},handleClusterDown:function(){this.clusterDownView||(this.clusterDownView=new window.ClusterDownView),this.clusterDownView.render()},dashboard:function(){var a=this.serverToShow;return a?(a.addAuth=this.addAuth.bind(this),this.dashboardView=new window.ServerDashboardView({dygraphConfig:this.dygraphConfig,serverToShow:this.serverToShow,database:{hasSystemAccess:function(){return!0}}}),void this.dashboardView.render()):void this.navigate("",{trigger:!0})},clusterUnreachable:function(){this.showClusterView&&(this.showClusterView.stopUpdating(),this.shutdownView.unrender()),this.unreachableView||(this.unreachableView=new window.ClusterUnreachableView),this.unreachableView.render()}})}(),function(){"use strict";$.get("cluster/amIDispatcher",function(a){if(!a){var b=window.location.origin;b+=window.location.pathname,b=b.replace("cluster","index"),window.location.replace(b)}}),window.location.hash="",$(document).ready(function(){window.App=new window.ClusterRouter,Backbone.history.start(),window.App.clusterPlan.get("plan")?window.App.clusterPlan.isAlive()?window.App.initial=window.App.showCluster:window.App.initial=window.App.handleClusterDown:window.App.initial=window.App.planScenario,window.App.initialRoute(),window.App.handleResize()})}(); \ No newline at end of file +!function(){"use strict";var a;window.isCoordinator=function(){return void 0===a&&$.ajax("cluster/amICoordinator",{async:!1,success:function(b){a=b}}),a},window.versionHelper={fromString:function(a){var b=a.replace(/-[a-zA-Z0-9_\-]*$/g,"").split(".");return{major:parseInt(b[0],10)||0,minor:parseInt(b[1],10)||0,patch:parseInt(b[2],10)||0,toString:function(){return this.major+"."+this.minor+"."+this.patch}}},toString:function(a){return a.major+"."+a.minor+"."+a.patch}},window.arangoHelper={lastNotificationMessage:null,CollectionTypes:{},systemAttributes:function(){return{_id:!0,_rev:!0,_key:!0,_bidirectional:!0,_vertices:!0,_from:!0,_to:!0,$id:!0}},setCheckboxStatus:function(a){_.each($(a).find("ul").find("li"),function(a){$(a).hasClass("nav-header")||($(a).find("input").attr("checked")?$(a).find("i").hasClass("css-round-label")?$(a).find("i").addClass("fa-dot-circle-o"):$(a).find("i").addClass("fa-check-square-o"):$(a).find("i").hasClass("css-round-label")?$(a).find("i").addClass("fa-circle-o"):$(a).find("i").addClass("fa-square-o"))})},calculateCenterDivHeight:function(){var a=$(".navbar").height(),b=$(".footer").height(),c=$(window).height();return c-b-a-110},fixTooltips:function(a,b){$(a).tooltip({placement:b,hide:!1,show:!1})},currentDatabase:function(){var a=!1;return $.ajax({type:"GET",cache:!1,url:"/_api/database/current",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b.result.name},error:function(){a=!1}}),a},allHotkeys:{global:{name:"Site wide",content:[{label:"scroll up",letter:"j"},{label:"scroll down",letter:"k"}]},jsoneditor:{name:"AQL editor",content:[{label:"Submit",letter:"Ctrl + Return"},{label:"Toggle comments",letter:"Ctrl + Shift + C"},{label:"Undo",letter:"Ctrl + Z"},{label:"Redo",letter:"Ctrl + Shift + Z"}]},doceditor:{name:"Document editor",content:[{label:"Insert",letter:"Ctrl + Insert"},{label:"Save",letter:"Ctrl + Return, CMD + Return"},{label:"Append",letter:"Ctrl + Shift + Insert"},{label:"Duplicate",letter:"Ctrl + D"},{label:"Remove",letter:"Ctrl + Delete"}]},modals:{name:"Modal",content:[{label:"Submit",letter:"Return"},{label:"Close",letter:"Esc"},{label:"Navigate buttons",letter:"Arrow keys"},{label:"Navigate content",letter:"Tab"}]}},hotkeysFunctions:{scrollDown:function(){window.scrollBy(0,180)},scrollUp:function(){window.scrollBy(0,-180)},showHotkeysModal:function(){var a=[],b=window.arangoHelper.allHotkeys;window.modalView.show("modalHotkeys.ejs","Keyboard Shortcuts",a,b)}},enableKeyboardHotkeys:function(a){var b=window.arangoHelper.hotkeysFunctions;a===!0&&($(document).on("keydown",null,"j",b.scrollDown),$(document).on("keydown",null,"k",b.scrollUp))},databaseAllowed:function(){var a=this.currentDatabase(),b=!1;return $.ajax({type:"GET",cache:!1,url:"/_db/"+encodeURIComponent(a)+"/_api/database/",contentType:"application/json",processData:!1,async:!1,success:function(){b=!0},error:function(){b=!1}}),b},arangoNotification:function(a,b,c){window.App.notificationList.add({title:a,content:b,info:c,type:"success"})},arangoError:function(a,b,c){window.App.notificationList.add({title:a,content:b,info:c,type:"error"})},openDocEditor:function(a,b,c){var d=a.split("/"),e=this,f=new window.DocumentView({collection:window.App.arangoDocumentStore});f.breadcrumb=function(){},f.colid=d[0],f.docid=d[1],f.el=".arangoFrame .innerDiv",f.render(),f.setType(b),$(".arangoFrame .headerBar").remove(),$(".arangoFrame .outerDiv").prepend(''),$(".arangoFrame .outerDiv").click(function(){e.closeDocEditor()}),$(".arangoFrame .innerDiv").click(function(a){a.stopPropagation()}),$(".fa-times").click(function(){e.closeDocEditor()}),$(".arangoFrame").show(),f.customView=!0,f.customDeleteFunction=function(){window.modalView.hide(),$(".arangoFrame").hide()},$(".arangoFrame #deleteDocumentButton").click(function(){f.deleteDocumentModal()}),$(".arangoFrame #saveDocumentButton").click(function(){f.saveDocument()}),$(".arangoFrame #deleteDocumentButton").css("display","none")},closeDocEditor:function(){$(".arangoFrame .outerDiv .fa-times").remove(),$(".arangoFrame").hide()},addAardvarkJob:function(a,b){$.ajax({cache:!1,type:"POST",url:"/_admin/aardvark/job",data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a){b&&b(!1,a)},error:function(a){b&&b(!0,a)}})},deleteAardvarkJob:function(a,b){$.ajax({cache:!1,type:"DELETE",url:"/_admin/aardvark/job/"+encodeURIComponent(a),contentType:"application/json",processData:!1,success:function(a){b&&b(!1,a)},error:function(a){b&&b(!0,a)}})},deleteAllAardvarkJobs:function(a){$.ajax({cache:!1,type:"DELETE",url:"/_admin/aardvark/job",contentType:"application/json",processData:!1,success:function(b){a&&a(!1,b)},error:function(b){a&&a(!0,b)}})},getAardvarkJobs:function(a){var b;return $.ajax({cache:!1,type:"GET",url:"/_admin/aardvark/job",contentType:"application/json",processData:!1,async:!1,success:function(c){a&&a(!1,c),b=c},error:function(b){a&&a(!0,b)}}),b},getPendingJobs:function(){var a;return $.ajax({cache:!1,type:"GET",url:"/_api/job/pending",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(a){console.log("pending jobs error: "+a)}}),a},syncAndReturnUninishedAardvarkJobs:function(a){var b=this.getAardvarkJobs(),c=this.getPendingJobs(),d=[];return c.length>0?_.each(b,function(b){if(b.type===a||void 0===b.type){var e=!1;_.each(c,function(a){b.id===a&&(e=!0)}),e?d.push({collection:b.collection,id:b.id,type:b.type}):window.arangoHelper.deleteAardvarkJob(b.id)}}):this.deleteAllAardvarkJobs(),d},getRandomToken:function(){return Math.round((new Date).getTime())},isSystemAttribute:function(a){var b=this.systemAttributes();return b[a]},isSystemCollection:function(a){return"_"===a.name.substr(0,1)},setDocumentStore:function(a){this.arangoDocumentStore=a},collectionApiType:function(a,b){return(b||void 0===this.CollectionTypes[a])&&(this.CollectionTypes[a]=this.arangoDocumentStore.getCollectionInfo(a).type),3===this.CollectionTypes[a]?"edge":"document"},collectionType:function(a){if(!a||""===a.name)return"-";var b;return b=2===a.type?"document":3===a.type?"edge":"unknown",this.isSystemCollection(a)&&(b+=" (system)"),b},formatDT:function(a){var b=function(a){return 10>a?"0"+a:a};return a.getUTCFullYear()+"-"+b(a.getUTCMonth()+1)+"-"+b(a.getUTCDate())+" "+b(a.getUTCHours())+":"+b(a.getUTCMinutes())+":"+b(a.getUTCSeconds())},escapeHtml:function(a){return String(a).replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}}}(),function(){"use strict";window.ClusterCollection=Backbone.Model.extend({defaults:{name:"",status:"ok"},idAttribute:"name",forList:function(){return{name:this.get("name"),status:this.get("status")}}})}(),function(){"use strict";window.ClusterCoordinator=Backbone.Model.extend({defaults:{name:"",url:"",status:"ok"},idAttribute:"name",forList:function(){return{name:this.get("name"),status:this.get("status"),url:this.get("url")}}})}(),function(){"use strict";window.ClusterDatabase=Backbone.Model.extend({defaults:{name:"",status:"ok"},idAttribute:"name",forList:function(){return{name:this.get("name"),status:this.get("status")}}})}(),function(){"use strict";window.ClusterPlan=Backbone.Model.extend({defaults:{},url:"cluster/plan",idAttribute:"config",getVersion:function(){var a=this.get("version");return a||"2.0"},getCoordinator:function(){if(this._coord)return this._coord[this._lastStableCoord];var a,b,c,d,e=[];if(c=this.get("runInfo")){for(b=c.length-1;b>0;){if(c[b].isStartServers&&(d=c[b],d.endpoints))for(a=0;a1){do a=Math.floor(Math.random()*this._coord.length);while(a===b);this._lastStableCoord=a}},isAlive:function(){var a=!1;return $.ajax({cache:!1,type:"GET",async:!1,url:"cluster/healthcheck",success:function(b){a=b},error:function(a){}}),a},storeCredentials:function(a,b){var c=this;$.ajax({url:"cluster/plan/credentials",type:"PUT",data:JSON.stringify({user:a,passwd:b}),async:!1}).done(function(){c.fetch()})},isSymmetricSetup:function(){var a=this.get("config"),b=_.size(a.dispatchers);return b===a.numberOfCoordinators&&b===a.numberOfDBservers},isTestSetup:function(){return 1===_.size(this.get("config").dispatchers)},cleanUp:function(){$.ajax({url:"cluster/plan/cleanUp",type:"DELETE",async:!1})}})}(),function(){"use strict";window.ClusterServer=Backbone.Model.extend({defaults:{name:"",address:"",role:"",status:"ok"},idAttribute:"name",forList:function(){return{name:this.get("name"),address:this.get("address"),status:this.get("status")}}})}(),function(){"use strict";window.ClusterShard=Backbone.Model.extend({defaults:{},idAttribute:"name",forList:function(){return{server:this.get("name"),shards:this.get("shards")}}})}(),function(){"use strict";window.ClusterType=Backbone.Model.extend({defaults:{type:"testPlan"}})}(),function(){"use strict";window.AutomaticRetryCollection=Backbone.Collection.extend({_retryCount:0,checkRetries:function(){var a=this;return this.updateUrl(),this._retryCount>10?(window.setTimeout(function(){a._retryCount=0},1e4),window.App.clusterUnreachable(),!1):!0},successFullTry:function(){this._retryCount=0},failureTry:function(a,b,c){401===c.status?window.App.requestAuth():(window.App.clusterPlan.rotateCoordinator(),this._retryCount++,a())}})}(),window.ClusterStatisticsCollection=Backbone.Collection.extend({model:window.Statistics,url:"/_admin/statistics",updateUrl:function(){this.url=window.App.getNewRoute("statistics")},initialize:function(){window.App.registerForUpdate(this)},fetch:function(a,b){this.forEach(function(c){c.fetch({beforeSend:window.App.addAuth.bind(window.App),error:function(){b(c)}}).done(function(){a(c)})})}}),function(){"use strict";window.ClusterCollections=window.AutomaticRetryCollection.extend({model:window.ClusterCollection,updateUrl:function(){this.url=window.App.getNewRoute(this.dbname+"/Collections")},url:function(){return"/_admin/aardvark/cluster/"+this.dbname+"/Collections"},initialize:function(){this.isUpdating=!1,this.timer=null,this.interval=1e3,window.App.registerForUpdate(this)},getList:function(a,b){if(void 0!==a&&(this.dbname=a,this.checkRetries())){var c=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:c.failureTry.bind(c,c.getList.bind(c,a,b))}).done(function(){b(c.map(function(a){return a.forList()}))})}},stopUpdating:function(){window.clearTimeout(this.timer),this.isUpdating=!1},startUpdating:function(){if(!this.isUpdating){this.isUpdating=!0;var a=this;this.timer=window.setInterval(function(){a.updateUrl(),a.fetch({beforeSend:window.App.addAuth.bind(window.App)})},this.interval)}}})}(),function(){"use strict";window.ClusterCoordinators=window.AutomaticRetryCollection.extend({model:window.ClusterCoordinator,url:"/_admin/aardvark/cluster/Coordinators",updateUrl:function(){this.url=window.App.getNewRoute("Coordinators")},initialize:function(){window.App.registerForUpdate(this)},statusClass:function(a){switch(a){case"ok":return"success";case"warning":return"warning";case"critical":return"danger";case"missing":return"inactive";default:return"danger"}},getStatuses:function(a,b){if(this.checkRetries()){var c=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:c.failureTry.bind(c,c.getStatuses.bind(c,a,b))}).done(function(){c.successFullTry(),c.forEach(function(b){a(c.statusClass(b.get("status")),b.get("address"))}),b()})}},byAddress:function(a,b){if(this.checkRetries()){var c=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:c.failureTry.bind(c,c.byAddress.bind(c,a,b))}).done(function(){c.successFullTry(),a=a||{},c.forEach(function(b){var c=b.get("address");c=c.split(":")[0],a[c]=a[c]||{},a[c].coords=a[c].coords||[],a[c].coords.push(b)}),b(a)})}},checkConnection:function(a){var b=this;this.checkRetries()&&this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:b.failureTry.bind(b,b.checkConnection.bind(b,a))}).done(function(){b.successFullTry(),a()})},getList:function(){throw"Do not use coordinator.getList"},getOverview:function(){throw"Do not use coordinator.getOverview"}})}(),function(){"use strict";window.ClusterDatabases=window.AutomaticRetryCollection.extend({model:window.ClusterDatabase,url:"/_admin/aardvark/cluster/Databases",updateUrl:function(){this.url=window.App.getNewRoute("Databases")},initialize:function(){window.App.registerForUpdate(this)},getList:function(a){if(this.checkRetries()){var b=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:b.failureTry.bind(b,b.getList.bind(b,a))}).done(function(){b.successFullTry(),a(b.map(function(a){return a.forList()}))})}}})}(),function(){"use strict";window.ClusterServers=window.AutomaticRetryCollection.extend({model:window.ClusterServer,url:"/_admin/aardvark/cluster/DBServers",updateUrl:function(){this.url=window.App.getNewRoute("DBServers")},initialize:function(){window.App.registerForUpdate(this)},statusClass:function(a){switch(a){case"ok":return"success";case"warning":return"warning";case"critical":return"danger";case"missing":return"inactive";default:return"danger"}},getStatuses:function(a){if(this.checkRetries()){var b=this,c=function(){b.successFullTry(),b._retryCount=0,b.forEach(function(c){a(b.statusClass(c.get("status")),c.get("address"))})};this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:b.failureTry.bind(b,b.getStatuses.bind(b,a))}).done(c)}},byAddress:function(a,b){if(this.checkRetries()){var c=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:c.failureTry.bind(c,c.byAddress.bind(c,a,b))}).done(function(){c.successFullTry(),a=a||{},c.forEach(function(b){var c=b.get("address");c=c.split(":")[0],a[c]=a[c]||{},a[c].dbs=a[c].dbs||[],a[c].dbs.push(b)}),b(a)})}},getList:function(a){throw"Do not use"},getOverview:function(){throw"Do not use DbServer.getOverview"}})}(),function(){"use strict";window.ClusterShards=window.AutomaticRetryCollection.extend({model:window.ClusterShard,updateUrl:function(){this.url=window.App.getNewRoute(this.dbname+"/"+this.colname+"/Shards")},url:function(){return"/_admin/aardvark/cluster/"+this.dbname+"/"+this.colname+"/Shards"},initialize:function(){this.isUpdating=!1,this.timer=null,this.interval=1e3,window.App.registerForUpdate(this)},getList:function(a,b,c){if(void 0!==a&&void 0!==b&&(this.dbname=a,this.colname=b,this.checkRetries())){var d=this;this.fetch({beforeSend:window.App.addAuth.bind(window.App),error:d.failureTry.bind(d,d.getList.bind(d,a,b,c))}).done(function(){c(d.map(function(a){return a.forList()}))})}},stopUpdating:function(){window.clearTimeout(this.timer),this.isUpdating=!1},startUpdating:function(){if(!this.isUpdating){this.isUpdating=!0;var a=this;this.timer=window.setInterval(function(){a.updateUrl(),a.fetch({beforeSend:window.App.addAuth.bind(window.App)})},this.interval)}}})}(),window.arangoDocumentModel=Backbone.Model.extend({initialize:function(){"use strict"},urlRoot:"/_api/document",defaults:{_id:"",_rev:"",_key:""},getSorted:function(){"use strict";var a=this,b=Object.keys(a.attributes).sort(function(a,b){var c=arangoHelper.isSystemAttribute(a),d=arangoHelper.isSystemAttribute(b);return c!==d?c?-1:1:b>a?-1:1}),c={};return _.each(b,function(b){c[b]=a.attributes[b]}),c}}),window.Statistics=Backbone.Model.extend({defaults:{},url:function(){"use strict";return"/_admin/statistics"}}),window.StatisticsDescription=Backbone.Model.extend({defaults:{figures:"",groups:""},url:function(){"use strict";return"/_admin/statistics-description"}}),function(){"use strict";window.PaginatedCollection=Backbone.Collection.extend({page:0,pagesize:10,totalAmount:0,getPage:function(){return this.page+1},setPage:function(a){return a>=this.getLastPageNumber()?void(this.page=this.getLastPageNumber()-1):1>a?void(this.page=0):void(this.page=a-1)},getLastPageNumber:function(){return Math.max(Math.ceil(this.totalAmount/this.pagesize),1)},getOffset:function(){return this.page*this.pagesize},getPageSize:function(){return this.pagesize},setPageSize:function(a){if("all"===a)this.pagesize="all";else try{a=parseInt(a,10),this.pagesize=a}catch(b){}},setToFirst:function(){this.page=0},setToLast:function(){this.setPage(this.getLastPageNumber())},setToPrev:function(){this.setPage(this.getPage()-1)},setToNext:function(){this.setPage(this.getPage()+1)},setTotal:function(a){this.totalAmount=a},getTotal:function(){return this.totalAmount},setTotalMinusOne:function(){this.totalAmount--}})}(),window.StatisticsCollection=Backbone.Collection.extend({model:window.Statistics,url:"/_admin/statistics"}),function(){"use strict";window.arangoDocuments=window.PaginatedCollection.extend({collectionID:1,filters:[],MAX_SORT:12e3,lastQuery:{},sortAttribute:"_key",url:"/_api/documents",model:window.arangoDocumentModel,loadTotal:function(){var a=this;$.ajax({cache:!1,type:"GET",url:"/_api/collection/"+this.collectionID+"/count",contentType:"application/json",processData:!1,async:!1,success:function(b){a.setTotal(b.count)}})},setCollection:function(a){this.resetFilter(),this.collectionID=a,this.setPage(1),this.loadTotal()},setSort:function(a){this.sortAttribute=a},getSort:function(){return this.sortAttribute},addFilter:function(a,b,c){this.filters.push({attr:a,op:b,val:c})},setFiltersForQuery:function(a){if(0===this.filters.length)return"";var b=" FILTER",c="",d=_.map(this.filters,function(b,d){return"LIKE"===b.op?(c=" "+b.op+"(x.`"+b.attr+"`, @param",c+=d,c+=")"):(c="IN"===b.op||"NOT IN"===b.op?" ":" x.`",c+=b.attr,c+="IN"===b.op||"NOT IN"===b.op?" ":"` ",c+=b.op,c+="IN"===b.op||"NOT IN"===b.op?" x.@param":" @param",c+=d),a["param"+d]=b.val,c});return b+d.join(" &&")},setPagesize:function(a){this.setPageSize(a)},resetFilter:function(){this.filters=[]},moveDocument:function(a,b,c,d){var e,f,g,h,i={"@collection":b,filterid:a};e="FOR x IN @@collection",e+=" FILTER x._key == @filterid",e+=" INSERT x IN ",e+=c,f="FOR x in @@collection",f+=" FILTER x._key == @filterid",f+=" REMOVE x IN @@collection",g={query:e,bindVars:i},h={query:f,bindVars:i},window.progressView.show(),$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(g),contentType:"application/json",success:function(a){$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(h),contentType:"application/json",success:function(a){d&&d(),window.progressView.hide()},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Documents inserted, but could not be removed.")}})},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not move selected documents.")}})},getDocuments:function(a){window.progressView.showWithDelay(300,"Fetching documents...");var b,c,d,e,f=this;c={"@collection":this.collectionID,offset:this.getOffset(),count:this.getPageSize()},b="FOR x IN @@collection LET att = SLICE(ATTRIBUTES(x), 0, 25)",b+=this.setFiltersForQuery(c),this.getTotal()0)&&(e.options={fullCount:!0}),$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(e),contentType:"application/json",success:function(b){window.progressView.toShow=!1,f.clearDocuments(),b.extra&&void 0!==b.extra.stats.fullCount&&f.setTotal(b.extra.stats.fullCount),0!==f.getTotal()&&_.each(b.result,function(a){f.add({id:a._id,rev:a._rev,key:a._key,content:a})}),f.lastQuery=e,a(),window.progressView.hide()},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not fetch requested documents.")}})},clearDocuments:function(){this.reset()},buildDownloadDocumentQuery:function(){var a,b,c;return c={"@collection":this.collectionID},a="FOR x in @@collection",a+=this.setFiltersForQuery(c),this.getTotal()0&&(b="At least one error occurred during upload")}catch(d){}}}),b}})}(),function(){"use strict";if(!window.hasOwnProperty("TEST_BUILD")){var a=function(){var a={};return a.createTemplate=function(a){var b=$("#"+a.replace(".","\\.")).html();return{render:function(a){return _.template(b,a)}}},a};window.templateEngine=new a}}(),function(){"use strict";window.FooterView=Backbone.View.extend({el:"#footerBar",system:{},isOffline:!0,isOfflineCounter:0,firstLogin:!0,events:{"click .footer-center p":"showShortcutModal"},initialize:function(){var a=this;window.setInterval(function(){a.getVersion()},15e3),a.getVersion()},template:templateEngine.createTemplate("footerView.ejs"),showServerStatus:function(a){a===!0?($(".serverStatusIndicator").addClass("isOnline"),$(".serverStatusIndicator").addClass("fa-check-circle-o"),$(".serverStatusIndicator").removeClass("fa-times-circle-o")):($(".serverStatusIndicator").removeClass("isOnline"),$(".serverStatusIndicator").removeClass("fa-check-circle-o"),$(".serverStatusIndicator").addClass("fa-times-circle-o"))},showShortcutModal:function(){window.arangoHelper.hotkeysFunctions.showHotkeysModal()},getVersion:function(){var a=this;$.ajax({type:"GET",cache:!1,url:"/_api/version",contentType:"application/json",processData:!1,async:!0,success:function(b){a.showServerStatus(!0),a.isOffline===!0&&(a.isOffline=!1,a.isOfflineCounter=0,a.firstLogin?a.firstLogin=!1:window.setTimeout(function(){a.showServerStatus(!0)},1e3),a.system.name=b.server,a.system.version=b.version,a.render())},error:function(b){a.isOffline=!0,a.isOfflineCounter++,a.isOfflineCounter>=1&&a.showServerStatus(!1)}}),a.system.hasOwnProperty("database")||$.ajax({type:"GET",cache:!1,url:"/_api/database/current",contentType:"application/json",processData:!1,async:!0,success:function(b){var c=b.result.name;a.system.database=c;var d=window.setInterval(function(){var b=$("#databaseNavi");b&&(window.clearTimeout(d),d=null,"_system"===c?($(".logs-menu").css("visibility","visible"),$(".logs-menu").css("display","inline"),$("#databaseNavi").css("display","inline")):($(".logs-menu").css("visibility","hidden"),$(".logs-menu").css("display","none")),a.render())},50)}})},renderVersion:function(){this.system.hasOwnProperty("database")&&this.system.hasOwnProperty("name")&&$(this.el).html(this.template.render({name:this.system.name,version:this.system.version,database:this.system.database}))},render:function(){return this.system.version||this.getVersion(),$(this.el).html(this.template.render({name:this.system.name,version:this.system.version})),this}})}(),function(){"use strict";function a(a,b){return(void 0===a||null===a)&&(a=0),a.toFixed(b)}window.DashboardView=Backbone.View.extend({el:"#content",interval:1e4,defaultTimeFrame:12e5,defaultDetailFrame:1728e5,history:{},graphs:{},events:{},tendencies:{asyncPerSecondCurrent:["asyncPerSecondCurrent","asyncPerSecondPercentChange"],syncPerSecondCurrent:["syncPerSecondCurrent","syncPerSecondPercentChange"],clientConnectionsCurrent:["clientConnectionsCurrent","clientConnectionsPercentChange"],clientConnectionsAverage:["clientConnections15M","clientConnections15MPercentChange"],numberOfThreadsCurrent:["numberOfThreadsCurrent","numberOfThreadsPercentChange"],numberOfThreadsAverage:["numberOfThreads15M","numberOfThreads15MPercentChange"],virtualSizeCurrent:["virtualSizeCurrent","virtualSizePercentChange"],virtualSizeAverage:["virtualSize15M","virtualSize15MPercentChange"]},barCharts:{totalTimeDistribution:["queueTimeDistributionPercent","requestTimeDistributionPercent"],dataTransferDistribution:["bytesSentDistributionPercent","bytesReceivedDistributionPercent"]},barChartsElementNames:{queueTimeDistributionPercent:"Queue",requestTimeDistributionPercent:"Computation",bytesSentDistributionPercent:"Bytes sent",bytesReceivedDistributionPercent:"Bytes received"},getDetailFigure:function(a){var b=$(a.currentTarget).attr("id").replace(/ChartButton/g,"");return b},showDetail:function(a){var b,c=this,d=this.getDetailFigure(a);b=this.dygraphConfig.getDetailChartConfig(d),this.getHistoryStatistics(d),this.detailGraphFigure=d,window.modalView.hideFooter=!0,window.modalView.hide(),window.modalView.show("modalGraph.ejs",b.header,void 0,void 0,void 0,void 0,this.events),window.modalView.hideFooter=!1,$("#modal-dialog").on("hidden",function(){c.hidden()}),$("#modal-dialog").toggleClass("modal-chart-detail",!0),b.height=.7*$(window).height(),b.width=$(".modal-inner-detail").width(),b.labelsDiv=$(b.labelsDiv)[0],this.detailGraph=new Dygraph(document.getElementById("lineChartDetail"),this.history[this.server][d],b)},hidden:function(){this.detailGraph.destroy(),delete this.detailGraph,delete this.detailGraphFigure},getCurrentSize:function(a){"#"!==a.substr(0,1)&&(a="#"+a);var b,c;return $(a).attr("style",""),b=$(a).height(),c=$(a).width(),{height:b,width:c}},prepareDygraphs:function(){var a,b=this;this.dygraphConfig.getDashBoardFigures().forEach(function(c){a=b.dygraphConfig.getDefaultConfig(c);var d=b.getCurrentSize(a.div);a.height=d.height,a.width=d.width,b.graphs[c]=new Dygraph(document.getElementById(a.div),b.history[b.server][c]||[],a)})},initialize:function(){this.dygraphConfig=this.options.dygraphConfig,this.d3NotInitialized=!0,this.events["click .dashboard-sub-bar-menu-sign"]=this.showDetail.bind(this),this.events["mousedown .dygraph-rangesel-zoomhandle"]=this.stopUpdating.bind(this),this.events["mouseup .dygraph-rangesel-zoomhandle"]=this.startUpdating.bind(this),this.serverInfo=this.options.serverToShow,this.serverInfo?this.server=this.serverInfo.target:this.server="-local-",this.history[this.server]={}},updateCharts:function(){var a=this;return this.detailGraph?void this.updateLineChart(this.detailGraphFigure,!0):(this.prepareD3Charts(this.isUpdating),this.prepareResidentSize(this.isUpdating),this.updateTendencies(),void Object.keys(this.graphs).forEach(function(b){a.updateLineChart(b,!1)}))},updateTendencies:function(){var a=this,b=this.tendencies,c="";Object.keys(b).forEach(function(b){var d="",e=0;a.history.hasOwnProperty(a.server)&&a.history[a.server].hasOwnProperty(b)&&(e=a.history[a.server][b][1]),0>e?c="#d05448":(c="#7da817",d="+"),a.history.hasOwnProperty(a.server)&&a.history[a.server].hasOwnProperty(b)?$("#"+b).html(a.history[a.server][b][0]+'
'+d+e+"%"):$("#"+b).html('
data not ready yet')})},updateDateWindow:function(a,b){var c,d,e=(new Date).getTime();return b&&a.dateWindow_?(c=a.dateWindow_[0],d=e-a.dateWindow_[1]-5*this.interval>0?a.dateWindow_[1]:e,[c,d]):[e-this.defaultTimeFrame,e]},updateLineChart:function(a,b){var c=b?this.detailGraph:this.graphs[a],d={file:this.history[this.server][a],dateWindow:this.updateDateWindow(c,b)},e=0,f=[];_.each(d.file,function(a){var b=a[0].getSeconds()-a[0].getSeconds()%10;d.file[e][0].setSeconds(b),f.push(d.file[e][0]),e++});for(var g=new Date(Math.max.apply(null,f)),h=new Date(Math.min.apply(null,f)),i=new Date(h.getTime()),j=[],k=[];g>i;)i=new Date(i.setSeconds(i.getSeconds()+10)),k.push(i);_.each(k,function(a){var b=!1;_.each(d.file,function(c){Math.floor(a.getTime()/1e3)===Math.floor(c[0].getTime()/1e3)&&(b=!0)}),b===!1&&a1&&d.history[d.server][e].push(c))})},cutOffHistory:function(a,b){for(var c=this;0!==c.history[c.server][a].length;){var d=c.history[c.server][a][0][0];if(d>=b)break;c.history[c.server][a].shift()}},cutOffDygraphHistory:function(a){var b=this,c=new Date(a);this.dygraphConfig.getDashBoardFigures(!0).forEach(function(a){b.dygraphConfig.mapStatToFigure[a]&&b.history[b.server][a]&&b.cutOffHistory(a,c)})},mergeHistory:function(b){var c,d=this;for(c=0;c=0;--c)d.values.push({label:this.getLabel(b[a[0]].cuts,c),value:b[a[0]].values[c]}),e.values.push({label:this.getLabel(b[a[1]].cuts,c),value:b[a[1]].values[c]});return[d,e]},getLabel:function(a,b){return a[b]?0===b?"0 - "+a[b]:a[b-1]+" - "+a[b]:">"+a[b-1]},renderReplicationStatistics:function(a){$("#repl-numbers table tr:nth-child(1) > td:nth-child(2)").html(a.state.totalEvents),$("#repl-numbers table tr:nth-child(2) > td:nth-child(2)").html(a.state.totalRequests),$("#repl-numbers table tr:nth-child(3) > td:nth-child(2)").html(a.state.totalFailedConnects),a.state.lastAppliedContinuousTick?$("#repl-ticks table tr:nth-child(1) > td:nth-child(2)").html(a.state.lastAppliedContinuousTick):$("#repl-ticks table tr:nth-child(1) > td:nth-child(2)").html("no data available").addClass("no-data"),a.state.lastProcessedContinuousTick?$("#repl-ticks table tr:nth-child(2) > td:nth-child(2)").html(a.state.lastProcessedContinuousTick):$("#repl-ticks table tr:nth-child(2) > td:nth-child(2)").html("no data available").addClass("no-data"),a.state.lastAvailableContinuousTick?$("#repl-ticks table tr:nth-child(3) > td:nth-child(2)").html(a.state.lastAvailableContinuousTick):$("#repl-ticks table tr:nth-child(3) > td:nth-child(2)").html("no data available").addClass("no-data"),$("#repl-progress table tr:nth-child(1) > td:nth-child(2)").html(a.state.progress.message),$("#repl-progress table tr:nth-child(2) > td:nth-child(2)").html(a.state.progress.time),$("#repl-progress table tr:nth-child(3) > td:nth-child(2)").html(a.state.progress.failedConnects)},getReplicationStatistics:function(){var a=this;$.ajax("/_api/replication/applier-state",{async:!0}).done(function(b){if(b.hasOwnProperty("state")){var c;c=b.state.running?"active":"inactive",c=''+c+"", +$("#replication-chart .dashboard-sub-bar").html("Replication "+c),a.renderReplicationStatistics(b)}})},getStatistics:function(a){var b=this,c="/_db/_system/_admin/aardvark/statistics/short",d="?start=";d+=b.nextStart?b.nextStart:((new Date).getTime()-b.defaultTimeFrame)/1e3,"-local-"!==b.server&&(c=b.serverInfo.endpoint+"/_admin/aardvark/statistics/cluster",d+="&type=short&DBserver="+b.serverInfo.target,b.history.hasOwnProperty(b.server)||(b.history[b.server]={})),$.ajax(c+d,{async:!0}).done(function(c){c.times.length>0&&(b.isUpdating=!0,b.mergeHistory(c)),b.isUpdating!==!1&&(a&&a(),b.updateCharts())}),this.getReplicationStatistics()},getHistoryStatistics:function(a){var b=this,c="statistics/long",d="?filter="+this.dygraphConfig.mapStatToFigure[a].join();"-local-"!==b.server&&(c=b.server.endpoint+"/_admin/aardvark/statistics/cluster",d+="&type=long&DBserver="+b.server.target,b.history.hasOwnProperty(b.server)||(b.history[b.server]={}));var e=window.location.href.split("/"),f=e[0]+"//"+e[2]+"/"+e[3]+"/_system/"+e[5]+"/"+e[6]+"/";$.ajax(f+c+d,{async:!0}).done(function(c){var d;for(b.history[b.server][a]=[],d=0;d data not ready yet

'),$("#totalTimeDistribution").prepend('

data not ready yet

'),$(".dashboard-bar-chart-title").prepend('

data not ready yet

'))},removeEmptyDataLabels:function(){$(".dataNotReadyYet").remove()},prepareResidentSize:function(b){var c=this,d=this.getCurrentSize("#residentSizeChartContainer"),e=c.history[c.server].residentSizeCurrent/1024/1024,f="";f=1025>e?a(e,2)+" MB":a(e/1024,2)+" GB";var g=a(100*c.history[c.server].residentSizePercent,2),h=[a(c.history[c.server].physicalMemory/1024/1024/1024,0)+" GB"];return void 0===c.history[c.server].residentSizeChart?void this.addEmptyDataLabels():(this.removeEmptyDataLabels(),void nv.addGraph(function(){var a=nv.models.multiBarHorizontalChart().x(function(a){return a.label}).y(function(a){return a.value}).width(d.width).height(d.height).margin({top:($("residentSizeChartContainer").outerHeight()-$("residentSizeChartContainer").height())/2,right:1,bottom:($("residentSizeChartContainer").outerHeight()-$("residentSizeChartContainer").height())/2,left:1}).showValues(!1).showYAxis(!1).showXAxis(!1).transitionDuration(100).tooltips(!1).showLegend(!1).showControls(!1).stacked(!0);return a.yAxis.tickFormat(function(a){return a+"%"}).showMaxMin(!1),a.xAxis.showMaxMin(!1),d3.select("#residentSizeChart svg").datum(c.history[c.server].residentSizeChart).call(a),d3.select("#residentSizeChart svg").select(".nv-zeroLine").remove(),b&&(d3.select("#residentSizeChart svg").select("#total").remove(),d3.select("#residentSizeChart svg").select("#percentage").remove()),d3.select(".dashboard-bar-chart-title .percentage").html(f+" ("+g+" %)"),d3.select(".dashboard-bar-chart-title .absolut").html(h[0]),nv.utils.windowResize(a.update),a},function(){d3.selectAll("#residentSizeChart .nv-bar").on("click",function(){})}))},prepareD3Charts:function(b){var c=this,d={totalTimeDistribution:["queueTimeDistributionPercent","requestTimeDistributionPercent"],dataTransferDistribution:["bytesSentDistributionPercent","bytesReceivedDistributionPercent"]};this.d3NotInitialized&&(b=!1,this.d3NotInitialized=!1),_.each(Object.keys(d),function(b){var d=c.getCurrentSize("#"+b+"Container .dashboard-interior-chart"),e="#"+b+"Container svg";return void 0===c.history[c.server].residentSizeChart?void c.addEmptyDataLabels():(c.removeEmptyDataLabels(),void nv.addGraph(function(){var f=[0,.25,.5,.75,1],g=75,h=23,i=6;d.width<219?(f=[0,.5,1],g=72,h=21,i=5):d.width<299?(f=[0,.3334,.6667,1],g=77):d.width<379?g=87:d.width<459?g=95:d.width<539?g=100:d.width<619&&(g=105);var j=nv.models.multiBarHorizontalChart().x(function(a){return a.label}).y(function(a){return a.value}).width(d.width).height(d.height).margin({top:5,right:20,bottom:h,left:g}).showValues(!1).showYAxis(!0).showXAxis(!0).transitionDuration(100).tooltips(!1).showLegend(!1).showControls(!1).forceY([0,1]);j.yAxis.showMaxMin(!1);d3.select(".nv-y.nv-axis").selectAll("text").attr("transform","translate (0, "+i+")");return j.yAxis.tickValues(f).tickFormat(function(b){return a(100*b*100/100,0)+"%"}),d3.select(e).datum(c.history[c.server][b]).call(j),nv.utils.windowResize(j.update),j},function(){d3.selectAll(e+" .nv-bar").on("click",function(){})}))})},stopUpdating:function(){this.isUpdating=!1},startUpdating:function(){var a=this;a.timer||(a.timer=window.setInterval(function(){a.getStatistics()},a.interval))},resize:function(){if(this.isUpdating){var a,b=this;_.each(this.graphs,function(c){a=b.getCurrentSize(c.maindiv_.id),c.resize(a.width,a.height)}),this.detailGraph&&(a=this.getCurrentSize(this.detailGraph.maindiv_.id),this.detailGraph.resize(a.width,a.height)),this.prepareD3Charts(!0),this.prepareResidentSize(!0)}},template:templateEngine.createTemplate("dashboardView.ejs"),render:function(a){a||$(this.el).html(this.template.render());var b=function(){this.prepareDygraphs(),this.isUpdating&&(this.prepareD3Charts(),this.prepareResidentSize(),this.updateTendencies()),this.startUpdating()}.bind(this),c=this.options.database.hasSystemAccess();c?this.getStatistics(b):($(".contentDiv").remove(),$(".headerBar").remove(),$(".dashboard-headerbar").remove(),$(".dashboard-row").remove(),$("#content").append('
You do not have permission to view this page.
'),$("#content").append("
You can switch to '_system' to see the dashboard.
"))}})}(),function(){"use strict";var a=function(a,b,c,d){return{type:a,title:b,callback:c,confirm:d}},b=function(a,b,c,d,e,f,g,h,i,j,k){var l={type:a,label:b};return void 0!==c&&(l.value=c),void 0!==d&&(l.info=d),void 0!==e&&(l.placeholder=e),void 0!==f&&(l.mandatory=f),void 0!==h&&(l.addDelete=h),void 0!==i&&(l.addAdd=i),void 0!==j&&(l.maxEntrySize=j),void 0!==k&&(l.tags=k),g&&(l.validateInput=function(){return g}),l};window.ModalView=Backbone.View.extend({_validators:[],_validateWatchers:[],baseTemplate:templateEngine.createTemplate("modalBase.ejs"),tableTemplate:templateEngine.createTemplate("modalTable.ejs"),el:"#modalPlaceholder",contentEl:"#modalContent",hideFooter:!1,confirm:{list:"#modal-delete-confirmation",yes:"#modal-confirm-delete",no:"#modal-abort-delete"},enabledHotkey:!1,enableHotKeys:!0,buttons:{SUCCESS:"success",NOTIFICATION:"notification",DELETE:"danger",NEUTRAL:"neutral",CLOSE:"close"},tables:{READONLY:"readonly",TEXT:"text",BLOB:"blob",PASSWORD:"password",SELECT:"select",SELECT2:"select2",CHECKBOX:"checkbox"},initialize:function(){Object.freeze(this.buttons),Object.freeze(this.tables)},createModalHotkeys:function(){$(this.el).unbind("keydown"),$(this.el).unbind("return"),$(this.el).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()}),$(".modal-body input").unbind("keydown"),$(".modal-body input").unbind("return"),$(".modal-body input",$(this.el)).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()}),$(".modal-body select").unbind("keydown"),$(".modal-body select").unbind("return"),$(".modal-body select",$(this.el)).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()})},createInitModalHotkeys:function(){var a=this;$(this.el).bind("keydown","left",function(){a.navigateThroughButtons("left")}),$(this.el).bind("keydown","right",function(){a.navigateThroughButtons("right")})},navigateThroughButtons:function(a){var b=$(".createModalDialog .modal-footer button").is(":focus");b===!1?"left"===a?$(".createModalDialog .modal-footer button").first().focus():"right"===a&&$("..createModalDialog .modal-footer button").last().focus():b===!0&&("left"===a?$(":focus").prev().focus():"right"===a&&$(":focus").next().focus())},createCloseButton:function(b,c){var d=this;return a(this.buttons.CLOSE,b,function(){d.hide(),c&&c()})},createSuccessButton:function(b,c){return a(this.buttons.SUCCESS,b,c)},createNotificationButton:function(b,c){return a(this.buttons.NOTIFICATION,b,c)},createDeleteButton:function(b,c,d){return a(this.buttons.DELETE,b,c,d)},createNeutralButton:function(b,c){return a(this.buttons.NEUTRAL,b,c)},createDisabledButton:function(b){var c=a(this.buttons.NEUTRAL,b);return c.disabled=!0,c},createReadOnlyEntry:function(a,c,d,e,f,g){var h=b(this.tables.READONLY,c,d,e,void 0,void 0,void 0,f,g);return h.id=a,h},createTextEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.TEXT,c,d,e,f,g,h);return i.id=a,i},createBlobEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.BLOB,c,d,e,f,g,h);return i.id=a,i},createSelect2Entry:function(a,c,d,e,f,g,h,i,j,k){var l=b(this.tables.SELECT2,c,d,e,f,g,void 0,h,i,j,k);return l.id=a,l},createPasswordEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.PASSWORD,c,d,e,f,g,h);return i.id=a,i},createCheckboxEntry:function(a,c,d,e,f){var g=b(this.tables.CHECKBOX,c,d,e);return g.id=a,f&&(g.checked=f),g},createSelectEntry:function(a,c,d,e,f){var g=b(this.tables.SELECT,c,null,e);return g.id=a,d&&(g.selected=d),g.options=f,g},createOptionEntry:function(a,b){return{label:a,value:b||a}},show:function(a,b,c,d,e,f,g,h,i){var j,k,l=this,m=!1;c=c||[],h=Boolean(h),this.clearValidators(),c.length>0?(c.forEach(function(a){a.type===l.buttons.CLOSE&&(m=!0),a.type===l.buttons.DELETE&&(k=k||a.confirm)}),m||(j=c.pop(),c.push(l.createCloseButton("Cancel")),c.push(j))):c.push(l.createCloseButton("Close")),$(this.el).html(this.baseTemplate.render({title:b,buttons:c,hideFooter:this.hideFooter,confirm:k,tabBar:i})),_.each(c,function(a,b){return!a.disabled&&a.callback?a.type!==l.buttons.DELETE||h?void $("#modalButton"+b).bind("click",a.callback):void $("#modalButton"+b).bind("click",function(){$(l.confirm.yes).unbind("click"),$(l.confirm.yes).bind("click",a.callback),$(l.confirm.list).css("display","block")}):void 0}),$(this.confirm.no).bind("click",function(){$(l.confirm.list).css("display","none")});var n;if("string"==typeof a)n=templateEngine.createTemplate(a),$(".createModalDialog .modal-body").html(n.render({content:d,advancedContent:e,info:f}));else{var o=0;_.each(a,function(a){n=templateEngine.createTemplate(a),$(".createModalDialog .modal-body .tab-content #"+i[o]).html(n.render({content:d,advancedContent:e,info:f})),o++})}$(".createModalDialog .modalTooltips").tooltip({position:{my:"left top",at:"right+55 top-1"}});var p=d||[];e&&e.content&&(p=p.concat(e.content)),_.each(p,function(a){l.modalBindValidation(a),a.type===l.tables.SELECT2&&$("#"+a.id).select2({tags:a.tags||[],showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:a.maxEntrySize||8})}),g&&(this.events=g,this.delegateEvents()),$("#accordion2")&&($("#accordion2 .accordion-toggle").bind("click",function(){$("#collapseOne").is(":visible")?($("#collapseOne").hide(),setTimeout(function(){$(".accordion-toggle").addClass("collapsed")},100)):($("#collapseOne").show(),setTimeout(function(){$(".accordion-toggle").removeClass("collapsed")},100))}),$("#collapseOne").hide(),setTimeout(function(){$(".accordion-toggle").addClass("collapsed")},100)),$("#modal-dialog").modal("show"),this.enabledHotkey===!1&&(this.createInitModalHotkeys(),this.enabledHotkey=!0),this.enableHotKeys&&this.createModalHotkeys();var q=$("#modal-dialog").find("input");q&&setTimeout(function(){var a=$("#modal-dialog");a.length>0&&(a=a.find("input"),a.length>0&&$(a[0]).focus())},800)},modalBindValidation:function(a){var b=this;if(a.hasOwnProperty("id")&&a.hasOwnProperty("validateInput")){var c=function(){var b=$("#"+a.id),c=a.validateInput(b),d=!1;return _.each(c,function(a){var c=b.val();if(a.rule||(a={rule:a}),"function"==typeof a.rule)try{a.rule(c)}catch(e){d=a.msg||e.message}else{var f=Joi.validate(c,a.rule);f.error&&(d=a.msg||f.error.message)}return d?!1:void 0}),d?d:void 0},d=$("#"+a.id);d.on("keyup focusout",function(){var a=c(),e=d.next()[0];a?(d.addClass("invalid-input"),e?$(e).text(a):d.after('

'+a+"

"),$(".createModalDialog .modal-footer .button-success").prop("disabled",!0).addClass("disabled")):(d.removeClass("invalid-input"),e&&$(e).remove(),b.modalTestAll())}),this._validators.push(c),this._validateWatchers.push(d)}},modalTestAll:function(){var a=_.map(this._validators,function(a){return a()}),b=_.any(a);return b?$(".createModalDialog .modal-footer .button-success").prop("disabled",!0).addClass("disabled"):$(".createModalDialog .modal-footer .button-success").prop("disabled",!1).removeClass("disabled"),!b},clearValidators:function(){this._validators=[],_.each(this._validateWatchers,function(a){a.unbind("keyup focusout")}),this._validateWatchers=[]},hide:function(){this.clearValidators(),$("#modal-dialog").modal("hide")}})}(),window.StatisticsDescriptionCollection=Backbone.Collection.extend({model:window.StatisticsDescription,url:"/_admin/statistics-description",parse:function(a){return a}}),function(){"use strict";window.ClusterDownView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("clusterDown.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),events:{"click #relaunchCluster":"relaunchCluster","click #upgradeCluster":"upgradeCluster","click #editPlan":"editPlan","click #submitEditPlan":"submitEditPlan","click #deletePlan":"deletePlan","click #submitDeletePlan":"submitDeletePlan"},render:function(){var a,b=window.versionHelper.fromString(window.App.clusterPlan.getVersion());$.ajax({type:"GET",cache:!1,url:"/_admin/database/target-version",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b.version}}),a=window.versionHelper.fromString(a);var c=!1;(a.major>b.major||a.major===b.major&&a.minor>b.minor)&&(c=!0),$(this.el).html(this.template.render({canUpgrade:c})),$(this.el).append(this.modal.render({}))},relaunchCluster:function(){$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster will be relaunched"),$.ajax({cache:!1,type:"GET",url:"cluster/relaunch",success:function(){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.navigate("showCluster",{trigger:!0})}})},upgradeCluster:function(){$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster will be upgraded"),$.ajax({cache:!1,type:"GET",url:"cluster/upgrade",success:function(){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.clusterPlan.fetch(),window.App.navigate("showCluster",{trigger:!0})}})},editPlan:function(){$("#deletePlanModal").modal("hide"),$("#editPlanModal").modal("show")},submitEditPlan:function(){$("#editPlanModal").modal("hide"),window.App.clusterPlan.cleanUp();var a=window.App.clusterPlan;return a.isTestSetup()?void window.App.navigate("planTest",{trigger:!0}):void window.App.navigate("planAsymmetrical",{trigger:!0})},deletePlan:function(){$("#editPlanModal").modal("hide"),$("#deletePlanModal").modal("show")},submitDeletePlan:function(){$("#deletePlanModal").modal("hide"),window.App.clusterPlan.cleanUp(),window.App.clusterPlan.destroy(),window.App.clusterPlan=new window.ClusterPlan,window.App.planScenario()}})}(),function(){"use strict";window.ClusterUnreachableView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("clusterUnreachable.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),events:{"click #clusterShutdown":"shutdown"},initialize:function(){this.coordinators=new window.ClusterCoordinators([],{})},retryCounter:0,retryNavigation:function(){var a=this;if(10===this.retryCounter){this.retryCounter=0;var b=new XMLHttpRequest;b.open("GET",window.location.origin+window.location.pathname,!1),b.send(),200===b.status?window.location.reload():window.setTimeout(function(){a.retryCounter++,a.retryNavigation()},1e3)}else this.retryCounter++,window.setTimeout(function(){a.retryNavigation()},1e3)},retryConnection:function(){this.coordinators.checkConnection(function(){window.App.showCluster()}),this.retryNavigation()},shutdown:function(){window.clearTimeout(this.timer),window.App.shutdownView.clusterShutdown()},render:function(){var a=window.App.clusterPlan,b=[];if(a&&a.has("runInfo")){var c=_.where(a.get("runInfo"),{isStartServers:!0});_.each(_.filter(c,function(a){return _.contains(a.roles,"Coordinator")}),function(a){var c=a.endpoints[0].split("://")[1];c=c.split(":")[0],b.push(c)})}$(this.el).html(this.template.render({coordinators:b})),$(this.el).append(this.modal.render({})),this.timer=window.setTimeout(this.retryConnection.bind(this),1e4)}})}(),function(){"use strict";window.ServerDashboardView=window.DashboardView.extend({modal:!0,hide:function(){window.App.showClusterView.startUpdating(),this.stopUpdating()},render:function(){var a=this;window.modalView.hideFooter=!0,window.modalView.show("dashboardView.ejs",null,void 0,void 0,void 0,this.events),$("#modal-dialog").toggleClass("modal-chart-detail",!0),window.DashboardView.prototype.render.bind(this)(!0),window.modalView.hideFooter=!1,$("#modal-dialog").on("hidden",function(){a.hide()});var b=document.createElement("button");b.className="close",b.appendChild(document.createTextNode("×")),b=$(b),b.attr("data-dismiss","modal"),b.attr("aria-hidden","true"),b.attr("type","button"),$(".modal-body .headerBar:first-child").toggleClass("headerBar",!1).toggleClass("modal-dashboard-header",!0).append(b)}})}(),function(){"use strict";window.LoginModalView=Backbone.View.extend({template:templateEngine.createTemplate("loginModal.ejs"),el:"#modalPlaceholder",events:{"click #confirmLogin":"confirmLogin","hidden #loginModalLayer":"hidden"},hidden:function(){this.undelegateEvents(),window.App.isCheckingUser=!1,$(this.el).html("")},confirmLogin:function(){var a=$("#username").val(),b=$("#password").val();window.App.clusterPlan.storeCredentials(a,b),this.hideModal()},hideModal:function(){$("#loginModalLayer").modal("hide")},render:function(){$(this.el).html(this.template.render({})),$("#loginModalLayer").modal("show")}})}(),function(){"use strict";window.PlanScenarioSelectorView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("planScenarioSelector.ejs","planner"),events:{"click #multiServerAsymmetrical":"multiServerAsymmetrical","click #singleServer":"singleServer"},render:function(){$(this.el).html(this.template.render({}))},multiServerAsymmetrical:function(){window.App.navigate("planAsymmetrical",{trigger:!0})},singleServer:function(){window.App.navigate("planTest",{trigger:!0})}})}(),function(){"use strict";window.PlanSymmetricView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("symmetricPlan.ejs"),entryTemplate:templateEngine.createTemplate("serverEntry.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),connectionValidationKey:null,events:{"click #startSymmetricPlan":"startPlan","click .add":"addEntry","click .delete":"removeEntry","click #cancel":"cancel","click #test-all-connections":"checkAllConnections","focusout .host":"checkAllConnections","focusout .port":"checkAllConnections","focusout .user":"checkAllConnections","focusout .passwd":"checkAllConnections"},cancel:function(){window.App.clusterPlan.get("plan")?window.App.navigate("handleClusterDown",{trigger:!0}):window.App.navigate("planScenario",{trigger:!0})},startPlan:function(){var a=this,b={dispatchers:[]},c=!1,d=!1;if(b.useSSLonDBservers=!!$(".useSSLonDBservers").prop("checked"),b.useSSLonCoordinators=!!$(".useSSLonCoordinators").prop("checked"),$(".dispatcher").each(function(e,f){var g=$(".host",f).val(),h=$(".port",f).val(),i=$(".user",f).val(),j=$(".passwd",f).val();if(!g||0===g.length||!h||0===h.length)return!0;var k={host:g+":"+h};a.isSymmetric?(k.isDBServer=!0,k.isCoordinator=!0):(k.isDBServer=!!$(".isDBServer",f).prop("checked"),k.isCoordinator=!!$(".isCoordinator",f).prop("checked")),k.username=i,k.passwd=j,c=c||k.isCoordinator,d=d||k.isDBServer,b.dispatchers.push(k)}),a.isSymmetric){if(0===b.dispatchers.length)return void alert("Please provide at least one host")}else{if(!d)return void alert("Please provide at least one database server");if(!c)return void alert("Please provide at least one coordinator")}b.type=this.isSymmetric?"symmetricalSetup":"asymmetricalSetup",$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster is being launched"),delete window.App.clusterPlan._coord,window.App.clusterPlan.save(b,{success:function(){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.updateAllUrls(),window.App.navigate("showCluster",{trigger:!0})},error:function(a,b){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),alert("Error while starting the cluster: "+b.statusText)}})},addEntry:function(){this.disableLaunchButton();var a=$("#server_list div.control-group.dispatcher:last .user").val(),b=$("#server_list div.control-group.dispatcher:last .passwd").val();$("#server_list").append(this.entryTemplate.render({isSymmetric:this.isSymmetric,isFirst:!1,isCoordinator:!0,isDBServer:!0,host:"",port:"",user:a,passwd:b}))},removeEntry:function(a){$(a.currentTarget).closest(".control-group").remove(),this.checkAllConnections()},render:function(a){var b={},c=!0,d=window.App.clusterPlan.get("config");if(this.isSymmetric=a,$(this.el).html(this.template.render({isSymmetric:a,params:b,useSSLonDBservers:d&&d.useSSLonDBservers?d.useSSLonDBservers:!1,useSSLonCoordinators:d&&d.useSSLonCoordinators?d.useSSLonCoordinators:!1})),d){var e=this,f=!1,g=!1;_.each(d.dispatchers,function(b){g=void 0===b.allowDBservers?!0:b.allowDBservers,f=void 0===b.allowCoordinators?!0:b.allowCoordinators;var d=b.endpoint;d=d.split("//")[1],d=d.split(":"),"localhost"===d&&(d="127.0.0.1");var h=b.username,i=b.passwd,j=e.entryTemplate.render({isSymmetric:a,isFirst:c,host:d[0],port:d[1],isCoordinator:f,isDBServer:g,user:h,passwd:i});$("#server_list").append(j),c=!1})}else $("#server_list").append(this.entryTemplate.render({isSymmetric:a,isFirst:!0,isCoordinator:!0,isDBServer:!0,host:"",port:"",user:"",passwd:""}));this.disableLaunchButton(),$(this.el).append(this.modal.render({}))},readAllConnections:function(){var a=[];return $(".dispatcher").each(function(b,c){var d={host:$(".host",c).val(),port:$(".port",c).val(),user:$(".user",c).val(),passwd:$(".passwd",c).val()};d.host&&d.port&&a.push(d)}),a},checkAllConnections:function(){var a=this,b=Math.random();this.connectionValidationKey=b,$(".cluster-connection-check-success").remove(),$(".cluster-connection-check-fail").remove();var c=this.readAllConnections();if(c.length)try{$.ajax({async:!0,cache:!1,type:"POST",url:"/_admin/aardvark/cluster/communicationCheck",data:JSON.stringify(c),success:function(c){if(b===a.connectionValidationKey){var d=$(".dispatcher"),e=0;d.each(function(a,b){var d=$(".host",b).val(),f=$(".port",b).val();d&&f&&(c[e]?$(".controls:first",b).append('Connection: ok'):$(".controls:first",b).append('Connection: fail'),e++)}),a.checkDispatcherArray(c,b)}}})}catch(d){this.disableLaunchButton()}},checkDispatcherArray:function(a,b){_.every(a,function(a){return a})&&b===this.connectionValidationKey&&this.enableLaunchButton()},disableLaunchButton:function(){$("#startSymmetricPlan").attr("disabled","disabled"),$("#startSymmetricPlan").removeClass("button-success"),$("#startSymmetricPlan").addClass("button-neutral")},enableLaunchButton:function(){$("#startSymmetricPlan").attr("disabled",!1),$("#startSymmetricPlan").removeClass("button-neutral"),$("#startSymmetricPlan").addClass("button-success")}})}(),function(){"use strict";window.PlanTestView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("testPlan.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),events:{"click #startTestPlan":"startPlan","click #cancel":"cancel"},cancel:function(){window.App.clusterPlan.get("plan")?window.App.navigate("handleClusterDown",{trigger:!0}):window.App.navigate("planScenario",{trigger:!0})},startPlan:function(){$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster is being launched");var a=$("#host").val(),b=$("#port").val(),c=$("#coordinators").val(),d=$("#dbs").val();return a?b?!c||0>c?void alert("Please define a number of coordinators"):!d||0>d?void alert("Please define a number of database servers"):(delete window.App.clusterPlan._coord,void window.App.clusterPlan.save({type:"testSetup",dispatchers:a+":"+b,numberDBServers:parseInt(d,10),numberCoordinators:parseInt(c,10)},{success:function(){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.updateAllUrls(),window.App.navigate("showCluster",{trigger:!0})},error:function(a,b){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),alert("Error while starting the cluster: "+b.statusText)}})):void alert("Please define a port"):void alert("Please define a host")},render:function(){var a={},b=window.App.clusterPlan.get("config");if(b){a.dbs=b.numberOfDBservers,a.coords=b.numberOfCoordinators;var c=b.dispatchers.d1.endpoint;c=c.split("://")[1],c=c.split(":"),"localhost"===c&&(c="127.0.0.1"),a.hostname=c[0],a.port=c[1]}else a.dbs=3,a.coords=2,a.hostname=window.location.hostname,"localhost"===a.hostname&&(a.hostname="127.0.0.1"),a.port=window.location.port;$(this.el).html(this.template.render(a)),$(this.el).append(this.modal.render({}))}})}(),function(){"use strict";window.ShowClusterView=Backbone.View.extend({detailEl:"#modalPlaceholder",el:"#content",defaultFrame:12e5,template:templateEngine.createTemplate("showCluster.ejs"),modal:templateEngine.createTemplate("waitModal.ejs"),detailTemplate:templateEngine.createTemplate("detailView.ejs"),events:{"change #selectDB":"updateCollections","change #selectCol":"updateShards","click .dbserver.success":"dashboard","click .coordinator.success":"dashboard"},replaceSVGs:function(){$(".svgToReplace").each(function(){var a=$(this),b=a.attr("id"),c=a.attr("src");$.get(c,function(c){var d=$(c).find("svg");d.attr("id",b).attr("class","icon").removeAttr("xmlns:a"),a.replaceWith(d)},"xml")})},updateServerTime:function(){this.serverTime=(new Date).getTime()},setShowAll:function(){this.graphShowAll=!0},resetShowAll:function(){this.graphShowAll=!1,this.renderLineChart()},initialize:function(){this.interval=1e4,this.isUpdating=!1,this.timer=null,this.knownServers=[],this.graph=void 0,this.graphShowAll=!1,this.updateServerTime(),this.dygraphConfig=this.options.dygraphConfig,this.dbservers=new window.ClusterServers([],{interval:this.interval}),this.coordinators=new window.ClusterCoordinators([],{interval:this.interval}),this.documentStore=new window.arangoDocuments,this.statisticsDescription=new window.StatisticsDescription,this.statisticsDescription.fetch({async:!1}),this.dbs=new window.ClusterDatabases([],{interval:this.interval}),this.cols=new window.ClusterCollections,this.shards=new window.ClusterShards,this.startUpdating()},listByAddress:function(a){var b={},c=this;this.dbservers.byAddress(b,function(b){c.coordinators.byAddress(b,a)})},updateCollections:function(){var a=this,b=$("#selectCol"),c=$("#selectDB").find(":selected").attr("id");if(c){var d=b.find(":selected").attr("id");b.html(""),this.cols.getList(c,function(c){_.each(_.pluck(c,"name"),function(a){b.append('")});var e=$("#"+d,b);1===e.length&&e.prop("selected",!0),a.updateShards()})}},updateShards:function(){var a=$("#selectDB").find(":selected").attr("id"),b=$("#selectCol").find(":selected").attr("id");this.shards.getList(a,b,function(a){$(".shardCounter").html("0"),_.each(a,function(a){$("#"+a.server+"Shards").html(a.shards.length)})})},updateServerStatus:function(a){var b=this,c=function(a,b,c){var d,e,f=c;f=f.replace(/\./g,"-"),f=f.replace(/\:/g,"_"),e=$("#id"+f),e.length<1||(d=e.attr("class").split(/\s+/)[1],e.attr("class",a+" "+d+" "+b),"coordinator"===a&&("success"===b?$(".button-gui",e.closest(".tile")).toggleClass("button-gui-disabled",!1):$(".button-gui",e.closest(".tile")).toggleClass("button-gui-disabled",!0)))};this.coordinators.getStatuses(c.bind(this,"coordinator"),function(){b.dbservers.getStatuses(c.bind(b,"dbserver")),a()})},updateDBDetailList:function(){var a=this,b=$("#selectDB"),c=b.find(":selected").attr("id");b.html(""),this.dbs.getList(function(d){_.each(_.pluck(d,"name"),function(a){b.append('")});var e=$("#"+c,b);1===e.length&&e.prop("selected",!0),a.updateCollections()})},rerender:function(){var a=this;this.updateServerStatus(function(){a.getServerStatistics(function(){a.updateServerTime(),a.data=a.generatePieData(),a.renderPieChart(a.data),a.renderLineChart(),a.updateDBDetailList()})})},render:function(){this.knownServers=[],delete this.hist;var a=this;this.listByAddress(function(b){1===Object.keys(b).length?a.type="testPlan":a.type="other",a.updateDBDetailList(),a.dbs.getList(function(c){$(a.el).html(a.template.render({dbs:_.pluck(c,"name"),byAddress:b,type:a.type})),$(a.el).append(a.modal.render({})),a.replaceSVGs(),a.getServerStatistics(function(){a.data=a.generatePieData(),a.renderPieChart(a.data),a.renderLineChart(),a.updateDBDetailList(),a.startUpdating()})})})},generatePieData:function(){var a=[],b=this;return this.data.forEach(function(c){a.push({key:c.get("name"),value:c.get("system").virtualSize,time:b.serverTime})}),a},addStatisticsItem:function(a,b,c,d){var e=this;e.hasOwnProperty("hist")||(e.hist={}),e.hist.hasOwnProperty(a)||(e.hist[a]=[]);var f=e.hist[a],g=f.length;if(0===g)f.push({time:b,snap:d,requests:c,requestsPerSecond:0});else{var h=f[g-1].time,i=f[g-1].requests;if(c>i){var j=b-h,k=0;j>0&&(k=(c-i)/j),f.push({time:b,snap:d,requests:c,requestsPerSecond:k})}}},getServerStatistics:function(a){var b=this,c=Math.round(b.serverTime/1e3);this.data=void 0;var d=new window.ClusterStatisticsCollection,e=this.coordinators.first();this.dbservers.forEach(function(a){if("ok"===a.get("status")){-1===b.knownServers.indexOf(a.id)&&b.knownServers.push(a.id);var c=new window.Statistics({name:a.id});c.url=e.get("protocol")+"://"+e.get("address")+"/_admin/clusterStatistics?DBserver="+a.get("name"),d.add(c)}}),this.coordinators.forEach(function(a){if("ok"===a.get("status")){-1===b.knownServers.indexOf(a.id)&&b.knownServers.push(a.id);var c=new window.Statistics({name:a.id});c.url=a.get("protocol")+"://"+a.get("address")+"/_admin/statistics",d.add(c)}});var f=d.size();this.data=[];var g=function(d){f--;var e=d.get("time"),g=d.get("name"),h=d.get("http").requestsTotal;b.addStatisticsItem(g,e,h,c),b.data.push(d),0===f&&a()},h=function(){f--,0===f&&a()};d.fetch(g,h)},renderPieChart:function(a){var b=$("#clusterGraphs svg").width(),c=$("#clusterGraphs svg").height(),d=Math.min(b,c)/2,e=this.dygraphConfig.colors,f=d3.svg.arc().outerRadius(d-20).innerRadius(0),g=d3.layout.pie().sort(function(a){return a.value}).value(function(a){return a.value});d3.select("#clusterGraphs").select("svg").remove();var h=d3.select("#clusterGraphs").append("svg").attr("class","clusterChart").append("g").attr("transform","translate("+b/2+","+(c/2-10)+")"),i=d3.svg.arc().outerRadius(d-2).innerRadius(d-2),j=h.selectAll(".arc").data(g(a)).enter().append("g").attr("class","slice");j.append("path").attr("d",f).style("fill",function(a,b){return e[b%e.length]}).style("stroke",function(a,b){return e[b%e.length]}),j.append("text").attr("transform",function(a){return"translate("+f.centroid(a)+")"}).style("text-anchor","middle").text(function(a){ +var b=a.data.value/1024/1024/1024;return b.toFixed(2)}),j.append("text").attr("transform",function(a){return"translate("+i.centroid(a)+")"}).style("text-anchor","middle").text(function(a){return a.data.key})},renderLineChart:function(){var a,b,c,d,e,f,g=this,h=1200,i=[],j=[],k=Math.round((new Date).getTime()/1e3)-h,l=g.knownServers,m=function(){return null};for(c=0;cf||(j.hasOwnProperty(f)?a=j[f]:(e=new Date(1e3*f),a=j[f]=[e].concat(l.map(m))),a[c+1]=b[d].requestsPerSecond);i=[],Object.keys(j).sort().forEach(function(a){i.push(j[a])});var n=this.dygraphConfig.getDefaultConfig("clusterRequestsPerSecond");n.labelsDiv=$("#lineGraphLegend")[0],n.labels=["datetime"].concat(l),g.graph=new Dygraph(document.getElementById("lineGraph"),i,n)},stopUpdating:function(){window.clearTimeout(this.timer),delete this.graph,this.isUpdating=!1},startUpdating:function(){if(!this.isUpdating){this.isUpdating=!0;var a=this;this.timer=window.setInterval(function(){a.rerender()},this.interval)}},dashboard:function(a){this.stopUpdating();var b,c,d=$(a.currentTarget),e={},f=d.attr("id");f=f.replace(/\-/g,"."),f=f.replace(/\_/g,":"),f=f.substr(2),e.raw=f,e.isDBServer=d.hasClass("dbserver"),e.isDBServer?(b=this.dbservers.findWhere({address:e.raw}),c=this.coordinators.findWhere({status:"ok"}),e.endpoint=c.get("protocol")+"://"+c.get("address")):(b=this.coordinators.findWhere({address:e.raw}),e.endpoint=b.get("protocol")+"://"+b.get("address")),e.target=encodeURIComponent(b.get("name")),window.App.serverToShow=e,window.App.dashboard()},getCurrentSize:function(a){"#"!==a.substr(0,1)&&(a="#"+a);var b,c;return $(a).attr("style",""),b=$(a).height(),c=$(a).width(),{height:b,width:c}},resize:function(){var a;this.graph&&(a=this.getCurrentSize(this.graph.maindiv_.id),this.graph.resize(a.width,a.height))}})}(),function(){"use strict";window.ShowShardsView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("showShards.ejs"),events:{"change #selectDB":"updateCollections","change #selectCol":"updateShards"},initialize:function(){this.dbservers=new window.ClusterServers([],{interval:1e4}),this.dbservers.fetch({async:!1,beforeSend:window.App.addAuth.bind(window.App)}),this.dbs=new window.ClusterDatabases([],{interval:1e4}),this.cols=new window.ClusterCollections,this.shards=new window.ClusterShards},updateCollections:function(){var a=$("#selectDB").find(":selected").attr("id");$("#selectCol").html(""),_.each(_.pluck(this.cols.getList(a),"name"),function(a){$("#selectCol").append('")}),this.updateShards()},updateShards:function(){var a=$("#selectDB").find(":selected").attr("id"),b=$("#selectCol").find(":selected").attr("id"),c=this.shards.getList(a,b);$(".shardContainer").empty(),_.each(c,function(a){var b=$("#"+a.server+"Shards");$(".collectionName",b).html(a.server+": "+a.shards.length)})},render:function(){$(this.el).html(this.template.render({names:this.dbservers.pluck("name"),dbs:_.pluck(this.dbs.getList(),"name")})),this.updateCollections()}})}(),function(){"use strict";window.ShutdownButtonView=Backbone.View.extend({el:"#navigationBar",events:{"click #clusterShutdown":"clusterShutdown"},initialize:function(){this.overview=this.options.overview},template:templateEngine.createTemplate("shutdownButtonView.ejs"),clusterShutdown:function(){this.overview.stopUpdating(),$("#waitModalLayer").modal("show"),$(".modal-backdrop.fade.in").addClass("waitModalBackdrop"),$("#waitModalMessage").html("Please be patient while your cluster is shutting down"),$.ajax({cache:!1,type:"GET",url:"cluster/shutdown",success:function(a){$(".modal-backdrop.fade.in").removeClass("waitModalBackdrop"),$("#waitModalLayer").modal("hide"),window.App.navigate("handleClusterDown",{trigger:!0})}})},render:function(){return $(this.el).html(this.template.render({})),this},unrender:function(){$(this.el).html("")}})}(),function(){"use strict";window.ClusterRouter=Backbone.Router.extend({routes:{"":"initialRoute",planScenario:"planScenario",planTest:"planTest",planAsymmetrical:"planAsymmetric",shards:"showShards",showCluster:"showCluster",handleClusterDown:"handleClusterDown"},addAuth:function(a){var b=this.clusterPlan.get("user");if(!b)return a.abort(),void(this.isCheckingUser||this.requestAuth());var c=b.name,d=b.passwd,e=c.concat(":",d);a.setRequestHeader("Authorization","Basic "+btoa(e))},requestAuth:function(){this.isCheckingUser=!0,this.clusterPlan.set({user:null});var a=new window.LoginModalView;a.render()},getNewRoute:function(a){return"statistics"===a?this.clusterPlan.getCoordinator()+"/_admin/"+a:this.clusterPlan.getCoordinator()+"/_admin/aardvark/cluster/"+a},initialRoute:function(){this.initial()},updateAllUrls:function(){_.each(this.toUpdate,function(a){a.updateUrl()})},registerForUpdate:function(a){this.toUpdate.push(a),a.updateUrl()},initialize:function(){this.footerView=new window.FooterView,this.footerView.render();var a=this;this.dygraphConfig=window.dygraphConfig,window.modalView=new window.ModalView,this.initial=this.planScenario,this.isCheckingUser=!1,this.bind("all",function(b,c){b.split(":");"route"===b&&"showCluster"!==c&&(a.showClusterView&&(a.showClusterView.stopUpdating(),a.shutdownView.unrender()),a.dashboardView&&a.dashboardView.stopUpdating())}),this.toUpdate=[],this.clusterPlan=new window.ClusterPlan,this.clusterPlan.fetch({async:!1}),$(window).resize(function(){a.handleResize()})},showCluster:function(){this.showClusterView||(this.showClusterView=new window.ShowClusterView({dygraphConfig:this.dygraphConfig})),this.shutdownView||(this.shutdownView=new window.ShutdownButtonView({overview:this.showClusterView})),this.shutdownView.render(),this.showClusterView.render()},showShards:function(){this.showShardsView||(this.showShardsView=new window.ShowShardsView),this.showShardsView.render()},handleResize:function(){this.dashboardView&&this.dashboardView.resize(),this.showClusterView&&this.showClusterView.resize()},planTest:function(){this.planTestView||(this.planTestView=new window.PlanTestView({model:this.clusterPlan})),this.planTestView.render()},planAsymmetric:function(){this.planSymmetricView||(this.planSymmetricView=new window.PlanSymmetricView({model:this.clusterPlan})),this.planSymmetricView.render(!1)},planScenario:function(){this.planScenarioSelector||(this.planScenarioSelector=new window.PlanScenarioSelectorView),this.planScenarioSelector.render()},handleClusterDown:function(){this.clusterDownView||(this.clusterDownView=new window.ClusterDownView),this.clusterDownView.render()},dashboard:function(){var a=this.serverToShow;return a?(a.addAuth=this.addAuth.bind(this),this.dashboardView=new window.ServerDashboardView({dygraphConfig:this.dygraphConfig,serverToShow:this.serverToShow,database:{hasSystemAccess:function(){return!0}}}),void this.dashboardView.render()):void this.navigate("",{trigger:!0})},clusterUnreachable:function(){this.showClusterView&&(this.showClusterView.stopUpdating(),this.shutdownView.unrender()),this.unreachableView||(this.unreachableView=new window.ClusterUnreachableView),this.unreachableView.render()}})}(),function(){"use strict";$.get("cluster/amIDispatcher",function(a){if(!a){var b=window.location.origin;b+=window.location.pathname,b=b.replace("cluster","index"),window.location.replace(b)}}),window.location.hash="",$(document).ready(function(){window.App=new window.ClusterRouter,Backbone.history.start(),window.App.clusterPlan.get("plan")?window.App.clusterPlan.isAlive()?window.App.initial=window.App.showCluster:window.App.initial=window.App.handleClusterDown:window.App.initial=window.App.planScenario,window.App.initialRoute(),window.App.handleResize()})}(); \ No newline at end of file diff --git a/js/apps/system/_admin/aardvark/APP/clusterFrontend/build/cluster.min.js.gz b/js/apps/system/_admin/aardvark/APP/clusterFrontend/build/cluster.min.js.gz index 1f84f58815..0c891c98ad 100644 Binary files a/js/apps/system/_admin/aardvark/APP/clusterFrontend/build/cluster.min.js.gz and b/js/apps/system/_admin/aardvark/APP/clusterFrontend/build/cluster.min.js.gz differ diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/app.js b/js/apps/system/_admin/aardvark/APP/frontend/build/app.js index 307622717a..3f095da1c3 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/app.js +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/app.js @@ -13078,7 +13078,7 @@ module.define("underscore", function(exports, module) { //////////////////////////////////////////////////////////////////////////////// /// @brief ArangoError //////////////////////////////////////////////////////////////////////////////// -if(global.ArangoError){exports.ArangoError = global.ArangoError;delete global.ArangoError;}else {exports.ArangoError = function(error){if(error !== undefined){this.error = error.error;this.code = error.code;this.errorNum = error.errorNum;this.errorMessage = error.errorMessage;}this.message = this.toString();};exports.ArangoError.prototype = new Error();}exports.ArangoError.prototype._PRINT = function(context){context.output += this.toString();};exports.ArangoError.prototype.toString = function(){var errorNum=this.errorNum;var errorMessage=this.errorMessage || this.message;return '[ArangoError ' + errorNum + ': ' + errorMessage + ']';}; //////////////////////////////////////////////////////////////////////////////// +if(global.ArangoError){exports.ArangoError = global.ArangoError;delete global.ArangoError;}else {exports.ArangoError = function(error){if(error !== undefined){this.error = error.error;this.code = error.code;this.errorNum = error.errorNum;this.errorMessage = error.errorMessage;}};exports.ArangoError.prototype = new Error();}Object.defineProperty(exports.ArangoError.prototype,'message',{configurable:true,enumerable:true,get:function get(){return this.errorMessage;}});exports.ArangoError.prototype.name = 'ArangoError';exports.ArangoError.prototype._PRINT = function(context){context.output += '[' + this.toString() + ']';};exports.ArangoError.prototype.toString = function(){return this.name + ' ' + this.errorNum + ': ' + this.message;}; //////////////////////////////////////////////////////////////////////////////// /// @brief threadNumber //////////////////////////////////////////////////////////////////////////////// exports.threadNumber = 0;if(global.THREAD_NUMBER){exports.threadNumber = global.THREAD_NUMBER;delete global.THREAD_NUMBER;} //////////////////////////////////////////////////////////////////////////////// @@ -13420,7 +13420,7 @@ global.start_color_print = function start_color_print(color){require('internal') global.stop_color_print = function stop_color_print(){require('internal').stopColorPrint();};if(global.EXPORTS_SLOW_BUFFER){Object.keys(global.EXPORTS_SLOW_BUFFER).forEach(function(key){exports[key] = global.EXPORTS_SLOW_BUFFER[key];});delete global.EXPORTS_SLOW_BUFFER;}if(global.APP_PATH){exports.appPath = global.APP_PATH;delete global.APP_PATH;}return exports;})()); /*jshint maxlen: 240 */ /*global require */ //////////////////////////////////////////////////////////////////////////////// /// @brief auto-generated file generated from errors.dat //////////////////////////////////////////////////////////////////////////////// -(function(){"use strict";var internal=require("internal");internal.errors = {"ERROR_NO_ERROR":{"code":0,"message":"no error"},"ERROR_FAILED":{"code":1,"message":"failed"},"ERROR_SYS_ERROR":{"code":2,"message":"system error"},"ERROR_OUT_OF_MEMORY":{"code":3,"message":"out of memory"},"ERROR_INTERNAL":{"code":4,"message":"internal error"},"ERROR_ILLEGAL_NUMBER":{"code":5,"message":"illegal number"},"ERROR_NUMERIC_OVERFLOW":{"code":6,"message":"numeric overflow"},"ERROR_ILLEGAL_OPTION":{"code":7,"message":"illegal option"},"ERROR_DEAD_PID":{"code":8,"message":"dead process identifier"},"ERROR_NOT_IMPLEMENTED":{"code":9,"message":"not implemented"},"ERROR_BAD_PARAMETER":{"code":10,"message":"bad parameter"},"ERROR_FORBIDDEN":{"code":11,"message":"forbidden"},"ERROR_OUT_OF_MEMORY_MMAP":{"code":12,"message":"out of memory in mmap"},"ERROR_CORRUPTED_CSV":{"code":13,"message":"csv is corrupt"},"ERROR_FILE_NOT_FOUND":{"code":14,"message":"file not found"},"ERROR_CANNOT_WRITE_FILE":{"code":15,"message":"cannot write file"},"ERROR_CANNOT_OVERWRITE_FILE":{"code":16,"message":"cannot overwrite file"},"ERROR_TYPE_ERROR":{"code":17,"message":"type error"},"ERROR_LOCK_TIMEOUT":{"code":18,"message":"lock timeout"},"ERROR_CANNOT_CREATE_DIRECTORY":{"code":19,"message":"cannot create directory"},"ERROR_CANNOT_CREATE_TEMP_FILE":{"code":20,"message":"cannot create temporary file"},"ERROR_REQUEST_CANCELED":{"code":21,"message":"canceled request"},"ERROR_DEBUG":{"code":22,"message":"intentional debug error"},"ERROR_AID_NOT_FOUND":{"code":23,"message":"internal error with attribute ID in shaper"},"ERROR_LEGEND_INCOMPLETE":{"code":24,"message":"internal error if a legend could not be created"},"ERROR_IP_ADDRESS_INVALID":{"code":25,"message":"IP address is invalid"},"ERROR_LEGEND_NOT_IN_WAL_FILE":{"code":26,"message":"internal error if a legend for a marker does not yet exist in the same WAL file"},"ERROR_FILE_EXISTS":{"code":27,"message":"file exists"},"ERROR_LOCKED":{"code":28,"message":"locked"},"ERROR_DEADLOCK":{"code":29,"message":"deadlock detected"},"ERROR_HTTP_BAD_PARAMETER":{"code":400,"message":"bad parameter"},"ERROR_HTTP_UNAUTHORIZED":{"code":401,"message":"unauthorized"},"ERROR_HTTP_FORBIDDEN":{"code":403,"message":"forbidden"},"ERROR_HTTP_NOT_FOUND":{"code":404,"message":"not found"},"ERROR_HTTP_METHOD_NOT_ALLOWED":{"code":405,"message":"method not supported"},"ERROR_HTTP_PRECONDITION_FAILED":{"code":412,"message":"precondition failed"},"ERROR_HTTP_SERVER_ERROR":{"code":500,"message":"internal server error"},"ERROR_HTTP_CORRUPTED_JSON":{"code":600,"message":"invalid JSON object"},"ERROR_HTTP_SUPERFLUOUS_SUFFICES":{"code":601,"message":"superfluous URL suffices"},"ERROR_ARANGO_ILLEGAL_STATE":{"code":1000,"message":"illegal state"},"ERROR_ARANGO_SHAPER_FAILED":{"code":1001,"message":"could not shape document"},"ERROR_ARANGO_DATAFILE_SEALED":{"code":1002,"message":"datafile sealed"},"ERROR_ARANGO_UNKNOWN_COLLECTION_TYPE":{"code":1003,"message":"unknown type"},"ERROR_ARANGO_READ_ONLY":{"code":1004,"message":"read only"},"ERROR_ARANGO_DUPLICATE_IDENTIFIER":{"code":1005,"message":"duplicate identifier"},"ERROR_ARANGO_DATAFILE_UNREADABLE":{"code":1006,"message":"datafile unreadable"},"ERROR_ARANGO_DATAFILE_EMPTY":{"code":1007,"message":"datafile empty"},"ERROR_ARANGO_RECOVERY":{"code":1008,"message":"logfile recovery error"},"ERROR_ARANGO_CORRUPTED_DATAFILE":{"code":1100,"message":"corrupted datafile"},"ERROR_ARANGO_ILLEGAL_PARAMETER_FILE":{"code":1101,"message":"illegal or unreadable parameter file"},"ERROR_ARANGO_CORRUPTED_COLLECTION":{"code":1102,"message":"corrupted collection"},"ERROR_ARANGO_MMAP_FAILED":{"code":1103,"message":"mmap failed"},"ERROR_ARANGO_FILESYSTEM_FULL":{"code":1104,"message":"filesystem full"},"ERROR_ARANGO_NO_JOURNAL":{"code":1105,"message":"no journal"},"ERROR_ARANGO_DATAFILE_ALREADY_EXISTS":{"code":1106,"message":"cannot create/rename datafile because it already exists"},"ERROR_ARANGO_DATADIR_LOCKED":{"code":1107,"message":"database directory is locked"},"ERROR_ARANGO_COLLECTION_DIRECTORY_ALREADY_EXISTS":{"code":1108,"message":"cannot create/rename collection because directory already exists"},"ERROR_ARANGO_MSYNC_FAILED":{"code":1109,"message":"msync failed"},"ERROR_ARANGO_DATADIR_UNLOCKABLE":{"code":1110,"message":"cannot lock database directory"},"ERROR_ARANGO_SYNC_TIMEOUT":{"code":1111,"message":"sync timeout"},"ERROR_ARANGO_CONFLICT":{"code":1200,"message":"conflict"},"ERROR_ARANGO_DATADIR_INVALID":{"code":1201,"message":"invalid database directory"},"ERROR_ARANGO_DOCUMENT_NOT_FOUND":{"code":1202,"message":"document not found"},"ERROR_ARANGO_COLLECTION_NOT_FOUND":{"code":1203,"message":"collection not found"},"ERROR_ARANGO_COLLECTION_PARAMETER_MISSING":{"code":1204,"message":"parameter 'collection' not found"},"ERROR_ARANGO_DOCUMENT_HANDLE_BAD":{"code":1205,"message":"illegal document handle"},"ERROR_ARANGO_MAXIMAL_SIZE_TOO_SMALL":{"code":1206,"message":"maximal size of journal too small"},"ERROR_ARANGO_DUPLICATE_NAME":{"code":1207,"message":"duplicate name"},"ERROR_ARANGO_ILLEGAL_NAME":{"code":1208,"message":"illegal name"},"ERROR_ARANGO_NO_INDEX":{"code":1209,"message":"no suitable index known"},"ERROR_ARANGO_UNIQUE_CONSTRAINT_VIOLATED":{"code":1210,"message":"unique constraint violated"},"ERROR_ARANGO_INDEX_NOT_FOUND":{"code":1212,"message":"index not found"},"ERROR_ARANGO_CROSS_COLLECTION_REQUEST":{"code":1213,"message":"cross collection request not allowed"},"ERROR_ARANGO_INDEX_HANDLE_BAD":{"code":1214,"message":"illegal index handle"},"ERROR_ARANGO_CAP_CONSTRAINT_ALREADY_DEFINED":{"code":1215,"message":"cap constraint already defined"},"ERROR_ARANGO_DOCUMENT_TOO_LARGE":{"code":1216,"message":"document too large"},"ERROR_ARANGO_COLLECTION_NOT_UNLOADED":{"code":1217,"message":"collection must be unloaded"},"ERROR_ARANGO_COLLECTION_TYPE_INVALID":{"code":1218,"message":"collection type invalid"},"ERROR_ARANGO_VALIDATION_FAILED":{"code":1219,"message":"validator failed"},"ERROR_ARANGO_ATTRIBUTE_PARSER_FAILED":{"code":1220,"message":"parsing attribute name definition failed"},"ERROR_ARANGO_DOCUMENT_KEY_BAD":{"code":1221,"message":"illegal document key"},"ERROR_ARANGO_DOCUMENT_KEY_UNEXPECTED":{"code":1222,"message":"unexpected document key"},"ERROR_ARANGO_DATADIR_NOT_WRITABLE":{"code":1224,"message":"server database directory not writable"},"ERROR_ARANGO_OUT_OF_KEYS":{"code":1225,"message":"out of keys"},"ERROR_ARANGO_DOCUMENT_KEY_MISSING":{"code":1226,"message":"missing document key"},"ERROR_ARANGO_DOCUMENT_TYPE_INVALID":{"code":1227,"message":"invalid document type"},"ERROR_ARANGO_DATABASE_NOT_FOUND":{"code":1228,"message":"database not found"},"ERROR_ARANGO_DATABASE_NAME_INVALID":{"code":1229,"message":"database name invalid"},"ERROR_ARANGO_USE_SYSTEM_DATABASE":{"code":1230,"message":"operation only allowed in system database"},"ERROR_ARANGO_ENDPOINT_NOT_FOUND":{"code":1231,"message":"endpoint not found"},"ERROR_ARANGO_INVALID_KEY_GENERATOR":{"code":1232,"message":"invalid key generator"},"ERROR_ARANGO_INVALID_EDGE_ATTRIBUTE":{"code":1233,"message":"edge attribute missing"},"ERROR_ARANGO_INDEX_DOCUMENT_ATTRIBUTE_MISSING":{"code":1234,"message":"index insertion warning - attribute missing in document"},"ERROR_ARANGO_INDEX_CREATION_FAILED":{"code":1235,"message":"index creation failed"},"ERROR_ARANGO_WRITE_THROTTLE_TIMEOUT":{"code":1236,"message":"write-throttling timeout"},"ERROR_ARANGO_COLLECTION_TYPE_MISMATCH":{"code":1237,"message":"collection type mismatch"},"ERROR_ARANGO_COLLECTION_NOT_LOADED":{"code":1238,"message":"collection not loaded"},"ERROR_ARANGO_DATAFILE_FULL":{"code":1300,"message":"datafile full"},"ERROR_ARANGO_EMPTY_DATADIR":{"code":1301,"message":"server database directory is empty"},"ERROR_REPLICATION_NO_RESPONSE":{"code":1400,"message":"no response"},"ERROR_REPLICATION_INVALID_RESPONSE":{"code":1401,"message":"invalid response"},"ERROR_REPLICATION_MASTER_ERROR":{"code":1402,"message":"master error"},"ERROR_REPLICATION_MASTER_INCOMPATIBLE":{"code":1403,"message":"master incompatible"},"ERROR_REPLICATION_MASTER_CHANGE":{"code":1404,"message":"master change"},"ERROR_REPLICATION_LOOP":{"code":1405,"message":"loop detected"},"ERROR_REPLICATION_UNEXPECTED_MARKER":{"code":1406,"message":"unexpected marker"},"ERROR_REPLICATION_INVALID_APPLIER_STATE":{"code":1407,"message":"invalid applier state"},"ERROR_REPLICATION_UNEXPECTED_TRANSACTION":{"code":1408,"message":"invalid transaction"},"ERROR_REPLICATION_INVALID_APPLIER_CONFIGURATION":{"code":1410,"message":"invalid replication applier configuration"},"ERROR_REPLICATION_RUNNING":{"code":1411,"message":"cannot perform operation while applier is running"},"ERROR_REPLICATION_APPLIER_STOPPED":{"code":1412,"message":"replication stopped"},"ERROR_REPLICATION_NO_START_TICK":{"code":1413,"message":"no start tick"},"ERROR_REPLICATION_START_TICK_NOT_PRESENT":{"code":1414,"message":"start tick not present"},"ERROR_CLUSTER_NO_AGENCY":{"code":1450,"message":"could not connect to agency"},"ERROR_CLUSTER_NO_COORDINATOR_HEADER":{"code":1451,"message":"missing coordinator header"},"ERROR_CLUSTER_COULD_NOT_LOCK_PLAN":{"code":1452,"message":"could not lock plan in agency"},"ERROR_CLUSTER_COLLECTION_ID_EXISTS":{"code":1453,"message":"collection ID already exists"},"ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION_IN_PLAN":{"code":1454,"message":"could not create collection in plan"},"ERROR_CLUSTER_COULD_NOT_READ_CURRENT_VERSION":{"code":1455,"message":"could not read version in current in agency"},"ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION":{"code":1456,"message":"could not create collection"},"ERROR_CLUSTER_TIMEOUT":{"code":1457,"message":"timeout in cluster operation"},"ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_PLAN":{"code":1458,"message":"could not remove collection from plan"},"ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_CURRENT":{"code":1459,"message":"could not remove collection from current"},"ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE_IN_PLAN":{"code":1460,"message":"could not create database in plan"},"ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE":{"code":1461,"message":"could not create database"},"ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_PLAN":{"code":1462,"message":"could not remove database from plan"},"ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_CURRENT":{"code":1463,"message":"could not remove database from current"},"ERROR_CLUSTER_SHARD_GONE":{"code":1464,"message":"no responsible shard found"},"ERROR_CLUSTER_CONNECTION_LOST":{"code":1465,"message":"cluster internal HTTP connection broken"},"ERROR_CLUSTER_MUST_NOT_SPECIFY_KEY":{"code":1466,"message":"must not specify _key for this collection"},"ERROR_CLUSTER_GOT_CONTRADICTING_ANSWERS":{"code":1467,"message":"got contradicting answers from different shards"},"ERROR_CLUSTER_NOT_ALL_SHARDING_ATTRIBUTES_GIVEN":{"code":1468,"message":"not all sharding attributes given"},"ERROR_CLUSTER_MUST_NOT_CHANGE_SHARDING_ATTRIBUTES":{"code":1469,"message":"must not change the value of a shard key attribute"},"ERROR_CLUSTER_UNSUPPORTED":{"code":1470,"message":"unsupported operation or parameter"},"ERROR_CLUSTER_ONLY_ON_COORDINATOR":{"code":1471,"message":"this operation is only valid on a coordinator in a cluster"},"ERROR_CLUSTER_READING_PLAN_AGENCY":{"code":1472,"message":"error reading Plan in agency"},"ERROR_CLUSTER_COULD_NOT_TRUNCATE_COLLECTION":{"code":1473,"message":"could not truncate collection"},"ERROR_CLUSTER_AQL_COMMUNICATION":{"code":1474,"message":"error in cluster internal communication for AQL"},"ERROR_ARANGO_DOCUMENT_NOT_FOUND_OR_SHARDING_ATTRIBUTES_CHANGED":{"code":1475,"message":"document not found or sharding attributes changed"},"ERROR_CLUSTER_COULD_NOT_DETERMINE_ID":{"code":1476,"message":"could not determine my ID from my local info"},"ERROR_CLUSTER_ONLY_ON_DBSERVER":{"code":1477,"message":"this operation is only valid on a DBserver in a cluster"},"ERROR_QUERY_KILLED":{"code":1500,"message":"query killed"},"ERROR_QUERY_PARSE":{"code":1501,"message":"%s"},"ERROR_QUERY_EMPTY":{"code":1502,"message":"query is empty"},"ERROR_QUERY_SCRIPT":{"code":1503,"message":"runtime error '%s'"},"ERROR_QUERY_NUMBER_OUT_OF_RANGE":{"code":1504,"message":"number out of range"},"ERROR_QUERY_VARIABLE_NAME_INVALID":{"code":1510,"message":"variable name '%s' has an invalid format"},"ERROR_QUERY_VARIABLE_REDECLARED":{"code":1511,"message":"variable '%s' is assigned multiple times"},"ERROR_QUERY_VARIABLE_NAME_UNKNOWN":{"code":1512,"message":"unknown variable '%s'"},"ERROR_QUERY_COLLECTION_LOCK_FAILED":{"code":1521,"message":"unable to read-lock collection %s"},"ERROR_QUERY_TOO_MANY_COLLECTIONS":{"code":1522,"message":"too many collections"},"ERROR_QUERY_DOCUMENT_ATTRIBUTE_REDECLARED":{"code":1530,"message":"document attribute '%s' is assigned multiple times"},"ERROR_QUERY_FUNCTION_NAME_UNKNOWN":{"code":1540,"message":"usage of unknown function '%s()'"},"ERROR_QUERY_FUNCTION_ARGUMENT_NUMBER_MISMATCH":{"code":1541,"message":"invalid number of arguments for function '%s()', expected number of arguments: minimum: %d, maximum: %d"},"ERROR_QUERY_FUNCTION_ARGUMENT_TYPE_MISMATCH":{"code":1542,"message":"invalid argument type in call to function '%s()'"},"ERROR_QUERY_INVALID_REGEX":{"code":1543,"message":"invalid regex value"},"ERROR_QUERY_BIND_PARAMETERS_INVALID":{"code":1550,"message":"invalid structure of bind parameters"},"ERROR_QUERY_BIND_PARAMETER_MISSING":{"code":1551,"message":"no value specified for declared bind parameter '%s'"},"ERROR_QUERY_BIND_PARAMETER_UNDECLARED":{"code":1552,"message":"bind parameter '%s' was not declared in the query"},"ERROR_QUERY_BIND_PARAMETER_TYPE":{"code":1553,"message":"bind parameter '%s' has an invalid value or type"},"ERROR_QUERY_INVALID_LOGICAL_VALUE":{"code":1560,"message":"invalid logical value"},"ERROR_QUERY_INVALID_ARITHMETIC_VALUE":{"code":1561,"message":"invalid arithmetic value"},"ERROR_QUERY_DIVISION_BY_ZERO":{"code":1562,"message":"division by zero"},"ERROR_QUERY_ARRAY_EXPECTED":{"code":1563,"message":"array expected"},"ERROR_QUERY_FAIL_CALLED":{"code":1569,"message":"FAIL(%s) called"},"ERROR_QUERY_GEO_INDEX_MISSING":{"code":1570,"message":"no suitable geo index found for geo restriction on '%s'"},"ERROR_QUERY_FULLTEXT_INDEX_MISSING":{"code":1571,"message":"no suitable fulltext index found for fulltext query on '%s'"},"ERROR_QUERY_INVALID_DATE_VALUE":{"code":1572,"message":"invalid date value"},"ERROR_QUERY_MULTI_MODIFY":{"code":1573,"message":"multi-modify query"},"ERROR_QUERY_INVALID_AGGREGATE_EXPRESSION":{"code":1574,"message":"invalid aggregate expression"},"ERROR_QUERY_COMPILE_TIME_OPTIONS":{"code":1575,"message":"query options must be readable at query compile time"},"ERROR_QUERY_EXCEPTION_OPTIONS":{"code":1576,"message":"query options expected"},"ERROR_QUERY_COLLECTION_USED_IN_EXPRESSION":{"code":1577,"message":"collection '%s' used as expression operand"},"ERROR_QUERY_DISALLOWED_DYNAMIC_CALL":{"code":1578,"message":"disallowed dynamic call to '%s'"},"ERROR_QUERY_ACCESS_AFTER_MODIFICATION":{"code":1579,"message":"access after data-modification"},"ERROR_QUERY_FUNCTION_INVALID_NAME":{"code":1580,"message":"invalid user function name"},"ERROR_QUERY_FUNCTION_INVALID_CODE":{"code":1581,"message":"invalid user function code"},"ERROR_QUERY_FUNCTION_NOT_FOUND":{"code":1582,"message":"user function '%s()' not found"},"ERROR_QUERY_FUNCTION_RUNTIME_ERROR":{"code":1583,"message":"user function runtime error: %s"},"ERROR_QUERY_BAD_JSON_PLAN":{"code":1590,"message":"bad execution plan JSON"},"ERROR_QUERY_NOT_FOUND":{"code":1591,"message":"query ID not found"},"ERROR_QUERY_IN_USE":{"code":1592,"message":"query with this ID is in use"},"ERROR_CURSOR_NOT_FOUND":{"code":1600,"message":"cursor not found"},"ERROR_CURSOR_BUSY":{"code":1601,"message":"cursor is busy"},"ERROR_TRANSACTION_INTERNAL":{"code":1650,"message":"internal transaction error"},"ERROR_TRANSACTION_NESTED":{"code":1651,"message":"nested transactions detected"},"ERROR_TRANSACTION_UNREGISTERED_COLLECTION":{"code":1652,"message":"unregistered collection used in transaction"},"ERROR_TRANSACTION_DISALLOWED_OPERATION":{"code":1653,"message":"disallowed operation inside transaction"},"ERROR_TRANSACTION_ABORTED":{"code":1654,"message":"transaction aborted"},"ERROR_USER_INVALID_NAME":{"code":1700,"message":"invalid user name"},"ERROR_USER_INVALID_PASSWORD":{"code":1701,"message":"invalid password"},"ERROR_USER_DUPLICATE":{"code":1702,"message":"duplicate user"},"ERROR_USER_NOT_FOUND":{"code":1703,"message":"user not found"},"ERROR_USER_CHANGE_PASSWORD":{"code":1704,"message":"user must change his password"},"ERROR_APPLICATION_INVALID_NAME":{"code":1750,"message":"invalid application name"},"ERROR_APPLICATION_INVALID_MOUNT":{"code":1751,"message":"invalid mount"},"ERROR_APPLICATION_DOWNLOAD_FAILED":{"code":1752,"message":"application download failed"},"ERROR_APPLICATION_UPLOAD_FAILED":{"code":1753,"message":"application upload failed"},"ERROR_KEYVALUE_INVALID_KEY":{"code":1800,"message":"invalid key declaration"},"ERROR_KEYVALUE_KEY_EXISTS":{"code":1801,"message":"key already exists"},"ERROR_KEYVALUE_KEY_NOT_FOUND":{"code":1802,"message":"key not found"},"ERROR_KEYVALUE_KEY_NOT_UNIQUE":{"code":1803,"message":"key is not unique"},"ERROR_KEYVALUE_KEY_NOT_CHANGED":{"code":1804,"message":"key value not changed"},"ERROR_KEYVALUE_KEY_NOT_REMOVED":{"code":1805,"message":"key value not removed"},"ERROR_KEYVALUE_NO_VALUE":{"code":1806,"message":"missing value"},"ERROR_TASK_INVALID_ID":{"code":1850,"message":"invalid task id"},"ERROR_TASK_DUPLICATE_ID":{"code":1851,"message":"duplicate task id"},"ERROR_TASK_NOT_FOUND":{"code":1852,"message":"task not found"},"ERROR_GRAPH_INVALID_GRAPH":{"code":1901,"message":"invalid graph"},"ERROR_GRAPH_COULD_NOT_CREATE_GRAPH":{"code":1902,"message":"could not create graph"},"ERROR_GRAPH_INVALID_VERTEX":{"code":1903,"message":"invalid vertex"},"ERROR_GRAPH_COULD_NOT_CREATE_VERTEX":{"code":1904,"message":"could not create vertex"},"ERROR_GRAPH_COULD_NOT_CHANGE_VERTEX":{"code":1905,"message":"could not change vertex"},"ERROR_GRAPH_INVALID_EDGE":{"code":1906,"message":"invalid edge"},"ERROR_GRAPH_COULD_NOT_CREATE_EDGE":{"code":1907,"message":"could not create edge"},"ERROR_GRAPH_COULD_NOT_CHANGE_EDGE":{"code":1908,"message":"could not change edge"},"ERROR_GRAPH_TOO_MANY_ITERATIONS":{"code":1909,"message":"too many iterations - try increasing the value of 'maxIterations'"},"ERROR_GRAPH_INVALID_FILTER_RESULT":{"code":1910,"message":"invalid filter result"},"ERROR_GRAPH_COLLECTION_MULTI_USE":{"code":1920,"message":"multi use of edge collection in edge def"},"ERROR_GRAPH_COLLECTION_USE_IN_MULTI_GRAPHS":{"code":1921,"message":"edge collection already used in edge def"},"ERROR_GRAPH_CREATE_MISSING_NAME":{"code":1922,"message":"missing graph name"},"ERROR_GRAPH_CREATE_MALFORMED_EDGE_DEFINITION":{"code":1923,"message":"malformed edge definition"},"ERROR_GRAPH_NOT_FOUND":{"code":1924,"message":"graph not found"},"ERROR_GRAPH_DUPLICATE":{"code":1925,"message":"graph already exists"},"ERROR_GRAPH_VERTEX_COL_DOES_NOT_EXIST":{"code":1926,"message":"vertex collection does not exist or is not part of the graph"},"ERROR_GRAPH_WRONG_COLLECTION_TYPE_VERTEX":{"code":1927,"message":"not a vertex collection"},"ERROR_GRAPH_NOT_IN_ORPHAN_COLLECTION":{"code":1928,"message":"not in orphan collection"},"ERROR_GRAPH_COLLECTION_USED_IN_EDGE_DEF":{"code":1929,"message":"collection already used in edge def"},"ERROR_GRAPH_EDGE_COLLECTION_NOT_USED":{"code":1930,"message":"edge collection not used in graph"},"ERROR_GRAPH_NOT_AN_ARANGO_COLLECTION":{"code":1931,"message":" is not an ArangoCollection"},"ERROR_GRAPH_NO_GRAPH_COLLECTION":{"code":1932,"message":"collection _graphs does not exist"},"ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT_STRING":{"code":1933,"message":"Invalid example type. Has to be String, Array or Object"},"ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT":{"code":1934,"message":"Invalid example type. Has to be Array or Object"},"ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS":{"code":1935,"message":"Invalid number of arguments. Expected: "},"ERROR_GRAPH_INVALID_PARAMETER":{"code":1936,"message":"Invalid parameter type."},"ERROR_GRAPH_INVALID_ID":{"code":1937,"message":"Invalid id"},"ERROR_GRAPH_COLLECTION_USED_IN_ORPHANS":{"code":1938,"message":"collection used in orphans"},"ERROR_GRAPH_EDGE_COL_DOES_NOT_EXIST":{"code":1939,"message":"edge collection does not exist or is not part of the graph"},"ERROR_GRAPH_EMPTY":{"code":1940,"message":"empty graph"},"ERROR_SESSION_UNKNOWN":{"code":1950,"message":"unknown session"},"ERROR_SESSION_EXPIRED":{"code":1951,"message":"session expired"},"SIMPLE_CLIENT_UNKNOWN_ERROR":{"code":2000,"message":"unknown client error"},"SIMPLE_CLIENT_COULD_NOT_CONNECT":{"code":2001,"message":"could not connect to server"},"SIMPLE_CLIENT_COULD_NOT_WRITE":{"code":2002,"message":"could not write to server"},"SIMPLE_CLIENT_COULD_NOT_READ":{"code":2003,"message":"could not read from server"},"ERROR_MALFORMED_MANIFEST_FILE":{"code":3000,"message":"malformed manifest file"},"ERROR_INVALID_APPLICATION_MANIFEST":{"code":3001,"message":"manifest file is invalid"},"ERROR_MANIFEST_FILE_ATTRIBUTE_MISSING":{"code":3002,"message":"missing manifest attribute"},"ERROR_CANNOT_EXTRACT_APPLICATION_ROOT":{"code":3003,"message":"unable to extract app root path"},"ERROR_INVALID_FOXX_OPTIONS":{"code":3004,"message":"invalid foxx options"},"ERROR_FAILED_TO_EXECUTE_SCRIPT":{"code":3005,"message":"failed to execute script"},"ERROR_SYNTAX_ERROR_IN_SCRIPT":{"code":3006,"message":"syntax error in script"},"ERROR_INVALID_MOUNTPOINT":{"code":3007,"message":"mountpoint is invalid"},"ERROR_NO_FOXX_FOUND":{"code":3008,"message":"No foxx found at this location"},"ERROR_APP_NOT_FOUND":{"code":3009,"message":"App not found"},"ERROR_APP_NEEDS_CONFIGURATION":{"code":3010,"message":"App not configured"},"ERROR_MODULE_NOT_FOUND":{"code":3100,"message":"cannot locate module"},"ERROR_MODULE_SYNTAX_ERROR":{"code":3101,"message":"syntax error in module"},"ERROR_MODULE_BAD_WRAPPER":{"code":3102,"message":"failed to wrap module"},"ERROR_MODULE_FAILURE":{"code":3103,"message":"failed to invoke module"},"ERROR_MODULE_UNKNOWN_FILE_TYPE":{"code":3110,"message":"unknown file type"},"ERROR_MODULE_PATH_MUST_BE_ABSOLUTE":{"code":3111,"message":"path must be absolute"},"ERROR_MODULE_CAN_NOT_ESCAPE":{"code":3112,"message":"cannot use '..' to escape top-level-directory"},"ERROR_MODULE_DRIVE_LETTER":{"code":3113,"message":"drive local path is not supported"},"ERROR_MODULE_BAD_MODULE_ORIGIN":{"code":3120,"message":"corrupted module origin"},"ERROR_MODULE_BAD_PACKAGE_ORIGIN":{"code":3121,"message":"corrupted package origin"},"ERROR_MODULE_DOCUMENT_IS_EMPTY":{"code":3125,"message":"no content"},"ERROR_MODULE_MAIN_NOT_READABLE":{"code":3130,"message":"cannot read main file"},"ERROR_MODULE_MAIN_NOT_JS":{"code":3131,"message":"main file is not of type 'js'"},"RESULT_ELEMENT_EXISTS":{"code":10000,"message":"element not inserted into structure, because it already exists"},"RESULT_ELEMENT_NOT_FOUND":{"code":10001,"message":"element not found in structure"},"ERROR_APP_ALREADY_EXISTS":{"code":20000,"message":"newest version of app already installed"},"ERROR_QUEUE_ALREADY_EXISTS":{"code":21000,"message":"named queue already exists"},"ERROR_DISPATCHER_IS_STOPPING":{"code":21001,"message":"dispatcher stopped"},"ERROR_QUEUE_UNKNOWN":{"code":21002,"message":"named queue does not exist"},"ERROR_QUEUE_FULL":{"code":21003,"message":"named queue is full"}};})(); /*jshint -W051:true */ /*global jqconsole, Symbol */ /*eslint-disable */global.DEFINE_MODULE('console',(function(){'use strict'; /*eslint-enable */ //////////////////////////////////////////////////////////////////////////////// +(function(){"use strict";var internal=require("internal");internal.errors = {"ERROR_NO_ERROR":{"code":0,"message":"no error"},"ERROR_FAILED":{"code":1,"message":"failed"},"ERROR_SYS_ERROR":{"code":2,"message":"system error"},"ERROR_OUT_OF_MEMORY":{"code":3,"message":"out of memory"},"ERROR_INTERNAL":{"code":4,"message":"internal error"},"ERROR_ILLEGAL_NUMBER":{"code":5,"message":"illegal number"},"ERROR_NUMERIC_OVERFLOW":{"code":6,"message":"numeric overflow"},"ERROR_ILLEGAL_OPTION":{"code":7,"message":"illegal option"},"ERROR_DEAD_PID":{"code":8,"message":"dead process identifier"},"ERROR_NOT_IMPLEMENTED":{"code":9,"message":"not implemented"},"ERROR_BAD_PARAMETER":{"code":10,"message":"bad parameter"},"ERROR_FORBIDDEN":{"code":11,"message":"forbidden"},"ERROR_OUT_OF_MEMORY_MMAP":{"code":12,"message":"out of memory in mmap"},"ERROR_CORRUPTED_CSV":{"code":13,"message":"csv is corrupt"},"ERROR_FILE_NOT_FOUND":{"code":14,"message":"file not found"},"ERROR_CANNOT_WRITE_FILE":{"code":15,"message":"cannot write file"},"ERROR_CANNOT_OVERWRITE_FILE":{"code":16,"message":"cannot overwrite file"},"ERROR_TYPE_ERROR":{"code":17,"message":"type error"},"ERROR_LOCK_TIMEOUT":{"code":18,"message":"lock timeout"},"ERROR_CANNOT_CREATE_DIRECTORY":{"code":19,"message":"cannot create directory"},"ERROR_CANNOT_CREATE_TEMP_FILE":{"code":20,"message":"cannot create temporary file"},"ERROR_REQUEST_CANCELED":{"code":21,"message":"canceled request"},"ERROR_DEBUG":{"code":22,"message":"intentional debug error"},"ERROR_AID_NOT_FOUND":{"code":23,"message":"internal error with attribute ID in shaper"},"ERROR_LEGEND_INCOMPLETE":{"code":24,"message":"internal error if a legend could not be created"},"ERROR_IP_ADDRESS_INVALID":{"code":25,"message":"IP address is invalid"},"ERROR_LEGEND_NOT_IN_WAL_FILE":{"code":26,"message":"internal error if a legend for a marker does not yet exist in the same WAL file"},"ERROR_FILE_EXISTS":{"code":27,"message":"file exists"},"ERROR_LOCKED":{"code":28,"message":"locked"},"ERROR_DEADLOCK":{"code":29,"message":"deadlock detected"},"ERROR_HTTP_BAD_PARAMETER":{"code":400,"message":"bad parameter"},"ERROR_HTTP_UNAUTHORIZED":{"code":401,"message":"unauthorized"},"ERROR_HTTP_FORBIDDEN":{"code":403,"message":"forbidden"},"ERROR_HTTP_NOT_FOUND":{"code":404,"message":"not found"},"ERROR_HTTP_METHOD_NOT_ALLOWED":{"code":405,"message":"method not supported"},"ERROR_HTTP_PRECONDITION_FAILED":{"code":412,"message":"precondition failed"},"ERROR_HTTP_SERVER_ERROR":{"code":500,"message":"internal server error"},"ERROR_HTTP_CORRUPTED_JSON":{"code":600,"message":"invalid JSON object"},"ERROR_HTTP_SUPERFLUOUS_SUFFICES":{"code":601,"message":"superfluous URL suffices"},"ERROR_ARANGO_ILLEGAL_STATE":{"code":1000,"message":"illegal state"},"ERROR_ARANGO_SHAPER_FAILED":{"code":1001,"message":"could not shape document"},"ERROR_ARANGO_DATAFILE_SEALED":{"code":1002,"message":"datafile sealed"},"ERROR_ARANGO_UNKNOWN_COLLECTION_TYPE":{"code":1003,"message":"unknown type"},"ERROR_ARANGO_READ_ONLY":{"code":1004,"message":"read only"},"ERROR_ARANGO_DUPLICATE_IDENTIFIER":{"code":1005,"message":"duplicate identifier"},"ERROR_ARANGO_DATAFILE_UNREADABLE":{"code":1006,"message":"datafile unreadable"},"ERROR_ARANGO_DATAFILE_EMPTY":{"code":1007,"message":"datafile empty"},"ERROR_ARANGO_RECOVERY":{"code":1008,"message":"logfile recovery error"},"ERROR_ARANGO_CORRUPTED_DATAFILE":{"code":1100,"message":"corrupted datafile"},"ERROR_ARANGO_ILLEGAL_PARAMETER_FILE":{"code":1101,"message":"illegal or unreadable parameter file"},"ERROR_ARANGO_CORRUPTED_COLLECTION":{"code":1102,"message":"corrupted collection"},"ERROR_ARANGO_MMAP_FAILED":{"code":1103,"message":"mmap failed"},"ERROR_ARANGO_FILESYSTEM_FULL":{"code":1104,"message":"filesystem full"},"ERROR_ARANGO_NO_JOURNAL":{"code":1105,"message":"no journal"},"ERROR_ARANGO_DATAFILE_ALREADY_EXISTS":{"code":1106,"message":"cannot create/rename datafile because it already exists"},"ERROR_ARANGO_DATADIR_LOCKED":{"code":1107,"message":"database directory is locked"},"ERROR_ARANGO_COLLECTION_DIRECTORY_ALREADY_EXISTS":{"code":1108,"message":"cannot create/rename collection because directory already exists"},"ERROR_ARANGO_MSYNC_FAILED":{"code":1109,"message":"msync failed"},"ERROR_ARANGO_DATADIR_UNLOCKABLE":{"code":1110,"message":"cannot lock database directory"},"ERROR_ARANGO_SYNC_TIMEOUT":{"code":1111,"message":"sync timeout"},"ERROR_ARANGO_CONFLICT":{"code":1200,"message":"conflict"},"ERROR_ARANGO_DATADIR_INVALID":{"code":1201,"message":"invalid database directory"},"ERROR_ARANGO_DOCUMENT_NOT_FOUND":{"code":1202,"message":"document not found"},"ERROR_ARANGO_COLLECTION_NOT_FOUND":{"code":1203,"message":"collection not found"},"ERROR_ARANGO_COLLECTION_PARAMETER_MISSING":{"code":1204,"message":"parameter 'collection' not found"},"ERROR_ARANGO_DOCUMENT_HANDLE_BAD":{"code":1205,"message":"illegal document handle"},"ERROR_ARANGO_MAXIMAL_SIZE_TOO_SMALL":{"code":1206,"message":"maximal size of journal too small"},"ERROR_ARANGO_DUPLICATE_NAME":{"code":1207,"message":"duplicate name"},"ERROR_ARANGO_ILLEGAL_NAME":{"code":1208,"message":"illegal name"},"ERROR_ARANGO_NO_INDEX":{"code":1209,"message":"no suitable index known"},"ERROR_ARANGO_UNIQUE_CONSTRAINT_VIOLATED":{"code":1210,"message":"unique constraint violated"},"ERROR_ARANGO_INDEX_NOT_FOUND":{"code":1212,"message":"index not found"},"ERROR_ARANGO_CROSS_COLLECTION_REQUEST":{"code":1213,"message":"cross collection request not allowed"},"ERROR_ARANGO_INDEX_HANDLE_BAD":{"code":1214,"message":"illegal index handle"},"ERROR_ARANGO_CAP_CONSTRAINT_ALREADY_DEFINED":{"code":1215,"message":"cap constraint already defined"},"ERROR_ARANGO_DOCUMENT_TOO_LARGE":{"code":1216,"message":"document too large"},"ERROR_ARANGO_COLLECTION_NOT_UNLOADED":{"code":1217,"message":"collection must be unloaded"},"ERROR_ARANGO_COLLECTION_TYPE_INVALID":{"code":1218,"message":"collection type invalid"},"ERROR_ARANGO_VALIDATION_FAILED":{"code":1219,"message":"validator failed"},"ERROR_ARANGO_ATTRIBUTE_PARSER_FAILED":{"code":1220,"message":"parsing attribute name definition failed"},"ERROR_ARANGO_DOCUMENT_KEY_BAD":{"code":1221,"message":"illegal document key"},"ERROR_ARANGO_DOCUMENT_KEY_UNEXPECTED":{"code":1222,"message":"unexpected document key"},"ERROR_ARANGO_DATADIR_NOT_WRITABLE":{"code":1224,"message":"server database directory not writable"},"ERROR_ARANGO_OUT_OF_KEYS":{"code":1225,"message":"out of keys"},"ERROR_ARANGO_DOCUMENT_KEY_MISSING":{"code":1226,"message":"missing document key"},"ERROR_ARANGO_DOCUMENT_TYPE_INVALID":{"code":1227,"message":"invalid document type"},"ERROR_ARANGO_DATABASE_NOT_FOUND":{"code":1228,"message":"database not found"},"ERROR_ARANGO_DATABASE_NAME_INVALID":{"code":1229,"message":"database name invalid"},"ERROR_ARANGO_USE_SYSTEM_DATABASE":{"code":1230,"message":"operation only allowed in system database"},"ERROR_ARANGO_ENDPOINT_NOT_FOUND":{"code":1231,"message":"endpoint not found"},"ERROR_ARANGO_INVALID_KEY_GENERATOR":{"code":1232,"message":"invalid key generator"},"ERROR_ARANGO_INVALID_EDGE_ATTRIBUTE":{"code":1233,"message":"edge attribute missing"},"ERROR_ARANGO_INDEX_DOCUMENT_ATTRIBUTE_MISSING":{"code":1234,"message":"index insertion warning - attribute missing in document"},"ERROR_ARANGO_INDEX_CREATION_FAILED":{"code":1235,"message":"index creation failed"},"ERROR_ARANGO_WRITE_THROTTLE_TIMEOUT":{"code":1236,"message":"write-throttling timeout"},"ERROR_ARANGO_COLLECTION_TYPE_MISMATCH":{"code":1237,"message":"collection type mismatch"},"ERROR_ARANGO_COLLECTION_NOT_LOADED":{"code":1238,"message":"collection not loaded"},"ERROR_ARANGO_DATAFILE_FULL":{"code":1300,"message":"datafile full"},"ERROR_ARANGO_EMPTY_DATADIR":{"code":1301,"message":"server database directory is empty"},"ERROR_REPLICATION_NO_RESPONSE":{"code":1400,"message":"no response"},"ERROR_REPLICATION_INVALID_RESPONSE":{"code":1401,"message":"invalid response"},"ERROR_REPLICATION_MASTER_ERROR":{"code":1402,"message":"master error"},"ERROR_REPLICATION_MASTER_INCOMPATIBLE":{"code":1403,"message":"master incompatible"},"ERROR_REPLICATION_MASTER_CHANGE":{"code":1404,"message":"master change"},"ERROR_REPLICATION_LOOP":{"code":1405,"message":"loop detected"},"ERROR_REPLICATION_UNEXPECTED_MARKER":{"code":1406,"message":"unexpected marker"},"ERROR_REPLICATION_INVALID_APPLIER_STATE":{"code":1407,"message":"invalid applier state"},"ERROR_REPLICATION_UNEXPECTED_TRANSACTION":{"code":1408,"message":"invalid transaction"},"ERROR_REPLICATION_INVALID_APPLIER_CONFIGURATION":{"code":1410,"message":"invalid replication applier configuration"},"ERROR_REPLICATION_RUNNING":{"code":1411,"message":"cannot perform operation while applier is running"},"ERROR_REPLICATION_APPLIER_STOPPED":{"code":1412,"message":"replication stopped"},"ERROR_REPLICATION_NO_START_TICK":{"code":1413,"message":"no start tick"},"ERROR_REPLICATION_START_TICK_NOT_PRESENT":{"code":1414,"message":"start tick not present"},"ERROR_CLUSTER_NO_AGENCY":{"code":1450,"message":"could not connect to agency"},"ERROR_CLUSTER_NO_COORDINATOR_HEADER":{"code":1451,"message":"missing coordinator header"},"ERROR_CLUSTER_COULD_NOT_LOCK_PLAN":{"code":1452,"message":"could not lock plan in agency"},"ERROR_CLUSTER_COLLECTION_ID_EXISTS":{"code":1453,"message":"collection ID already exists"},"ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION_IN_PLAN":{"code":1454,"message":"could not create collection in plan"},"ERROR_CLUSTER_COULD_NOT_READ_CURRENT_VERSION":{"code":1455,"message":"could not read version in current in agency"},"ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION":{"code":1456,"message":"could not create collection"},"ERROR_CLUSTER_TIMEOUT":{"code":1457,"message":"timeout in cluster operation"},"ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_PLAN":{"code":1458,"message":"could not remove collection from plan"},"ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_CURRENT":{"code":1459,"message":"could not remove collection from current"},"ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE_IN_PLAN":{"code":1460,"message":"could not create database in plan"},"ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE":{"code":1461,"message":"could not create database"},"ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_PLAN":{"code":1462,"message":"could not remove database from plan"},"ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_CURRENT":{"code":1463,"message":"could not remove database from current"},"ERROR_CLUSTER_SHARD_GONE":{"code":1464,"message":"no responsible shard found"},"ERROR_CLUSTER_CONNECTION_LOST":{"code":1465,"message":"cluster internal HTTP connection broken"},"ERROR_CLUSTER_MUST_NOT_SPECIFY_KEY":{"code":1466,"message":"must not specify _key for this collection"},"ERROR_CLUSTER_GOT_CONTRADICTING_ANSWERS":{"code":1467,"message":"got contradicting answers from different shards"},"ERROR_CLUSTER_NOT_ALL_SHARDING_ATTRIBUTES_GIVEN":{"code":1468,"message":"not all sharding attributes given"},"ERROR_CLUSTER_MUST_NOT_CHANGE_SHARDING_ATTRIBUTES":{"code":1469,"message":"must not change the value of a shard key attribute"},"ERROR_CLUSTER_UNSUPPORTED":{"code":1470,"message":"unsupported operation or parameter"},"ERROR_CLUSTER_ONLY_ON_COORDINATOR":{"code":1471,"message":"this operation is only valid on a coordinator in a cluster"},"ERROR_CLUSTER_READING_PLAN_AGENCY":{"code":1472,"message":"error reading Plan in agency"},"ERROR_CLUSTER_COULD_NOT_TRUNCATE_COLLECTION":{"code":1473,"message":"could not truncate collection"},"ERROR_CLUSTER_AQL_COMMUNICATION":{"code":1474,"message":"error in cluster internal communication for AQL"},"ERROR_ARANGO_DOCUMENT_NOT_FOUND_OR_SHARDING_ATTRIBUTES_CHANGED":{"code":1475,"message":"document not found or sharding attributes changed"},"ERROR_CLUSTER_COULD_NOT_DETERMINE_ID":{"code":1476,"message":"could not determine my ID from my local info"},"ERROR_CLUSTER_ONLY_ON_DBSERVER":{"code":1477,"message":"this operation is only valid on a DBserver in a cluster"},"ERROR_QUERY_KILLED":{"code":1500,"message":"query killed"},"ERROR_QUERY_PARSE":{"code":1501,"message":"%s"},"ERROR_QUERY_EMPTY":{"code":1502,"message":"query is empty"},"ERROR_QUERY_SCRIPT":{"code":1503,"message":"runtime error '%s'"},"ERROR_QUERY_NUMBER_OUT_OF_RANGE":{"code":1504,"message":"number out of range"},"ERROR_QUERY_VARIABLE_NAME_INVALID":{"code":1510,"message":"variable name '%s' has an invalid format"},"ERROR_QUERY_VARIABLE_REDECLARED":{"code":1511,"message":"variable '%s' is assigned multiple times"},"ERROR_QUERY_VARIABLE_NAME_UNKNOWN":{"code":1512,"message":"unknown variable '%s'"},"ERROR_QUERY_COLLECTION_LOCK_FAILED":{"code":1521,"message":"unable to read-lock collection %s"},"ERROR_QUERY_TOO_MANY_COLLECTIONS":{"code":1522,"message":"too many collections"},"ERROR_QUERY_DOCUMENT_ATTRIBUTE_REDECLARED":{"code":1530,"message":"document attribute '%s' is assigned multiple times"},"ERROR_QUERY_FUNCTION_NAME_UNKNOWN":{"code":1540,"message":"usage of unknown function '%s()'"},"ERROR_QUERY_FUNCTION_ARGUMENT_NUMBER_MISMATCH":{"code":1541,"message":"invalid number of arguments for function '%s()', expected number of arguments: minimum: %d, maximum: %d"},"ERROR_QUERY_FUNCTION_ARGUMENT_TYPE_MISMATCH":{"code":1542,"message":"invalid argument type in call to function '%s()'"},"ERROR_QUERY_INVALID_REGEX":{"code":1543,"message":"invalid regex value"},"ERROR_QUERY_BIND_PARAMETERS_INVALID":{"code":1550,"message":"invalid structure of bind parameters"},"ERROR_QUERY_BIND_PARAMETER_MISSING":{"code":1551,"message":"no value specified for declared bind parameter '%s'"},"ERROR_QUERY_BIND_PARAMETER_UNDECLARED":{"code":1552,"message":"bind parameter '%s' was not declared in the query"},"ERROR_QUERY_BIND_PARAMETER_TYPE":{"code":1553,"message":"bind parameter '%s' has an invalid value or type"},"ERROR_QUERY_INVALID_LOGICAL_VALUE":{"code":1560,"message":"invalid logical value"},"ERROR_QUERY_INVALID_ARITHMETIC_VALUE":{"code":1561,"message":"invalid arithmetic value"},"ERROR_QUERY_DIVISION_BY_ZERO":{"code":1562,"message":"division by zero"},"ERROR_QUERY_ARRAY_EXPECTED":{"code":1563,"message":"array expected"},"ERROR_QUERY_FAIL_CALLED":{"code":1569,"message":"FAIL(%s) called"},"ERROR_QUERY_GEO_INDEX_MISSING":{"code":1570,"message":"no suitable geo index found for geo restriction on '%s'"},"ERROR_QUERY_FULLTEXT_INDEX_MISSING":{"code":1571,"message":"no suitable fulltext index found for fulltext query on '%s'"},"ERROR_QUERY_INVALID_DATE_VALUE":{"code":1572,"message":"invalid date value"},"ERROR_QUERY_MULTI_MODIFY":{"code":1573,"message":"multi-modify query"},"ERROR_QUERY_INVALID_AGGREGATE_EXPRESSION":{"code":1574,"message":"invalid aggregate expression"},"ERROR_QUERY_COMPILE_TIME_OPTIONS":{"code":1575,"message":"query options must be readable at query compile time"},"ERROR_QUERY_EXCEPTION_OPTIONS":{"code":1576,"message":"query options expected"},"ERROR_QUERY_COLLECTION_USED_IN_EXPRESSION":{"code":1577,"message":"collection '%s' used as expression operand"},"ERROR_QUERY_DISALLOWED_DYNAMIC_CALL":{"code":1578,"message":"disallowed dynamic call to '%s'"},"ERROR_QUERY_ACCESS_AFTER_MODIFICATION":{"code":1579,"message":"access after data-modification"},"ERROR_QUERY_FUNCTION_INVALID_NAME":{"code":1580,"message":"invalid user function name"},"ERROR_QUERY_FUNCTION_INVALID_CODE":{"code":1581,"message":"invalid user function code"},"ERROR_QUERY_FUNCTION_NOT_FOUND":{"code":1582,"message":"user function '%s()' not found"},"ERROR_QUERY_FUNCTION_RUNTIME_ERROR":{"code":1583,"message":"user function runtime error: %s"},"ERROR_QUERY_BAD_JSON_PLAN":{"code":1590,"message":"bad execution plan JSON"},"ERROR_QUERY_NOT_FOUND":{"code":1591,"message":"query ID not found"},"ERROR_QUERY_IN_USE":{"code":1592,"message":"query with this ID is in use"},"ERROR_CURSOR_NOT_FOUND":{"code":1600,"message":"cursor not found"},"ERROR_CURSOR_BUSY":{"code":1601,"message":"cursor is busy"},"ERROR_TRANSACTION_INTERNAL":{"code":1650,"message":"internal transaction error"},"ERROR_TRANSACTION_NESTED":{"code":1651,"message":"nested transactions detected"},"ERROR_TRANSACTION_UNREGISTERED_COLLECTION":{"code":1652,"message":"unregistered collection used in transaction"},"ERROR_TRANSACTION_DISALLOWED_OPERATION":{"code":1653,"message":"disallowed operation inside transaction"},"ERROR_TRANSACTION_ABORTED":{"code":1654,"message":"transaction aborted"},"ERROR_USER_INVALID_NAME":{"code":1700,"message":"invalid user name"},"ERROR_USER_INVALID_PASSWORD":{"code":1701,"message":"invalid password"},"ERROR_USER_DUPLICATE":{"code":1702,"message":"duplicate user"},"ERROR_USER_NOT_FOUND":{"code":1703,"message":"user not found"},"ERROR_USER_CHANGE_PASSWORD":{"code":1704,"message":"user must change his password"},"ERROR_APPLICATION_INVALID_NAME":{"code":1750,"message":"invalid application name"},"ERROR_APPLICATION_INVALID_MOUNT":{"code":1751,"message":"invalid mount"},"ERROR_APPLICATION_DOWNLOAD_FAILED":{"code":1752,"message":"application download failed"},"ERROR_APPLICATION_UPLOAD_FAILED":{"code":1753,"message":"application upload failed"},"ERROR_KEYVALUE_INVALID_KEY":{"code":1800,"message":"invalid key declaration"},"ERROR_KEYVALUE_KEY_EXISTS":{"code":1801,"message":"key already exists"},"ERROR_KEYVALUE_KEY_NOT_FOUND":{"code":1802,"message":"key not found"},"ERROR_KEYVALUE_KEY_NOT_UNIQUE":{"code":1803,"message":"key is not unique"},"ERROR_KEYVALUE_KEY_NOT_CHANGED":{"code":1804,"message":"key value not changed"},"ERROR_KEYVALUE_KEY_NOT_REMOVED":{"code":1805,"message":"key value not removed"},"ERROR_KEYVALUE_NO_VALUE":{"code":1806,"message":"missing value"},"ERROR_TASK_INVALID_ID":{"code":1850,"message":"invalid task id"},"ERROR_TASK_DUPLICATE_ID":{"code":1851,"message":"duplicate task id"},"ERROR_TASK_NOT_FOUND":{"code":1852,"message":"task not found"},"ERROR_GRAPH_INVALID_GRAPH":{"code":1901,"message":"invalid graph"},"ERROR_GRAPH_COULD_NOT_CREATE_GRAPH":{"code":1902,"message":"could not create graph"},"ERROR_GRAPH_INVALID_VERTEX":{"code":1903,"message":"invalid vertex"},"ERROR_GRAPH_COULD_NOT_CREATE_VERTEX":{"code":1904,"message":"could not create vertex"},"ERROR_GRAPH_COULD_NOT_CHANGE_VERTEX":{"code":1905,"message":"could not change vertex"},"ERROR_GRAPH_INVALID_EDGE":{"code":1906,"message":"invalid edge"},"ERROR_GRAPH_COULD_NOT_CREATE_EDGE":{"code":1907,"message":"could not create edge"},"ERROR_GRAPH_COULD_NOT_CHANGE_EDGE":{"code":1908,"message":"could not change edge"},"ERROR_GRAPH_TOO_MANY_ITERATIONS":{"code":1909,"message":"too many iterations - try increasing the value of 'maxIterations'"},"ERROR_GRAPH_INVALID_FILTER_RESULT":{"code":1910,"message":"invalid filter result"},"ERROR_GRAPH_COLLECTION_MULTI_USE":{"code":1920,"message":"multi use of edge collection in edge def"},"ERROR_GRAPH_COLLECTION_USE_IN_MULTI_GRAPHS":{"code":1921,"message":"edge collection already used in edge def"},"ERROR_GRAPH_CREATE_MISSING_NAME":{"code":1922,"message":"missing graph name"},"ERROR_GRAPH_CREATE_MALFORMED_EDGE_DEFINITION":{"code":1923,"message":"malformed edge definition"},"ERROR_GRAPH_NOT_FOUND":{"code":1924,"message":"graph not found"},"ERROR_GRAPH_DUPLICATE":{"code":1925,"message":"graph already exists"},"ERROR_GRAPH_VERTEX_COL_DOES_NOT_EXIST":{"code":1926,"message":"vertex collection does not exist or is not part of the graph"},"ERROR_GRAPH_WRONG_COLLECTION_TYPE_VERTEX":{"code":1927,"message":"not a vertex collection"},"ERROR_GRAPH_NOT_IN_ORPHAN_COLLECTION":{"code":1928,"message":"not in orphan collection"},"ERROR_GRAPH_COLLECTION_USED_IN_EDGE_DEF":{"code":1929,"message":"collection already used in edge def"},"ERROR_GRAPH_EDGE_COLLECTION_NOT_USED":{"code":1930,"message":"edge collection not used in graph"},"ERROR_GRAPH_NOT_AN_ARANGO_COLLECTION":{"code":1931,"message":" is not an ArangoCollection"},"ERROR_GRAPH_NO_GRAPH_COLLECTION":{"code":1932,"message":"collection _graphs does not exist"},"ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT_STRING":{"code":1933,"message":"Invalid example type. Has to be String, Array or Object"},"ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT":{"code":1934,"message":"Invalid example type. Has to be Array or Object"},"ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS":{"code":1935,"message":"Invalid number of arguments. Expected: "},"ERROR_GRAPH_INVALID_PARAMETER":{"code":1936,"message":"Invalid parameter type."},"ERROR_GRAPH_INVALID_ID":{"code":1937,"message":"Invalid id"},"ERROR_GRAPH_COLLECTION_USED_IN_ORPHANS":{"code":1938,"message":"collection used in orphans"},"ERROR_GRAPH_EDGE_COL_DOES_NOT_EXIST":{"code":1939,"message":"edge collection does not exist or is not part of the graph"},"ERROR_GRAPH_EMPTY":{"code":1940,"message":"empty graph"},"ERROR_SESSION_UNKNOWN":{"code":1950,"message":"unknown session"},"ERROR_SESSION_EXPIRED":{"code":1951,"message":"session expired"},"SIMPLE_CLIENT_UNKNOWN_ERROR":{"code":2000,"message":"unknown client error"},"SIMPLE_CLIENT_COULD_NOT_CONNECT":{"code":2001,"message":"could not connect to server"},"SIMPLE_CLIENT_COULD_NOT_WRITE":{"code":2002,"message":"could not write to server"},"SIMPLE_CLIENT_COULD_NOT_READ":{"code":2003,"message":"could not read from server"},"ERROR_MALFORMED_MANIFEST_FILE":{"code":3000,"message":"malformed manifest file"},"ERROR_INVALID_APPLICATION_MANIFEST":{"code":3001,"message":"manifest file is invalid"},"ERROR_INVALID_FOXX_OPTIONS":{"code":3004,"message":"invalid foxx options"},"ERROR_INVALID_MOUNTPOINT":{"code":3007,"message":"mountpoint is invalid"},"ERROR_APP_NOT_FOUND":{"code":3009,"message":"App not found"},"ERROR_APP_NEEDS_CONFIGURATION":{"code":3010,"message":"App not configured"},"ERROR_MODULE_NOT_FOUND":{"code":3100,"message":"cannot locate module"},"ERROR_MODULE_FAILURE":{"code":3103,"message":"failed to invoke module"},"RESULT_ELEMENT_EXISTS":{"code":10000,"message":"element not inserted into structure, because it already exists"},"RESULT_ELEMENT_NOT_FOUND":{"code":10001,"message":"element not found in structure"},"ERROR_QUEUE_ALREADY_EXISTS":{"code":21000,"message":"named queue already exists"},"ERROR_DISPATCHER_IS_STOPPING":{"code":21001,"message":"dispatcher stopped"},"ERROR_QUEUE_UNKNOWN":{"code":21002,"message":"named queue does not exist"},"ERROR_QUEUE_FULL":{"code":21003,"message":"named queue is full"}};})(); /*jshint -W051:true */ /*global jqconsole, Symbol */ /*eslint-disable */global.DEFINE_MODULE('console',(function(){'use strict'; /*eslint-enable */ //////////////////////////////////////////////////////////////////////////////// /// @brief module "console" /// /// @file @@ -14234,7 +14234,7 @@ exports.createHelpHeadline = function(text){var i;var p="";var x=Math.abs(78 - t /// throws an exception in case of an an error //////////////////////////////////////////////////////////////////////////////// // must came after the export of createHelpHeadline -var arangodb=require("@arangodb");var ArangoError=arangodb.ArangoError;exports.checkRequestResult = function(requestResult){if(requestResult === undefined){throw new ArangoError({"error":true,"code":500,"errorNum":arangodb.ERROR_INTERNAL,"errorMessage":"Unknown error. Request result is empty"});}if(requestResult.hasOwnProperty('error')){if(requestResult.error){if(requestResult.errorNum === arangodb.ERROR_TYPE_ERROR){throw new TypeError(requestResult.errorMessage);}throw new ArangoError(requestResult);} // remove the property from the original object +var arangodb=require("@arangodb");var ArangoError=arangodb.ArangoError;exports.checkRequestResult = function(requestResult){if(requestResult === undefined){throw new ArangoError({"error":true,"code":500,"errorNum":arangodb.ERROR_INTERNAL,"errorMessage":"Unknown error. Request result is empty"});}if(requestResult.hasOwnProperty('error')){if(requestResult.error){if(requestResult.errorNum === arangodb.ERROR_TYPE_ERROR){throw new TypeError(requestResult.errorMessage);}var error=new ArangoError(requestResult);error.message = requestResult.message;throw error;} // remove the property from the original object delete requestResult.error;}return requestResult;}; //////////////////////////////////////////////////////////////////////////////// /// @brief general help //////////////////////////////////////////////////////////////////////////////// @@ -16528,12 +16528,12 @@ var __fs__=require("fs");var __rcf__=__fs__.join(__fs__.home(),".arangosh.rc");i data: JSON.stringify(postParameter), contentType: "application/json", processData: false, - async: true, success: function (data, textStatus, xhr) { if (xhr.getResponseHeader('x-arango-async-id')) { window.arangoHelper.addAardvarkJob({ id: xhr.getResponseHeader('x-arango-async-id'), type: 'index', + desc: 'Creating index...', collection: self.get("id") }); callback(false, data); @@ -16550,13 +16550,29 @@ var __fs__=require("fs");var __rcf__=__fs__.join(__fs__.home(),".arangosh.rc");i }, deleteIndex: function (id, callback) { + + var self = this; + $.ajax({ cache: false, type: 'DELETE', url: "/_api/index/"+ this.get("name") +"/"+encodeURIComponent(id), - async: true, - success: function () { - callback(false); + headers: { + 'x-arango-async': 'store' + }, + success: function (data, textStatus, xhr) { + if (xhr.getResponseHeader('x-arango-async-id')) { + window.arangoHelper.addAardvarkJob({ + id: xhr.getResponseHeader('x-arango-async-id'), + type: 'index', + desc: 'Removing index...', + collection: self.get("id") + }); + callback(false, data); + } + else { + callback(true, data); + } }, error: function (data) { callback(true, data); @@ -16583,7 +16599,6 @@ var __fs__=require("fs");var __rcf__=__fs__.join(__fs__.home(),".arangosh.rc");i loadCollection: function (callback) { $.ajax({ - async: true, cache: false, type: 'PUT', url: "/_api/collection/" + this.get("id") + "/load", @@ -16599,7 +16614,6 @@ var __fs__=require("fs");var __rcf__=__fs__.join(__fs__.home(),".arangosh.rc");i unloadCollection: function (callback) { $.ajax({ - async: true, cache: false, type: 'PUT', url: "/_api/collection/" + this.get("id") + "/unload?flush=true", @@ -19533,6 +19547,13 @@ window.ArangoUsers = Backbone.Collection.extend({ render: function () { if (this.model.get("locked")) { $(this.el).addClass('locked'); + } + else { + $(this.el).removeClass('locked'); + } + + if (this.model.get("status") === 'loading') { + $(this.el).addClass('locked'); } $(this.el).html(this.template.render({ model: this.model @@ -19567,10 +19588,19 @@ window.ArangoUsers = Backbone.Collection.extend({ if (this.model.get("locked")) { return 0; } + if (this.model.get("status") === 'loading' ) { + return 0; + } + + if (this.model.get("status") === 'unloaded' ) { + this.loadCollection(); + } + else { + window.App.navigate( + "collection/" + encodeURIComponent(this.model.get("name")) + "/documents/1", {trigger: true} + ); + } - window.App.navigate( - "collection/" + encodeURIComponent(this.model.get("name")) + "/documents/1", {trigger: true} - ); }, noop: function(event) { @@ -20098,6 +20128,15 @@ window.ArangoUsers = Backbone.Collection.extend({ }, + refreshCollectionsView: function() { + var self = this; + window.App.arangoCollectionsStore.fetch({ + success: function () { + self.collectionsView.checkLockedCollections(); + } + }); + }, + deleteIndex: function () { var callback = function(error) { if (error) { @@ -20106,13 +20145,21 @@ window.ArangoUsers = Backbone.Collection.extend({ '' ); + this.model.set("locked", false); + this.refreshCollectionsView(); } - else { + else if (!error && error !== undefined) { $("tr th:contains('"+ this.lastId+"')").parent().remove(); + this.model.set("locked", false); + this.refreshCollectionsView(); } }.bind(this); + this.model.set("locked", true); this.model.deleteIndex(this.lastId, callback); + + this.refreshCollectionsView(); + $("tr th:contains('"+ this.lastId+"')").parent().children().last().html( '' ); @@ -20244,12 +20291,15 @@ window.ArangoUsers = Backbone.Collection.extend({ }); this.collection.each(function(model) { - if (model.get("locked")) { + if (model.get("locked") || model.get("status") === 'loading') { $('#collection_' + model.get("name")).addClass('locked'); } else { $('#collection_' + model.get("name")).removeClass('locked'); } + if (model.get("status") === 'loading') { + $('#collection_' + model.get("name")).removeClass('loading'); + } }); }, @@ -26761,6 +26811,8 @@ window.ArangoUsers = Backbone.Collection.extend({ if (typeof callback === "function") { callback(); } + $.noty.clearQueue(); + $.noty.closeAll(); }, error: function (data) { window.progressView.hide(); @@ -26952,7 +27004,8 @@ window.ArangoUsers = Backbone.Collection.extend({ if (xhr.getResponseHeader('x-arango-async-id')) { self.queryCallbackFunction(xhr.getResponseHeader('x-arango-async-id'), callback); } - + $.noty.clearQueue(); + $.noty.closeAll(); }, error: function (data) { self.switchTab("result-switch"); diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/app.js.gz b/js/apps/system/_admin/aardvark/APP/frontend/build/app.js.gz index e40d940da9..39b2a382f8 100644 Binary files a/js/apps/system/_admin/aardvark/APP/frontend/build/app.js.gz and b/js/apps/system/_admin/aardvark/APP/frontend/build/app.js.gz differ diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/app.min.js b/js/apps/system/_admin/aardvark/APP/frontend/build/app.min.js index cf0b529669..c6f2c9c234 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/app.min.js +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/app.min.js @@ -1,18 +1,18 @@ function JSONAdapter(a,b,c,d,e,f){"use strict";var g=this,h={},i={},j=new AbstractAdapter(b,c,this,d);h.range=e/2,h.start=e/4,h.getStart=function(){return this.start+Math.random()*this.range},i.range=f/2,i.start=f/4,i.getStart=function(){return this.start+Math.random()*this.range},g.loadNode=function(a,b){g.loadNodeFromTreeById(a,b)},g.loadInitialNode=function(b,c){var d=a+b+".json";j.cleanUp(),d3.json(d,function(a,d){void 0!==a&&null!==a&&console.log(a);var e=j.insertInitialNode(d);g.requestCentralityChildren(b,function(a){e._centrality=a}),_.each(d.children,function(a){var b=j.insertNode(a),c={_from:e._id,_to:b._id,_id:e._id+"-"+b._id};j.insertEdge(c),g.requestCentralityChildren(b._id,function(a){b._centrality=a}),delete b._data.children}),delete e._data.children,c&&c(e)})},g.loadNodeFromTreeById=function(b,c){var d=a+b+".json";d3.json(d,function(a,d){void 0!==a&&null!==a&&console.log(a);var e=j.insertNode(d);g.requestCentralityChildren(b,function(a){e._centrality=a}),_.each(d.children,function(a){var b=j.insertNode(a),c={_from:e._id,_to:b._id,_id:e._id+"-"+b._id};j.insertEdge(c),g.requestCentralityChildren(b._id,function(a){e._centrality=a}),delete b._data.children}),delete e._data.children,c&&c(e)})},g.requestCentralityChildren=function(b,c){var d=a+b+".json";d3.json(d,function(a,b){void 0!==a&&null!==a&&console.log(a),void 0!==c&&c(void 0!==b.children?b.children.length:0)})},g.loadNodeFromTreeByAttributeValue=function(a,b,c){throw"Sorry this adapter is read-only"},g.loadInitialNodeByAttributeValue=function(a,b,c){throw"Sorry this adapter is read-only"},g.createEdge=function(a,b){throw"Sorry this adapter is read-only"},g.deleteEdge=function(a,b){throw"Sorry this adapter is read-only"},g.patchEdge=function(a,b,c){throw"Sorry this adapter is read-only"},g.createNode=function(a,b){throw"Sorry this adapter is read-only"},g.deleteNode=function(a,b){throw"Sorry this adapter is read-only"},g.patchNode=function(a,b,c){throw"Sorry this adapter is read-only"},g.setNodeLimit=function(a,b){},g.setChildLimit=function(a){},g.expandCommunity=function(a,b){},g.setWidth=function(){},g.explore=j.explore}function AbstractAdapter(a,b,c,d,e){"use strict";if(void 0===a)throw"The nodes have to be given.";if(void 0===b)throw"The edges have to be given.";if(void 0===c)throw"An inheriting class has to be given.";if(void 0===d)throw"A reference to the graph viewer has to be given.";e=e||{};var f,g,h,i,j,k=this,l=!1,m={},n={},o={},p={},q=0,r={},s={},t=function(a){void 0!==a.prioList&&g.changePrioList(a.prioList||[])},u=function(a){m.range=a/2,m.start=a/4,m.getStart=function(){return this.start+Math.random()*this.range}},v=function(a){n.range=a/2,n.start=a/4,n.getStart=function(){return this.start+Math.random()*this.range}},w=function(b){var c=p[b]||b,d=$.grep(a,function(a){return a._id===c});if(0===d.length)return!1;if(1===d.length)return d[0];throw"Too many nodes with the same ID, should never happen"},x=function(a){var c=$.grep(b,function(b){return b._id===a});if(0===c.length)return!1;if(1===c.length)return c[0];throw"Too many edges with the same ID, should never happen"},y=function(b,c,d){var e={_data:b,_id:b._id},f=w(e._id);return f?f:(e.x=c||m.getStart(),e.y=d||n.getStart(),e.weight=1,a.push(e),e._outboundCounter=0,e._inboundCounter=0,e)},z=function(a){var b=y(a);return b.x=2*m.start,b.y=2*n.start,b.fixed=!0,b},A=function(){a.length=0,b.length=0,p={},o={},d.cleanUp()},B=function(a){var c,d,e,f=!0,g={_data:a,_id:a._id},i=x(g._id);if(i)return i;if(c=w(a._from),d=w(a._to),!c)throw"Unable to insert Edge, source node not existing "+a._from;if(!d)throw"Unable to insert Edge, target node not existing "+a._to;return g.source=c,g.source._isCommunity?(e=o[g.source._id],g.source=e.getNode(a._from),g.source._outboundCounter++,e.insertOutboundEdge(g),f=!1):c._outboundCounter++,g.target=d,g.target._isCommunity?(e=o[g.target._id],g.target=e.getNode(a._to),g.target._inboundCounter++,e.insertInboundEdge(g),f=!1):d._inboundCounter++,b.push(g),f&&h.call("insertEdge",c._id,d._id),g},C=function(b){var c;for(c=0;c0){var c,d=[];for(c=0;cf&&(c?c.collapse():K(b))},M=function(c){var d=c.getDissolveInfo(),e=d.nodes,g=d.edges.both,i=d.edges.inbound,j=d.edges.outbound;C(c),fi){var b=g.bucketNodes(_.values(a),i);_.each(b,function(a){if(a.nodes.length>1){var b=_.map(a.nodes,function(a){return a._id});I(b,a.reason)}})}},P=function(a,b){f=a,L(),void 0!==b&&b()},Q=function(a){i=a},R=function(a,b){a._expanded=!1;var c=b.removeOutboundEdgesFromNode(a);_.each(c,function(a){j(a),E(a,!0)})},S=function(a){a._expanded=!1,p[a._id]&&o[p[a._id]].collapseNode(a);var b=H(a),c=[];_.each(b,function(b){0===q?(r=b,s=a,c.push(b)):void 0!==a&&(a._id===r.target._id?b.target._id===s._id&&c.push(r):c.push(b),r=b,s=a),q++}),_.each(c,j),q=0},T=function(a){var b=a.getDissolveInfo();C(a),_.each(b.nodes,function(a){delete p[a._id]}),_.each(b.edges.outbound,function(a){j(a),E(a,!0)}),delete o[a._id]},U=function(a,b){a._isCommunity?k.expandCommunity(a,b):(a._expanded=!0,c.loadNode(a._id,b))},V=function(a,b){a._expanded?S(a):U(a,b)};j=function(a){var b,c=a.target;return c._isCommunity?(b=a._target,c.removeInboundEdge(a),b._inboundCounter--,0===b._inboundCounter&&(R(b,c),c.removeNode(b),delete p[b._id]),void(0===c._inboundCounter&&T(c))):(c._inboundCounter--,void(0===c._inboundCounter&&(S(c),C(c))))},i=Number.POSITIVE_INFINITY,g=e.prioList?new NodeReducer(e.prioList):new NodeReducer,h=new WebWorkerWrapper(ModularityJoiner,J),m.getStart=function(){return 0},n.getStart=function(){return 0},this.cleanUp=A,this.setWidth=u,this.setHeight=v,this.insertNode=y,this.insertInitialNode=z,this.insertEdge=B,this.removeNode=C,this.removeEdge=E,this.removeEdgesForNode=F,this.expandCommunity=N,this.setNodeLimit=P,this.setChildLimit=Q,this.checkSizeOfInserted=O,this.checkNodeLimit=L,this.explore=V,this.changeTo=t,this.getPrioList=g.getPrioList,this.dissolveCommunity=M}function ArangoAdapter(a,b,c,d){"use strict";if(void 0===a)throw"The nodes have to be given.";if(void 0===b)throw"The edges have to be given.";if(void 0===c)throw"A reference to the graph viewer has to be given.";if(void 0===d)throw"A configuration with node- and edgeCollection has to be given.";if(void 0===d.graph){if(void 0===d.nodeCollection)throw"The nodeCollection or a graphname has to be given.";if(void 0===d.edgeCollection)throw"The edgeCollection or a graphname has to be given."}var e,f,g,h,i,j=this,k={},l={},m={},n=function(a){h=a},o=function(a){f=a,l.node=l.base+"document?collection="+f},p=function(a){g=a,l.edge=l.base+"edge?collection="+g},q=function(a){$.ajax({cache:!1,type:"GET",async:!1,url:l.graph+"/"+a,contentType:"application/json",success:function(a){o(a.graph.vertices),p(a.graph.edges)}})},r=function(a){var b=a.baseUrl||"";void 0!==a.width&&e.setWidth(a.width),void 0!==a.height&&e.setHeight(a.height),i=void 0!==a.undirected&&a.undirected===!0?"any":"outbound",l.base=b+"_api/",l.cursor=l.base+"cursor",l.graph=l.base+"graph",l.collection=l.base+"collection/",l.document=l.base+"document/",l.any=l.base+"simple/any",a.graph?(q(a.graph),n(a.graph)):(o(a.nodeCollection),p(a.edgeCollection),n(void 0))},s=function(a,b,c){a!==m.getAllGraphs&&(a!==m.connectedEdges&&(b["@nodes"]=f,a!==m.childrenCentrality&&(b.dir=i)),b["@edges"]=g);var d={query:a,bindVars:b};$.ajax({type:"POST",url:l.cursor,data:JSON.stringify(d),contentType:"application/json",dataType:"json",processData:!1,success:function(a){c(a.result)},error:function(a){try{throw console.log(a.statusText),"["+a.errorNum+"] "+a.errorMessage}catch(b){throw"Undefined ERROR"}}})},t=function(a,b){var c=[],d=0,e=function(d){c.push(d.document||{}),c.length===a&&b(c)};for(d=0;a>d;d++)$.ajax({cache:!1,type:"PUT",url:l.any,data:JSON.stringify({collection:f}),contentType:"application/json",success:e})},u=function(b,c){if(0===b.length)return void(c&&c({errorCode:404}));b=b[0];var d={},f=e.insertNode(b[0].vertex),g=a.length;_.each(b,function(b){var c=e.insertNode(b.vertex),f=b.path;g=2&&$.ajax({cache:!1,type:"GET",url:l.collection,contentType:"application/json",dataType:"json",processData:!1,success:function(b){var c=b.collections,d=[],e=[];_.each(c,function(a){a.name.match(/^_/)||(3===a.type?e.push(a.name):2===a.type&&d.push(a.name))}),a(d,e)},error:function(a){throw a.statusText}})},j.getGraphs=function(a){a&&a.length>=1&&s(m.getAllGraphs,{},a)},j.getAttributeExamples=function(a){a&&a.length>=1&&t(10,function(b){var c=_.sortBy(_.uniq(_.flatten(_.map(b,function(a){return _.keys(a)}))),function(a){return a.toLowerCase()});a(c)})},j.getNodeCollection=function(){return f},j.getEdgeCollection=function(){return g},j.getDirection=function(){return i},j.getGraphName=function(){return h},j.setWidth=e.setWidth,j.changeTo=e.changeTo,j.getPrioList=e.getPrioList}function ColourMapper(){"use strict";var a,b={},c={},d=[],e=this,f=0;d.push({back:"#C8E6C9",front:"black"}),d.push({back:"#8aa249",front:"white"}),d.push({back:"#8BC34A",front:"black"}),d.push({back:"#388E3C",front:"white"}),d.push({back:"#4CAF50",front:"white"}),d.push({back:"#212121",front:"white"}),d.push({back:"#727272",front:"white"}),d.push({back:"#B6B6B6",front:"black"}),d.push({back:"#e5f0a3",front:"black"}),d.push({back:"#6c4313",front:"white"}),d.push({back:"#9d8564",front:"white"}),this.getColour=function(g){return void 0===b[g]&&(b[g]=d[f],void 0===c[d[f].back]&&(c[d[f].back]={front:d[f].front,list:[]}),c[d[f].back].list.push(g),f++,f===d.length&&(f=0)),void 0!==a&&a(e.getList()),b[g].back},this.getCommunityColour=function(){return"#333333"},this.getForegroundColour=function(g){return void 0===b[g]&&(b[g]=d[f],void 0===c[d[f].back]&&(c[d[f].back]={front:d[f].front,list:[]}),c[d[f].back].list.push(g),f++,f===d.length&&(f=0)),void 0!==a&&a(e.getList()),b[g].front},this.getForegroundCommunityColour=function(){return"white"},this.reset=function(){b={},c={},f=0,void 0!==a&&a(e.getList())},this.getList=function(){return c},this.setChangeListener=function(b){a=b},this.reset()}function CommunityNode(a,b){"use strict";if(_.isUndefined(a)||!_.isFunction(a.dissolveCommunity)||!_.isFunction(a.checkNodeLimit))throw"A parent element has to be given.";b=b||[];var c,d,e,f,g,h=this,i={},j=[],k=[],l={},m={},n={},o={},p=function(a){return h._expanded?2*a*Math.sqrt(j.length):a},q=function(a){return h._expanded?4*a*Math.sqrt(j.length):a},r=function(a){var b=h.position,c=a.x*b.z+b.x,d=a.y*b.z+b.y,e=a.z*b.z;return{x:c,y:d,z:e}},s=function(a){return h._expanded?r(a._source.position):h.position},t=function(a){return h._expanded?r(a._target.position):h.position},u=function(){var a=document.getElementById(h._id).getBBox();c.attr("transform","translate("+(a.x-5)+","+(a.y-25)+")"),d.attr("width",a.width+10).attr("height",a.height+30),e.attr("width",a.width+10)},v=function(){if(!f){var a=new DomObserverFactory;f=a.createObserver(function(a){_.any(a,function(a){return"transform"===a.attributeName})&&(u(),f.disconnect())})}return f},w=function(){g.stop(),j.length=0,_.each(i,function(a){j.push(a)}),g.start()},x=function(){g.stop(),k.length=0,_.each(l,function(a){k.push(a)}),g.start()},y=function(a){var b=[];return _.each(a,function(a){b.push(a)}),b},z=function(a){return!!i[a]},A=function(){return j},B=function(a){return i[a]},C=function(a){i[a._id]=a,w(),h._size++},D=function(a){_.each(a,function(a){i[a._id]=a,h._size++}),w()},E=function(a){var b=a._id||a;delete i[b],w(),h._size--},F=function(a){var b;return _.has(a,"_id")?b=a._id:(b=a,a=l[b]||m[b]),a.target=a._target,delete a._target,l[b]?(delete l[b],h._outboundCounter++,n[b]=a,void x()):(delete m[b],void h._inboundCounter--)},G=function(a){var b;return _.has(a,"_id")?b=a._id:(b=a,a=l[b]||n[b]),a.source=a._source,delete a._source,delete o[a.source._id][b],l[b]?(delete l[b],h._inboundCounter++,m[b]=a,void x()):(delete n[b],void h._outboundCounter--)},H=function(a){var b=a._id||a,c=[];return _.each(o[b],function(a){G(a),c.push(a)}),delete o[b],c},I=function(a){return a._target=a.target,a.target=h,n[a._id]?(delete n[a._id],h._outboundCounter--,l[a._id]=a,x(),!0):(m[a._id]=a,h._inboundCounter++,!1)},J=function(a){var b=a.source._id;return a._source=a.source,a.source=h,o[b]=o[b]||{},o[b][a._id]=a,m[a._id]?(delete m[a._id],h._inboundCounter--,l[a._id]=a,x(),!0):(h._outboundCounter++,n[a._id]=a,!1)},K=function(){return{nodes:j,edges:{both:k,inbound:y(m),outbound:y(n)}}},L=function(){this._expanded=!0},M=function(){a.dissolveCommunity(h)},N=function(){this._expanded=!1},O=function(a,b){var c=a.select("rect").attr("width"),d=a.append("text").attr("text-anchor","middle").attr("fill",b.getForegroundCommunityColour()).attr("stroke","none");c*=2,c/=3,h._reason&&h._reason.key&&(d.append("tspan").attr("x","0").attr("dy","-4").text(h._reason.key+":"),d.append("tspan").attr("x","0").attr("dy","16").text(h._reason.value)),d.append("tspan").attr("x",c).attr("y","0").attr("fill",b.getCommunityColour()).text(h._size)},P=function(b,c,d,e){var f=b.append("g").attr("stroke",e.getForegroundCommunityColour()).attr("fill",e.getCommunityColour());c(f,9),c(f,6),c(f,3),c(f),f.on("click",function(){h.expand(),a.checkNodeLimit(h),d()}),O(f,e)},Q=function(a,b){var c=a.selectAll(".node").data(j,function(a){return a._id});c.enter().append("g").attr("class","node").attr("id",function(a){return a._id}),c.exit().remove(),c.selectAll("* > *").remove(),b(c)},R=function(a,b){c=a.append("g"),d=c.append("rect").attr("rx","8").attr("ry","8").attr("fill","none").attr("stroke","black"),e=c.append("rect").attr("rx","8").attr("ry","8").attr("height","20").attr("fill","#686766").attr("stroke","none"),c.append("image").attr("id",h._id+"_dissolve").attr("xlink:href","img/icon_delete.png").attr("width","16").attr("height","16").attr("x","5").attr("y","2").attr("style","cursor:pointer").on("click",function(){h.dissolve(),b()}),c.append("image").attr("id",h._id+"_collapse").attr("xlink:href","img/gv_collapse.png").attr("width","16").attr("height","16").attr("x","25").attr("y","2").attr("style","cursor:pointer").on("click",function(){h.collapse(),b()});var f=c.append("text").attr("x","45").attr("y","15").attr("fill","white").attr("stroke","none").attr("text-anchor","left");h._reason&&f.text(h._reason.text),v().observe(document.getElementById(h._id),{subtree:!0,attributes:!0})},S=function(a){if(h._expanded){var b=a.focus(),c=[b[0]-h.position.x,b[1]-h.position.y];a.focus(c),_.each(j,function(b){b.position=a(b),b.position.x/=h.position.z,b.position.y/=h.position.z,b.position.z/=h.position.z}),a.focus(b)}},T=function(a,b,c,d,e){return a.on("click",null),h._expanded?(R(a,d),void Q(a,c,d,e)):void P(a,b,d,e)},U=function(a,b,c){if(h._expanded){var d=a.selectAll(".link"),e=d.select("line");b(e,d),c(d)}},V=function(a,b){var c,d,e=function(a){return a._id};h._expanded&&(d=a.selectAll(".link").data(k,e),d.enter().append("g").attr("class","link").attr("id",e),d.exit().remove(),d.selectAll("* > *").remove(),c=d.append("line"),b(c,d))},W=function(a){H(a)};g=new ForceLayouter({distance:100,gravity:.1,charge:-500,width:1,height:1,nodes:j,links:k}),this._id="*community_"+Math.floor(1e6*Math.random()),b.length>0?(this.x=b[0].x,this.y=b[0].y):(this.x=0,this.y=0),this._size=0,this._inboundCounter=0,this._outboundCounter=0,this._expanded=!1,this._isCommunity=!0,D(b),this.hasNode=z,this.getNodes=A,this.getNode=B,this.getDistance=p,this.getCharge=q,this.insertNode=C,this.insertInboundEdge=I,this.insertOutboundEdge=J,this.removeNode=E,this.removeInboundEdge=F,this.removeOutboundEdge=G,this.removeOutboundEdgesFromNode=H,this.collapseNode=W,this.dissolve=M,this.getDissolveInfo=K,this.collapse=N,this.expand=L,this.shapeNodes=T,this.shapeInnerEdges=V,this.updateInnerEdges=U,this.addDistortion=S,this.getSourcePosition=s,this.getTargetPosition=t}function DomObserverFactory(){"use strict";var a=window.WebKitMutationObserver||window.MutationObserver;this.createObserver=function(b){if(!a)throw"Observer not supported";return new a(b)}}function EdgeShaper(a,b,c){"use strict";var d,e,f,g=this,h=[],i={},j=new ContextMenu("gv_edge_cm"),k=function(a,b){return _.isArray(a)?b[_.find(a,function(a){return b[a]})]:b[a]},l=function(a){if(void 0===a)return[""];"string"!=typeof a&&(a=String(a));var b=a.match(/[\w\W]{1,10}(\s|$)|\S+?(\s|$)/g);return b[0]=$.trim(b[0]),b[1]=$.trim(b[1]),b[0].length>12&&(b[0]=$.trim(a.substring(0,10))+"-",b[1]=$.trim(a.substring(10)),b[1].length>12&&(b[1]=b[1].split(/\W/)[0],b[1].length>12&&(b[1]=b[1].substring(0,10)+"...")),b.length=2),b.length>2&&(b.length=2,b[1]+="..."),b},m=!0,n={},o=function(a){return a._id},p=function(a,b){},q=new ColourMapper,r=function(){q.reset()},s=p,t=p,u=p,v=p,w=function(){f={click:p,dblclick:p,mousedown:p,mouseup:p,mousemove:p,mouseout:p,mouseover:p}},x=function(a,b){return 180*Math.atan2(b.y-a.y,b.x-a.x)/Math.PI},y=function(a,b){var c,d=Math.sqrt((b.y-a.y)*(b.y-a.y)+(b.x-a.x)*(b.x-a.x));return a.x===b.x?d-=18*b.z:(c=Math.abs((b.y-a.y)/(b.x-a.x)),d-=.4>c?Math.abs(d*b.z*45/(b.x-a.x)):Math.abs(d*b.z*18/(b.y-a.y))),d},z=function(a,b){_.each(f,function(a,c){b.on(c,a)})},A=function(a,b){if("update"===a)s=b;else{if(void 0===f[a])throw"Sorry Unknown Event "+a+" cannot be bound.";f[a]=b}},B=function(a){var b,c,d,e;return d=a.source,e=a.target,d._isCommunity?(i[d._id]=d,b=d.getSourcePosition(a)):b=d.position,e._isCommunity?(i[e._id]=e,c=e.getTargetPosition(a)):c=e.position,{s:b,t:c}},C=function(a,b){i={},b.attr("transform",function(a){var b=B(a);return"translate("+b.s.x+", "+b.s.y+")rotate("+x(b.s,b.t)+")"}),a.attr("x2",function(a){var b=B(a);return y(b.s,b.t)})},D=function(a,b){t(a,b),m&&u(a,b),v(a,b),z(a,b),C(a,b)},E=function(a){void 0!==a&&(h=a);var b,c=g.parent.selectAll(".link").data(h,o);c.enter().append("g").attr("class","link").attr("id",o),c.exit().remove(),c.selectAll("* > *").remove(),b=c.append("line"),D(b,c),_.each(i,function(a){a.shapeInnerEdges(d3.select(this),D)}),j.bindMenu($(".link"))},F=function(){var a=g.parent.selectAll(".link"),b=a.select("line");C(b,a),s(a),_.each(i,function(a){a.updateInnerEdges(d3.select(this),C,s)})},G=function(a){switch($("svg defs marker#arrow").remove(),a.type){case EdgeShaper.shapes.NONE:t=p;break;case EdgeShaper.shapes.ARROW:t=function(a,b){a.attr("marker-end","url(#arrow)")},0===d.selectAll("defs")[0].length&&d.append("defs"),d.select("defs").append("marker").attr("id","arrow").attr("refX","10").attr("refY","5").attr("markerUnits","strokeWidth").attr("markerHeight","10").attr("markerWidth","10").attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z");break;default:throw"Sorry given Shape not known!"}},H=function(a){u=_.isFunction(a)?function(b,c){c.append("text").attr("text-anchor","middle").text(a)}:function(b,c){c.append("text").attr("text-anchor","middle").text(function(b){var c=l(k(a,b._data));return c[0]||""})},s=function(a){a.select("text").attr("transform",function(a){var b=B(a);return"translate("+y(b.s,b.t)/2+", -3)"})}},I=function(a){void 0!==a.reset&&a.reset&&w(),_.each(a,function(a,b){"reset"!==b&&A(b,a)})},J=function(a){switch($("svg defs #gradientEdgeColor").remove(),r(),a.type){case"single":v=function(b,c){b.attr("stroke",a.stroke)};break;case"gradient":0===d.selectAll("defs")[0].length&&d.append("defs");var b=d.select("defs").append("linearGradient").attr("id","gradientEdgeColor");b.append("stop").attr("offset","0").attr("stop-color",a.source),b.append("stop").attr("offset","0.4").attr("stop-color",a.source),b.append("stop").attr("offset","0.6").attr("stop-color",a.target),b.append("stop").attr("offset","1").attr("stop-color",a.target),v=function(a,b){a.attr("stroke","url(#gradientEdgeColor)"),a.attr("y2","0.0000000000000001")};break;case"attribute":v=function(b,c){c.attr("stroke",function(b){return q.getColour(b._data[a.key])})};break;default:throw"Sorry given colour-scheme not known"}},K=function(a){void 0!==a.shape&&G(a.shape),void 0!==a.label&&(H(a.label),g.label=a.label),void 0!==a.actions&&I(a.actions),void 0!==a.color&&J(a.color)};for(g.parent=a,w(),d=a;d[0][0]&&d[0][0].ownerSVGElement;)d=d3.select(d[0][0].ownerSVGElement);void 0===b&&(b={color:{type:"single",stroke:"#686766"}}),void 0===b.color&&(b.color={type:"single",stroke:"#686766"}),K(b),_.isFunction(c)&&(o=c),e=d.append("g"),g.changeTo=function(a){K(a),E(),F()},g.drawEdges=function(a){E(a),F()},g.updateEdges=function(){F()},g.reshapeEdges=function(){E()},g.activateLabel=function(a){m=a?!0:!1,E()},g.addAnEdgeFollowingTheCursor=function(a,b){return n=e.append("line"),n.attr("stroke","black").attr("id","connectionLine").attr("x1",a).attr("y1",b).attr("x2",a).attr("y2",b),function(a,b){n.attr("x2",a).attr("y2",b)}},g.removeCursorFollowingEdge=function(){n.remove&&(n.remove(),n={})},g.addMenuEntry=function(a,b){j.addEntry(a,b)},g.getLabel=function(){return g.label||""},g.resetColourMap=r}function EventDispatcher(a,b,c){"use strict";var d,e,f,g,h=this,i=function(b){if(void 0===b.shaper&&(b.shaper=a),d.checkNodeEditorConfig(b)){var c=new d.InsertNode(b),e=new d.PatchNode(b),f=new d.DeleteNode(b);h.events.CREATENODE=function(a,b,d,e){var f;return f=_.isFunction(a)?a():a,function(){c(f,b,d,e)}},h.events.PATCHNODE=function(a,b,c){if(!_.isFunction(b))throw"Please give a function to extract the new node data";return function(){e(a,b(),c)}},h.events.DELETENODE=function(a){return function(b){f(b,a)}}}},j=function(a){if(void 0===a.shaper&&(a.shaper=b),d.checkEdgeEditorConfig(a)){var c=new d.InsertEdge(a),e=new d.PatchEdge(a),f=new d.DeleteEdge(a),g=null,i=!1;h.events.STARTCREATEEDGE=function(a){return function(b){var c=d3.event||window.event;g=b,i=!1,void 0!==a&&a(b,c),c.stopPropagation()}},h.events.CANCELCREATEEDGE=function(a){return function(){g=null,void 0===a||i||a()}},h.events.FINISHCREATEEDGE=function(a){return function(b){null!==g&&b!==g&&(c(g,b,a),i=!0)}},h.events.PATCHEDGE=function(a,b,c){if(!_.isFunction(b))throw"Please give a function to extract the new node data";return function(){e(a,b(),c)}},h.events.DELETEEDGE=function(a){return function(b){f(b,a)}}}},k=function(){g=g||$("svg"),g.unbind(),_.each(e,function(a,b){g.bind(b,function(c){_.each(a,function(a){a(c)}),f[b]&&f[b](c)})})};if(void 0===a)throw"NodeShaper has to be given.";if(void 0===b)throw"EdgeShaper has to be given.";d=new EventLibrary,e={click:[],dblclick:[],mousedown:[],mouseup:[],mousemove:[],mouseout:[],mouseover:[]},f={},h.events={},void 0!==c&&(void 0!==c.expand&&d.checkExpandConfig(c.expand)&&(h.events.EXPAND=new d.Expand(c.expand),a.setGVStartFunction(function(){c.expand.reshapeNodes(),c.expand.startCallback()})),void 0!==c.drag&&d.checkDragConfig(c.drag)&&(h.events.DRAG=d.Drag(c.drag)),void 0!==c.nodeEditor&&i(c.nodeEditor),void 0!==c.edgeEditor&&j(c.edgeEditor)),Object.freeze(h.events),h.bind=function(c,d,e){if(void 0===e||!_.isFunction(e))throw"You have to give a function that should be bound as a third argument";var g={};switch(c){case"nodes":g[d]=e,a.changeTo({actions:g});break;case"edges":g[d]=e,b.changeTo({actions:g});break;case"svg":f[d]=e,k();break;default:if(void 0===c.bind)throw'Sorry cannot bind to object. Please give either "nodes", "edges" or a jQuery-selected DOM-Element';c.unbind(d),c.bind(d,e)}},h.rebind=function(c,d){switch(d=d||{},d.reset=!0,c){case"nodes":a.changeTo({actions:d});break;case"edges":b.changeTo({actions:d});break;case"svg":f={},_.each(d,function(a,b){"reset"!==b&&(f[b]=a)}),k();break;default:throw'Sorry cannot rebind to object. Please give either "nodes", "edges" or "svg"'}},h.fixSVG=function(a,b){if(void 0===e[a])throw"Sorry unkown event";e[a].push(b),k()},Object.freeze(h.events)}function EventLibrary(){"use strict";var a=this;this.checkExpandConfig=function(a){if(void 0===a.startCallback)throw"A callback to the Start-method has to be defined";if(void 0===a.adapter||void 0===a.adapter.explore)throw"An adapter to load data has to be defined";if(void 0===a.reshapeNodes)throw"A callback to reshape nodes has to be defined";return!0},this.Expand=function(b){a.checkExpandConfig(b);var c=b.startCallback,d=b.adapter.explore,e=b.reshapeNodes;return function(a){d(a,c),e(),c()}},this.checkDragConfig=function(a){if(void 0===a.layouter)throw"A layouter has to be defined";if(void 0===a.layouter.drag||!_.isFunction(a.layouter.drag))throw"The layouter has to offer a drag function";return!0},this.Drag=function(b){return a.checkDragConfig(b),b.layouter.drag},this.checkNodeEditorConfig=function(a){if(void 0===a.adapter)throw"An adapter has to be defined";if(void 0===a.shaper)throw"A node shaper has to be defined";return!0},this.checkEdgeEditorConfig=function(a){if(void 0===a.adapter)throw"An adapter has to be defined";if(void 0===a.shaper)throw"An edge Shaper has to be defined";return!0},this.InsertNode=function(b){a.checkNodeEditorConfig(b);var c=b.adapter,d=b.shaper;return function(a,b,e,f){var g,h;_.isFunction(a)&&!b?(g=a,h={}):(g=b,h=a),c.createNode(h,function(a){d.reshapeNodes(),g(a)},e,f)}},this.PatchNode=function(b){a.checkNodeEditorConfig(b);var c=b.adapter,d=b.shaper;return function(a,b,e){c.patchNode(a,b,function(a){d.reshapeNodes(),e(a)})}},this.DeleteNode=function(b){a.checkNodeEditorConfig(b);var c=b.adapter,d=b.shaper;return function(a,b){c.deleteNode(a,function(){d.reshapeNodes(),b()})}},this.SelectNodeCollection=function(b){a.checkNodeEditorConfig(b);var c=b.adapter;if(!_.isFunction(c.useNodeCollection))throw"The adapter has to support collection changes";return function(a,b){c.useNodeCollection(a),b()}},this.InsertEdge=function(b){a.checkEdgeEditorConfig(b);var c=b.adapter,d=b.shaper;return function(a,b,e){c.createEdge({source:a,target:b},function(a){d.reshapeEdges(),e(a)})}},this.PatchEdge=function(b){a.checkEdgeEditorConfig(b);var c=b.adapter,d=b.shaper;return function(a,b,e){c.patchEdge(a,b,function(a){d.reshapeEdges(),e(a)})}},this.DeleteEdge=function(b){a.checkEdgeEditorConfig(b);var c=b.adapter,d=b.shaper;return function(a,b){c.deleteEdge(a,function(){d.reshapeEdges(),b()})}}}function ForceLayouter(a){"use strict";var b=this,c=d3.layout.force(),d=a.charge||-600,e=a.distance||80,f=a.gravity||.01,g=function(a){ var b=0;return b+=a.source._isCommunity?a.source.getDistance(e):e,b+=a.target._isCommunity?a.target.getDistance(e):e},h=function(a){return a._isCommunity?a.getCharge(d):d},i=a.onUpdate||function(){},j=a.width||880,k=a.height||680,l=function(a){a.distance&&(e=a.distance),a.gravity&&c.gravity(a.gravity),a.charge&&(d=a.charge)};if(void 0===a.nodes)throw"No nodes defined";if(void 0===a.links)throw"No links defined";c.nodes(a.nodes),c.links(a.links),c.size([j,k]),c.linkDistance(g),c.gravity(f),c.charge(h),c.on("tick",function(){}),b.start=function(){c.start()},b.stop=function(){c.stop()},b.drag=c.drag,b.setCombinedUpdateFunction=function(a,d,e){void 0!==e?(i=function(){c.alpha()<.1&&(a.updateNodes(),d.updateEdges(),e(),c.alpha()<.05&&b.stop())},c.on("tick",i)):(i=function(){c.alpha()<.1&&(a.updateNodes(),d.updateEdges(),c.alpha()<.05&&b.stop())},c.on("tick",i))},b.changeTo=function(a){l(a)},b.changeWidth=function(a){j=a,c.size([j,k])}}function FoxxAdapter(a,b,c,d,e){"use strict";if(void 0===a)throw"The nodes have to be given.";if(void 0===b)throw"The edges have to be given.";if(void 0===c)throw"The route has to be given.";if(void 0===d)throw"A reference to the graph viewer has to be given.";e=e||{};var f,g=this,h={},i={},j=c,k={cache:!1,contentType:"application/json",dataType:"json",processData:!1,error:function(a){try{throw console.log(a.statusText),"["+a.errorNum+"] "+a.errorMessage}catch(b){throw console.log(b),"Undefined ERROR"}}},l=function(){i.query={get:function(a,b){var c=$.extend(k,{type:"GET",url:j+"/query/"+a,success:b});$.ajax(c)}},i.nodes={post:function(a,b){var c=$.extend(k,{type:"POST",url:j+"/nodes",data:JSON.stringify(a),success:b});$.ajax(c)},put:function(a,b,c){var d=$.extend(k,{type:"PUT",url:j+"/nodes/"+a,data:JSON.stringify(b),success:c});$.ajax(d)},del:function(a,b){var c=$.extend(k,{type:"DELETE",url:j+"/nodes/"+a,success:b});$.ajax(c)}},i.edges={post:function(a,b){var c=$.extend(k,{type:"POST",url:j+"/edges",data:JSON.stringify(a),success:b});$.ajax(c)},put:function(a,b,c){var d=$.extend(k,{type:"PUT",url:j+"/edges/"+a,data:JSON.stringify(b),success:c});$.ajax(d)},del:function(a,b){var c=$.extend(k,{type:"DELETE",url:j+"/edges/"+a,success:b});$.ajax(c)}},i.forNode={del:function(a,b){var c=$.extend(k,{type:"DELETE",url:j+"/edges/forNode/"+a,success:b});$.ajax(c)}}},m=function(a,b,c){i[a].get(b,c)},n=function(a,b,c){i[a].post(b,c)},o=function(a,b,c){i[a].del(b,c)},p=function(a,b,c,d){i[a].put(b,c,d)},q=function(a){void 0!==a.width&&f.setWidth(a.width),void 0!==a.height&&f.setHeight(a.height)},r=function(b,c){var d={},e=b.first,g=a.length;e=f.insertNode(e),_.each(b.nodes,function(b){b=f.insertNode(b),g=l.TOTAL_NODES?$(".infoField").hide():$(".infoField").show());var e=t(l.NODES_TO_DISPLAY,d[c]);if(e.length>0){return _.each(e,function(a){l.randomNodes.push(a)}),void l.loadInitialNode(e[0]._id,a)}}a({errorCode:404})},l.loadInitialNode=function(a,b){e.cleanUp(),l.loadNode(a,v(b))},l.getRandomNodes=function(){var a=[],b=[];l.definedNodes.length>0&&_.each(l.definedNodes,function(a){b.push(a)}),l.randomNodes.length>0&&_.each(l.randomNodes,function(a){b.push(a)});var c=0;return _.each(b,function(b){c0?_.each(d,function(a){s(o.traversal,{example:a.vertex._id},function(a){_.each(a[0][0],function(a){c[0][0].push(a)}),u(c,b)})}):s(o.traversal,{example:a},function(a){u(a,b)})})},l.loadNodeFromTreeByAttributeValue=function(a,b,c){var d={};d[a]=b,s(o.traversal,{example:d},function(a){u(a,c)})},l.getNodeExampleFromTreeByAttributeValue=function(a,b,c){var d={};d[a]=b,s(o.traversal,{example:d},function(d){if(void 0===d[0][0])throw arangoHelper.arangoError("Graph error","no nodes found"),"No suitable nodes have been found.";_.each(d[0][0],function(d){if(d.vertex[a]===b){var f={};f._key=d.vertex._key,f._id=d.vertex._id,f._rev=d.vertex._rev,e.insertNode(f),c(f)}})})},l.loadAdditionalNodeByAttributeValue=function(a,b,c){l.getNodeExampleFromTreeByAttributeValue(a,b,c)},l.loadInitialNodeByAttributeValue=function(a,b,c){e.cleanUp(),l.loadNodeFromTreeByAttributeValue(a,b,v(c))},l.requestCentralityChildren=function(a,b){s(o.childrenCentrality,{id:a},function(a){b(a[0])})},l.createEdge=function(a,b){var c={};c._from=a.source._id,c._to=a.target._id,$.ajax({cache:!1,type:"POST",url:n.edges+i,data:JSON.stringify(c),dataType:"json",contentType:"application/json",processData:!1,success:function(a){if(a.error===!1){var d,f=a.edge;f._from=c._from,f._to=c._to,d=e.insertEdge(f),b(d)}},error:function(a){var b="";try{b=JSON.parse(a.responseText).errorMessage+" ("+JSON.parse(a.responseText).errorNum+")",arangoHelper.arangoError(a.statusText,b)}catch(c){throw a.statusText}}})},l.deleteEdge=function(a,b){$.ajax({cache:!1,type:"DELETE",url:n.edges+a._id,contentType:"application/json",dataType:"json",processData:!1,success:function(){e.removeEdge(a),void 0!==b&&_.isFunction(b)&&b()},error:function(a){var b="";try{b=JSON.parse(a.responseText).errorMessage+" ("+JSON.parse(a.responseText).errorNum+")",arangoHelper.arangoError(a.statusText,b)}catch(c){throw a.statusText}}})},l.patchEdge=function(a,b,c){$.ajax({cache:!1,type:"PUT",url:n.edges+a._id,data:JSON.stringify(b),dataType:"json",contentType:"application/json",processData:!1,success:function(){a._data=$.extend(a._data,b),c()},error:function(a){var b="";try{b=JSON.parse(a.responseText).errorMessage+" ("+JSON.parse(a.responseText).errorNum+")",arangoHelper.arangoError(a.statusText,b)}catch(c){throw a.statusText}}})},l.createNode=function(a,b){$.ajax({cache:!1,type:"POST",url:n.vertices+g,data:JSON.stringify(a),dataType:"json",contentType:"application/json",processData:!1,success:function(c){c.error===!1&&(a._key=c.vertex._key,a._id=c.vertex._id,a._rev=c.vertex._rev,e.insertNode(a),b(a))},error:function(a){var b="";try{b=JSON.parse(a.responseText).errorMessage+" ("+JSON.parse(a.responseText).errorNum+")",arangoHelper.arangoError(a.statusText,b)}catch(c){throw a.statusText}}})},l.deleteNode=function(a,b){$.ajax({cache:!1,type:"DELETE",url:n.vertices+a._id,dataType:"json",contentType:"application/json",processData:!1,success:function(){e.removeEdgesForNode(a),e.removeNode(a),void 0!==b&&_.isFunction(b)&&b()},error:function(a){var b="";try{b=JSON.parse(a.responseText).errorMessage+" ("+JSON.parse(a.responseText).errorNum+")",arangoHelper.arangoError(a.statusText,b)}catch(c){throw a.statusText}}})},l.patchNode=function(a,b,c){$.ajax({cache:!1,type:"PUT",url:n.vertices+a._id,data:JSON.stringify(b),dataType:"json",contentType:"application/json",processData:!1,success:function(){a._data=$.extend(a._data,b),c(a)},error:function(a){throw a.statusText}})},l.changeToGraph=function(a,b){e.cleanUp(),q(a),void 0!==b&&(k=b===!0?"any":"outbound")},l.setNodeLimit=function(a,b){e.setNodeLimit(a,b)},l.setChildLimit=function(a){e.setChildLimit(a)},l.expandCommunity=function(a,b){e.expandCommunity(a),void 0!==b&&b()},l.getGraphs=function(a){a&&a.length>=1&&s(o.getAllGraphs,{},a)},l.getAttributeExamples=function(a){if(a&&a.length>=1){var b,c=[],d=_.shuffle(l.getNodeCollections());for(b=0;b0&&(c=c.concat(_.flatten(_.map(e,function(a){return _.keys(a)}))))}var c=_.sortBy(_.uniq(c),function(a){return a.toLowerCase()});a(c)}},l.getEdgeCollections=function(){return h},l.getSelectedEdgeCollection=function(){return i},l.useEdgeCollection=function(a){if(!_.contains(h,a))throw"Collection "+a+" is not available in the graph.";i=a},l.getNodeCollections=function(){return f},l.getSelectedNodeCollection=function(){return g},l.useNodeCollection=function(a){if(!_.contains(f,a))throw"Collection "+a+" is not available in the graph.";g=a},l.getDirection=function(){return k},l.getGraphName=function(){return j},l.setWidth=e.setWidth,l.changeTo=e.changeTo,l.getPrioList=e.getPrioList}function ModularityJoiner(){"use strict";var a={},b=Array.prototype.forEach,c=Object.keys,d=Array.isArray,e=Object.prototype.toString,f=Array.prototype.indexOf,g=Array.prototype.map,h=Array.prototype.some,i={isArray:d||function(a){return"[object Array]"===e.call(a)},isFunction:function(a){return"function"==typeof a},isString:function(a){return"[object String]"===e.call(a)},each:function(c,d,e){if(null!==c&&void 0!==c){var f,g,h;if(b&&c.forEach===b)c.forEach(d,e);else if(c.length===+c.length){for(f=0,g=c.length;g>f;f++)if(d.call(e,c[f],f,c)===a)return}else for(h in c)if(c.hasOwnProperty(h)&&d.call(e,c[h],h,c)===a)return}},keys:c||function(a){if("object"!=typeof a||Array.isArray(a))throw new TypeError("Invalid object");var b,c=[];for(b in a)a.hasOwnProperty(b)&&(c[c.length]=b);return c},min:function(a,b,c){if(!b&&i.isArray(a)&&a[0]===+a[0]&&a.length<65535)return Math.min.apply(Math,a);if(!b&&i.isEmpty(a))return 1/0;var d={computed:1/0,value:1/0};return i.each(a,function(a,e,f){var g=b?b.call(c,a,e,f):a;gc&&(c=a,b=d)}),0>c?void delete q[a]:void(q[a]=b)},t=function(a,b){s(b)},u=function(a,b){return b>a?p[a]&&p[a][b]:p[b]&&p[b][a]},v=function(a,b){return b>a?p[a][b]:p[b][a]},w=function(a,b,c){return b>a?(p[a]=p[a]||{},void(p[a][b]=c)):(p[b]=p[b]||{},void(p[b][a]=c))},x=function(a,b){if(b>a){if(!p[a])return;return delete p[a][b],void(i.isEmpty(p[a])&&delete p[a])}a!==b&&x(b,a)},y=function(a,b){var c,d;return b>a?u(a,b)?(d=v(a,b),q[a]===b?void s(a):u(a,q[a])?(c=v(a,q[a]),void(d>c&&(q[a]=b))):void s(a)):void s(a):void(a!==b&&y(b,a))},z=function(a,b){o[a]._in+=o[b]._in,o[a]._out+=o[b]._out,delete o[b]},A=function(a,b){j[a]=j[a]||{},j[a][b]=(j[a][b]||0)+1,k[b]=k[b]||{},k[b][a]=(k[b][a]||0)+1,l[a]=l[a]||{_in:0,_out:0},l[b]=l[b]||{_in:0,_out:0},l[a]._out++,l[b]._in++,m++,n=Math.pow(m,-1)},B=function(a,b){j[a]&&(j[a][b]--,0===j[a][b]&&delete j[a][b],k[b][a]--,0===k[b][a]&&delete k[b][a],l[a]._out--,l[b]._in--,m--,n=m>0?Math.pow(m,-1):0,i.isEmpty(j[a])&&delete j[a],i.isEmpty(k[b])&&delete k[b],0===l[a]._in&&0===l[a]._out&&delete l[a],0===l[b]._in&&0===l[b]._out&&delete l[b])},C=function(){return o={},i.each(l,function(a,b){o[b]={_in:a._in/m,_out:a._out/m}}),o},D=function(a,b){return o[a]._out*o[b]._in+o[a]._in*o[b]._out},E=function(a){var b=i.keys(j[a]||{}),c=i.keys(k[a]||{});return i.union(b,c)},F=function(){p={},i.each(j,function(a,b){var c=k[b]||{},d=E(b);i.each(d,function(d){var e,f=a[d]||0;f+=c[d]||0,e=f*n-D(b,d),e>0&&w(b,d,e)})})},G=function(){return q={},i.each(p,t),q},H=function(a,b,c){var d;return u(c,a)?(d=v(c,a),u(c,b)?(d+=v(c,b),w(c,a,d),x(c,b),y(c,a),void y(c,b)):(d-=D(c,b),0>d&&x(c,a),void y(c,a))):void(u(c,b)&&(d=v(c,b),d-=D(c,a),d>0&&w(c,a,d),y(c,a),x(c,b),y(c,b)))},I=function(a,b){i.each(p,function(c,d){return d===a||d===b?void i.each(c,function(c,d){return d===b?(x(a,b),void y(a,b)):void H(a,b,d)}):void H(a,b,d)})},J=function(){return j},K=function(){return q},L=function(){return p},M=function(){return o},N=function(){return r},O=function(){var a,b,c=Number.NEGATIVE_INFINITY;return i.each(q,function(d,e){c=c?null:{sID:b,lID:a,val:c}},P=function(a){var b,c=Number.NEGATIVE_INFINITY;return i.each(a,function(a){a.q>c&&(c=a.q,b=a.nodes)}),b},Q=function(){C(),F(),G(),r={}},R=function(a){var b=a.sID,c=a.lID,d=a.val;r[b]=r[b]||{nodes:[b],q:0},r[c]?(r[b].nodes=r[b].nodes.concat(r[c].nodes),r[b].q+=r[c].q,delete r[c]):r[b].nodes.push(c),r[b].q+=d,I(b,c),z(b,c)},S=function(a,b,c){if(0===c.length)return!0;var d=[];return i.each(c,function(c){a[c]===Number.POSITIVE_INFINITY&&(a[c]=b,d=d.concat(E(c)))}),S(a,b+1,d)},T=function(a){var b={};if(i.each(j,function(a,c){b[c]=Number.POSITIVE_INFINITY}),b[a]=0,S(b,1,E(a)))return b;throw"FAIL!"},U=function(a){return function(b){return a[b]}},V=function(a,b){var c,d={},e=[],f={},g=function(a,b){var c=f[i.min(a,U(f))],e=f[i.min(b,U(f))],g=e-c;return 0===g&&(g=d[b[b.length-1]].q-d[a[a.length-1]].q),g};for(Q(),c=O();null!==c;)R(c),c=O();return d=N(),void 0!==b?(i.each(d,function(a,c){i.contains(a.nodes,b)&&delete d[c]}),e=i.pluck(i.values(d),"nodes"),f=T(b),e.sort(g),e[0]):P(d)};this.insertEdge=A,this.deleteEdge=B,this.getAdjacencyMatrix=J,this.getHeap=K,this.getDQ=L,this.getDegrees=M,this.getCommunities=N,this.getBest=O,this.setup=Q,this.joinCommunity=R,this.getCommunity=V}function NodeReducer(a){"use strict";a=a||[];var b=function(a,b){a.push(b)},c=function(a,b){if(!a.reason.example)return a.reason.example=b,1;var c=b._data||{},d=a.reason.example._data||{},e=_.union(_.keys(d),_.keys(c)),f=0,g=0;return _.each(e,function(a){void 0!==d[a]&&void 0!==c[a]&&(f++,d[a]===c[a]&&(f+=4))}),g=5*e.length,g++,f++,f/g},d=function(){return a},e=function(b){a=b},f=function(b,c){var d={},e=[];return _.each(b,function(b){var c,e,f=b._data,g=0;for(g=0;gd;d++){if(g[d]=g[d]||{reason:{type:"similar",text:"Similar Nodes"},nodes:[]},c(g[d],a)>h)return void b(g[d].nodes,a);i>g[d].nodes.length&&(f=d,i=g[d].nodes.length)}b(g[f].nodes,a)}),g):f(d,e)};this.bucketNodes=g,this.changePrioList=e,this.getPrioList=d}function NodeShaper(a,b,c){"use strict";var d,e,f=this,g=[],h=!0,i=new ContextMenu("gv_node_cm"),j=function(a,b){return _.isArray(a)?b[_.find(a,function(a){return b[a]})]:b[a]},k=function(a){if(void 0===a)return[""];"string"!=typeof a&&(a=String(a));var b=a.match(/[\w\W]{1,10}(\s|$)|\S+?(\s|$)/g);return b[0]=$.trim(b[0]),b[1]=$.trim(b[1]),b[0].length>12&&(b[0]=$.trim(a.substring(0,10)),b[1]=$.trim(a.substring(10)),b[1].length>12&&(b[1]=b[1].split(/\W/)[0],b[1].length>2&&(b[1]=b[1].substring(0,5)+"...")),b.length=2),b.length>2&&(b.length=2,b[1]+="..."),b},l=function(a){},m=l,n=function(a){return{x:a.x,y:a.y,z:1}},o=n,p=function(){_.each(g,function(a){a.position=o(a),a._isCommunity&&a.addDistortion(o)})},q=new ColourMapper,r=function(){q.reset()},s=function(a){return a._id},t=l,u=l,v=l,w=function(){return"black"},x=function(){f.parent.selectAll(".node").on("mousedown.drag",null),d={click:l,dblclick:l,drag:l,mousedown:l,mouseup:l,mousemove:l,mouseout:l,mouseover:l},e=l},y=function(a){_.each(d,function(b,c){"drag"===c?a.call(b):a.on(c,b)})},z=function(a){var b=a.filter(function(a){return a._isCommunity}),c=a.filter(function(a){return!a._isCommunity});u(c),b.each(function(a){a.shapeNodes(d3.select(this),u,z,m,q)}),h&&v(c),t(c),y(c),p()},A=function(a,b){if("update"===a)e=b;else{if(void 0===d[a])throw"Sorry Unknown Event "+a+" cannot be bound.";d[a]=b}},B=function(){var a=f.parent.selectAll(".node");p(),a.attr("transform",function(a){return"translate("+a.position.x+","+a.position.y+")scale("+a.position.z+")"}),e(a)},C=function(a){void 0!==a&&(g=a);var b=f.parent.selectAll(".node").data(g,s);b.enter().append("g").attr("class",function(a){return a._isCommunity?"node communitynode":"node"}).attr("id",s),b.exit().remove(),b.selectAll("* > *").remove(),z(b),B(),i.bindMenu($(".node"))},D=function(a){var b,c,d,e,f,g,h;switch(a.type){case NodeShaper.shapes.NONE:u=l;break;case NodeShaper.shapes.CIRCLE:b=a.radius||25,u=function(a,c){a.append("circle").attr("r",b),c&&a.attr("cx",-c).attr("cy",-c)};break;case NodeShaper.shapes.RECT:c=a.width||90,d=a.height||36,e=_.isFunction(c)?function(a){return-(c(a)/2)}:function(a){return-(c/2)},f=_.isFunction(d)?function(a){return-(d(a)/2)}:function(){return-(d/2)},u=function(a,b){b=b||0,a.append("rect").attr("width",c).attr("height",d).attr("x",function(a){return e(a)-b}).attr("y",function(a){return f(a)-b}).attr("rx","8").attr("ry","8")};break;case NodeShaper.shapes.IMAGE:c=a.width||32,d=a.height||32,g=a.fallback||"",h=a.source||g,e=_.isFunction(c)?function(a){return-(c(a)/2)}:-(c/2),f=_.isFunction(d)?function(a){return-(d(a)/2)}:-(d/2),u=function(a){var b=a.append("image").attr("width",c).attr("height",d).attr("x",e).attr("y",f);_.isFunction(h)?b.attr("xlink:href",h):b.attr("xlink:href",function(a){return a._data[h]?a._data[h]:g})};break;case void 0:break;default:throw"Sorry given Shape not known!"}},E=function(a){var b=[];_.each(a,function(a){b=$(a).find("text"),$(a).css("width","90px"),$(a).css("height","36px"),$(a).textfill({innerTag:"text",maxFontPixels:16,minFontPixels:10,explicitWidth:90,explicitHeight:36})})},F=function(a){v=_.isFunction(a)?function(b){var c=b.append("text").attr("text-anchor","middle").attr("fill",w).attr("stroke","none");c.each(function(b){var c=k(a(b)),d=c[0];2===c.length&&(d+=c[1]),d.length>15&&(d=d.substring(0,13)+"..."),(void 0===d||""===d)&&(d="ATTR NOT SET"),d3.select(this).append("tspan").attr("x","0").attr("dy","5").text(d)}),E(b)}:function(b){var c=b.append("text").attr("text-anchor","middle").attr("fill",w).attr("stroke","none");c.each(function(b){var c=k(j(a,b._data)),d=c[0];2===c.length&&(d+=c[1]),d.length>15&&(d=d.substring(0,13)+"..."),(void 0===d||""===d)&&(d="ATTR NOT SET"),d3.select(this).append("tspan").attr("x","0").attr("dy","5").text(d)}),E(b)}},G=function(a){void 0!==a.reset&&a.reset&&x(),_.each(a,function(a,b){"reset"!==b&&A(b,a)})},H=function(a){switch(r(),a.type){case"single":t=function(b){b.attr("fill",a.fill)},w=function(b){return a.stroke};break;case"expand":t=function(b){b.attr("fill",function(b){return b._expanded?a.expanded:a.collapsed})},w=function(a){return"white"};break;case"attribute":t=function(b){b.attr("fill",function(b){return void 0===b._data?q.getCommunityColour():q.getColour(j(a.key,b._data))}).attr("stroke",function(a){return a._expanded?"#fff":"transparent"}).attr("fill-opacity",function(a){return a._expanded?"1":"0.3"})},w=function(b){return void 0===b._data?q.getForegroundCommunityColour():q.getForegroundColour(j(a.key,b._data))};break;default:throw"Sorry given colour-scheme not known"}},I=function(a){if("reset"===a)o=n;else{if(!_.isFunction(a))throw"Sorry distortion cannot be parsed.";o=a}},J=function(a){void 0!==a.shape&&D(a.shape),void 0!==a.label&&(F(a.label),f.label=a.label),void 0!==a.actions&&G(a.actions),void 0!==a.color&&(H(a.color),f.color=a.color),void 0!==a.distortion&&I(a.distortion)};f.parent=a,x(),void 0===b&&(b={}),void 0===b.shape&&(b.shape={type:NodeShaper.shapes.RECT}),void 0===b.color&&(b.color={type:"single",fill:"#333333",stroke:"white"}),void 0===b.distortion&&(b.distortion="reset"),J(b),_.isFunction(c)&&(s=c),f.changeTo=function(a){J(a),C()},f.drawNodes=function(a){C(a)},f.updateNodes=function(){B()},f.reshapeNodes=function(){C()},f.activateLabel=function(a){h=a?!0:!1,C()},f.getColourMapping=function(){return q.getList()},f.setColourMappingListener=function(a){q.setChangeListener(a)},f.setGVStartFunction=function(a){m=a},f.getLabel=function(){return f.label||""},f.getColor=function(){return f.color.key||""},f.addMenuEntry=function(a,b){i.addEntry(a,b)},f.resetColourMap=r}function PreviewAdapter(a,b,c,d){"use strict";if(void 0===a)throw"The nodes have to be given.";if(void 0===b)throw"The edges have to be given.";if(void 0===c)throw"A reference to the graph viewer has to be given.";var e=this,f=new AbstractAdapter(a,b,this,c),g=function(a){void 0!==a.width&&f.setWidth(a.width),void 0!==a.height&&f.setHeight(a.height)},h=function(a,b){var c={},d=a.first;d=f.insertNode(d),_.each(a.nodes,function(a){a=f.insertNode(a),c[a._id]=a}),_.each(a.edges,function(a){f.insertEdge(a)}),delete c[d._id],void 0!==b&&_.isFunction(b)&&b(d)};d=d||{},g(d),e.loadInitialNode=function(a,b){f.cleanUp();var c=function(a){b(f.insertInitialNode(a))};e.loadNode(a,c)},e.loadNode=function(a,b){var c=[],d=[],e={},f={_id:1,label:"Node 1",image:"img/stored.png"},g={_id:2,label:"Node 2"},i={_id:3,label:"Node 3"},j={_id:4,label:"Node 4"},k={_id:5,label:"Node 5"},l={_id:"1-2",_from:1,_to:2,label:"Edge 1"},m={_id:"1-3",_from:1,_to:3,label:"Edge 2"},n={_id:"1-4",_from:1,_to:4,label:"Edge 3"},o={_id:"1-5",_from:1,_to:5,label:"Edge 4"},p={_id:"2-3",_from:2,_to:3,label:"Edge 5"};c.push(f),c.push(g),c.push(i),c.push(j),c.push(k),d.push(l),d.push(m),d.push(n),d.push(o),d.push(p),e.first=f,e.nodes=c,e.edges=d,h(e,b)},e.explore=f.explore,e.requestCentralityChildren=function(a,b){},e.createEdge=function(a,b){window.alert("Server-side: createEdge was triggered.")},e.deleteEdge=function(a,b){window.alert("Server-side: deleteEdge was triggered.")},e.patchEdge=function(a,b,c){window.alert("Server-side: patchEdge was triggered.")},e.createNode=function(a,b){window.alert("Server-side: createNode was triggered.")},e.deleteNode=function(a,b){window.alert("Server-side: deleteNode was triggered."),window.alert("Server-side: onNodeDelete was triggered.")},e.patchNode=function(a,b,c){window.alert("Server-side: patchNode was triggered.")},e.setNodeLimit=function(a,b){f.setNodeLimit(a,b)},e.setChildLimit=function(a){f.setChildLimit(a)},e.setWidth=f.setWidth,e.expandCommunity=function(a,b){f.expandCommunity(a),void 0!==b&&b()}}function WebWorkerWrapper(a,b){"use strict";if(void 0===a)throw"A class has to be given.";if(void 0===b)throw"A callback has to be given.";var c,d=Array.prototype.slice.call(arguments),e={},f=function(){var c,d=function(a){switch(a.data.cmd){case"construct":try{w=new(Function.prototype.bind.apply(Construct,[null].concat(a.data.args))),w?self.postMessage({cmd:"construct",result:!0}):self.postMessage({cmd:"construct",result:!1})}catch(b){self.postMessage({cmd:"construct",result:!1,error:b.message||b})}break;default:var c,d={cmd:a.data.cmd};if(w&&"function"==typeof w[a.data.cmd])try{c=w[a.data.cmd].apply(w,a.data.args),c&&(d.result=c),self.postMessage(d)}catch(e){d.error=e.message||e,self.postMessage(d)}else d.error="Method not known",self.postMessage(d)}},e=function(a){var b="var w, Construct = "+a.toString()+";self.onmessage = "+d.toString();return new window.Blob(b.split())},f=window.webkitURL||window.URL,g=new e(a);return c=new window.Worker(f.createObjectURL(g)),c.onmessage=b,c},g=function(){return a.apply(this,d)};try{return c=f(),e.call=function(a){var b=Array.prototype.slice.call(arguments);b.shift(),c.postMessage({cmd:a,args:b})},d.shift(),d.shift(),d.unshift("construct"),e.call.apply(this,d),e}catch(h){d.shift(),d.shift(),g.prototype=a.prototype;try{c=new g}catch(i){return void b({data:{cmd:"construct",error:i}})}return e.call=function(a){var d=Array.prototype.slice.call(arguments),e={data:{cmd:a}};if(!_.isFunction(c[a]))return e.data.error="Method not known",void b(e);d.shift();try{e.data.result=c[a].apply(c,d),b(e)}catch(f){e.data.error=f,b(e)}},b({data:{cmd:"construct",result:!0}}),e}}function ZoomManager(a,b,c,d,e,f,g,h){"use strict";if(void 0===a||0>a)throw"A width has to be given.";if(void 0===b||0>b)throw"A height has to be given.";if(void 0===c||void 0===c.node||"svg"!==c.node().tagName.toLowerCase())throw"A svg has to be given.";if(void 0===d||void 0===d.node||"g"!==d.node().tagName.toLowerCase())throw"A group has to be given.";if(void 0===e||void 0===e.activateLabel||void 0===e.changeTo||void 0===e.updateNodes)throw"The Node shaper has to be given.";if(void 0===f||void 0===f.activateLabel||void 0===f.updateEdges)throw"The Edge shaper has to be given.";var i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x=this,y=a*b,z=h||function(){},A=function(){var a,b;return l>=k?(b=i*l,b*=b,a=60*b):(b=j*l,b*=b,a=4*Math.PI*b),Math.floor(y/a)},B=function(){q=s/l-.99999999,r=t/l,p.distortion(q),p.radius(r)},C=function(a,b,c,g){g?null!==a&&(l=a):l=a,null!==b&&(m[0]+=b),null!==c&&(m[1]+=c),o=A(),z(o),e.activateLabel(l>=k),f.activateLabel(l>=k),B();var h="translate("+m+")",i=" scale("+l+")";d._isCommunity?d.attr("transform",h):d.attr("transform",h+i),v&&v.slider("option","value",l)},D=function(a){var b=[];return b[0]=a[0]-n[0],b[1]=a[1]-n[1],n[0]=a[0],n[1]=a[1],b},E=function(a){void 0===a&&(a={});var b=a.maxFont||16,c=a.minFont||6,d=a.maxRadius||25,e=a.minRadius||4;s=a.focusZoom||1,t=a.focusRadius||100,w=e/d,i=b,j=d,k=c/b,l=1,m=[0,0],n=[0,0],B(),o=A(),u=d3.behavior.zoom().scaleExtent([w,1]).on("zoom",function(){var a,b=d3.event.sourceEvent,c=l;"mousewheel"===b.type||"DOMMouseScroll"===b.type?(b.wheelDelta?b.wheelDelta>0?(c+=.01,c>1&&(c=1)):(c-=.01,w>c&&(c=w)):b.detail>0?(c+=.01,c>1&&(c=1)):(c-=.01,w>c&&(c=w)),a=[0,0]):a=D(d3.event.translate),C(c,a[0],a[1])})},F=function(){};p=d3.fisheye.circular(),E(g),c.call(u),e.changeTo({distortion:p}),c.on("mousemove",F),x.translation=function(){return null},x.scaleFactor=function(){return l},x.scaledMouse=function(){return null},x.getDistortion=function(){return q},x.getDistortionRadius=function(){return r},x.getNodeLimit=function(){return o},x.getMinimalZoomFactor=function(){return w},x.registerSlider=function(a){v=a},x.triggerScale=function(a){C(a,null,null,!0)},x.triggerTranslation=function(a,b){C(null,a,b,!0)},x.changeWidth=function(c){y=a*b}}function ArangoAdapterControls(a,b){"use strict";if(void 0===a)throw"A list element has to be given.";if(void 0===b)throw"The ArangoAdapter has to be given.";this.addControlChangeCollections=function(c){var d="control_adapter_collections",e=d+"_";b.getCollections(function(f,g){b.getGraphs(function(h){uiComponentsHelper.createButton(a,"Collections",d,function(){modalDialogHelper.createModalDialog("Switch Collections",e,[{type:"decission",id:"collections",group:"loadtype",text:"Select existing collections",isDefault:void 0===b.getGraphName(),interior:[{type:"list",id:"node_collection",text:"Vertex collection",objects:f,selected:b.getNodeCollection()},{type:"list",id:"edge_collection",text:"Edge collection",objects:g,selected:b.getEdgeCollection()}]},{type:"decission",id:"graphs",group:"loadtype",text:"Select existing graph",isDefault:void 0!==b.getGraphName(), interior:[{type:"list",id:"graph",objects:h,selected:b.getGraphName()}]},{type:"checkbox",text:"Start with random vertex",id:"random",selected:!0},{type:"checkbox",id:"undirected",selected:"any"===b.getDirection()}],function(){var a=$("#"+e+"node_collection").children("option").filter(":selected").text(),d=$("#"+e+"edge_collection").children("option").filter(":selected").text(),f=$("#"+e+"graph").children("option").filter(":selected").text(),g=!!$("#"+e+"undirected").prop("checked"),h=!!$("#"+e+"random").prop("checked"),i=$("input[type='radio'][name='loadtype']:checked").prop("id");return i===e+"collections"?b.changeToCollections(a,d,g):b.changeToGraph(f,g),h?void b.loadRandomNode(c):void(_.isFunction(c)&&c())})})})})},this.addControlChangePriority=function(){var c="control_adapter_priority",d=c+"_",e=(b.getPrioList(),"Group vertices");uiComponentsHelper.createButton(a,e,c,function(){modalDialogHelper.createModalChangeDialog(e,d,[{type:"extendable",id:"attribute",objects:b.getPrioList()}],function(){var a=$("input[id^="+d+"attribute_]"),c=[];a.each(function(a,b){var d=$(b).val();""!==d&&c.push(d)}),b.changeTo({prioList:c})})})},this.addAll=function(){this.addControlChangeCollections(),this.addControlChangePriority()}}function ContextMenu(a){"use strict";if(void 0===a)throw"An id has to be given.";var b,c,d="#"+a,e=function(a,d){var e,f;e=document.createElement("div"),e.className="context-menu-item",f=document.createElement("div"),f.className="context-menu-item-inner",f.appendChild(document.createTextNode(a)),f.onclick=function(){d(d3.select(c.target).data()[0])},e.appendChild(f),b.appendChild(e)},f=function(a){c=$.contextMenu.create(d,{shadow:!1}),a.each(function(){$(this).bind("contextmenu",function(a){return c.show(this,a),!1})})},g=function(){return b=document.getElementById(a),b&&b.parentElement.removeChild(b),b=document.createElement("div"),b.className="context-menu context-menu-theme-osx",b.id=a,document.body.appendChild(b),b};g(),this.addEntry=e,this.bindMenu=f}function EdgeShaperControls(a,b){"use strict";if(void 0===a)throw"A list element has to be given.";if(void 0===b)throw"The EdgeShaper has to be given.";var c=this;this.addControlOpticShapeNone=function(){var c="control_edge_none";uiComponentsHelper.createButton(a,"None",c,function(){b.changeTo({shape:{type:EdgeShaper.shapes.NONE}})})},this.addControlOpticShapeArrow=function(){var c="control_edge_arrow";uiComponentsHelper.createButton(a,"Arrow",c,function(){b.changeTo({shape:{type:EdgeShaper.shapes.ARROW}})})},this.addControlOpticLabel=function(){var c="control_edge_label",d=c+"_";uiComponentsHelper.createButton(a,"Configure Label",c,function(){modalDialogHelper.createModalDialog("Switch Label Attribute",d,[{type:"text",id:"key",text:"Edge label attribute",value:b.getLabel()}],function(){var a=$("#"+d+"key").attr("value");b.changeTo({label:a})})})},this.addControlOpticLabelList=function(){var d="control_edge_label",e=d+"_";uiComponentsHelper.createButton(a,"Configure Label",d,function(){modalDialogHelper.createModalDialog("Change Label Attribute",e,[{type:"extendable",id:"label",text:"Edge label attribute",objects:b.getLabel()}],function(){var a=$("input[id^="+e+"label_]"),d=[];a.each(function(a,b){var c=$(b).val();""!==c&&d.push(c)});var f={label:d};c.applyLocalStorage(f),b.changeTo(f)})})},this.applyLocalStorage=function(a){if("undefined"!==Storage)try{var b=JSON.parse(localStorage.getItem("graphSettings")),c=window.location.hash.split("/")[1],d=window.location.pathname.split("/")[2],e=c+d;_.each(a,function(a,c){void 0!==c&&(b[e].viewer.hasOwnProperty("edgeShaper")||(b[e].viewer.edgeShaper={}),b[e].viewer.edgeShaper[c]=a)}),localStorage.setItem("graphSettings",JSON.stringify(b))}catch(f){console.log(f)}},this.addControlOpticSingleColour=function(){var c="control_edge_singlecolour",d=c+"_";uiComponentsHelper.createButton(a,"Single Colour",c,function(){modalDialogHelper.createModalDialog("Switch to Colour",d,[{type:"text",id:"stroke"}],function(){var a=$("#"+d+"stroke").attr("value");b.changeTo({color:{type:"single",stroke:a}})})})},this.addControlOpticAttributeColour=function(){var c="control_edge_attributecolour",d=c+"_";uiComponentsHelper.createButton(a,"Colour by Attribute",c,function(){modalDialogHelper.createModalDialog("Display colour by attribute",d,[{type:"text",id:"key"}],function(){var a=$("#"+d+"key").attr("value");b.changeTo({color:{type:"attribute",key:a}})})})},this.addControlOpticGradientColour=function(){var c="control_edge_gradientcolour",d=c+"_";uiComponentsHelper.createButton(a,"Gradient Colour",c,function(){modalDialogHelper.createModalDialog("Change colours for gradient",d,[{type:"text",id:"source"},{type:"text",id:"target"}],function(){var a=$("#"+d+"source").attr("value"),c=$("#"+d+"target").attr("value");b.changeTo({color:{type:"gradient",source:a,target:c}})})})},this.addAllOptics=function(){c.addControlOpticShapeNone(),c.addControlOpticShapeArrow(),c.addControlOpticLabel(),c.addControlOpticSingleColour(),c.addControlOpticAttributeColour(),c.addControlOpticGradientColour()},this.addAllActions=function(){},this.addAll=function(){c.addAllOptics(),c.addAllActions()}}function EventDispatcherControls(a,b,c,d,e){"use strict";if(void 0===a)throw"A list element has to be given.";if(void 0===b)throw"The NodeShaper has to be given.";if(void 0===c)throw"The EdgeShaper has to be given.";if(void 0===d)throw"The Start callback has to be given.";var f=this,g={expand:{icon:"hand-pointer-o",title:"Expand a node."},add:{icon:"plus-square",title:"Add a node."},trash:{icon:"minus-square",title:"Remove a node/edge."},drag:{icon:"hand-rock-o",title:"Drag a node."},edge:{icon:"external-link-square",title:"Create an edge between two nodes."},edit:{icon:"pencil-square",title:"Edit attributes of a node."},view:{icon:"search",title:"View attributes of a node."}},h=new EventDispatcher(b,c,e),i=e.edgeEditor.adapter,j=!!i&&_.isFunction(i.useNodeCollection)&&_.isFunction(i.useEdgeCollection),k=function(b){a.appendChild(b)},l=function(a,b,c){var d=uiComponentsHelper.createIconButton(a,"control_event_"+b,c);k(d)},m=function(a){h.rebind("nodes",a)},n=function(a){h.rebind("edges",a)},o=function(a){h.rebind("svg",a)},p=function(a){var b=a||window.event,c={};return c.x=b.clientX,c.y=b.clientY,c.x+=document.body.scrollLeft,c.y+=document.body.scrollTop,c},q=function(a){var b,c,d,e=p(a),f=$("svg#graphViewerSVG").offset();return b=d3.select("svg#graphViewerSVG").node(),d=b.getBoundingClientRect(),$("svg#graphViewerSVG").height()<=d.height?{x:e.x-f.left,y:e.y-f.top}:(c=b.getBBox(),{x:e.x-(d.left-c.x),y:e.y-(d.top-c.y)})},r={nodes:{},edges:{},svg:{}},s=function(){var a="control_event_new_node",c=a+"_",e=function(a){var e=q(a);modalDialogHelper.createModalCreateDialog("Create New Node",c,{},function(a){h.events.CREATENODE(a,function(a){$("#"+c+"modal").modal("hide"),b.reshapeNodes(),d()},e.x,e.y)()})};r.nodes.newNode=e},t=function(){var a=function(a){modalDialogHelper.createModalViewDialog("View Node "+a._id,"control_event_node_view_",a._data,function(){modalDialogHelper.createModalEditDialog("Edit Node "+a._id,"control_event_node_edit_",a._data,function(b){h.events.PATCHNODE(a,b,function(){$("#control_event_node_edit_modal").modal("hide")})()})})},b=function(a){modalDialogHelper.createModalViewDialog("View Edge "+a._id,"control_event_edge_view_",a._data,function(){modalDialogHelper.createModalEditDialog("Edit Edge "+a._id,"control_event_edge_edit_",a._data,function(b){h.events.PATCHEDGE(a,b,function(){$("#control_event_edge_edit_modal").modal("hide")})()})})};r.nodes.view=a,r.edges.view=b},u=function(){var a=h.events.STARTCREATEEDGE(function(a,b){var d=q(b),e=c.addAnEdgeFollowingTheCursor(d.x,d.y);h.bind("svg","mousemove",function(a){var b=q(a);e(b.x,b.y)})}),b=h.events.FINISHCREATEEDGE(function(a){c.removeCursorFollowingEdge(),h.bind("svg","mousemove",function(){return void 0}),d()}),e=function(){h.events.CANCELCREATEEDGE(),c.removeCursorFollowingEdge(),h.bind("svg","mousemove",function(){return void 0})};r.nodes.startEdge=a,r.nodes.endEdge=b,r.svg.cancelEdge=e},v=function(){var a=function(a){arangoHelper.openDocEditor(a._id,"document")},b=function(a){arangoHelper.openDocEditor(a._id,"edge")};r.nodes.edit=a,r.edges.edit=b},w=function(){var a=function(a){modalDialogHelper.createModalDeleteDialog("Delete Node "+a._id,"control_event_node_delete_",a,function(a){h.events.DELETENODE(function(){$("#control_event_node_delete_modal").modal("hide"),b.reshapeNodes(),c.reshapeEdges(),d()})(a)})},e=function(a){modalDialogHelper.createModalDeleteDialog("Delete Edge "+a._id,"control_event_edge_delete_",a,function(a){h.events.DELETEEDGE(function(){$("#control_event_edge_delete_modal").modal("hide"),b.reshapeNodes(),c.reshapeEdges(),d()})(a)})};r.nodes.del=a,r.edges.del=e},x=function(){r.nodes.spot=h.events.EXPAND};s(),t(),u(),v(),w(),x(),this.dragRebinds=function(){return{nodes:{drag:h.events.DRAG}}},this.newNodeRebinds=function(){return{svg:{click:r.nodes.newNode}}},this.viewRebinds=function(){return{nodes:{click:r.nodes.view},edges:{click:r.edges.view}}},this.connectNodesRebinds=function(){return{nodes:{mousedown:r.nodes.startEdge,mouseup:r.nodes.endEdge},svg:{mouseup:r.svg.cancelEdge}}},this.editRebinds=function(){return{nodes:{click:r.nodes.edit},edges:{click:r.edges.edit}}},this.expandRebinds=function(){return{nodes:{click:r.nodes.spot}}},this.deleteRebinds=function(){return{nodes:{click:r.nodes.del},edges:{click:r.edges.del}}},this.rebindAll=function(a){m(a.nodes),n(a.edges),o(a.svg)},b.addMenuEntry("Edit",r.nodes.edit),b.addMenuEntry("Spot",r.nodes.spot),b.addMenuEntry("Trash",r.nodes.del),c.addMenuEntry("Edit",r.edges.edit),c.addMenuEntry("Trash",r.edges.del),this.addControlNewNode=function(){var a=g.add,b="select_node_collection",c=function(){j&&i.getNodeCollections().length>1&&modalDialogHelper.createModalDialog("Select Vertex Collection",b,[{type:"list",id:"vertex",objects:i.getNodeCollections(),text:"Select collection",selected:i.getSelectedNodeCollection()}],function(){var a=$("#"+b+"vertex").children("option").filter(":selected").text();i.useNodeCollection(a)},"Select"),f.rebindAll(f.newNodeRebinds())};l(a,"new_node",c)},this.addControlView=function(){var a=g.view,b=function(){f.rebindAll(f.viewRebinds())};l(a,"view",b)},this.addControlDrag=function(){var a=g.drag,b=function(){f.rebindAll(f.dragRebinds())};l(a,"drag",b)},this.addControlEdit=function(){var a=g.edit,b=function(){f.rebindAll(f.editRebinds())};l(a,"edit",b)},this.addControlExpand=function(){var a=g.expand,b=function(){f.rebindAll(f.expandRebinds())};l(a,"expand",b)},this.addControlDelete=function(){var a=g.trash,b=function(){f.rebindAll(f.deleteRebinds())};l(a,"delete",b)},this.addControlConnect=function(){var a=g.edge,b="select_edge_collection",c=function(){j&&i.getEdgeCollections().length>1&&modalDialogHelper.createModalDialog("Select Edge Collection",b,[{type:"list",id:"edge",objects:i.getEdgeCollections(),text:"Select collection",selected:i.getSelectedEdgeCollection()}],function(){var a=$("#"+b+"edge").children("option").filter(":selected").text();i.useEdgeCollection(a)},"Select"),f.rebindAll(f.connectNodesRebinds())};l(a,"connect",c)},this.addAll=function(){f.addControlExpand(),f.addControlDrag(),f.addControlEdit(),f.addControlConnect(),f.addControlNewNode(),f.addControlDelete()}}function GharialAdapterControls(a,b){"use strict";if(void 0===a)throw"A list element has to be given.";if(void 0===b)throw"The GharialAdapter has to be given.";this.addControlChangeGraph=function(c){var d="control_adapter_graph",e=d+"_";b.getGraphs(function(f){uiComponentsHelper.createButton(a,"Switch Graph",d,function(){modalDialogHelper.createModalDialog("Switch Graph",e,[{type:"list",id:"graph",objects:f,text:"Select graph",selected:b.getGraphName()},{type:"checkbox",text:"Start with random vertex",id:"random",selected:!0}],function(){var a=$("#"+e+"graph").children("option").filter(":selected").text(),d=!!$("#"+e+"undirected").prop("checked"),f=!!$("#"+e+"random").prop("checked");return b.changeToGraph(a,d),f?void b.loadRandomNode(c):void(_.isFunction(c)&&c())})})})},this.addControlChangePriority=function(){var c="control_adapter_priority",d=c+"_",e="Group vertices";uiComponentsHelper.createButton(a,e,c,function(){modalDialogHelper.createModalChangeDialog(e+" by attribute",d,[{type:"extendable",id:"attribute",objects:b.getPrioList()}],function(){var a=$("input[id^="+d+"attribute_]"),c=[];_.each(a,function(a){var b=$(a).val();""!==b&&c.push(b)}),b.changeTo({prioList:c})})})},this.addAll=function(){this.addControlChangeGraph(),this.addControlChangePriority()}}function GraphViewerPreview(a,b){"use strict";var c,d,e,f,g,h,i,j=function(){return d3.select(a).append("svg").attr("id","graphViewerSVG").attr("width",d).attr("height",e).attr("class","graph-viewer").attr("style","width:"+d+"px;height:"+e+";")},k=function(a){var b=0;return _.each(a,function(c,d){c===!1?delete a[d]:b++}),b>0},l=function(a,b){_.each(b,function(b,c){a[c]=a[c]||{},_.each(b,function(b,d){a[c][d]=b})})},m=function(a){if(a){var b={};a.drag&&l(b,i.dragRebinds()),a.create&&(l(b,i.newNodeRebinds()),l(b,i.connectNodesRebinds())),a.remove&&l(b,i.deleteRebinds()),a.expand&&l(b,i.expandRebinds()),a.edit&&l(b,i.editRebinds()),i.rebindAll(b)}},n=function(b){var c=document.createElement("div");i=new EventDispatcherControls(c,f.nodeShaper,f.edgeShaper,f.start,f.dispatcherConfig),c.id="toolbox",c.className="btn-group btn-group-vertical pull-left toolbox",a.appendChild(c),_.each(b,function(a,b){switch(b){case"expand":i.addControlExpand();break;case"create":i.addControlNewNode(),i.addControlConnect();break;case"drag":i.addControlDrag();break;case"edit":i.addControlEdit();break;case"remove":i.addControlDelete()}})},o=function(a){var b=document.createElement("div");i=new EventDispatcherControls(b,f.nodeShaper,f.edgeShaper,f.start,f.dispatcherConfig)},p=function(){b&&(b.nodeShaper&&(b.nodeShaper.label&&(b.nodeShaper.label="label"),b.nodeShaper.shape&&b.nodeShaper.shape.type===NodeShaper.shapes.IMAGE&&b.nodeShaper.shape.source&&(b.nodeShaper.shape.source="image")),b.edgeShaper&&b.edgeShaper.label&&(b.edgeShaper.label="label"))},q=function(){return p(),new GraphViewer(c,d,e,h,b)};d=a.offsetWidth,e=a.offsetHeight,h={type:"preview"},b=b||{},g=k(b.toolbox),g&&(d-=43),c=j(),f=q(),g?n(b.toolbox):o(),f.loadGraph("1"),m(b.actions)}function GraphViewerUI(a,b,c,d,e,f){"use strict";if(void 0===a)throw"A parent element has to be given.";if(!a.id)throw"The parent element needs an unique id.";if(void 0===b)throw"An adapter configuration has to be given";var g,h,i,j,k,l,m,n,o,p=c+20||a.offsetWidth-81+20,q=d||a.offsetHeight,r=document.createElement("ul"),s=document.createElement("div"),t=function(){g.adapter.NODES_TO_DISPLAYGraph too big. A random section is rendered.
'),$(".infoField .fa-info-circle").attr("title","You can display additional/other vertices by using the toolbar buttons.").tooltip())},u=function(){var a,b=document.createElement("div"),c=document.createElement("div"),d=document.createElement("div"),e=document.createElement("div"),f=document.createElement("button"),h=document.createElement("span"),i=document.createElement("input"),j=document.createElement("i"),k=document.createElement("span"),l=function(){$(s).css("cursor","progress")},n=function(){$(s).css("cursor","")},o=function(a){return n(),a&&a.errorCode&&404===a.errorCode?void arangoHelper.arangoError("Graph error","could not find a matching node."):void 0},p=function(){l(),""===a.value||void 0===a.value?g.loadGraph(i.value,o):g.loadGraphWithAttributeValue(a.value,i.value,o)};b.id="filterDropdown",b.className="headerDropdown smallDropdown",c.className="dropdownInner",d.className="queryline",a=document.createElement("input"),m=document.createElement("ul"),e.className="pull-left input-append searchByAttribute",a.id="attribute",a.type="text",a.placeholder="Attribute name",f.id="attribute_example_toggle",f.className="button-neutral gv_example_toggle",h.className="caret gv_caret",m.className="gv-dropdown-menu",i.id="value",i.className="searchInput gv_searchInput",i.type="text",i.placeholder="Attribute value",j.id="loadnode",j.className="fa fa-search",k.className="searchEqualsLabel",k.appendChild(document.createTextNode("==")),c.appendChild(d),d.appendChild(e),e.appendChild(a),e.appendChild(f),e.appendChild(m),f.appendChild(h),d.appendChild(k),d.appendChild(i),d.appendChild(j),j.onclick=p,$(i).keypress(function(a){return 13===a.keyCode||13===a.which?(p(),!1):void 0}),f.onclick=function(){$(m).slideToggle(200)};var q=document.createElement("p");return q.className="dropdown-title",q.innerHTML="Filter graph by attribute:",b.appendChild(q),b.appendChild(c),b},v=function(){var a,b=document.createElement("div"),c=document.createElement("div"),d=document.createElement("div"),e=document.createElement("div"),f=document.createElement("button"),h=document.createElement("span"),i=document.createElement("input"),j=document.createElement("i"),k=document.createElement("span"),l=function(){$(s).css("cursor","progress")},m=function(){$(s).css("cursor","")},o=function(a){return m(),a&&a.errorCode&&404===a.errorCode?void arangoHelper.arangoError("Graph error","could not find a matching node."):void 0},p=function(){l(),""!==a.value&&g.loadGraphWithAdditionalNode(a.value,i.value,o)};b.id="nodeDropdown",b.className="headerDropdown smallDropdown",c.className="dropdownInner",d.className="queryline",a=document.createElement("input"),n=document.createElement("ul"),e.className="pull-left input-append searchByAttribute",a.id="attribute",a.type="text",a.placeholder="Attribute name",f.id="attribute_example_toggle2",f.className="button-neutral gv_example_toggle",h.className="caret gv_caret",n.className="gv-dropdown-menu",i.id="value",i.className="searchInput gv_searchInput",i.type="text",i.placeholder="Attribute value",j.id="loadnode",j.className="fa fa-search",k.className="searchEqualsLabel",k.appendChild(document.createTextNode("==")),c.appendChild(d),d.appendChild(e),e.appendChild(a),e.appendChild(f),e.appendChild(n),f.appendChild(h),d.appendChild(k),d.appendChild(i),d.appendChild(j),C(n),j.onclick=p,$(i).keypress(function(a){return 13===a.keyCode||13===a.which?(p(),!1):void 0}),f.onclick=function(){$(n).slideToggle(200)};var q=document.createElement("p");return q.className="dropdown-title",q.innerHTML="Add specific node by attribute:",b.appendChild(q),b.appendChild(c),b},w=function(){var a,b,c,d,e,f,g,h;return a=document.createElement("div"),a.id="configureDropdown",a.className="headerDropdown",b=document.createElement("div"),b.className="dropdownInner",c=document.createElement("ul"),d=document.createElement("li"),d.className="nav-header",d.appendChild(document.createTextNode("Vertices")),g=document.createElement("ul"),h=document.createElement("li"),h.className="nav-header",h.appendChild(document.createTextNode("Edges")),e=document.createElement("ul"),f=document.createElement("li"),f.className="nav-header",f.appendChild(document.createTextNode("Connection")),c.appendChild(d),g.appendChild(h),e.appendChild(f),b.appendChild(c),b.appendChild(g),b.appendChild(e),a.appendChild(b),{configure:a,nodes:c,edges:g,col:e}},x=function(a,b,c,d){var e,f,g,h,i,j,k,l,m,n,o;return a.className="headerButtonBar",e=document.createElement("ul"),e.className="headerButtonList",a.appendChild(e),g=document.createElement("li"),g.className="enabled",h=document.createElement("a"),h.id=b,h.className="headerButton",i=document.createElement("span"),i.className="icon_arangodb_settings2",$(i).attr("title","Configure"),e.appendChild(g),g.appendChild(h),h.appendChild(i),j=document.createElement("li"),j.className="enabled",k=document.createElement("a"),k.id=d,k.className="headerButton",l=document.createElement("span"),l.className="fa fa-search-plus",$(l).attr("title","Show additional vertices"),e.appendChild(j),j.appendChild(k),k.appendChild(l),m=document.createElement("li"),m.className="enabled",n=document.createElement("a"),n.id=c,n.className="headerButton",o=document.createElement("span"),o.className="icon_arangodb_filter",$(o).attr("title","Filter"),e.appendChild(m),m.appendChild(n),n.appendChild(o),f=w(),f.filter=u(),f.node=v(),h.onclick=function(){$("#filterdropdown").removeClass("activated"),$("#nodedropdown").removeClass("activated"),$("#configuredropdown").toggleClass("activated"),$(f.configure).slideToggle(200),$(f.filter).hide(),$(f.node).hide()},k.onclick=function(){$("#filterdropdown").removeClass("activated"),$("#configuredropdown").removeClass("activated"),$("#nodedropdown").toggleClass("activated"),$(f.node).slideToggle(200),$(f.filter).hide(),$(f.configure).hide()},n.onclick=function(){$("#configuredropdown").removeClass("activated"),$("#nodedropdown").removeClass("activated"),$("#filterdropdown").toggleClass("activated"),$(f.filter).slideToggle(200),$(f.node).hide(),$(f.configure).hide()},f},y=function(){return d3.select("#"+a.id+" #background").append("svg").attr("id","graphViewerSVG").attr("width",p).attr("height",q).attr("class","graph-viewer").style("width",p+"px").style("height",q+"px")},z=function(){var a=document.createElement("div"),b=document.createElement("div"),c=document.createElement("button"),d=document.createElement("button"),e=document.createElement("button"),f=document.createElement("button");a.className="gv_zoom_widget",b.className="gv_zoom_buttons_bg",c.className="btn btn-icon btn-zoom btn-zoom-top gv-zoom-btn pan-top",d.className="btn btn-icon btn-zoom btn-zoom-left gv-zoom-btn pan-left",e.className="btn btn-icon btn-zoom btn-zoom-right gv-zoom-btn pan-right",f.className="btn btn-icon btn-zoom btn-zoom-bottom gv-zoom-btn pan-bottom",c.onclick=function(){g.zoomManager.triggerTranslation(0,-10)},d.onclick=function(){g.zoomManager.triggerTranslation(-10,0)},e.onclick=function(){g.zoomManager.triggerTranslation(10,0)},f.onclick=function(){g.zoomManager.triggerTranslation(0,10)},b.appendChild(c),b.appendChild(d),b.appendChild(e),b.appendChild(f),l=document.createElement("div"),l.id="gv_zoom_slider",l.className="gv_zoom_slider",s.appendChild(a),s.insertBefore(a,o[0][0]),a.appendChild(b),a.appendChild(l),$("#gv_zoom_slider").slider({orientation:"vertical",min:g.zoomManager.getMinimalZoomFactor(),max:1,value:1,step:.01,slide:function(a,b){g.zoomManager.triggerScale(b.value)}}),g.zoomManager.registerSlider($("#gv_zoom_slider"))},A=function(){var a=document.createElement("div"),b=new EventDispatcherControls(a,g.nodeShaper,g.edgeShaper,g.start,g.dispatcherConfig);a.id="toolbox",a.className="btn-group btn-group-vertical toolbox",s.insertBefore(a,o[0][0]),b.addAll(),$("#control_event_expand").click()},B=function(){var a='
  • ';$(".headerBar .headerButtonList").prepend(a)},C=function(a){var b;b=a?$(a):$(m),b.innerHTML="";var c=document.createElement("li"),d=document.createElement("img");$(c).append(d),d.className="gv-throbber",b.append(c),g.adapter.getAttributeExamples(function(a){$(b).html(""),_.each(a,function(a){var c=document.createElement("li"),d=document.createElement("a"),e=document.createElement("label");$(c).append(d),$(d).append(e),$(e).append(document.createTextNode(a)),e.className="gv_dropdown_label",b.append(c),c.onclick=function(){b.value=a,$(b).parent().find("input").val(a),$(b).slideToggle(200)}})})},D=function(){var a=document.createElement("div"),b=document.createElement("div"),c=document.createElement("a"),d=x(b,"configuredropdown","filterdropdown","nodedropdown");i=new NodeShaperControls(d.nodes,g.nodeShaper),j=new EdgeShaperControls(d.edges,g.edgeShaper),k=new GharialAdapterControls(d.col,g.adapter),r.id="menubar",a.className="headerBar",b.id="modifiers",c.appendChild(document.createTextNode("Graph Viewer")),c.className="arangoHeader",r.appendChild(a),r.appendChild(d.configure),r.appendChild(d.filter),r.appendChild(d.node),a.appendChild(b),a.appendChild(c),k.addControlChangeGraph(function(){C(),g.start(!0)}),k.addControlChangePriority(),i.addControlOpticLabelAndColourList(g.adapter),j.addControlOpticLabelList(),C()},E=function(){h=i.createColourMappingList(),h.className="gv-colour-list",s.insertBefore(h,o[0][0])};a.appendChild(r),a.appendChild(s),s.className="contentDiv gv-background ",s.id="background",e=e||{},e.zoom=!0,o=y(),"undefined"!==Storage&&(this.graphSettings={},this.loadLocalStorage=function(){var a=b.baseUrl.split("/")[2],c=b.graphName+a;if(null===localStorage.getItem("graphSettings")||"null"===localStorage.getItem("graphSettings")){var d={};d[c]={viewer:e,adapter:b},localStorage.setItem("graphSettings",JSON.stringify(d))}else try{var f=JSON.parse(localStorage.getItem("graphSettings"));this.graphSettings=f,void 0!==f[c].viewer&&(e=f[c].viewer),void 0!==f[c].adapter&&(b=f[c].adapter)}catch(g){console.log("Could not load graph settings, resetting graph settings."),this.graphSettings[c]={viewer:e,adapter:b},localStorage.setItem("graphSettings",JSON.stringify(this.graphSettings))}},this.loadLocalStorage(),this.writeLocalStorage=function(){}),g=new GraphViewer(o,p,q,b,e),A(),z(),D(),E(),t(),B(),$("#graphSize").on("change",function(){var a=$("#graphSize").find(":selected").val();g.loadGraphWithRandomStart(function(a){a&&a.errorCode&&window.alert("Sorry your graph seems to be empty")},a)}),f&&("string"==typeof f?g.loadGraph(f):g.loadGraphWithRandomStart(function(a){a&&a.errorCode&&window.alert("Sorry your graph seems to be empty")})),this.changeWidth=function(a){g.changeWidth(a);var b=a-55;o.attr("width",b).style("width",b+"px")}}function GraphViewerWidget(a,b){"use strict";var c,d,e,f,g,h,i,j,k=function(){return d3.select(d).append("svg").attr("id","graphViewerSVG").attr("width",e).attr("height",f).attr("class","graph-viewer").attr("style","width:"+e+"px;height:"+f+"px;")},l=function(a){var b=0;return _.each(a,function(c,d){c===!1?delete a[d]:b++}),b>0},m=function(a,b){_.each(b,function(b,c){a[c]=a[c]||{},_.each(b,function(b,d){a[c][d]=b})})},n=function(a){if(a){var b={};a.drag&&m(b,j.dragRebinds()),a.create&&(m(b,j.newNodeRebinds()),m(b,j.connectNodesRebinds())),a.remove&&m(b,j.deleteRebinds()),a.expand&&m(b,j.expandRebinds()),a.edit&&m(b,j.editRebinds()),j.rebindAll(b)}},o=function(a){var b=document.createElement("div");j=new EventDispatcherControls(b,g.nodeShaper,g.edgeShaper,g.start,g.dispatcherConfig),b.id="toolbox",b.className="btn-group btn-group-vertical pull-left toolbox",d.appendChild(b),_.each(a,function(a,b){switch(b){case"expand":j.addControlExpand();break;case"create":j.addControlNewNode(),j.addControlConnect();break;case"drag":j.addControlDrag();break;case"edit":j.addControlEdit();break;case"remove":j.addControlDelete()}})},p=function(a){var b=document.createElement("div");j=new EventDispatcherControls(b,g.nodeShaper,g.edgeShaper,g.start,g.dispatcherConfig)},q=function(){return new GraphViewer(c,e,f,i,a)};d=document.body,e=d.offsetWidth,f=d.offsetHeight,i={type:"foxx",route:"."},a=a||{},h=l(a.toolbox),h&&(e-=43),c=k(),g=q(),h?o(a.toolbox):p(),b&&g.loadGraph(b),n(a.actions)}function LayouterControls(a,b){"use strict";if(void 0===a)throw"A list element has to be given.";if(void 0===b)throw"The Layouter has to be given.";var c=this;this.addControlGravity=function(){var c="control_layout_gravity",d=c+"_";uiComponentsHelper.createButton(a,"Gravity",c,function(){modalDialogHelper.createModalDialog("Switch Gravity Strength",d,[{type:"text",id:"value"}],function(){var a=$("#"+d+"value").attr("value");b.changeTo({gravity:a})})})},this.addControlCharge=function(){var c="control_layout_charge",d=c+"_";uiComponentsHelper.createButton(a,"Charge",c,function(){modalDialogHelper.createModalDialog("Switch Charge Strength",d,[{type:"text",id:"value"}],function(){var a=$("#"+d+"value").attr("value");b.changeTo({charge:a})})})},this.addControlDistance=function(){var c="control_layout_distance",d=c+"_";uiComponentsHelper.createButton(a,"Distance",c,function(){modalDialogHelper.createModalDialog("Switch Distance Strength",d,[{type:"text",id:"value"}],function(){var a=$("#"+d+"value").attr("value");b.changeTo({distance:a})})})},this.addAll=function(){c.addControlDistance(),c.addControlGravity(),c.addControlCharge()}}function NodeShaperControls(a,b){"use strict";if(void 0===a)throw"A list element has to be given.";if(void 0===b)throw"The NodeShaper has to be given.";var c,d=this,e=function(a){for(;c.hasChildNodes();)c.removeChild(c.lastChild);var b=document.createElement("ul");c.appendChild(b),_.each(a,function(a,c){var d=document.createElement("ul"),e=a.list,f=a.front;d.style.backgroundColor=c,d.style.color=f,_.each(e,function(a){var b=document.createElement("li");b.appendChild(document.createTextNode(a)),d.appendChild(b)}),b.appendChild(d)})};this.addControlOpticShapeNone=function(){uiComponentsHelper.createButton(a,"None","control_node_none",function(){b.changeTo({shape:{type:NodeShaper.shapes.NONE}})})},this.applyLocalStorage=function(a){if("undefined"!==Storage)try{var b=JSON.parse(localStorage.getItem("graphSettings")),c=window.location.hash.split("/")[1],d=window.location.pathname.split("/")[2],e=c+d;_.each(a,function(a,c){void 0!==c&&(b[e].viewer.nodeShaper[c]=a)}),localStorage.setItem("graphSettings",JSON.stringify(b))}catch(f){console.log(f)}},this.addControlOpticShapeCircle=function(){var c="control_node_circle",d=c+"_";uiComponentsHelper.createButton(a,"Circle",c,function(){modalDialogHelper.createModalDialog("Switch to Circle",d,[{type:"text",id:"radius"}],function(){var a=$("#"+d+"radius").attr("value");b.changeTo({shape:{type:NodeShaper.shapes.CIRCLE,radius:a}})})})},this.addControlOpticShapeRect=function(){var c="control_node_rect",d=c+"_";uiComponentsHelper.createButton(a,"Rectangle",c,function(){modalDialogHelper.createModalDialog("Switch to Rectangle","control_node_rect_",[{type:"text",id:"width"},{type:"text",id:"height"}],function(){var a=$("#"+d+"width").attr("value"),c=$("#"+d+"height").attr("value");b.changeTo({shape:{type:NodeShaper.shapes.RECT,width:a,height:c}})})})},this.addControlOpticLabel=function(){var c="control_node_label",e=c+"_";uiComponentsHelper.createButton(a,"Configure Label",c,function(){modalDialogHelper.createModalChangeDialog("Change label attribute",e,[{type:"text",id:"key"}],function(){var a=$("#"+e+"key").attr("value"),c={label:a};d.applyLocalStorage(c),b.changeTo(c)})})},this.addControlOpticSingleColour=function(){var c="control_node_singlecolour",d=c+"_";uiComponentsHelper.createButton(a,"Single Colour",c,function(){modalDialogHelper.createModalDialog("Switch to Colour",d,[{type:"text",id:"fill"},{type:"text",id:"stroke"}],function(){var a=$("#"+d+"fill").attr("value"),c=$("#"+d+"stroke").attr("value");b.changeTo({color:{type:"single",fill:a,stroke:c}})})})},this.addControlOpticAttributeColour=function(){var c="control_node_attributecolour",d=c+"_";uiComponentsHelper.createButton(a,"Colour by Attribute",c,function(){modalDialogHelper.createModalDialog("Display colour by attribute",d,[{type:"text",id:"key"}],function(){var a=$("#"+d+"key").attr("value");b.changeTo({color:{type:"attribute",key:a}})})})},this.addControlOpticExpandColour=function(){var c="control_node_expandcolour",d=c+"_";uiComponentsHelper.createButton(a,"Expansion Colour",c,function(){modalDialogHelper.createModalDialog("Display colours for expansion",d,[{type:"text",id:"expanded"},{type:"text",id:"collapsed"}],function(){var a=$("#"+d+"expanded").attr("value"),c=$("#"+d+"collapsed").attr("value");b.changeTo({color:{type:"expand",expanded:a, -collapsed:c}})})})},this.addControlOpticLabelAndColour=function(e){var f="control_node_labelandcolour",g=f+"_";uiComponentsHelper.createButton(a,"Configure Label",f,function(){modalDialogHelper.createModalChangeDialog("Change label attribute",g,[{type:"text",id:"label-attribute",text:"Vertex label attribute",value:b.getLabel()||""},{type:"decission",id:"samecolour",group:"colour",text:"Use this attribute for coloring, too",isDefault:b.getLabel()===b.getColor()},{type:"decission",id:"othercolour",group:"colour",text:"Use different attribute for coloring",isDefault:b.getLabel()!==b.getColor(),interior:[{type:"text",id:"colour-attribute",text:"Color attribute",value:b.getColor()||""}]}],function(){var a=$("#"+g+"label-attribute").attr("value"),e=$("#"+g+"colour-attribute").attr("value"),f=$("input[type='radio'][name='colour']:checked").attr("id");f===g+"samecolour"&&(e=a);var h={label:a,color:{type:"attribute",key:e}};d.applyLocalStorage(h),b.changeTo(h),void 0===c&&(c=d.createColourMappingList())})})},this.addControlOpticLabelAndColourList=function(e){var f="control_node_labelandcolourlist",g=f+"_";uiComponentsHelper.createButton(a,"Configure Label",f,function(){modalDialogHelper.createModalChangeDialog("Change label attribute",g,[{type:"extendable",id:"label",text:"Vertex label attribute",objects:b.getLabel()},{type:"decission",id:"samecolour",group:"colour",text:"Use this attribute for coloring, too",isDefault:b.getLabel()===b.getColor()},{type:"decission",id:"othercolour",group:"colour",text:"Use different attribute for coloring",isDefault:b.getLabel()!==b.getColor(),interior:[{type:"extendable",id:"colour",text:"Color attribute",objects:b.getColor()||""}]}],function(){var a=$("input[id^="+g+"label_]"),e=$("input[id^="+g+"colour_]"),f=$("input[type='radio'][name='colour']:checked").attr("id"),h=[],i=[];a.each(function(a,b){var c=$(b).val();""!==c&&h.push(c)}),e.each(function(a,b){var c=$(b).val();""!==c&&i.push(c)}),f===g+"samecolour"&&(i=h);var j={label:h,color:{type:"attribute",key:i}};d.applyLocalStorage(j),b.changeTo(j),void 0===c&&(c=d.createColourMappingList())})})},this.addAllOptics=function(){d.addControlOpticShapeNone(),d.addControlOpticShapeCircle(),d.addControlOpticShapeRect(),d.addControlOpticLabel(),d.addControlOpticSingleColour(),d.addControlOpticAttributeColour(),d.addControlOpticExpandColour()},this.addAllActions=function(){},this.addAll=function(){d.addAllOptics(),d.addAllActions()},this.createColourMappingList=function(){return void 0!==c?c:(c=document.createElement("div"),c.id="node_colour_list",e(b.getColourMapping()),b.setColourMappingListener(e),c)}}function GraphViewer(a,b,c,d,e){"use strict";if($("html").attr("xmlns:xlink","http://www.w3.org/1999/xlink"),void 0===a||void 0===a.append)throw"SVG has to be given and has to be selected using d3.select";if(void 0===b||0>=b)throw"A width greater 0 has to be given";if(void 0===c||0>=c)throw"A height greater 0 has to be given";if(void 0===d||void 0===d.type)throw"An adapter configuration has to be given";var f,g,h,i,j,k,l,m,n=this,o=[],p=[],q=function(a){if(!a)return a={},a.nodes=p,a.links=o,a.width=b,a.height=c,void(i=new ForceLayouter(a));switch(a.type.toLowerCase()){case"force":a.nodes=p,a.links=o,a.width=b,a.height=c,i=new ForceLayouter(a);break;default:throw"Sorry unknown layout type."}},r=function(a){f.setNodeLimit(a,n.start)},s=function(d){d&&(j=new ZoomManager(b,c,a,k,g,h,{},r))},t=function(a){var b=a.edgeShaper||{},c=a.nodeShaper||{},d=c.idfunc||void 0,e=a.zoom||!1;b.shape=b.shape||{type:EdgeShaper.shapes.ARROW},q(a.layouter),m=k.append("g"),h=new EdgeShaper(m,b),l=k.append("g"),g=new NodeShaper(l,c,d),i.setCombinedUpdateFunction(g,h),s(e)};switch(d.type.toLowerCase()){case"arango":d.width=b,d.height=c,f=new ArangoAdapter(p,o,this,d),f.setChildLimit(10);break;case"gharial":d.width=b,d.height=c,f=new GharialAdapter(p,o,this,d),f.setChildLimit(10);break;case"foxx":d.width=b,d.height=c,f=new FoxxAdapter(p,o,d.route,this,d);break;case"json":f=new JSONAdapter(d.path,p,o,this,b,c);break;case"preview":d.width=b,d.height=c,f=new PreviewAdapter(p,o,this,d);break;default:throw"Sorry unknown adapter type."}k=a.append("g"),t(e||{}),this.start=function(a){i.stop(),a&&(""!==$(".infoField").text()?_.each(p,function(a){_.each(f.randomNodes,function(b){a._id===b._id&&(a._expanded=!0)})}):_.each(p,function(a){a._expanded=!0})),g.drawNodes(p),h.drawEdges(o),i.start()},this.loadGraph=function(a,b){f.loadInitialNode(a,function(a){return a.errorCode?void b(a):(a._expanded=!0,n.start(),void(_.isFunction(b)&&b()))})},this.loadGraphWithRandomStart=function(a,b){f.loadRandomNode(function(b){return b.errorCode&&404===b.errorCode?void a(b):(b._expanded=!0,n.start(!0),void(_.isFunction(a)&&a()))},b)},this.loadGraphWithAdditionalNode=function(a,b,c){f.loadAdditionalNodeByAttributeValue(a,b,function(a){return a.errorCode?void c(a):(a._expanded=!0,n.start(),void(_.isFunction(c)&&c()))})},this.loadGraphWithAttributeValue=function(a,b,c){f.randomNodes=[],f.definedNodes=[],f.loadInitialNodeByAttributeValue(a,b,function(a){return a.errorCode?void c(a):(a._expanded=!0,n.start(),void(_.isFunction(c)&&c()))})},this.cleanUp=function(){g.resetColourMap(),h.resetColourMap()},this.changeWidth=function(a){i.changeWidth(a),j.changeWidth(a),f.setWidth(a)},this.dispatcherConfig={expand:{edges:o,nodes:p,startCallback:n.start,adapter:f,reshapeNodes:g.reshapeNodes},drag:{layouter:i},nodeEditor:{nodes:p,adapter:f},edgeEditor:{edges:o,adapter:f}},this.adapter=f,this.nodeShaper=g,this.edgeShaper=h,this.layouter=i,this.zoomManager=j}function Module(a){this.id=a,this.exports={},this.definition=null}function require(a){return global.module.require(a)}function print(){var a=require("internal");a.print.apply(a.print,arguments)}function ArangoConnection(){this._databaseName="_system";var a=global.document.location.pathname;if("/_db/"===a.substr(0,5)){for(var b=5,c=a.length;c>b&&"/"!==a[b];)b++;b>5&&(this._databaseName=a.substring(5,b))}}EdgeShaper.shapes=Object.freeze({NONE:0,ARROW:1}),NodeShaper.shapes=Object.freeze({NONE:0,CIRCLE:1,RECT:2,IMAGE:3});var modalDialogHelper=modalDialogHelper||{};!function(){"use strict";var a,b=function(a){$(document).bind("keypress.key13",function(b){b.which&&13===b.which&&$(a).click()})},c=function(){$(document).unbind("keypress.key13")},d=function(a,b,c,d,e){var f,g,h=function(){e(f)},i=modalDialogHelper.modalDivTemplate(a,b,c,h),j=document.createElement("tr"),k=document.createElement("th"),l=document.createElement("th"),m=document.createElement("th"),n=document.createElement("button"),o=1;f=function(){var a={};return _.each($("#"+c+"table tr:not(#first_row)"),function(b){var c=$(".keyCell input",b).val(),d=$(".valueCell input",b).val();a[c]=d}),a},i.appendChild(j),j.id="first_row",j.appendChild(k),k.className="keyCell",j.appendChild(l),l.className="valueCell",j.appendChild(m),m.className="actionCell",m.appendChild(n),n.id=c+"new",n.className="graphViewer-icon-button gv-icon-small add",g=function(a,b){var d,e,f,g=/^_(id|rev|key|from|to)/,h=document.createElement("tr"),j=document.createElement("th"),k=document.createElement("th"),l=document.createElement("th");g.test(b)||(i.appendChild(h),h.appendChild(k),k.className="keyCell",e=document.createElement("input"),e.type="text",e.id=c+b+"_key",e.value=b,k.appendChild(e),h.appendChild(l),l.className="valueCell",f=document.createElement("input"),f.type="text",f.id=c+b+"_value","object"==typeof a?f.value=JSON.stringify(a):f.value=a,l.appendChild(f),h.appendChild(j),j.className="actionCell",d=document.createElement("button"),d.id=c+b+"_delete",d.className="graphViewer-icon-button gv-icon-small delete",j.appendChild(d),d.onclick=function(){i.removeChild(h)})},n.onclick=function(){g("","new_"+o),o++},_.each(d,g),$("#"+c+"modal").modal("show")},e=function(a,b,c,d,e){var f=modalDialogHelper.modalDivTemplate(a,b,c,e),g=document.createElement("tr"),h=document.createElement("th"),i=document.createElement("pre");f.appendChild(g),g.appendChild(h),h.appendChild(i),i.className="gv-object-view",i.innerHTML=JSON.stringify(d,null,2),$("#"+c+"modal").modal("show")},f=function(a,b){var c=document.createElement("input");return c.type="text",c.id=a,c.value=b,c},g=function(a,b){var c=document.createElement("input");return c.type="checkbox",c.id=a,c.checked=b,c},h=function(a,b,c){var d=document.createElement("select");return d.id=a,_.each(_.sortBy(b,function(a){return a.toLowerCase()}),function(a){var b=document.createElement("option");b.value=a,b.selected=a===c,b.appendChild(document.createTextNode(a)),d.appendChild(b)}),d},i=function(a){var b=$(".decission_"+a),c=$("input[type='radio'][name='"+a+"']:checked").attr("id");b.each(function(){$(this).attr("decider")===c?$(this).css("display",""):$(this).css("display","none")})},j=function(b,c,d,e,f,g,h,j){var k=document.createElement("input"),l=b+c,m=document.createElement("label"),n=document.createElement("tbody");k.id=l,k.type="radio",k.name=d,k.className="gv-radio-button",m.className="radio",h.appendChild(m),m.appendChild(k),m.appendChild(document.createTextNode(e)),j.appendChild(n),$(n).toggleClass("decission_"+d,!0),$(n).attr("decider",l),_.each(g,function(c){a(n,b,c)}),f?k.checked=!0:k.checked=!1,m.onclick=function(a){i(d),a.stopPropagation()},i(d)},k=function(a,b,c,d,e,f){var g,h=[],i=a+b,j=1,k=document.createElement("th"),l=document.createElement("button"),m=document.createElement("input"),n=function(a){j++;var c,d=document.createElement("tr"),g=document.createElement("th"),k=document.createElement("th"),l=document.createElement("th"),m=document.createElement("input"),n=document.createElement("button");m.type="text",m.id=i+"_"+j,m.value=a||"",c=0===h.length?$(f):$(h[h.length-1]),c.after(d),d.appendChild(g),g.className="collectionTh capitalize",g.appendChild(document.createTextNode(b+" "+j+":")),d.appendChild(k),k.className="collectionTh",k.appendChild(m),n.id=i+"_"+j+"_remove",n.className="graphViewer-icon-button gv-icon-small delete",n.onclick=function(){e.removeChild(d),h.splice(h.indexOf(d),1)},l.appendChild(n),d.appendChild(l),h.push(d)};for(m.type="text",m.id=i+"_1",d.appendChild(m),k.appendChild(l),f.appendChild(k),l.onclick=function(){n()},l.id=i+"_addLine",l.className="graphViewer-icon-button gv-icon-small add","string"==typeof c&&c.length>0&&(c=[c]),c.length>0&&(m.value=c[0]),g=1;g'),$(".arangoFrame .outerDiv").click(function(){e.closeDocEditor()}),$(".arangoFrame .innerDiv").click(function(a){a.stopPropagation()}),$(".fa-times").click(function(){e.closeDocEditor()}),$(".arangoFrame").show(),f.customView=!0,f.customDeleteFunction=function(){window.modalView.hide(),$(".arangoFrame").hide()},$(".arangoFrame #deleteDocumentButton").click(function(){f.deleteDocumentModal()}),$(".arangoFrame #saveDocumentButton").click(function(){f.saveDocument()}),$(".arangoFrame #deleteDocumentButton").css("display","none")},closeDocEditor:function(){$(".arangoFrame .outerDiv .fa-times").remove(),$(".arangoFrame").hide()},getRandomToken:function(){return Math.round((new Date).getTime())},isSystemAttribute:function(a){var b=this.systemAttributes();return b[a]},isSystemCollection:function(a){return"_"===a.name.substr(0,1)},setDocumentStore:function(a){this.arangoDocumentStore=a},collectionApiType:function(a,b){return(b||void 0===this.CollectionTypes[a])&&(this.CollectionTypes[a]=this.arangoDocumentStore.getCollectionInfo(a).type),3===this.CollectionTypes[a]?"edge":"document"},collectionType:function(a){if(!a||""===a.name)return"-";var b;return b=2===a.type?"document":3===a.type?"edge":"unknown",this.isSystemCollection(a)&&(b+=" (system)"),b},formatDT:function(a){var b=function(a){return 10>a?"0"+a:a};return a.getUTCFullYear()+"-"+b(a.getUTCMonth()+1)+"-"+b(a.getUTCDate())+" "+b(a.getUTCHours())+":"+b(a.getUTCMinutes())+":"+b(a.getUTCSeconds())},escapeHtml:function(a){return String(a).replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}}}(),function(){"use strict";if(!window.hasOwnProperty("TEST_BUILD")){var a=function(){var a={};return a.createTemplate=function(a){var b=$("#"+a.replace(".","\\.")).html();return{render:function(a){return _.template(b,a)}}},a};window.templateEngine=new a}}(),Module.prototype.moduleCache={},Module.prototype.moduleCache["/internal"]=new Module("/internal"),"undefined"==typeof global&&"undefined"!=typeof window&&(global=window),global.module=Module.prototype.moduleCache["/"]=new Module("/"),Module.prototype.normalise=function(a){var b,c,d,e,f;if(""===a)return this.id;for(d=a.split("/"),"."===d[0]||".."===d[0]?(e=this.id.split("/"),e.pop(),e=e.concat(d)):e=d,c=[],b=0;b "+require("internal").browserOutputBuffer,"jssuccess"),require("internal").browserOutputBuffer=""},$(global.document).ajaxSend(function(a,b,c){c.url=require("internal").arango.databasePrefix(c.url)}),global.DEFINE_MODULE=function(a,b){var c=Module.prototype.normalise(a),d=Module.prototype.moduleCache[c];d?Object.keys(d.exports).forEach(function(a){b[a]=d.exports[a]}):(d=new Module(c),Module.prototype.moduleCache[c]=d),d.exports=b}}(),module.define("underscore",function(a,b){(function(){function c(a){function b(b,c,d,e,f,g){for(;f>=0&&g>f;f+=a){var h=e?e[f]:f;d=c(d,b[h],h,b)}return d}return function(c,d,e,f){d=v(d,f,4);var g=!C(c)&&u.keys(c),h=(g||c).length,i=a>0?0:h-1;return arguments.length<3&&(e=c[g?g[i]:i],i+=a),b(c,d,e,g,i,h)}}function d(a){return function(b,c,d){c=w(c,d);for(var e=B(b),f=a>0?0:e-1;f>=0&&e>f;f+=a)if(c(b[f],f,b))return f;return-1}}function e(a,b,c){return function(d,e,f){var g=0,h=B(d);if("number"==typeof f)a>0?g=f>=0?f:Math.max(f+h,g):h=f>=0?Math.min(f+1,h):f+h+1;else if(c&&f&&h)return f=c(d,e),d[f]===e?f:-1;if(e!==e)return f=b(m.call(d,g,h),u.isNaN),f>=0?f+g:-1;for(f=a>0?g:h-1;f>=0&&h>f;f+=a)if(d[f]===e)return f;return-1}}function f(a,b){var c=H.length,d=a.constructor,e=u.isFunction(d)&&d.prototype||j,f="constructor";for(u.has(a,f)&&!u.contains(b,f)&&b.push(f);c--;)f=H[c],f in a&&a[f]!==e[f]&&!u.contains(b,f)&&b.push(f)}var g=this,h=g._,i=Array.prototype,j=Object.prototype,k=Function.prototype,l=i.push,m=i.slice,n=j.toString,o=j.hasOwnProperty,p=Array.isArray,q=Object.keys,r=k.bind,s=Object.create,t=function(){},u=function(a){return a instanceof u?a:this instanceof u?void(this._wrapped=a):new u(a)};"undefined"!=typeof a?("undefined"!=typeof b&&b.exports&&(a=b.exports=u),a._=u):g._=u,u.VERSION="1.8.3";var v=function(a,b,c){if(void 0===b)return a;switch(null==c?3:c){case 1:return function(c){return a.call(b,c)};case 2:return function(c,d){return a.call(b,c,d)};case 3:return function(c,d,e){return a.call(b,c,d,e)};case 4:return function(c,d,e,f){return a.call(b,c,d,e,f)}}return function(){return a.apply(b,arguments)}},w=function(a,b,c){return null==a?u.identity:u.isFunction(a)?v(a,b,c):u.isObject(a)?u.matcher(a):u.property(a)};u.iteratee=function(a,b){return w(a,b,1/0)};var x=function(a,b){return function(c){var d=arguments.length;if(2>d||null==c)return c;for(var e=1;d>e;e++)for(var f=arguments[e],g=a(f),h=g.length,i=0;h>i;i++){var j=g[i];b&&void 0!==c[j]||(c[j]=f[j])}return c}},y=function(a){if(!u.isObject(a))return{};if(s)return s(a);t.prototype=a;var b=new t;return t.prototype=null,b},z=function(a){return function(b){return null==b?void 0:b[a]}},A=Math.pow(2,53)-1,B=z("length"),C=function(a){var b=B(a);return"number"==typeof b&&b>=0&&A>=b};u.each=u.forEach=function(a,b,c){b=v(b,c);var d,e;if(C(a))for(d=0,e=a.length;e>d;d++)b(a[d],d,a);else{var f=u.keys(a);for(d=0,e=f.length;e>d;d++)b(a[f[d]],f[d],a)}return a},u.map=u.collect=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=Array(e),g=0;e>g;g++){var h=d?d[g]:g;f[g]=b(a[h],h,a)}return f},u.reduce=u.foldl=u.inject=c(1),u.reduceRight=u.foldr=c(-1),u.find=u.detect=function(a,b,c){var d;return d=C(a)?u.findIndex(a,b,c):u.findKey(a,b,c),void 0!==d&&-1!==d?a[d]:void 0},u.filter=u.select=function(a,b,c){var d=[];return b=w(b,c),u.each(a,function(a,c,e){b(a,c,e)&&d.push(a)}),d},u.reject=function(a,b,c){return u.filter(a,u.negate(w(b)),c)},u.every=u.all=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=0;e>f;f++){var g=d?d[f]:f;if(!b(a[g],g,a))return!1}return!0},u.some=u.any=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=0;e>f;f++){var g=d?d[f]:f;if(b(a[g],g,a))return!0}return!1},u.contains=u.includes=u.include=function(a,b,c,d){return C(a)||(a=u.values(a)),("number"!=typeof c||d)&&(c=0),u.indexOf(a,b,c)>=0},u.invoke=function(a,b){var c=m.call(arguments,2),d=u.isFunction(b);return u.map(a,function(a){var e=d?b:a[b];return null==e?e:e.apply(a,c)})},u.pluck=function(a,b){return u.map(a,u.property(b))},u.where=function(a,b){return u.filter(a,u.matcher(b))},u.findWhere=function(a,b){return u.find(a,u.matcher(b))},u.max=function(a,b,c){var d,e,f=-(1/0),g=-(1/0);if(null==b&&null!=a){a=C(a)?a:u.values(a);for(var h=0,i=a.length;i>h;h++)d=a[h],d>f&&(f=d)}else b=w(b,c),u.each(a,function(a,c,d){e=b(a,c,d),(e>g||e===-(1/0)&&f===-(1/0))&&(f=a,g=e)});return f},u.min=function(a,b,c){var d,e,f=1/0,g=1/0;if(null==b&&null!=a){a=C(a)?a:u.values(a);for(var h=0,i=a.length;i>h;h++)d=a[h],f>d&&(f=d)}else b=w(b,c),u.each(a,function(a,c,d){e=b(a,c,d),(g>e||e===1/0&&f===1/0)&&(f=a,g=e)});return f},u.shuffle=function(a){for(var b,c=C(a)?a:u.values(a),d=c.length,e=Array(d),f=0;d>f;f++)b=u.random(0,f),b!==f&&(e[f]=e[b]),e[b]=c[f];return e},u.sample=function(a,b,c){return null==b||c?(C(a)||(a=u.values(a)),a[u.random(a.length-1)]):u.shuffle(a).slice(0,Math.max(0,b))},u.sortBy=function(a,b,c){return b=w(b,c),u.pluck(u.map(a,function(a,c,d){return{value:a,index:c,criteria:b(a,c,d)}}).sort(function(a,b){var c=a.criteria,d=b.criteria;if(c!==d){if(c>d||void 0===c)return 1;if(d>c||void 0===d)return-1}return a.index-b.index}),"value")};var D=function(a){return function(b,c,d){var e={};return c=w(c,d),u.each(b,function(d,f){var g=c(d,f,b);a(e,d,g)}),e}};u.groupBy=D(function(a,b,c){u.has(a,c)?a[c].push(b):a[c]=[b]}),u.indexBy=D(function(a,b,c){a[c]=b}),u.countBy=D(function(a,b,c){u.has(a,c)?a[c]++:a[c]=1}),u.toArray=function(a){return a?u.isArray(a)?m.call(a):C(a)?u.map(a,u.identity):u.values(a):[]},u.size=function(a){return null==a?0:C(a)?a.length:u.keys(a).length},u.partition=function(a,b,c){b=w(b,c);var d=[],e=[];return u.each(a,function(a,c,f){(b(a,c,f)?d:e).push(a)}),[d,e]},u.first=u.head=u.take=function(a,b,c){return null==a?void 0:null==b||c?a[0]:u.initial(a,a.length-b)},u.initial=function(a,b,c){return m.call(a,0,Math.max(0,a.length-(null==b||c?1:b)))},u.last=function(a,b,c){return null==a?void 0:null==b||c?a[a.length-1]:u.rest(a,Math.max(0,a.length-b))},u.rest=u.tail=u.drop=function(a,b,c){return m.call(a,null==b||c?1:b)},u.compact=function(a){return u.filter(a,u.identity)};var E=function(a,b,c,d){for(var e=[],f=0,g=d||0,h=B(a);h>g;g++){var i=a[g];if(C(i)&&(u.isArray(i)||u.isArguments(i))){b||(i=E(i,b,c));var j=0,k=i.length;for(e.length+=k;k>j;)e[f++]=i[j++]}else c||(e[f++]=i)}return e};u.flatten=function(a,b){return E(a,b,!1)},u.without=function(a){return u.difference(a,m.call(arguments,1))},u.uniq=u.unique=function(a,b,c,d){u.isBoolean(b)||(d=c,c=b,b=!1),null!=c&&(c=w(c,d));for(var e=[],f=[],g=0,h=B(a);h>g;g++){var i=a[g],j=c?c(i,g,a):i;b?(g&&f===j||e.push(i),f=j):c?u.contains(f,j)||(f.push(j),e.push(i)):u.contains(e,i)||e.push(i)}return e},u.union=function(){return u.uniq(E(arguments,!0,!0))},u.intersection=function(a){for(var b=[],c=arguments.length,d=0,e=B(a);e>d;d++){var f=a[d];if(!u.contains(b,f)){for(var g=1;c>g&&u.contains(arguments[g],f);g++);g===c&&b.push(f)}}return b},u.difference=function(a){var b=E(arguments,!0,!0,1);return u.filter(a,function(a){return!u.contains(b,a)})},u.zip=function(){return u.unzip(arguments)},u.unzip=function(a){for(var b=a&&u.max(a,B).length||0,c=Array(b),d=0;b>d;d++)c[d]=u.pluck(a,d);return c},u.object=function(a,b){for(var c={},d=0,e=B(a);e>d;d++)b?c[a[d]]=b[d]:c[a[d][0]]=a[d][1];return c},u.findIndex=d(1),u.findLastIndex=d(-1),u.sortedIndex=function(a,b,c,d){ -c=w(c,d,1);for(var e=c(b),f=0,g=B(a);g>f;){var h=Math.floor((f+g)/2);c(a[h])f;f++,a+=c)e[f]=a;return e};var F=function(a,b,c,d,e){if(!(d instanceof b))return a.apply(c,e);var f=y(a.prototype),g=a.apply(f,e);return u.isObject(g)?g:f};u.bind=function(a,b){if(r&&a.bind===r)return r.apply(a,m.call(arguments,1));if(!u.isFunction(a))throw new TypeError("Bind must be called on a function");var c=m.call(arguments,2),d=function(){return F(a,d,b,this,c.concat(m.call(arguments)))};return d},u.partial=function(a){var b=m.call(arguments,1),c=function(){for(var d=0,e=b.length,f=Array(e),g=0;e>g;g++)f[g]=b[g]===u?arguments[d++]:b[g];for(;d=d)throw new Error("bindAll must be passed function names");for(b=1;d>b;b++)c=arguments[b],a[c]=u.bind(a[c],a);return a},u.memoize=function(a,b){var c=function(d){var e=c.cache,f=""+(b?b.apply(this,arguments):d);return u.has(e,f)||(e[f]=a.apply(this,arguments)),e[f]};return c.cache={},c},u.delay=function(a,b){var c=m.call(arguments,2);return setTimeout(function(){return a.apply(null,c)},b)},u.defer=u.partial(u.delay,u,1),u.throttle=function(a,b,c){var d,e,f,g=null,h=0;c||(c={});var i=function(){h=c.leading===!1?0:u.now(),g=null,f=a.apply(d,e),g||(d=e=null)};return function(){var j=u.now();h||c.leading!==!1||(h=j);var k=b-(j-h);return d=this,e=arguments,0>=k||k>b?(g&&(clearTimeout(g),g=null),h=j,f=a.apply(d,e),g||(d=e=null)):g||c.trailing===!1||(g=setTimeout(i,k)),f}},u.debounce=function(a,b,c){var d,e,f,g,h,i=function(){var j=u.now()-g;b>j&&j>=0?d=setTimeout(i,b-j):(d=null,c||(h=a.apply(f,e),d||(f=e=null)))};return function(){f=this,e=arguments,g=u.now();var j=c&&!d;return d||(d=setTimeout(i,b)),j&&(h=a.apply(f,e),f=e=null),h}},u.wrap=function(a,b){return u.partial(b,a)},u.negate=function(a){return function(){return!a.apply(this,arguments)}},u.compose=function(){var a=arguments,b=a.length-1;return function(){for(var c=b,d=a[b].apply(this,arguments);c--;)d=a[c].call(this,d);return d}},u.after=function(a,b){return function(){return--a<1?b.apply(this,arguments):void 0}},u.before=function(a,b){var c;return function(){return--a>0&&(c=b.apply(this,arguments)),1>=a&&(b=null),c}},u.once=u.partial(u.before,2);var G=!{toString:null}.propertyIsEnumerable("toString"),H=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"];u.keys=function(a){if(!u.isObject(a))return[];if(q)return q(a);var b=[];for(var c in a)u.has(a,c)&&b.push(c);return G&&f(a,b),b},u.allKeys=function(a){if(!u.isObject(a))return[];var b=[];for(var c in a)b.push(c);return G&&f(a,b),b},u.values=function(a){for(var b=u.keys(a),c=b.length,d=Array(c),e=0;c>e;e++)d[e]=a[b[e]];return d},u.mapObject=function(a,b,c){b=w(b,c);for(var d,e=u.keys(a),f=e.length,g={},h=0;f>h;h++)d=e[h],g[d]=b(a[d],d,a);return g},u.pairs=function(a){for(var b=u.keys(a),c=b.length,d=Array(c),e=0;c>e;e++)d[e]=[b[e],a[b[e]]];return d},u.invert=function(a){for(var b={},c=u.keys(a),d=0,e=c.length;e>d;d++)b[a[c[d]]]=c[d];return b},u.functions=u.methods=function(a){var b=[];for(var c in a)u.isFunction(a[c])&&b.push(c);return b.sort()},u.extend=x(u.allKeys),u.extendOwn=u.assign=x(u.keys),u.findKey=function(a,b,c){b=w(b,c);for(var d,e=u.keys(a),f=0,g=e.length;g>f;f++)if(d=e[f],b(a[d],d,a))return d},u.pick=function(a,b,c){var d,e,f={},g=a;if(null==g)return f;u.isFunction(b)?(e=u.allKeys(g),d=v(b,c)):(e=E(arguments,!1,!1,1),d=function(a,b,c){return b in c},g=Object(g));for(var h=0,i=e.length;i>h;h++){var j=e[h],k=g[j];d(k,j,g)&&(f[j]=k)}return f},u.omit=function(a,b,c){if(u.isFunction(b))b=u.negate(b);else{var d=u.map(E(arguments,!1,!1,1),String);b=function(a,b){return!u.contains(d,b)}}return u.pick(a,b,c)},u.defaults=x(u.allKeys,!0),u.create=function(a,b){var c=y(a);return b&&u.extendOwn(c,b),c},u.clone=function(a){return u.isObject(a)?u.isArray(a)?a.slice():u.extend({},a):a},u.tap=function(a,b){return b(a),a},u.isMatch=function(a,b){var c=u.keys(b),d=c.length;if(null==a)return!d;for(var e=Object(a),f=0;d>f;f++){var g=c[f];if(b[g]!==e[g]||!(g in e))return!1}return!0};var I=function(a,b,c,d){if(a===b)return 0!==a||1/a===1/b;if(null==a||null==b)return a===b;a instanceof u&&(a=a._wrapped),b instanceof u&&(b=b._wrapped);var e=n.call(a);if(e!==n.call(b))return!1;switch(e){case"[object RegExp]":case"[object String]":return""+a==""+b;case"[object Number]":return+a!==+a?+b!==+b:0===+a?1/+a===1/b:+a===+b;case"[object Date]":case"[object Boolean]":return+a===+b}var f="[object Array]"===e;if(!f){if("object"!=typeof a||"object"!=typeof b)return!1;var g=a.constructor,h=b.constructor;if(g!==h&&!(u.isFunction(g)&&g instanceof g&&u.isFunction(h)&&h instanceof h)&&"constructor"in a&&"constructor"in b)return!1}c=c||[],d=d||[];for(var i=c.length;i--;)if(c[i]===a)return d[i]===b;if(c.push(a),d.push(b),f){if(i=a.length,i!==b.length)return!1;for(;i--;)if(!I(a[i],b[i],c,d))return!1}else{var j,k=u.keys(a);if(i=k.length,u.keys(b).length!==i)return!1;for(;i--;)if(j=k[i],!u.has(b,j)||!I(a[j],b[j],c,d))return!1}return c.pop(),d.pop(),!0};u.isEqual=function(a,b){return I(a,b)},u.isEmpty=function(a){return null==a?!0:C(a)&&(u.isArray(a)||u.isString(a)||u.isArguments(a))?0===a.length:0===u.keys(a).length},u.isElement=function(a){return!(!a||1!==a.nodeType)},u.isArray=p||function(a){return"[object Array]"===n.call(a)},u.isObject=function(a){var b=typeof a;return"function"===b||"object"===b&&!!a},u.each(["Arguments","Function","String","Number","Date","RegExp","Error"],function(a){u["is"+a]=function(b){return n.call(b)==="[object "+a+"]"}}),u.isArguments(arguments)||(u.isArguments=function(a){return u.has(a,"callee")}),"function"!=typeof/./&&"object"!=typeof Int8Array&&(u.isFunction=function(a){return"function"==typeof a||!1}),u.isFinite=function(a){return isFinite(a)&&!isNaN(parseFloat(a))},u.isNaN=function(a){return u.isNumber(a)&&a!==+a},u.isBoolean=function(a){return a===!0||a===!1||"[object Boolean]"===n.call(a)},u.isNull=function(a){return null===a},u.isUndefined=function(a){return void 0===a},u.has=function(a,b){return null!=a&&o.call(a,b)},u.noConflict=function(){return g._=h,this},u.identity=function(a){return a},u.constant=function(a){return function(){return a}},u.noop=function(){},u.property=z,u.propertyOf=function(a){return null==a?function(){}:function(b){return a[b]}},u.matcher=u.matches=function(a){return a=u.extendOwn({},a),function(b){return u.isMatch(b,a)}},u.times=function(a,b,c){var d=Array(Math.max(0,a));b=v(b,c,1);for(var e=0;a>e;e++)d[e]=b(e);return d},u.random=function(a,b){return null==b&&(b=a,a=0),a+Math.floor(Math.random()*(b-a+1))},u.now=Date.now||function(){return(new Date).getTime()};var J={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},K=u.invert(J),L=function(a){var b=function(b){return a[b]},c="(?:"+u.keys(a).join("|")+")",d=RegExp(c),e=RegExp(c,"g");return function(a){return a=null==a?"":""+a,d.test(a)?a.replace(e,b):a}};u.escape=L(J),u.unescape=L(K),u.result=function(a,b,c){var d=null==a?void 0:a[b];return void 0===d&&(d=c),u.isFunction(d)?d.call(a):d};var M=0;u.uniqueId=function(a){var b=++M+"";return a?a+b:b},u.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var N=/(.)^/,O={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},P=/\\|'|\r|\n|\u2028|\u2029/g,Q=function(a){return"\\"+O[a]};u.template=function(a,b,c){!b&&c&&(b=c),b=u.defaults({},b,u.templateSettings);var d=RegExp([(b.escape||N).source,(b.interpolate||N).source,(b.evaluate||N).source].join("|")+"|$","g"),e=0,f="__p+='";a.replace(d,function(b,c,d,g,h){return f+=a.slice(e,h).replace(P,Q),e=h+b.length,c?f+="'+\n((__t=("+c+"))==null?'':_.escape(__t))+\n'":d?f+="'+\n((__t=("+d+"))==null?'':__t)+\n'":g&&(f+="';\n"+g+"\n__p+='"),b}),f+="';\n",b.variable||(f="with(obj||{}){\n"+f+"}\n"),f="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+f+"return __p;\n";try{var g=new Function(b.variable||"obj","_",f)}catch(h){throw h.source=f,h}var i=function(a){return g.call(this,a,u)},j=b.variable||"obj";return i.source="function("+j+"){\n"+f+"}",i},u.chain=function(a){var b=u(a);return b._chain=!0,b};var R=function(a,b){return a._chain?u(b).chain():b};u.mixin=function(a){u.each(u.functions(a),function(b){var c=u[b]=a[b];u.prototype[b]=function(){var a=[this._wrapped];return l.apply(a,arguments),R(this,c.apply(u,a))}})},u.mixin(u),u.each(["pop","push","reverse","shift","sort","splice","unshift"],function(a){var b=i[a];u.prototype[a]=function(){var c=this._wrapped;return b.apply(c,arguments),"shift"!==a&&"splice"!==a||0!==c.length||delete c[0],R(this,c)}}),u.each(["concat","join","slice"],function(a){var b=i[a];u.prototype[a]=function(){return R(this,b.apply(this._wrapped,arguments))}}),u.prototype.value=function(){return this._wrapped},u.prototype.valueOf=u.prototype.toJSON=u.prototype.value,u.prototype.toString=function(){return""+this._wrapped},"function"==typeof define&&define.amd&&define("underscore",[],function(){return u})}).call(this)}),global.DEFINE_MODULE("internal",function(){"use strict";function a(a){if(i.hasOwnProperty(a))return i[a];var b,c=a.charCodeAt(0);return b=16>c?"\\u000":256>c?"\\u00":4096>c?"\\u0":"\\u",b+=c.toString(16),i[a]=b,b}function b(b){return'"'+b.replace(n,a)+'"'}function c(a){var b,c="";if(a.prettyPrint)for(c+="\n",b=0;b=b.emit&&(h.output(b.output),b.output=""),b.path=i,f=", "}b.level=e-1,b.output+=" ",c(b),d&&(b.output+=j.COLOR_PUNCTUATION),b.output+="]",d&&(b.output+=j.COLOR_RESET)}}function e(a,d){var e=d.useColor,f=" ";e&&(d.output+=j.COLOR_PUNCTUATION),d.output+="{",e&&(d.output+=j.COLOR_RESET);var g=d.level+1;d.level=g;var i;try{i=Object.keys(a)}catch(k){i=[]}for(var l=0,n=i.length;n>l;++l){var o=i[l],p=a[o];e&&(d.output+=j.COLOR_PUNCTUATION),d.output+=f,e&&(d.output+=j.COLOR_RESET),c(d),e&&(d.output+=j.COLOR_INDEX),d.output+=b(o),e&&(d.output+=j.COLOR_RESET),d.output+=" : ";var q=d.path;d.path+="["+o+"]",m(p,d),d.path=q,f=", ",d.emit&&d.output.length>=d.emit&&(h.output(d.output),d.output="")}d.level=g-1,d.output+=" ",c(d),e&&(d.output+=j.COLOR_PUNCTUATION),d.output+="}",e&&(d.output+=j.COLOR_RESET)}function f(){for(var a=0;a0&&a(" "),"string"==typeof arguments[b])a(arguments[b]);else{var c={customInspect:!0,emit:16384,level:0,limitString:g.limitString,names:[],output:"",path:"~",prettyPrint:l,seen:[],showFunction:!1,useColor:k,useToString:!0};m(arguments[b],c),a(c.output)}a("\n")}var h={};global.ArangoError?(h.ArangoError=global.ArangoError,delete global.ArangoError):(h.ArangoError=function(a){void 0!==a&&(this.error=a.error,this.code=a.code,this.errorNum=a.errorNum,this.errorMessage=a.errorMessage),this.message=this.toString()},h.ArangoError.prototype=new Error),h.ArangoError.prototype._PRINT=function(a){a.output+=this.toString()},h.ArangoError.prototype.toString=function(){var a=this.errorNum,b=this.errorMessage||this.message;return"[ArangoError "+a+": "+b+"]"},h.threadNumber=0,global.THREAD_NUMBER&&(h.threadNumber=global.THREAD_NUMBER,delete global.THREAD_NUMBER),h.developmentMode=!1,h.quiet=!1,global.ARANGO_QUIET&&(h.quiet=global.ARANGO_QUIET,delete global.ARANGO_QUIET),h.valgrind=!1,global.VALGRIND&&(h.valgrind=global.VALGRIND,delete global.VALGRIND),h.coverage=!1,global.COVERAGE&&(h.coverage=global.COVERAGE,delete global.COVERAGE),h.version="unknown",global.VERSION&&(h.version=global.VERSION,delete global.VERSION),h.platform="unknown",global.SYS_PLATFORM&&(h.platform=global.SYS_PLATFORM,delete global.SYS_PLATFORM),h.bytesSentDistribution=[],global.BYTES_SENT_DISTRIBUTION&&(h.bytesSentDistribution=global.BYTES_SENT_DISTRIBUTION,delete global.BYTES_SENT_DISTRIBUTION),h.bytesReceivedDistribution=[],global.BYTES_RECEIVED_DISTRIBUTION&&(h.bytesReceivedDistribution=global.BYTES_RECEIVED_DISTRIBUTION,delete global.BYTES_RECEIVED_DISTRIBUTION),h.connectionTimeDistribution=[],global.CONNECTION_TIME_DISTRIBUTION&&(h.connectionTimeDistribution=global.CONNECTION_TIME_DISTRIBUTION,delete global.CONNECTION_TIME_DISTRIBUTION),h.requestTimeDistribution=[],global.REQUEST_TIME_DISTRIBUTION&&(h.requestTimeDistribution=global.REQUEST_TIME_DISTRIBUTION,delete global.REQUEST_TIME_DISTRIBUTION),h.startupPath="",global.STARTUP_PATH&&(h.startupPath=global.STARTUP_PATH,delete global.STARTUP_PATH),""===h.startupPath&&(h.startupPath="."),global.CONFIGURE_ENDPOINT&&(h.configureEndpoint=global.CONFIGURE_ENDPOINT,delete global.CONFIGURE_ENDPOINT),global.REMOVE_ENDPOINT&&(h.removeEndpoint=global.REMOVE_ENDPOINT,delete global.REMOVE_ENDPOINT),global.LIST_ENDPOINTS&&(h.listEndpoints=global.LIST_ENDPOINTS,delete global.LIST_ENDPOINTS),global.SYS_BASE64DECODE&&(h.base64Decode=global.SYS_BASE64DECODE,delete global.SYS_BASE64DECODE),global.SYS_BASE64ENCODE&&(h.base64Encode=global.SYS_BASE64ENCODE,delete global.SYS_BASE64ENCODE),global.SYS_DEBUG_SEGFAULT&&(h.debugSegfault=global.SYS_DEBUG_SEGFAULT,delete global.SYS_DEBUG_SEGFAULT),global.SYS_DEBUG_SET_FAILAT&&(h.debugSetFailAt=global.SYS_DEBUG_SET_FAILAT,delete global.SYS_DEBUG_SET_FAILAT),global.SYS_DEBUG_REMOVE_FAILAT&&(h.debugRemoveFailAt=global.SYS_DEBUG_REMOVE_FAILAT,delete global.SYS_DEBUG_REMOVE_FAILAT),global.SYS_DEBUG_CLEAR_FAILAT&&(h.debugClearFailAt=global.SYS_DEBUG_CLEAR_FAILAT,delete global.SYS_DEBUG_CLEAR_FAILAT),global.SYS_DEBUG_CAN_USE_FAILAT&&(h.debugCanUseFailAt=global.SYS_DEBUG_CAN_USE_FAILAT,delete global.SYS_DEBUG_CAN_USE_FAILAT),global.SYS_DOWNLOAD&&(h.download=global.SYS_DOWNLOAD,delete global.SYS_DOWNLOAD),global.SYS_EXECUTE&&(h.executeScript=global.SYS_EXECUTE,delete global.SYS_EXECUTE),global.SYS_GET_CURRENT_REQUEST&&(h.getCurrentRequest=global.SYS_GET_CURRENT_REQUEST,delete global.SYS_GET_CURRENT_REQUEST),global.SYS_GET_CURRENT_RESPONSE&&(h.getCurrentResponse=global.SYS_GET_CURRENT_RESPONSE,delete global.SYS_GET_CURRENT_RESPONSE),h.extend=function(a,b){return Object.getOwnPropertyNames(b).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))}),a},global.SYS_LOAD&&(h.load=global.SYS_LOAD,delete global.SYS_LOAD),global.SYS_LOG_LEVEL&&(h.logLevel=global.SYS_LOG_LEVEL,delete global.SYS_LOG_LEVEL),global.SYS_MD5&&(h.md5=global.SYS_MD5,delete global.SYS_MD5),global.SYS_GEN_RANDOM_NUMBERS&&(h.genRandomNumbers=global.SYS_GEN_RANDOM_NUMBERS,delete global.SYS_GEN_RANDOM_NUMBERS),global.SYS_GEN_RANDOM_ALPHA_NUMBERS&&(h.genRandomAlphaNumbers=global.SYS_GEN_RANDOM_ALPHA_NUMBERS,delete global.SYS_GEN_RANDOM_ALPHA_NUMBERS),global.SYS_GEN_RANDOM_SALT&&(h.genRandomSalt=global.SYS_GEN_RANDOM_SALT,delete global.SYS_GEN_RANDOM_SALT),global.SYS_HMAC&&(h.hmac=global.SYS_HMAC,delete global.SYS_HMAC),global.SYS_PBKDF2&&(h.pbkdf2=global.SYS_PBKDF2,delete global.SYS_PBKDF2),global.SYS_CREATE_NONCE&&(h.createNonce=global.SYS_CREATE_NONCE,delete global.SYS_CREATE_NONCE),global.SYS_CHECK_AND_MARK_NONCE&&(h.checkAndMarkNonce=global.SYS_CHECK_AND_MARK_NONCE,delete global.SYS_CHECK_AND_MARK_NONCE),global.SYS_OUTPUT&&(h.stdOutput=global.SYS_OUTPUT,h.output=h.stdOutput,delete global.SYS_OUTPUT),global.SYS_PARSE&&(h.parse=global.SYS_PARSE,delete global.SYS_PARSE),global.SYS_PARSE_FILE&&(h.parseFile=global.SYS_PARSE_FILE,delete global.SYS_PARSE_FILE),global.SYS_PROCESS_STATISTICS&&(h.processStatistics=global.SYS_PROCESS_STATISTICS,delete global.SYS_PROCESS_STATISTICS),global.SYS_RAND&&(h.rand=global.SYS_RAND,delete global.SYS_RAND),global.SYS_SHA512&&(h.sha512=global.SYS_SHA512,delete global.SYS_SHA512),global.SYS_SHA384&&(h.sha384=global.SYS_SHA384,delete global.SYS_SHA384),global.SYS_SHA256&&(h.sha256=global.SYS_SHA256,delete global.SYS_SHA256),global.SYS_SHA224&&(h.sha224=global.SYS_SHA224,delete global.SYS_SHA224),global.SYS_SHA1&&(h.sha1=global.SYS_SHA1,delete global.SYS_SHA1),global.SYS_SERVER_STATISTICS&&(h.serverStatistics=global.SYS_SERVER_STATISTICS,delete global.SYS_SERVER_STATISTICS),global.SYS_SLEEP&&(h.sleep=global.SYS_SLEEP,delete global.SYS_SLEEP),global.SYS_TIME&&(h.time=global.SYS_TIME,delete global.SYS_TIME),global.SYS_WAIT&&(h.wait=global.SYS_WAIT,delete global.SYS_WAIT),global.SYS_IMPORT_CSV_FILE&&(h.importCsvFile=global.SYS_IMPORT_CSV_FILE,delete global.SYS_IMPORT_CSV_FILE),global.SYS_IMPORT_JSON_FILE&&(h.importJsonFile=global.SYS_IMPORT_JSON_FILE,delete global.SYS_IMPORT_JSON_FILE),global.SYS_PROCESS_CSV_FILE&&(h.processCsvFile=global.SYS_PROCESS_CSV_FILE,delete global.SYS_PROCESS_CSV_FILE),global.SYS_PROCESS_JSON_FILE&&(h.processJsonFile=global.SYS_PROCESS_JSON_FILE,delete global.SYS_PROCESS_JSON_FILE),global.SYS_CLIENT_STATISTICS&&(h.clientStatistics=global.SYS_CLIENT_STATISTICS,delete global.SYS_CLIENT_STATISTICS),global.SYS_HTTP_STATISTICS&&(h.httpStatistics=global.SYS_HTTP_STATISTICS,delete global.SYS_HTTP_STATISTICS),global.SYS_EXECUTE_EXTERNAL&&(h.executeExternal=global.SYS_EXECUTE_EXTERNAL,delete global.SYS_EXECUTE_EXTERNAL),global.SYS_EXECUTE_EXTERNAL_AND_WAIT&&(h.executeExternalAndWait=global.SYS_EXECUTE_EXTERNAL_AND_WAIT,delete global.SYS_EXECUTE_EXTERNAL_AND_WAIT),global.SYS_KILL_EXTERNAL&&(h.killExternal=global.SYS_KILL_EXTERNAL,delete global.SYS_KILL_EXTERNAL),global.SYS_STATUS_EXTERNAL&&(h.statusExternal=global.SYS_STATUS_EXTERNAL,delete global.SYS_STATUS_EXTERNAL),global.SYS_REGISTER_TASK&&(h.registerTask=global.SYS_REGISTER_TASK,delete global.SYS_REGISTER_TASK),global.SYS_UNREGISTER_TASK&&(h.unregisterTask=global.SYS_UNREGISTER_TASK,delete global.SYS_UNREGISTER_TASK),global.SYS_GET_TASK&&(h.getTask=global.SYS_GET_TASK,delete global.SYS_GET_TASK),global.SYS_TEST_PORT&&(h.testPort=global.SYS_TEST_PORT,delete global.SYS_TEST_PORT),global.SYS_IS_IP&&(h.isIP=global.SYS_IS_IP,delete global.SYS_IS_IP),h.unitTests=function(){return global.SYS_UNIT_TESTS},h.setUnitTestsResult=function(a){global.SYS_UNIT_TESTS_RESULT=a},h.toArgv=function(a,b){"undefined"==typeof b&&(b=!1);var c=[];for(var d in a)if(a.hasOwnProperty(d))if("commandSwitches"===d){for(var e="",f=0;f1?c.push(a[d][f]):e+=a[d][f];e.length>0&&c.push(e)}else"flatCommands"===d?c=c.concat(a[d]):b?c.push("--"+d+"="+a[d]):(c.push("--"+d),a[d]!==!1?a[d]!==!0?c.push(a[d]):c.push("true"):c.push("false"));return c},h.parseArgv=function(a,b){function c(b,d,e){if(d.indexOf(":")>0){var f=d.indexOf(":"),h=d.slice(0,f);b.hasOwnProperty(h)||(b[h]={}),c(b[h],d.slice(f+1,d.length),e)}else"true"===a[g+1]?b[d]=!0:"false"===a[g+1]?b[d]=!1:isNaN(a[g+1])?b[d]=a[g+1]:b[d]=parseInt(a[g+1])}function d(a,b){a.hasOwnProperty("commandSwitches")||(a.commandSwitches=[]),a.commandSwitches.push(b)}function e(a,b){for(var c=0;c2&&"--"===j.slice(0,2)){var k=j.slice(2,j.length);a.length>g&&"-"!==a[g+1].slice(0,1)?(c(i,k,a[g+1]),g++):d(i,k)}else"--"===j?h=!0:j.length>1&&"-"===j.slice(0,1)?e(i,j.slice(1,j.length)):f(i,j)}return i},h.COLORS={},global.COLORS?(h.COLORS=global.COLORS,delete global.COLORS):["COLOR_RED","COLOR_BOLD_RED","COLOR_GREEN","COLOR_BOLD_GREEN","COLOR_BLUE","COLOR_BOLD_BLUE","COLOR_YELLOW","COLOR_BOLD_YELLOW","COLOR_WHITE","COLOR_BOLD_WHITE","COLOR_CYAN","COLOR_BOLD_CYAN","COLOR_MAGENTA","COLOR_BOLD_MAGENTA","COLOR_BLACK","COLOR_BOLD_BLACK","COLOR_BLINK","COLOR_BRIGHT","COLOR_RESET"].forEach(function(a){h.COLORS[a]=""}),h.COLORS.COLOR_PUNCTUATION=h.COLORS.COLOR_RESET,h.COLORS.COLOR_STRING=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_NUMBER=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_INDEX=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_TRUE=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_FALSE=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_NULL=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_UNDEFINED=h.COLORS.COLOR_BRIGHT;var i={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},j=h.COLORS,k=!1;global.COLOR_OUTPUT&&(k=global.COLOR_OUTPUT,delete global.COLOR_OUTPUT);var l=!1;global.PRETTY_PRINT&&(l=global.PRETTY_PRINT,delete global.PRETTY_PRINT);var m,n=/[\\\"\x00-\x1f]/g,o=/function ([^\(]*)?\(\) \{ \[native code\] \}/,p=/function ([^\(]*)?\((.*)\) \{/;h.printRecursive=m=function(a,c){var f=c.useColor,g=c.customInspect,i=c.useToString,k=c.limitString,l=c.showFunction;"undefined"==typeof c.seen&&(c.seen=[],c.names=[]);var m=c.seen.indexOf(a);if(m>=0)c.output+=c.names[m];else if(a&&(a instanceof Object||"object"==typeof a&&null===Object.getPrototypeOf(a)))if(c.seen.push(a),c.names.push(c.path),g&&"function"==typeof a._PRINT)a._PRINT(c),c.emit&&c.output.length>=c.emit&&(h.output(c.output),c.output="");else if(a instanceof Array)d(a,c);else if(a.toString===Object.prototype.toString||"object"==typeof a&&null===Object.getPrototypeOf(a)){var n=!1;try{(a instanceof Set||a instanceof Map||a instanceof WeakSet||a instanceof WeakMap||"function"==typeof a[Symbol.iterator])&&(c.output+=a.toString(),n=!0)}catch(q){}n||e(a,c),c.emit&&c.output.length>=c.emit&&(h.output(c.output),c.output="")}else if("function"==typeof a)try{var r=a.toString();if(c.level>0&&!l){var s=r.split("\n"),t=s[0],u=o.exec(t);null!==u?void 0===u[1]?c.output+="function { [native code] }":c.output+="function "+u[1]+" { [native code] }":(u=p.exec(t),null!==u?void 0===u[1]?c.output+="function ("+u[2]+") { ... }":c.output+="function "+u[1]+" ("+u[2]+") { ... }":(t=t.substr(8,t.length-10).trim(),c.output+='[Function "'+t+'" ...]'))}else c.output+=r}catch(v){h.stdOutput(String(v)),c.output+="[Function]"}else if(i&&"function"==typeof a.toString)try{c.output+=a.toString()}catch(w){c.output+="[Object ",e(a,c),c.output+="]"}else c.output+="[Object ",e(a,c),c.output+="]";else void 0===a?(f&&(c.output+=j.COLOR_UNDEFINED),c.output+="undefined",f&&(c.output+=j.COLOR_RESET)):"string"==typeof a?(f&&(c.output+=j.COLOR_STRING),k&&k0&&a(" "),"string"==typeof arguments[c])a(arguments[c]);else{var d={names:[],seen:[],path:"~",level:0,output:"",prettyPrint:!1,useColor:!1,customInspect:!0};b(arguments[c],d),a(d.output)}a("\n")},global.start_pretty_print=function(){require("internal").startPrettyPrint()},global.stop_pretty_print=function(){require("internal").stopPrettyPrint()},global.start_color_print=function(a){require("internal").startColorPrint(a,!1)},global.stop_color_print=function(){require("internal").stopColorPrint()},global.EXPORTS_SLOW_BUFFER&&(Object.keys(global.EXPORTS_SLOW_BUFFER).forEach(function(a){h[a]=global.EXPORTS_SLOW_BUFFER[a]}),delete global.EXPORTS_SLOW_BUFFER),global.APP_PATH&&(h.appPath=global.APP_PATH,delete global.APP_PATH),h}()),function(){"use strict";var a=require("internal");a.errors={ERROR_NO_ERROR:{code:0,message:"no error"},ERROR_FAILED:{code:1,message:"failed"},ERROR_SYS_ERROR:{code:2,message:"system error"},ERROR_OUT_OF_MEMORY:{code:3,message:"out of memory"},ERROR_INTERNAL:{code:4,message:"internal error"},ERROR_ILLEGAL_NUMBER:{code:5,message:"illegal number"},ERROR_NUMERIC_OVERFLOW:{code:6,message:"numeric overflow"},ERROR_ILLEGAL_OPTION:{code:7,message:"illegal option"},ERROR_DEAD_PID:{code:8,message:"dead process identifier"},ERROR_NOT_IMPLEMENTED:{code:9,message:"not implemented"},ERROR_BAD_PARAMETER:{code:10,message:"bad parameter"},ERROR_FORBIDDEN:{code:11,message:"forbidden"},ERROR_OUT_OF_MEMORY_MMAP:{code:12,message:"out of memory in mmap"},ERROR_CORRUPTED_CSV:{code:13,message:"csv is corrupt"},ERROR_FILE_NOT_FOUND:{code:14,message:"file not found"},ERROR_CANNOT_WRITE_FILE:{code:15,message:"cannot write file"},ERROR_CANNOT_OVERWRITE_FILE:{code:16,message:"cannot overwrite file"},ERROR_TYPE_ERROR:{code:17,message:"type error"},ERROR_LOCK_TIMEOUT:{code:18,message:"lock timeout"},ERROR_CANNOT_CREATE_DIRECTORY:{code:19,message:"cannot create directory"},ERROR_CANNOT_CREATE_TEMP_FILE:{code:20,message:"cannot create temporary file"},ERROR_REQUEST_CANCELED:{code:21,message:"canceled request"},ERROR_DEBUG:{code:22,message:"intentional debug error"},ERROR_AID_NOT_FOUND:{code:23,message:"internal error with attribute ID in shaper"},ERROR_LEGEND_INCOMPLETE:{code:24,message:"internal error if a legend could not be created"},ERROR_IP_ADDRESS_INVALID:{code:25,message:"IP address is invalid"},ERROR_LEGEND_NOT_IN_WAL_FILE:{code:26,message:"internal error if a legend for a marker does not yet exist in the same WAL file"},ERROR_FILE_EXISTS:{code:27,message:"file exists"},ERROR_LOCKED:{code:28,message:"locked"},ERROR_DEADLOCK:{code:29,message:"deadlock detected"},ERROR_HTTP_BAD_PARAMETER:{code:400,message:"bad parameter"},ERROR_HTTP_UNAUTHORIZED:{code:401,message:"unauthorized"},ERROR_HTTP_FORBIDDEN:{code:403,message:"forbidden"},ERROR_HTTP_NOT_FOUND:{code:404,message:"not found"},ERROR_HTTP_METHOD_NOT_ALLOWED:{code:405,message:"method not supported"},ERROR_HTTP_PRECONDITION_FAILED:{code:412,message:"precondition failed"},ERROR_HTTP_SERVER_ERROR:{code:500,message:"internal server error"},ERROR_HTTP_CORRUPTED_JSON:{code:600,message:"invalid JSON object"},ERROR_HTTP_SUPERFLUOUS_SUFFICES:{code:601,message:"superfluous URL suffices"},ERROR_ARANGO_ILLEGAL_STATE:{code:1e3,message:"illegal state"},ERROR_ARANGO_SHAPER_FAILED:{code:1001,message:"could not shape document"},ERROR_ARANGO_DATAFILE_SEALED:{code:1002,message:"datafile sealed"},ERROR_ARANGO_UNKNOWN_COLLECTION_TYPE:{code:1003,message:"unknown type"},ERROR_ARANGO_READ_ONLY:{code:1004,message:"read only"},ERROR_ARANGO_DUPLICATE_IDENTIFIER:{code:1005,message:"duplicate identifier"},ERROR_ARANGO_DATAFILE_UNREADABLE:{code:1006,message:"datafile unreadable"},ERROR_ARANGO_DATAFILE_EMPTY:{code:1007,message:"datafile empty"},ERROR_ARANGO_RECOVERY:{code:1008,message:"logfile recovery error"},ERROR_ARANGO_CORRUPTED_DATAFILE:{code:1100,message:"corrupted datafile"},ERROR_ARANGO_ILLEGAL_PARAMETER_FILE:{code:1101,message:"illegal or unreadable parameter file"},ERROR_ARANGO_CORRUPTED_COLLECTION:{code:1102,message:"corrupted collection"},ERROR_ARANGO_MMAP_FAILED:{code:1103,message:"mmap failed"},ERROR_ARANGO_FILESYSTEM_FULL:{code:1104,message:"filesystem full"},ERROR_ARANGO_NO_JOURNAL:{code:1105,message:"no journal"},ERROR_ARANGO_DATAFILE_ALREADY_EXISTS:{code:1106,message:"cannot create/rename datafile because it already exists"},ERROR_ARANGO_DATADIR_LOCKED:{code:1107,message:"database directory is locked"},ERROR_ARANGO_COLLECTION_DIRECTORY_ALREADY_EXISTS:{code:1108,message:"cannot create/rename collection because directory already exists"},ERROR_ARANGO_MSYNC_FAILED:{code:1109,message:"msync failed"},ERROR_ARANGO_DATADIR_UNLOCKABLE:{code:1110,message:"cannot lock database directory"},ERROR_ARANGO_SYNC_TIMEOUT:{code:1111,message:"sync timeout"},ERROR_ARANGO_CONFLICT:{code:1200,message:"conflict"},ERROR_ARANGO_DATADIR_INVALID:{code:1201,message:"invalid database directory"},ERROR_ARANGO_DOCUMENT_NOT_FOUND:{code:1202,message:"document not found"},ERROR_ARANGO_COLLECTION_NOT_FOUND:{code:1203,message:"collection not found"},ERROR_ARANGO_COLLECTION_PARAMETER_MISSING:{code:1204,message:"parameter 'collection' not found"},ERROR_ARANGO_DOCUMENT_HANDLE_BAD:{code:1205,message:"illegal document handle"},ERROR_ARANGO_MAXIMAL_SIZE_TOO_SMALL:{code:1206,message:"maximal size of journal too small"},ERROR_ARANGO_DUPLICATE_NAME:{code:1207,message:"duplicate name"},ERROR_ARANGO_ILLEGAL_NAME:{code:1208,message:"illegal name"},ERROR_ARANGO_NO_INDEX:{code:1209,message:"no suitable index known"},ERROR_ARANGO_UNIQUE_CONSTRAINT_VIOLATED:{ -code:1210,message:"unique constraint violated"},ERROR_ARANGO_INDEX_NOT_FOUND:{code:1212,message:"index not found"},ERROR_ARANGO_CROSS_COLLECTION_REQUEST:{code:1213,message:"cross collection request not allowed"},ERROR_ARANGO_INDEX_HANDLE_BAD:{code:1214,message:"illegal index handle"},ERROR_ARANGO_CAP_CONSTRAINT_ALREADY_DEFINED:{code:1215,message:"cap constraint already defined"},ERROR_ARANGO_DOCUMENT_TOO_LARGE:{code:1216,message:"document too large"},ERROR_ARANGO_COLLECTION_NOT_UNLOADED:{code:1217,message:"collection must be unloaded"},ERROR_ARANGO_COLLECTION_TYPE_INVALID:{code:1218,message:"collection type invalid"},ERROR_ARANGO_VALIDATION_FAILED:{code:1219,message:"validator failed"},ERROR_ARANGO_ATTRIBUTE_PARSER_FAILED:{code:1220,message:"parsing attribute name definition failed"},ERROR_ARANGO_DOCUMENT_KEY_BAD:{code:1221,message:"illegal document key"},ERROR_ARANGO_DOCUMENT_KEY_UNEXPECTED:{code:1222,message:"unexpected document key"},ERROR_ARANGO_DATADIR_NOT_WRITABLE:{code:1224,message:"server database directory not writable"},ERROR_ARANGO_OUT_OF_KEYS:{code:1225,message:"out of keys"},ERROR_ARANGO_DOCUMENT_KEY_MISSING:{code:1226,message:"missing document key"},ERROR_ARANGO_DOCUMENT_TYPE_INVALID:{code:1227,message:"invalid document type"},ERROR_ARANGO_DATABASE_NOT_FOUND:{code:1228,message:"database not found"},ERROR_ARANGO_DATABASE_NAME_INVALID:{code:1229,message:"database name invalid"},ERROR_ARANGO_USE_SYSTEM_DATABASE:{code:1230,message:"operation only allowed in system database"},ERROR_ARANGO_ENDPOINT_NOT_FOUND:{code:1231,message:"endpoint not found"},ERROR_ARANGO_INVALID_KEY_GENERATOR:{code:1232,message:"invalid key generator"},ERROR_ARANGO_INVALID_EDGE_ATTRIBUTE:{code:1233,message:"edge attribute missing"},ERROR_ARANGO_INDEX_DOCUMENT_ATTRIBUTE_MISSING:{code:1234,message:"index insertion warning - attribute missing in document"},ERROR_ARANGO_INDEX_CREATION_FAILED:{code:1235,message:"index creation failed"},ERROR_ARANGO_WRITE_THROTTLE_TIMEOUT:{code:1236,message:"write-throttling timeout"},ERROR_ARANGO_COLLECTION_TYPE_MISMATCH:{code:1237,message:"collection type mismatch"},ERROR_ARANGO_COLLECTION_NOT_LOADED:{code:1238,message:"collection not loaded"},ERROR_ARANGO_DATAFILE_FULL:{code:1300,message:"datafile full"},ERROR_ARANGO_EMPTY_DATADIR:{code:1301,message:"server database directory is empty"},ERROR_REPLICATION_NO_RESPONSE:{code:1400,message:"no response"},ERROR_REPLICATION_INVALID_RESPONSE:{code:1401,message:"invalid response"},ERROR_REPLICATION_MASTER_ERROR:{code:1402,message:"master error"},ERROR_REPLICATION_MASTER_INCOMPATIBLE:{code:1403,message:"master incompatible"},ERROR_REPLICATION_MASTER_CHANGE:{code:1404,message:"master change"},ERROR_REPLICATION_LOOP:{code:1405,message:"loop detected"},ERROR_REPLICATION_UNEXPECTED_MARKER:{code:1406,message:"unexpected marker"},ERROR_REPLICATION_INVALID_APPLIER_STATE:{code:1407,message:"invalid applier state"},ERROR_REPLICATION_UNEXPECTED_TRANSACTION:{code:1408,message:"invalid transaction"},ERROR_REPLICATION_INVALID_APPLIER_CONFIGURATION:{code:1410,message:"invalid replication applier configuration"},ERROR_REPLICATION_RUNNING:{code:1411,message:"cannot perform operation while applier is running"},ERROR_REPLICATION_APPLIER_STOPPED:{code:1412,message:"replication stopped"},ERROR_REPLICATION_NO_START_TICK:{code:1413,message:"no start tick"},ERROR_REPLICATION_START_TICK_NOT_PRESENT:{code:1414,message:"start tick not present"},ERROR_CLUSTER_NO_AGENCY:{code:1450,message:"could not connect to agency"},ERROR_CLUSTER_NO_COORDINATOR_HEADER:{code:1451,message:"missing coordinator header"},ERROR_CLUSTER_COULD_NOT_LOCK_PLAN:{code:1452,message:"could not lock plan in agency"},ERROR_CLUSTER_COLLECTION_ID_EXISTS:{code:1453,message:"collection ID already exists"},ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION_IN_PLAN:{code:1454,message:"could not create collection in plan"},ERROR_CLUSTER_COULD_NOT_READ_CURRENT_VERSION:{code:1455,message:"could not read version in current in agency"},ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION:{code:1456,message:"could not create collection"},ERROR_CLUSTER_TIMEOUT:{code:1457,message:"timeout in cluster operation"},ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_PLAN:{code:1458,message:"could not remove collection from plan"},ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_CURRENT:{code:1459,message:"could not remove collection from current"},ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE_IN_PLAN:{code:1460,message:"could not create database in plan"},ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE:{code:1461,message:"could not create database"},ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_PLAN:{code:1462,message:"could not remove database from plan"},ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_CURRENT:{code:1463,message:"could not remove database from current"},ERROR_CLUSTER_SHARD_GONE:{code:1464,message:"no responsible shard found"},ERROR_CLUSTER_CONNECTION_LOST:{code:1465,message:"cluster internal HTTP connection broken"},ERROR_CLUSTER_MUST_NOT_SPECIFY_KEY:{code:1466,message:"must not specify _key for this collection"},ERROR_CLUSTER_GOT_CONTRADICTING_ANSWERS:{code:1467,message:"got contradicting answers from different shards"},ERROR_CLUSTER_NOT_ALL_SHARDING_ATTRIBUTES_GIVEN:{code:1468,message:"not all sharding attributes given"},ERROR_CLUSTER_MUST_NOT_CHANGE_SHARDING_ATTRIBUTES:{code:1469,message:"must not change the value of a shard key attribute"},ERROR_CLUSTER_UNSUPPORTED:{code:1470,message:"unsupported operation or parameter"},ERROR_CLUSTER_ONLY_ON_COORDINATOR:{code:1471,message:"this operation is only valid on a coordinator in a cluster"},ERROR_CLUSTER_READING_PLAN_AGENCY:{code:1472,message:"error reading Plan in agency"},ERROR_CLUSTER_COULD_NOT_TRUNCATE_COLLECTION:{code:1473,message:"could not truncate collection"},ERROR_CLUSTER_AQL_COMMUNICATION:{code:1474,message:"error in cluster internal communication for AQL"},ERROR_ARANGO_DOCUMENT_NOT_FOUND_OR_SHARDING_ATTRIBUTES_CHANGED:{code:1475,message:"document not found or sharding attributes changed"},ERROR_CLUSTER_COULD_NOT_DETERMINE_ID:{code:1476,message:"could not determine my ID from my local info"},ERROR_CLUSTER_ONLY_ON_DBSERVER:{code:1477,message:"this operation is only valid on a DBserver in a cluster"},ERROR_QUERY_KILLED:{code:1500,message:"query killed"},ERROR_QUERY_PARSE:{code:1501,message:"%s"},ERROR_QUERY_EMPTY:{code:1502,message:"query is empty"},ERROR_QUERY_SCRIPT:{code:1503,message:"runtime error '%s'"},ERROR_QUERY_NUMBER_OUT_OF_RANGE:{code:1504,message:"number out of range"},ERROR_QUERY_VARIABLE_NAME_INVALID:{code:1510,message:"variable name '%s' has an invalid format"},ERROR_QUERY_VARIABLE_REDECLARED:{code:1511,message:"variable '%s' is assigned multiple times"},ERROR_QUERY_VARIABLE_NAME_UNKNOWN:{code:1512,message:"unknown variable '%s'"},ERROR_QUERY_COLLECTION_LOCK_FAILED:{code:1521,message:"unable to read-lock collection %s"},ERROR_QUERY_TOO_MANY_COLLECTIONS:{code:1522,message:"too many collections"},ERROR_QUERY_DOCUMENT_ATTRIBUTE_REDECLARED:{code:1530,message:"document attribute '%s' is assigned multiple times"},ERROR_QUERY_FUNCTION_NAME_UNKNOWN:{code:1540,message:"usage of unknown function '%s()'"},ERROR_QUERY_FUNCTION_ARGUMENT_NUMBER_MISMATCH:{code:1541,message:"invalid number of arguments for function '%s()', expected number of arguments: minimum: %d, maximum: %d"},ERROR_QUERY_FUNCTION_ARGUMENT_TYPE_MISMATCH:{code:1542,message:"invalid argument type in call to function '%s()'"},ERROR_QUERY_INVALID_REGEX:{code:1543,message:"invalid regex value"},ERROR_QUERY_BIND_PARAMETERS_INVALID:{code:1550,message:"invalid structure of bind parameters"},ERROR_QUERY_BIND_PARAMETER_MISSING:{code:1551,message:"no value specified for declared bind parameter '%s'"},ERROR_QUERY_BIND_PARAMETER_UNDECLARED:{code:1552,message:"bind parameter '%s' was not declared in the query"},ERROR_QUERY_BIND_PARAMETER_TYPE:{code:1553,message:"bind parameter '%s' has an invalid value or type"},ERROR_QUERY_INVALID_LOGICAL_VALUE:{code:1560,message:"invalid logical value"},ERROR_QUERY_INVALID_ARITHMETIC_VALUE:{code:1561,message:"invalid arithmetic value"},ERROR_QUERY_DIVISION_BY_ZERO:{code:1562,message:"division by zero"},ERROR_QUERY_ARRAY_EXPECTED:{code:1563,message:"array expected"},ERROR_QUERY_FAIL_CALLED:{code:1569,message:"FAIL(%s) called"},ERROR_QUERY_GEO_INDEX_MISSING:{code:1570,message:"no suitable geo index found for geo restriction on '%s'"},ERROR_QUERY_FULLTEXT_INDEX_MISSING:{code:1571,message:"no suitable fulltext index found for fulltext query on '%s'"},ERROR_QUERY_INVALID_DATE_VALUE:{code:1572,message:"invalid date value"},ERROR_QUERY_MULTI_MODIFY:{code:1573,message:"multi-modify query"},ERROR_QUERY_INVALID_AGGREGATE_EXPRESSION:{code:1574,message:"invalid aggregate expression"},ERROR_QUERY_COMPILE_TIME_OPTIONS:{code:1575,message:"query options must be readable at query compile time"},ERROR_QUERY_EXCEPTION_OPTIONS:{code:1576,message:"query options expected"},ERROR_QUERY_COLLECTION_USED_IN_EXPRESSION:{code:1577,message:"collection '%s' used as expression operand"},ERROR_QUERY_DISALLOWED_DYNAMIC_CALL:{code:1578,message:"disallowed dynamic call to '%s'"},ERROR_QUERY_ACCESS_AFTER_MODIFICATION:{code:1579,message:"access after data-modification"},ERROR_QUERY_FUNCTION_INVALID_NAME:{code:1580,message:"invalid user function name"},ERROR_QUERY_FUNCTION_INVALID_CODE:{code:1581,message:"invalid user function code"},ERROR_QUERY_FUNCTION_NOT_FOUND:{code:1582,message:"user function '%s()' not found"},ERROR_QUERY_FUNCTION_RUNTIME_ERROR:{code:1583,message:"user function runtime error: %s"},ERROR_QUERY_BAD_JSON_PLAN:{code:1590,message:"bad execution plan JSON"},ERROR_QUERY_NOT_FOUND:{code:1591,message:"query ID not found"},ERROR_QUERY_IN_USE:{code:1592,message:"query with this ID is in use"},ERROR_CURSOR_NOT_FOUND:{code:1600,message:"cursor not found"},ERROR_CURSOR_BUSY:{code:1601,message:"cursor is busy"},ERROR_TRANSACTION_INTERNAL:{code:1650,message:"internal transaction error"},ERROR_TRANSACTION_NESTED:{code:1651,message:"nested transactions detected"},ERROR_TRANSACTION_UNREGISTERED_COLLECTION:{code:1652,message:"unregistered collection used in transaction"},ERROR_TRANSACTION_DISALLOWED_OPERATION:{code:1653,message:"disallowed operation inside transaction"},ERROR_TRANSACTION_ABORTED:{code:1654,message:"transaction aborted"},ERROR_USER_INVALID_NAME:{code:1700,message:"invalid user name"},ERROR_USER_INVALID_PASSWORD:{code:1701,message:"invalid password"},ERROR_USER_DUPLICATE:{code:1702,message:"duplicate user"},ERROR_USER_NOT_FOUND:{code:1703,message:"user not found"},ERROR_USER_CHANGE_PASSWORD:{code:1704,message:"user must change his password"},ERROR_APPLICATION_INVALID_NAME:{code:1750,message:"invalid application name"},ERROR_APPLICATION_INVALID_MOUNT:{code:1751,message:"invalid mount"},ERROR_APPLICATION_DOWNLOAD_FAILED:{code:1752,message:"application download failed"},ERROR_APPLICATION_UPLOAD_FAILED:{code:1753,message:"application upload failed"},ERROR_KEYVALUE_INVALID_KEY:{code:1800,message:"invalid key declaration"},ERROR_KEYVALUE_KEY_EXISTS:{code:1801,message:"key already exists"},ERROR_KEYVALUE_KEY_NOT_FOUND:{code:1802,message:"key not found"},ERROR_KEYVALUE_KEY_NOT_UNIQUE:{code:1803,message:"key is not unique"},ERROR_KEYVALUE_KEY_NOT_CHANGED:{code:1804,message:"key value not changed"},ERROR_KEYVALUE_KEY_NOT_REMOVED:{code:1805,message:"key value not removed"},ERROR_KEYVALUE_NO_VALUE:{code:1806,message:"missing value"},ERROR_TASK_INVALID_ID:{code:1850,message:"invalid task id"},ERROR_TASK_DUPLICATE_ID:{code:1851,message:"duplicate task id"},ERROR_TASK_NOT_FOUND:{code:1852,message:"task not found"},ERROR_GRAPH_INVALID_GRAPH:{code:1901,message:"invalid graph"},ERROR_GRAPH_COULD_NOT_CREATE_GRAPH:{code:1902,message:"could not create graph"},ERROR_GRAPH_INVALID_VERTEX:{code:1903,message:"invalid vertex"},ERROR_GRAPH_COULD_NOT_CREATE_VERTEX:{code:1904,message:"could not create vertex"},ERROR_GRAPH_COULD_NOT_CHANGE_VERTEX:{code:1905,message:"could not change vertex"},ERROR_GRAPH_INVALID_EDGE:{code:1906,message:"invalid edge"},ERROR_GRAPH_COULD_NOT_CREATE_EDGE:{code:1907,message:"could not create edge"},ERROR_GRAPH_COULD_NOT_CHANGE_EDGE:{code:1908,message:"could not change edge"},ERROR_GRAPH_TOO_MANY_ITERATIONS:{code:1909,message:"too many iterations - try increasing the value of 'maxIterations'"},ERROR_GRAPH_INVALID_FILTER_RESULT:{code:1910,message:"invalid filter result"},ERROR_GRAPH_COLLECTION_MULTI_USE:{code:1920,message:"multi use of edge collection in edge def"},ERROR_GRAPH_COLLECTION_USE_IN_MULTI_GRAPHS:{code:1921,message:"edge collection already used in edge def"},ERROR_GRAPH_CREATE_MISSING_NAME:{code:1922,message:"missing graph name"},ERROR_GRAPH_CREATE_MALFORMED_EDGE_DEFINITION:{code:1923,message:"malformed edge definition"},ERROR_GRAPH_NOT_FOUND:{code:1924,message:"graph not found"},ERROR_GRAPH_DUPLICATE:{code:1925,message:"graph already exists"},ERROR_GRAPH_VERTEX_COL_DOES_NOT_EXIST:{code:1926,message:"vertex collection does not exist or is not part of the graph"},ERROR_GRAPH_WRONG_COLLECTION_TYPE_VERTEX:{code:1927,message:"not a vertex collection"},ERROR_GRAPH_NOT_IN_ORPHAN_COLLECTION:{code:1928,message:"not in orphan collection"},ERROR_GRAPH_COLLECTION_USED_IN_EDGE_DEF:{code:1929,message:"collection already used in edge def"},ERROR_GRAPH_EDGE_COLLECTION_NOT_USED:{code:1930,message:"edge collection not used in graph"},ERROR_GRAPH_NOT_AN_ARANGO_COLLECTION:{code:1931,message:" is not an ArangoCollection"},ERROR_GRAPH_NO_GRAPH_COLLECTION:{code:1932,message:"collection _graphs does not exist"},ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT_STRING:{code:1933,message:"Invalid example type. Has to be String, Array or Object"},ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT:{code:1934,message:"Invalid example type. Has to be Array or Object"},ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS:{code:1935,message:"Invalid number of arguments. Expected: "},ERROR_GRAPH_INVALID_PARAMETER:{code:1936,message:"Invalid parameter type."},ERROR_GRAPH_INVALID_ID:{code:1937,message:"Invalid id"},ERROR_GRAPH_COLLECTION_USED_IN_ORPHANS:{code:1938,message:"collection used in orphans"},ERROR_GRAPH_EDGE_COL_DOES_NOT_EXIST:{code:1939,message:"edge collection does not exist or is not part of the graph"},ERROR_GRAPH_EMPTY:{code:1940,message:"empty graph"},ERROR_SESSION_UNKNOWN:{code:1950,message:"unknown session"},ERROR_SESSION_EXPIRED:{code:1951,message:"session expired"},SIMPLE_CLIENT_UNKNOWN_ERROR:{code:2e3,message:"unknown client error"},SIMPLE_CLIENT_COULD_NOT_CONNECT:{code:2001,message:"could not connect to server"},SIMPLE_CLIENT_COULD_NOT_WRITE:{code:2002,message:"could not write to server"},SIMPLE_CLIENT_COULD_NOT_READ:{code:2003,message:"could not read from server"},ERROR_MALFORMED_MANIFEST_FILE:{code:3e3,message:"malformed manifest file"},ERROR_INVALID_APPLICATION_MANIFEST:{code:3001,message:"manifest file is invalid"},ERROR_MANIFEST_FILE_ATTRIBUTE_MISSING:{code:3002,message:"missing manifest attribute"},ERROR_CANNOT_EXTRACT_APPLICATION_ROOT:{code:3003,message:"unable to extract app root path"},ERROR_INVALID_FOXX_OPTIONS:{code:3004,message:"invalid foxx options"},ERROR_FAILED_TO_EXECUTE_SCRIPT:{code:3005,message:"failed to execute script"},ERROR_SYNTAX_ERROR_IN_SCRIPT:{code:3006,message:"syntax error in script"},ERROR_INVALID_MOUNTPOINT:{code:3007,message:"mountpoint is invalid"},ERROR_NO_FOXX_FOUND:{code:3008,message:"No foxx found at this location"},ERROR_APP_NOT_FOUND:{code:3009,message:"App not found"},ERROR_APP_NEEDS_CONFIGURATION:{code:3010,message:"App not configured"},ERROR_MODULE_NOT_FOUND:{code:3100,message:"cannot locate module"},ERROR_MODULE_SYNTAX_ERROR:{code:3101,message:"syntax error in module"},ERROR_MODULE_BAD_WRAPPER:{code:3102,message:"failed to wrap module"},ERROR_MODULE_FAILURE:{code:3103,message:"failed to invoke module"},ERROR_MODULE_UNKNOWN_FILE_TYPE:{code:3110,message:"unknown file type"},ERROR_MODULE_PATH_MUST_BE_ABSOLUTE:{code:3111,message:"path must be absolute"},ERROR_MODULE_CAN_NOT_ESCAPE:{code:3112,message:"cannot use '..' to escape top-level-directory"},ERROR_MODULE_DRIVE_LETTER:{code:3113,message:"drive local path is not supported"},ERROR_MODULE_BAD_MODULE_ORIGIN:{code:3120,message:"corrupted module origin"},ERROR_MODULE_BAD_PACKAGE_ORIGIN:{code:3121,message:"corrupted package origin"},ERROR_MODULE_DOCUMENT_IS_EMPTY:{code:3125,message:"no content"},ERROR_MODULE_MAIN_NOT_READABLE:{code:3130,message:"cannot read main file"},ERROR_MODULE_MAIN_NOT_JS:{code:3131,message:"main file is not of type 'js'"},RESULT_ELEMENT_EXISTS:{code:1e4,message:"element not inserted into structure, because it already exists"},RESULT_ELEMENT_NOT_FOUND:{code:10001,message:"element not found in structure"},ERROR_APP_ALREADY_EXISTS:{code:2e4,message:"newest version of app already installed"},ERROR_QUEUE_ALREADY_EXISTS:{code:21e3,message:"named queue already exists"},ERROR_DISPATCHER_IS_STOPPING:{code:21001,message:"dispatcher stopped"},ERROR_QUEUE_UNKNOWN:{code:21002,message:"named queue does not exist"},ERROR_QUEUE_FULL:{code:21003,message:"named queue is full"}}}(),global.DEFINE_MODULE("console",function(){"use strict";function a(a,b){j(a,h+b)}function b(a){var b=require("internal").ShapedJson,c=[];a.length>0&&"string"!=typeof a[0]&&c.push("%s");for(var d=0;d curl ","POST"===e?(i=a.arango.POST_RAW(f,g,h),j+="-X "+e+" "):"PUT"===e?(i=a.arango.PUT_RAW(f,g,h),j+="-X "+e+" "):"GET"===e?i=a.arango.GET_RAW(f,h):"DELETE"===e?(i=a.arango.DELETE_RAW(f,h),j+="-X "+e+" "):"PATCH"===e?(i=a.arango.PATCH_RAW(f,g,h),j+="-X "+e+" "):"HEAD"===e?(i=a.arango.HEAD_RAW(f,h),j+="-X "+e+" "):"OPTION"===e&&(i=a.arango.OPTION_RAW(f,g,h),j+="-X "+e+" "),void 0!==h&&""!==h)for(k in h)h.hasOwnProperty(k)&&(j+="--header '"+k+": "+h[k]+"' ");return void 0!==g&&""!==g&&(j+="--data-binary @- "),j+="--dump - http://localhost:8529"+f,b(j),void 0!==g&&""!==g&&g&&(d(" <<EOF\n"),l?c(g):d(g),d("\nEOF")),d("\n\n"),i}},a.appendRawResponse=function(b,c){return function(d){var e,f=d.headers;b("HTTP/1.1 "+f["http/1.1"]+"\n");for(e in f)f.hasOwnProperty(e)&&"http/1.1"!==e&&"server"!==e&&"connection"!==e&&"content-length"!==e&&b(e+": "+f[e]+"\n");b("\n"),void 0!==d.body&&(c(a.inspect(d.body)),b("\n"))}},a.appendJsonResponse=function(b,c){return function(b){var d=a.appendRawResponse(c,c),e=b.body;b.body=JSON.parse(b.body),d(b),b.body=e}},a.log=function(b,c){a.output(b,": ",c,"\n")};try{"undefined"!=typeof window&&(a.sprintf=function(a){var b=arguments.length;if(0===b)return"";if(1>=b)return String(a);var c,d=[];for(c=1;c col = db.mycoll; \n > col = db._create("mycoll"); \n \nAdministration Functions: \n name() collection name \n status() status of the collection \n type() type of the collection \n truncate() delete all documents \n properties() show collection properties \n drop() delete a collection \n load() load a collection \n unload() unload a collection \n rename() renames a collection \n getIndexes() return defined indexes \n refresh() refreshes the status and name \n _help() this help \n \nDocument Functions: \n count() return number of documents \n save() create document and return handle \n document() get document by handle (_id or _key)\n replace(, , ) overwrite document \n update(, , , partially update document \n ) \n remove() delete document \n exists() checks whether a document exists \n first() first inserted/updated document \n last() last inserted/updated document \n \nAttributes: \n _database database object \n _id collection identifier ';d.prototype._help=function(){e.print(h)},d.prototype.name=function(){return null===this._name&&this.refresh(),this._name},d.prototype.status=function(){var a;return null===this._status&&this.refresh(),a=this._status,this._status===d.STATUS_UNLOADING&&(this._status=null),a},d.prototype.type=function(){return null===this._type&&this.refresh(),this._type},d.prototype.properties=function(a){var b,c,d={doCompact:!0,journalSize:!0,isSystem:!1,isVolatile:!1,waitForSync:!0,shardKeys:!1,numberOfShards:!1,keyOptions:!1,indexBuckets:!0};if(void 0===a)c=this._database._connection.GET(this._baseurl("properties")),f.checkRequestResult(c);else{var e={};for(b in d)d.hasOwnProperty(b)&&d[b]&&a.hasOwnProperty(b)&&(e[b]=a[b]);c=this._database._connection.PUT(this._baseurl("properties"),JSON.stringify(e)),f.checkRequestResult(c)}var g={};for(b in d)d.hasOwnProperty(b)&&c.hasOwnProperty(b)&&void 0!==c[b]&&(g[b]=c[b]);return g},d.prototype.rotate=function(){var a=this._database._connection.PUT(this._baseurl("rotate"),"");return f.checkRequestResult(a),a.result},d.prototype.figures=function(){var a=this._database._connection.GET(this._baseurl("figures"));return f.checkRequestResult(a),a.figures},d.prototype.checksum=function(a,b){var c="";a&&(c+="?withRevisions=true"),b&&(c+=(""===c?"?":"&")+"withData=true");var d=this._database._connection.GET(this._baseurl("checksum")+c);return f.checkRequestResult(d),{checksum:d.checksum,revision:d.revision}},d.prototype.revision=function(){var a=this._database._connection.GET(this._baseurl("revision"));return f.checkRequestResult(a),a.revision},d.prototype.drop=function(){var a=this._database._connection.DELETE(this._baseurl());null!==a&&a.error===!0&&a.errorNum!==e.errors.ERROR_ARANGO_COLLECTION_NOT_FOUND.code&&f.checkRequestResult(a),this._status=d.STATUS_DELETED;var b,c=this._database;for(b in c)if(c.hasOwnProperty(b)){var g=c[b];g instanceof d&&g.name()===this.name()&&delete c[b]}},d.prototype.truncate=function(){var a=this._database._connection.PUT(this._baseurl("truncate"),"");f.checkRequestResult(a),this._status=null},d.prototype.load=function(a){var b={count:!0};void 0!==a&&(b.count=a);var c=this._database._connection.PUT(this._baseurl("load"),JSON.stringify(b));f.checkRequestResult(c),this._status=null},d.prototype.unload=function(){var a=this._database._connection.PUT(this._baseurl("unload"),"");f.checkRequestResult(a),this._status=null},d.prototype.rename=function(a){var b={name:a},c=this._database._connection.PUT(this._baseurl("rename"),JSON.stringify(b));f.checkRequestResult(c),delete this._database[this._name],this._database[a]=this,this._status=null,this._name=null},d.prototype.refresh=function(){var a=this._database._connection.GET(this._database._collectionurl(this._id)+"?useId=true");f.checkRequestResult(a),this._name=a.name,this._status=a.status,this._type=a.type},d.prototype.getIndexes=function(a){var b=this._database._connection.GET(this._indexurl()+"&withStats="+(a||!1));return f.checkRequestResult(b),b.indexes},d.prototype.index=function(a){a.hasOwnProperty("id")&&(a=a.id);var b=this._database._connection.GET(this._database._indexurl(a,this.name()));return f.checkRequestResult(b),b},d.prototype.dropIndex=function(a){a.hasOwnProperty("id")&&(a=a.id);var b=this._database._connection.DELETE(this._database._indexurl(a,this.name()));return null!==b&&b.error===!0&&b.errorNum===e.errors.ERROR_ARANGO_INDEX_NOT_FOUND.code?!1:(f.checkRequestResult(b),!0)},d.prototype.ensureCapConstraint=function(a,b){var c={type:"cap",size:a||void 0,byteSize:b||void 0},d=this._database._connection.POST(this._indexurl(),JSON.stringify(c));return f.checkRequestResult(d),d},d.prototype.ensureUniqueSkiplist=function(){var a=c({type:"skiplist", -unique:!0},arguments),b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.ensureSkiplist=function(){var a=c({type:"skiplist",unique:!1},arguments),b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.ensureFulltextIndex=function(a,b){var c={type:"fulltext",minLength:b||void 0,fields:[a]},d=this._database._connection.POST(this._indexurl(),JSON.stringify(c));return f.checkRequestResult(d),d},d.prototype.ensureUniqueConstraint=function(){var a=c({type:"hash",unique:!0},arguments),b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.ensureHashIndex=function(){var a=c({type:"hash",unique:!1},arguments),b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.ensureGeoIndex=function(a,b){var c;if("string"!=typeof a)throw"usage: ensureGeoIndex(, ) or ensureGeoIndex([, ])";c="boolean"==typeof b?{type:"geo",fields:[a],geoJson:b}:void 0===b?{type:"geo",fields:[a],geoJson:!1}:{type:"geo",fields:[a,b],geoJson:!1};var d=this._database._connection.POST(this._indexurl(),JSON.stringify(c));return f.checkRequestResult(d),d},d.prototype.ensureGeoConstraint=function(a,b){return this.ensureGeoIndex(a,b)},d.prototype.ensureIndex=function(a){if("object"!=typeof a||Array.isArray(a))throw"usage: ensureIndex()";var b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.count=function(){var a=this._database._connection.GET(this._baseurl("count"));return f.checkRequestResult(a),a.count},d.prototype.document=function(a){var b,c=null;if(a.hasOwnProperty("_id")&&(a.hasOwnProperty("_rev")&&(c=a._rev),a=a._id),b=null===c?this._database._connection.GET(this._documenturl(a)):this._database._connection.GET(this._documenturl(a),{"if-match":JSON.stringify(c)}),null!==b&&b.error===!0&&b.errorNum===e.errors.ERROR_ARANGO_COLLECTION_NOT_FOUND.code)throw new g(b);return f.checkRequestResult(b),b},d.prototype.exists=function(a){var b,c=null;if(void 0===a||null===a)throw new g({errorNum:e.errors.ERROR_ARANGO_DOCUMENT_HANDLE_BAD.code,errorMessage:e.errors.ERROR_ARANGO_DOCUMENT_HANDLE_BAD.message});return a.hasOwnProperty("_id")&&(a.hasOwnProperty("_rev")&&(c=a._rev),a=a._id),b=null===c?this._database._connection.HEAD(this._documenturl(a)):this._database._connection.HEAD(this._documenturl(a),{"if-match":JSON.stringify(c)}),null===b||b.error!==!0||b.errorNum!==e.errors.ERROR_ARANGO_COLLECTION_NOT_FOUND.code&&b.errorNum!==e.errors.ERROR_HTTP_NOT_FOUND.code&&b.errorNum!==e.errors.ERROR_HTTP_PRECONDITION_FAILED.code?(f.checkRequestResult(b),!0):!1},d.prototype.any=function(){var a=this._database._connection.PUT(this._prefixurl("/_api/simple/any"),JSON.stringify({collection:this._name}));return f.checkRequestResult(a),a.document},d.prototype.firstExample=function(a){var b,c;if(1===arguments.length)b=a;else for(b={},c=0;c) get collection by identifier/name \n _create(, ) creates a new collection \n _createEdgeCollection() creates a new edge collection \n _drop() delete a collection \n \nDocument Functions: \n _document() get document by handle (_id) \n _replace(, , ) overwrite document \n _update(, , , partially update document \n ) \n _remove() delete document \n _exists() checks whether a document exists \n _truncate() delete all documents \n \nDatabase Management Functions: \n _createDatabase() creates a new database \n _dropDatabase() drops an existing database \n _useDatabase() switches into an existing database\n _drop() delete a collection \n _name() name of the current database \n \nQuery / Transaction Functions: \n _executeTransaction() execute transaction \n _query() execute AQL query \n _createStatement() create and return AQL query ";c.prototype._help=function(){e.print(i)},c.prototype.toString=function(){return'[object ArangoDatabase "'+this._name()+'"]'},c.prototype._collections=function(){var a=this._connection.GET(this._collectionurl());if(f.checkRequestResult(a),void 0!==a.collections){var b,c=a.collections,d=[];for(b=0;b1&&(a={query:a,bindVars:b,options:c}),require("@arangodb/aql/explainer").explain(a)},c.prototype._createDatabase=function(a,b,c){var d={name:a,options:b||{},users:c||[]},e=this._connection.POST("/_api/database",JSON.stringify(d));if(null!==e&&e.error===!0)throw new g(e);return f.checkRequestResult(e),e.result},c.prototype._dropDatabase=function(a){var b=this._connection.DELETE("/_api/database/"+encodeURIComponent(a));if(null!==b&&b.error===!0)throw new g(b);return f.checkRequestResult(b),b.result},c.prototype._listDatabases=function(){var a=this._connection.GET("/_api/database");if(null!==a&&a.error===!0)throw new g(a);return f.checkRequestResult(a),a.result},c.prototype._useDatabase=function(a){if(e.printBrowser)throw new g({error:!0,code:e.errors.ERROR_NOT_IMPLEMENTED.code,errorNum:e.errors.ERROR_NOT_IMPLEMENTED.code,errorMessage:"_useDatabase() is not supported in the web interface"});var b=this._connection.getDatabaseName();if(a===b)return!0;this._connection.setDatabaseName(a);try{this._queryProperties(!0),this._flushCache()}catch(c){if(this._connection.setDatabaseName(b),c.hasOwnProperty("errorNum"))throw c;throw new g({error:!0,code:e.errors.ERROR_BAD_PARAMETER.code,errorNum:e.errors.ERROR_BAD_PARAMETER.code,errorMessage:"cannot use database '"+a+"'"})}return!0},c.prototype._listEndpoints=function(){var a=this._connection.GET("/_api/endpoint");if(null!==a&&a.error===!0)throw new g(a);return f.checkRequestResult(a),a},c.prototype._executeTransaction=function(a){if(!a||"object"!=typeof a)throw new g({error:!0,code:e.errors.ERROR_HTTP_BAD_PARAMETER.code,errorNum:e.errors.ERROR_BAD_PARAMETER.code,errorMessage:"usage: _executeTransaction()"});if(!a.collections||"object"!=typeof a.collections)throw new g({error:!0,code:e.errors.ERROR_HTTP_BAD_PARAMETER.code,errorNum:e.errors.ERROR_BAD_PARAMETER.code,errorMessage:"missing/invalid collections definition for transaction"});if(!a.action||"string"!=typeof a.action&&"function"!=typeof a.action)throw new g({error:!0,code:e.errors.ERROR_HTTP_BAD_PARAMETER.code,errorNum:e.errors.ERROR_BAD_PARAMETER.code,errorMessage:"missing/invalid action definition for transaction"});"function"==typeof a.action&&(a.action=String(a.action));var b=this._connection.POST("/_api/transaction",JSON.stringify(a));if(null!==b&&b.error===!0)throw new g(b);return f.checkRequestResult(b),b.result}}),module.define("@arangodb/arango-query-cursor",function(a,b){function c(a,b){this._database=a,this._dbName=a._name(),this.data=b,this._hasNext=!1,this._hasMore=!1,this._pos=0,this._count=0,this._total=0,void 0!==b.result&&(this._count=b.result.length,this._pos0){if(a)d.print(b);else{var g=d.startCaptureMode();d.print(b),e+="\n\n"+d.stopCaptureMode(g)}this.hasNext()&&(e+="\ntype 'more' to show more documents\n",more=this)}return a||(d.print(e),e=""),e},c.prototype.toArray=function(){for(var a=[];this.hasNext();)a.push(this.next());return a};var f=e.createHelpHeadline("ArangoQueryCursor help")+'ArangoQueryCursor constructor: \n > cursor = stmt.execute() \nFunctions: \n hasNext() returns true if there are \n more results to fetch \n next() returns the next document \n toArray() returns all data from the cursor\n _help() this help \nAttributes: \n _database database object \nExample: \n > stmt = db._createStatement({ "query": "FOR c IN coll RETURN c" })\n > cursor = stmt.execute() \n > documents = cursor.toArray() \n > cursor = stmt.execute() \n > while (cursor.hasNext()) { print(cursor.next()) } ';c.prototype._help=function(){d.print(f)},c.prototype.hasNext=function(){return this._hasNext},c.prototype.next=function(){if(!this._hasNext)throw"No more results";var a=this.data.result[this._pos];if(this._pos++,this._pos===this._count&&(this._hasNext=!1,this._pos=0,this._hasMore&&this.data.id)){this._hasMore=!1;var b=this._database._connection.PUT(this._baseurl(),"");e.checkRequestResult(b),this.data=b,this._count=b.result.length,this._pos stmt = new ArangoStatement(db, { "query": "FOR..." }) \n > stmt = db._createStatement({ "query": "FOR..." }) \nSet query options: \n > stmt.setBatchSize() set the max. number of results \n to be transferred per roundtrip \n > stmt.setCount() set count flag (return number of\n results in "count" attribute) \nGet query options: \n > stmt.setBatchSize() return the max. number of results\n to be transferred per roundtrip \n > stmt.getCount() return count flag (return number\n of results in "count" attribute)\n > stmt.getQuery() return query string \n results in "count" attribute) \nBind parameters to a query: \n > stmt.bind(, ) bind single variable \n > stmt.bind() bind multiple variables \nExecute query: \n > cursor = stmt.execute() returns a cursor \nGet all results in an array: \n > docs = cursor.toArray() \nOr loop over the result set: \n > while (cursor.hasNext()) { print(cursor.next()) } ';e.prototype._help=function(){c.print(g)},e.prototype.parse=function(){var a={query:this._query},b=this._database._connection.POST("/_api/query",JSON.stringify(a));d.checkRequestResult(b);var c={bindVars:b.bindVars,collections:b.collections,ast:b.ast};return c},e.prototype.explain=function(a){var b=this._options||{};"object"==typeof b&&"object"==typeof a&&Object.keys(a).forEach(function(c){b[c]=a[c]});var c={query:this._query,bindVars:this._bindVars,options:b},e=this._database._connection.POST("/_api/explain",JSON.stringify(c));return d.checkRequestResult(e),b&&b.allPlans?{plans:e.plans,warnings:e.warnings,stats:e.stats}:{plan:e.plan,warnings:e.warnings,stats:e.stats,cacheable:e.cacheable}},e.prototype.execute=function(){var a={query:this._query,count:this._doCount,bindVars:this._bindVars};this._batchSize&&(a.batchSize=this._batchSize),this._options&&(a.options=this._options),void 0!==this._cache&&(a.cache=this._cache);var b=this._database._connection.POST("/_api/cursor",JSON.stringify(a));return d.checkRequestResult(b),new f(this._database,b)},a.ArangoStatement=e}),module.define("@arangodb/arangosh",function(a,b){var c=require("internal");a.getIdString=function(a,b){var c="[object "+b;return a._id?c+=":"+a._id:a.data&&a.data._id&&(c+=":"+a.data._id),c+="]"},a.createHelpHeadline=function(a){var b,c="",d=Math.abs(78-a.length)/2;for(b=0;d>b;++b)c+="-";return"\n"+c+" "+a+" "+c+"\n"};var d=require("@arangodb"),e=d.ArangoError;a.checkRequestResult=function(a){if(void 0===a)throw new e({error:!0,code:500,errorNum:d.ERROR_INTERNAL,errorMessage:"Unknown error. Request result is empty"});if(a.hasOwnProperty("error")){if(a.error){if(a.errorNum===d.ERROR_TYPE_ERROR)throw new TypeError(a.errorMessage);throw new e(a)}delete a.error}return a},a.HELP=a.createHelpHeadline("Help")+"Predefined objects: \n arango: ArangoConnection \n db: ArangoDatabase \n"+(c.printBrowser?"":" fm: FoxxManager \n")+"Examples: \n > db._collections() list all collections \n > db._query().toArray() execute an AQL query \n > db._explain() explain an AQL query \n > help show help pages \n > exit \nNote: collection names and statuses may be cached in arangosh. \nTo refresh the list of collections and their statuses, issue: \n > db._collections(); \n \n"+(c.printBrowser?"To cancel the current prompt, press CTRL + z. \n \nPlease note that all variables defined with the var keyword will \ndisappear when the command is finished. To introduce variables that\nare persisting until the next command, omit the var keyword. \n\nType 'tutorial' for a tutorial or 'help' to see common examples":"To cancel the current prompt, press CTRL + d. \n"),a.helpExtended=a.createHelpHeadline("More help")+"Pager: \n > stop_pager() stop the pager output \n > start_pager() start the pager \nPretty printing: \n > stop_pretty_print() stop pretty printing \n > start_pretty_print() start pretty printing \nColor output: \n > stop_color_print() stop color printing \n > start_color_print() start color printing \nPrint function: \n > print(x) std. print function \n > print_plain(x) print without prettifying \n and without colors \n > clear() clear screen "; +collapsed:c}})})})},this.addControlOpticLabelAndColour=function(e){var f="control_node_labelandcolour",g=f+"_";uiComponentsHelper.createButton(a,"Configure Label",f,function(){modalDialogHelper.createModalChangeDialog("Change label attribute",g,[{type:"text",id:"label-attribute",text:"Vertex label attribute",value:b.getLabel()||""},{type:"decission",id:"samecolour",group:"colour",text:"Use this attribute for coloring, too",isDefault:b.getLabel()===b.getColor()},{type:"decission",id:"othercolour",group:"colour",text:"Use different attribute for coloring",isDefault:b.getLabel()!==b.getColor(),interior:[{type:"text",id:"colour-attribute",text:"Color attribute",value:b.getColor()||""}]}],function(){var a=$("#"+g+"label-attribute").attr("value"),e=$("#"+g+"colour-attribute").attr("value"),f=$("input[type='radio'][name='colour']:checked").attr("id");f===g+"samecolour"&&(e=a);var h={label:a,color:{type:"attribute",key:e}};d.applyLocalStorage(h),b.changeTo(h),void 0===c&&(c=d.createColourMappingList())})})},this.addControlOpticLabelAndColourList=function(e){var f="control_node_labelandcolourlist",g=f+"_";uiComponentsHelper.createButton(a,"Configure Label",f,function(){modalDialogHelper.createModalChangeDialog("Change label attribute",g,[{type:"extendable",id:"label",text:"Vertex label attribute",objects:b.getLabel()},{type:"decission",id:"samecolour",group:"colour",text:"Use this attribute for coloring, too",isDefault:b.getLabel()===b.getColor()},{type:"decission",id:"othercolour",group:"colour",text:"Use different attribute for coloring",isDefault:b.getLabel()!==b.getColor(),interior:[{type:"extendable",id:"colour",text:"Color attribute",objects:b.getColor()||""}]}],function(){var a=$("input[id^="+g+"label_]"),e=$("input[id^="+g+"colour_]"),f=$("input[type='radio'][name='colour']:checked").attr("id"),h=[],i=[];a.each(function(a,b){var c=$(b).val();""!==c&&h.push(c)}),e.each(function(a,b){var c=$(b).val();""!==c&&i.push(c)}),f===g+"samecolour"&&(i=h);var j={label:h,color:{type:"attribute",key:i}};d.applyLocalStorage(j),b.changeTo(j),void 0===c&&(c=d.createColourMappingList())})})},this.addAllOptics=function(){d.addControlOpticShapeNone(),d.addControlOpticShapeCircle(),d.addControlOpticShapeRect(),d.addControlOpticLabel(),d.addControlOpticSingleColour(),d.addControlOpticAttributeColour(),d.addControlOpticExpandColour()},this.addAllActions=function(){},this.addAll=function(){d.addAllOptics(),d.addAllActions()},this.createColourMappingList=function(){return void 0!==c?c:(c=document.createElement("div"),c.id="node_colour_list",e(b.getColourMapping()),b.setColourMappingListener(e),c)}}function GraphViewer(a,b,c,d,e){"use strict";if($("html").attr("xmlns:xlink","http://www.w3.org/1999/xlink"),void 0===a||void 0===a.append)throw"SVG has to be given and has to be selected using d3.select";if(void 0===b||0>=b)throw"A width greater 0 has to be given";if(void 0===c||0>=c)throw"A height greater 0 has to be given";if(void 0===d||void 0===d.type)throw"An adapter configuration has to be given";var f,g,h,i,j,k,l,m,n=this,o=[],p=[],q=function(a){if(!a)return a={},a.nodes=p,a.links=o,a.width=b,a.height=c,void(i=new ForceLayouter(a));switch(a.type.toLowerCase()){case"force":a.nodes=p,a.links=o,a.width=b,a.height=c,i=new ForceLayouter(a);break;default:throw"Sorry unknown layout type."}},r=function(a){f.setNodeLimit(a,n.start)},s=function(d){d&&(j=new ZoomManager(b,c,a,k,g,h,{},r))},t=function(a){var b=a.edgeShaper||{},c=a.nodeShaper||{},d=c.idfunc||void 0,e=a.zoom||!1;b.shape=b.shape||{type:EdgeShaper.shapes.ARROW},q(a.layouter),m=k.append("g"),h=new EdgeShaper(m,b),l=k.append("g"),g=new NodeShaper(l,c,d),i.setCombinedUpdateFunction(g,h),s(e)};switch(d.type.toLowerCase()){case"arango":d.width=b,d.height=c,f=new ArangoAdapter(p,o,this,d),f.setChildLimit(10);break;case"gharial":d.width=b,d.height=c,f=new GharialAdapter(p,o,this,d),f.setChildLimit(10);break;case"foxx":d.width=b,d.height=c,f=new FoxxAdapter(p,o,d.route,this,d);break;case"json":f=new JSONAdapter(d.path,p,o,this,b,c);break;case"preview":d.width=b,d.height=c,f=new PreviewAdapter(p,o,this,d);break;default:throw"Sorry unknown adapter type."}k=a.append("g"),t(e||{}),this.start=function(a){i.stop(),a&&(""!==$(".infoField").text()?_.each(p,function(a){_.each(f.randomNodes,function(b){a._id===b._id&&(a._expanded=!0)})}):_.each(p,function(a){a._expanded=!0})),g.drawNodes(p),h.drawEdges(o),i.start()},this.loadGraph=function(a,b){f.loadInitialNode(a,function(a){return a.errorCode?void b(a):(a._expanded=!0,n.start(),void(_.isFunction(b)&&b()))})},this.loadGraphWithRandomStart=function(a,b){f.loadRandomNode(function(b){return b.errorCode&&404===b.errorCode?void a(b):(b._expanded=!0,n.start(!0),void(_.isFunction(a)&&a()))},b)},this.loadGraphWithAdditionalNode=function(a,b,c){f.loadAdditionalNodeByAttributeValue(a,b,function(a){return a.errorCode?void c(a):(a._expanded=!0,n.start(),void(_.isFunction(c)&&c()))})},this.loadGraphWithAttributeValue=function(a,b,c){f.randomNodes=[],f.definedNodes=[],f.loadInitialNodeByAttributeValue(a,b,function(a){return a.errorCode?void c(a):(a._expanded=!0,n.start(),void(_.isFunction(c)&&c()))})},this.cleanUp=function(){g.resetColourMap(),h.resetColourMap()},this.changeWidth=function(a){i.changeWidth(a),j.changeWidth(a),f.setWidth(a)},this.dispatcherConfig={expand:{edges:o,nodes:p,startCallback:n.start,adapter:f,reshapeNodes:g.reshapeNodes},drag:{layouter:i},nodeEditor:{nodes:p,adapter:f},edgeEditor:{edges:o,adapter:f}},this.adapter=f,this.nodeShaper=g,this.edgeShaper=h,this.layouter=i,this.zoomManager=j}function Module(a){this.id=a,this.exports={},this.definition=null}function require(a){return global.module.require(a)}function print(){var a=require("internal");a.print.apply(a.print,arguments)}function ArangoConnection(){this._databaseName="_system";var a=global.document.location.pathname;if("/_db/"===a.substr(0,5)){for(var b=5,c=a.length;c>b&&"/"!==a[b];)b++;b>5&&(this._databaseName=a.substring(5,b))}}EdgeShaper.shapes=Object.freeze({NONE:0,ARROW:1}),NodeShaper.shapes=Object.freeze({NONE:0,CIRCLE:1,RECT:2,IMAGE:3});var modalDialogHelper=modalDialogHelper||{};!function(){"use strict";var a,b=function(a){$(document).bind("keypress.key13",function(b){b.which&&13===b.which&&$(a).click()})},c=function(){$(document).unbind("keypress.key13")},d=function(a,b,c,d,e){var f,g,h=function(){e(f)},i=modalDialogHelper.modalDivTemplate(a,b,c,h),j=document.createElement("tr"),k=document.createElement("th"),l=document.createElement("th"),m=document.createElement("th"),n=document.createElement("button"),o=1;f=function(){var a={};return _.each($("#"+c+"table tr:not(#first_row)"),function(b){var c=$(".keyCell input",b).val(),d=$(".valueCell input",b).val();a[c]=d}),a},i.appendChild(j),j.id="first_row",j.appendChild(k),k.className="keyCell",j.appendChild(l),l.className="valueCell",j.appendChild(m),m.className="actionCell",m.appendChild(n),n.id=c+"new",n.className="graphViewer-icon-button gv-icon-small add",g=function(a,b){var d,e,f,g=/^_(id|rev|key|from|to)/,h=document.createElement("tr"),j=document.createElement("th"),k=document.createElement("th"),l=document.createElement("th");g.test(b)||(i.appendChild(h),h.appendChild(k),k.className="keyCell",e=document.createElement("input"),e.type="text",e.id=c+b+"_key",e.value=b,k.appendChild(e),h.appendChild(l),l.className="valueCell",f=document.createElement("input"),f.type="text",f.id=c+b+"_value","object"==typeof a?f.value=JSON.stringify(a):f.value=a,l.appendChild(f),h.appendChild(j),j.className="actionCell",d=document.createElement("button"),d.id=c+b+"_delete",d.className="graphViewer-icon-button gv-icon-small delete",j.appendChild(d),d.onclick=function(){i.removeChild(h)})},n.onclick=function(){g("","new_"+o),o++},_.each(d,g),$("#"+c+"modal").modal("show")},e=function(a,b,c,d,e){var f=modalDialogHelper.modalDivTemplate(a,b,c,e),g=document.createElement("tr"),h=document.createElement("th"),i=document.createElement("pre");f.appendChild(g),g.appendChild(h),h.appendChild(i),i.className="gv-object-view",i.innerHTML=JSON.stringify(d,null,2),$("#"+c+"modal").modal("show")},f=function(a,b){var c=document.createElement("input");return c.type="text",c.id=a,c.value=b,c},g=function(a,b){var c=document.createElement("input");return c.type="checkbox",c.id=a,c.checked=b,c},h=function(a,b,c){var d=document.createElement("select");return d.id=a,_.each(_.sortBy(b,function(a){return a.toLowerCase()}),function(a){var b=document.createElement("option");b.value=a,b.selected=a===c,b.appendChild(document.createTextNode(a)),d.appendChild(b)}),d},i=function(a){var b=$(".decission_"+a),c=$("input[type='radio'][name='"+a+"']:checked").attr("id");b.each(function(){$(this).attr("decider")===c?$(this).css("display",""):$(this).css("display","none")})},j=function(b,c,d,e,f,g,h,j){var k=document.createElement("input"),l=b+c,m=document.createElement("label"),n=document.createElement("tbody");k.id=l,k.type="radio",k.name=d,k.className="gv-radio-button",m.className="radio",h.appendChild(m),m.appendChild(k),m.appendChild(document.createTextNode(e)),j.appendChild(n),$(n).toggleClass("decission_"+d,!0),$(n).attr("decider",l),_.each(g,function(c){a(n,b,c)}),f?k.checked=!0:k.checked=!1,m.onclick=function(a){i(d),a.stopPropagation()},i(d)},k=function(a,b,c,d,e,f){var g,h=[],i=a+b,j=1,k=document.createElement("th"),l=document.createElement("button"),m=document.createElement("input"),n=function(a){j++;var c,d=document.createElement("tr"),g=document.createElement("th"),k=document.createElement("th"),l=document.createElement("th"),m=document.createElement("input"),n=document.createElement("button");m.type="text",m.id=i+"_"+j,m.value=a||"",c=0===h.length?$(f):$(h[h.length-1]),c.after(d),d.appendChild(g),g.className="collectionTh capitalize",g.appendChild(document.createTextNode(b+" "+j+":")),d.appendChild(k),k.className="collectionTh",k.appendChild(m),n.id=i+"_"+j+"_remove",n.className="graphViewer-icon-button gv-icon-small delete",n.onclick=function(){e.removeChild(d),h.splice(h.indexOf(d),1)},l.appendChild(n),d.appendChild(l),h.push(d)};for(m.type="text",m.id=i+"_1",d.appendChild(m),k.appendChild(l),f.appendChild(k),l.onclick=function(){n()},l.id=i+"_addLine",l.className="graphViewer-icon-button gv-icon-small add","string"==typeof c&&c.length>0&&(c=[c]),c.length>0&&(m.value=c[0]),g=1;g'),$(".arangoFrame .outerDiv").click(function(){e.closeDocEditor()}),$(".arangoFrame .innerDiv").click(function(a){a.stopPropagation()}),$(".fa-times").click(function(){e.closeDocEditor()}),$(".arangoFrame").show(),f.customView=!0,f.customDeleteFunction=function(){window.modalView.hide(),$(".arangoFrame").hide()},$(".arangoFrame #deleteDocumentButton").click(function(){f.deleteDocumentModal()}),$(".arangoFrame #saveDocumentButton").click(function(){f.saveDocument()}),$(".arangoFrame #deleteDocumentButton").css("display","none")},closeDocEditor:function(){$(".arangoFrame .outerDiv .fa-times").remove(),$(".arangoFrame").hide()},addAardvarkJob:function(a,b){$.ajax({cache:!1,type:"POST",url:"/_admin/aardvark/job",data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a){b&&b(!1,a)},error:function(a){b&&b(!0,a)}})},deleteAardvarkJob:function(a,b){$.ajax({cache:!1,type:"DELETE",url:"/_admin/aardvark/job/"+encodeURIComponent(a),contentType:"application/json",processData:!1,success:function(a){b&&b(!1,a)},error:function(a){b&&b(!0,a)}})},deleteAllAardvarkJobs:function(a){$.ajax({cache:!1,type:"DELETE",url:"/_admin/aardvark/job",contentType:"application/json",processData:!1,success:function(b){a&&a(!1,b)},error:function(b){a&&a(!0,b)}})},getAardvarkJobs:function(a){var b;return $.ajax({cache:!1,type:"GET",url:"/_admin/aardvark/job",contentType:"application/json",processData:!1,async:!1,success:function(c){a&&a(!1,c),b=c},error:function(b){a&&a(!0,b)}}),b},getPendingJobs:function(){var a;return $.ajax({cache:!1,type:"GET",url:"/_api/job/pending",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(a){console.log("pending jobs error: "+a)}}),a},syncAndReturnUninishedAardvarkJobs:function(a){var b=this.getAardvarkJobs(),c=this.getPendingJobs(),d=[];return c.length>0?_.each(b,function(b){if(b.type===a||void 0===b.type){var e=!1;_.each(c,function(a){b.id===a&&(e=!0)}),e?d.push({collection:b.collection,id:b.id,type:b.type}):window.arangoHelper.deleteAardvarkJob(b.id)}}):this.deleteAllAardvarkJobs(),d},getRandomToken:function(){return Math.round((new Date).getTime())},isSystemAttribute:function(a){var b=this.systemAttributes();return b[a]},isSystemCollection:function(a){return"_"===a.name.substr(0,1)},setDocumentStore:function(a){this.arangoDocumentStore=a},collectionApiType:function(a,b){return(b||void 0===this.CollectionTypes[a])&&(this.CollectionTypes[a]=this.arangoDocumentStore.getCollectionInfo(a).type),3===this.CollectionTypes[a]?"edge":"document"},collectionType:function(a){if(!a||""===a.name)return"-";var b;return b=2===a.type?"document":3===a.type?"edge":"unknown",this.isSystemCollection(a)&&(b+=" (system)"),b},formatDT:function(a){var b=function(a){return 10>a?"0"+a:a};return a.getUTCFullYear()+"-"+b(a.getUTCMonth()+1)+"-"+b(a.getUTCDate())+" "+b(a.getUTCHours())+":"+b(a.getUTCMinutes())+":"+b(a.getUTCSeconds())},escapeHtml:function(a){return String(a).replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}}}(),function(){"use strict";if(!window.hasOwnProperty("TEST_BUILD")){var a=function(){var a={};return a.createTemplate=function(a){var b=$("#"+a.replace(".","\\.")).html();return{render:function(a){return _.template(b,a)}}},a};window.templateEngine=new a}}(),Module.prototype.moduleCache={},Module.prototype.moduleCache["/internal"]=new Module("/internal"),"undefined"==typeof global&&"undefined"!=typeof window&&(global=window),global.module=Module.prototype.moduleCache["/"]=new Module("/"),Module.prototype.normalise=function(a){var b,c,d,e,f;if(""===a)return this.id;for(d=a.split("/"),"."===d[0]||".."===d[0]?(e=this.id.split("/"),e.pop(),e=e.concat(d)):e=d,c=[],b=0;b "+require("internal").browserOutputBuffer,"jssuccess"),require("internal").browserOutputBuffer=""},$(global.document).ajaxSend(function(a,b,c){c.url=require("internal").arango.databasePrefix(c.url)}),global.DEFINE_MODULE=function(a,b){var c=Module.prototype.normalise(a),d=Module.prototype.moduleCache[c];d?Object.keys(d.exports).forEach(function(a){b[a]=d.exports[a]}):(d=new Module(c),Module.prototype.moduleCache[c]=d),d.exports=b}}(),module.define("underscore",function(a,b){(function(){function c(a){function b(b,c,d,e,f,g){for(;f>=0&&g>f;f+=a){var h=e?e[f]:f;d=c(d,b[h],h,b)}return d}return function(c,d,e,f){d=v(d,f,4);var g=!C(c)&&u.keys(c),h=(g||c).length,i=a>0?0:h-1;return arguments.length<3&&(e=c[g?g[i]:i],i+=a),b(c,d,e,g,i,h)}}function d(a){return function(b,c,d){c=w(c,d);for(var e=B(b),f=a>0?0:e-1;f>=0&&e>f;f+=a)if(c(b[f],f,b))return f;return-1}}function e(a,b,c){return function(d,e,f){var g=0,h=B(d);if("number"==typeof f)a>0?g=f>=0?f:Math.max(f+h,g):h=f>=0?Math.min(f+1,h):f+h+1;else if(c&&f&&h)return f=c(d,e),d[f]===e?f:-1;if(e!==e)return f=b(m.call(d,g,h),u.isNaN),f>=0?f+g:-1;for(f=a>0?g:h-1;f>=0&&h>f;f+=a)if(d[f]===e)return f;return-1}}function f(a,b){var c=H.length,d=a.constructor,e=u.isFunction(d)&&d.prototype||j,f="constructor";for(u.has(a,f)&&!u.contains(b,f)&&b.push(f);c--;)f=H[c],f in a&&a[f]!==e[f]&&!u.contains(b,f)&&b.push(f)}var g=this,h=g._,i=Array.prototype,j=Object.prototype,k=Function.prototype,l=i.push,m=i.slice,n=j.toString,o=j.hasOwnProperty,p=Array.isArray,q=Object.keys,r=k.bind,s=Object.create,t=function(){},u=function(a){return a instanceof u?a:this instanceof u?void(this._wrapped=a):new u(a)};"undefined"!=typeof a?("undefined"!=typeof b&&b.exports&&(a=b.exports=u),a._=u):g._=u,u.VERSION="1.8.3";var v=function(a,b,c){if(void 0===b)return a;switch(null==c?3:c){case 1:return function(c){return a.call(b,c)};case 2:return function(c,d){return a.call(b,c,d)};case 3:return function(c,d,e){return a.call(b,c,d,e)};case 4:return function(c,d,e,f){return a.call(b,c,d,e,f)}}return function(){return a.apply(b,arguments)}},w=function(a,b,c){return null==a?u.identity:u.isFunction(a)?v(a,b,c):u.isObject(a)?u.matcher(a):u.property(a)};u.iteratee=function(a,b){return w(a,b,1/0)};var x=function(a,b){return function(c){var d=arguments.length;if(2>d||null==c)return c;for(var e=1;d>e;e++)for(var f=arguments[e],g=a(f),h=g.length,i=0;h>i;i++){var j=g[i];b&&void 0!==c[j]||(c[j]=f[j])}return c}},y=function(a){if(!u.isObject(a))return{};if(s)return s(a);t.prototype=a;var b=new t;return t.prototype=null,b},z=function(a){return function(b){return null==b?void 0:b[a]}},A=Math.pow(2,53)-1,B=z("length"),C=function(a){var b=B(a);return"number"==typeof b&&b>=0&&A>=b};u.each=u.forEach=function(a,b,c){b=v(b,c);var d,e;if(C(a))for(d=0,e=a.length;e>d;d++)b(a[d],d,a);else{var f=u.keys(a);for(d=0,e=f.length;e>d;d++)b(a[f[d]],f[d],a)}return a},u.map=u.collect=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=Array(e),g=0;e>g;g++){var h=d?d[g]:g;f[g]=b(a[h],h,a)}return f},u.reduce=u.foldl=u.inject=c(1),u.reduceRight=u.foldr=c(-1),u.find=u.detect=function(a,b,c){var d;return d=C(a)?u.findIndex(a,b,c):u.findKey(a,b,c),void 0!==d&&-1!==d?a[d]:void 0},u.filter=u.select=function(a,b,c){var d=[];return b=w(b,c),u.each(a,function(a,c,e){b(a,c,e)&&d.push(a)}),d},u.reject=function(a,b,c){return u.filter(a,u.negate(w(b)),c)},u.every=u.all=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=0;e>f;f++){var g=d?d[f]:f;if(!b(a[g],g,a))return!1}return!0},u.some=u.any=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=0;e>f;f++){var g=d?d[f]:f;if(b(a[g],g,a))return!0}return!1},u.contains=u.includes=u.include=function(a,b,c,d){return C(a)||(a=u.values(a)),("number"!=typeof c||d)&&(c=0),u.indexOf(a,b,c)>=0},u.invoke=function(a,b){var c=m.call(arguments,2),d=u.isFunction(b);return u.map(a,function(a){var e=d?b:a[b];return null==e?e:e.apply(a,c)})},u.pluck=function(a,b){return u.map(a,u.property(b))},u.where=function(a,b){return u.filter(a,u.matcher(b))},u.findWhere=function(a,b){return u.find(a,u.matcher(b))},u.max=function(a,b,c){var d,e,f=-(1/0),g=-(1/0);if(null==b&&null!=a){a=C(a)?a:u.values(a);for(var h=0,i=a.length;i>h;h++)d=a[h],d>f&&(f=d)}else b=w(b,c),u.each(a,function(a,c,d){e=b(a,c,d),(e>g||e===-(1/0)&&f===-(1/0))&&(f=a,g=e)});return f},u.min=function(a,b,c){var d,e,f=1/0,g=1/0;if(null==b&&null!=a){a=C(a)?a:u.values(a);for(var h=0,i=a.length;i>h;h++)d=a[h],f>d&&(f=d)}else b=w(b,c),u.each(a,function(a,c,d){e=b(a,c,d),(g>e||e===1/0&&f===1/0)&&(f=a,g=e)});return f},u.shuffle=function(a){for(var b,c=C(a)?a:u.values(a),d=c.length,e=Array(d),f=0;d>f;f++)b=u.random(0,f),b!==f&&(e[f]=e[b]),e[b]=c[f];return e},u.sample=function(a,b,c){return null==b||c?(C(a)||(a=u.values(a)),a[u.random(a.length-1)]):u.shuffle(a).slice(0,Math.max(0,b))},u.sortBy=function(a,b,c){return b=w(b,c),u.pluck(u.map(a,function(a,c,d){return{value:a,index:c,criteria:b(a,c,d)}}).sort(function(a,b){var c=a.criteria,d=b.criteria;if(c!==d){if(c>d||void 0===c)return 1;if(d>c||void 0===d)return-1}return a.index-b.index}),"value")};var D=function(a){return function(b,c,d){var e={};return c=w(c,d),u.each(b,function(d,f){var g=c(d,f,b);a(e,d,g)}),e}};u.groupBy=D(function(a,b,c){u.has(a,c)?a[c].push(b):a[c]=[b]}),u.indexBy=D(function(a,b,c){a[c]=b}),u.countBy=D(function(a,b,c){u.has(a,c)?a[c]++:a[c]=1}),u.toArray=function(a){return a?u.isArray(a)?m.call(a):C(a)?u.map(a,u.identity):u.values(a):[]},u.size=function(a){return null==a?0:C(a)?a.length:u.keys(a).length},u.partition=function(a,b,c){b=w(b,c);var d=[],e=[];return u.each(a,function(a,c,f){(b(a,c,f)?d:e).push(a)}),[d,e]},u.first=u.head=u.take=function(a,b,c){return null==a?void 0:null==b||c?a[0]:u.initial(a,a.length-b)},u.initial=function(a,b,c){return m.call(a,0,Math.max(0,a.length-(null==b||c?1:b)))},u.last=function(a,b,c){ +return null==a?void 0:null==b||c?a[a.length-1]:u.rest(a,Math.max(0,a.length-b))},u.rest=u.tail=u.drop=function(a,b,c){return m.call(a,null==b||c?1:b)},u.compact=function(a){return u.filter(a,u.identity)};var E=function(a,b,c,d){for(var e=[],f=0,g=d||0,h=B(a);h>g;g++){var i=a[g];if(C(i)&&(u.isArray(i)||u.isArguments(i))){b||(i=E(i,b,c));var j=0,k=i.length;for(e.length+=k;k>j;)e[f++]=i[j++]}else c||(e[f++]=i)}return e};u.flatten=function(a,b){return E(a,b,!1)},u.without=function(a){return u.difference(a,m.call(arguments,1))},u.uniq=u.unique=function(a,b,c,d){u.isBoolean(b)||(d=c,c=b,b=!1),null!=c&&(c=w(c,d));for(var e=[],f=[],g=0,h=B(a);h>g;g++){var i=a[g],j=c?c(i,g,a):i;b?(g&&f===j||e.push(i),f=j):c?u.contains(f,j)||(f.push(j),e.push(i)):u.contains(e,i)||e.push(i)}return e},u.union=function(){return u.uniq(E(arguments,!0,!0))},u.intersection=function(a){for(var b=[],c=arguments.length,d=0,e=B(a);e>d;d++){var f=a[d];if(!u.contains(b,f)){for(var g=1;c>g&&u.contains(arguments[g],f);g++);g===c&&b.push(f)}}return b},u.difference=function(a){var b=E(arguments,!0,!0,1);return u.filter(a,function(a){return!u.contains(b,a)})},u.zip=function(){return u.unzip(arguments)},u.unzip=function(a){for(var b=a&&u.max(a,B).length||0,c=Array(b),d=0;b>d;d++)c[d]=u.pluck(a,d);return c},u.object=function(a,b){for(var c={},d=0,e=B(a);e>d;d++)b?c[a[d]]=b[d]:c[a[d][0]]=a[d][1];return c},u.findIndex=d(1),u.findLastIndex=d(-1),u.sortedIndex=function(a,b,c,d){c=w(c,d,1);for(var e=c(b),f=0,g=B(a);g>f;){var h=Math.floor((f+g)/2);c(a[h])f;f++,a+=c)e[f]=a;return e};var F=function(a,b,c,d,e){if(!(d instanceof b))return a.apply(c,e);var f=y(a.prototype),g=a.apply(f,e);return u.isObject(g)?g:f};u.bind=function(a,b){if(r&&a.bind===r)return r.apply(a,m.call(arguments,1));if(!u.isFunction(a))throw new TypeError("Bind must be called on a function");var c=m.call(arguments,2),d=function(){return F(a,d,b,this,c.concat(m.call(arguments)))};return d},u.partial=function(a){var b=m.call(arguments,1),c=function(){for(var d=0,e=b.length,f=Array(e),g=0;e>g;g++)f[g]=b[g]===u?arguments[d++]:b[g];for(;d=d)throw new Error("bindAll must be passed function names");for(b=1;d>b;b++)c=arguments[b],a[c]=u.bind(a[c],a);return a},u.memoize=function(a,b){var c=function(d){var e=c.cache,f=""+(b?b.apply(this,arguments):d);return u.has(e,f)||(e[f]=a.apply(this,arguments)),e[f]};return c.cache={},c},u.delay=function(a,b){var c=m.call(arguments,2);return setTimeout(function(){return a.apply(null,c)},b)},u.defer=u.partial(u.delay,u,1),u.throttle=function(a,b,c){var d,e,f,g=null,h=0;c||(c={});var i=function(){h=c.leading===!1?0:u.now(),g=null,f=a.apply(d,e),g||(d=e=null)};return function(){var j=u.now();h||c.leading!==!1||(h=j);var k=b-(j-h);return d=this,e=arguments,0>=k||k>b?(g&&(clearTimeout(g),g=null),h=j,f=a.apply(d,e),g||(d=e=null)):g||c.trailing===!1||(g=setTimeout(i,k)),f}},u.debounce=function(a,b,c){var d,e,f,g,h,i=function(){var j=u.now()-g;b>j&&j>=0?d=setTimeout(i,b-j):(d=null,c||(h=a.apply(f,e),d||(f=e=null)))};return function(){f=this,e=arguments,g=u.now();var j=c&&!d;return d||(d=setTimeout(i,b)),j&&(h=a.apply(f,e),f=e=null),h}},u.wrap=function(a,b){return u.partial(b,a)},u.negate=function(a){return function(){return!a.apply(this,arguments)}},u.compose=function(){var a=arguments,b=a.length-1;return function(){for(var c=b,d=a[b].apply(this,arguments);c--;)d=a[c].call(this,d);return d}},u.after=function(a,b){return function(){return--a<1?b.apply(this,arguments):void 0}},u.before=function(a,b){var c;return function(){return--a>0&&(c=b.apply(this,arguments)),1>=a&&(b=null),c}},u.once=u.partial(u.before,2);var G=!{toString:null}.propertyIsEnumerable("toString"),H=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"];u.keys=function(a){if(!u.isObject(a))return[];if(q)return q(a);var b=[];for(var c in a)u.has(a,c)&&b.push(c);return G&&f(a,b),b},u.allKeys=function(a){if(!u.isObject(a))return[];var b=[];for(var c in a)b.push(c);return G&&f(a,b),b},u.values=function(a){for(var b=u.keys(a),c=b.length,d=Array(c),e=0;c>e;e++)d[e]=a[b[e]];return d},u.mapObject=function(a,b,c){b=w(b,c);for(var d,e=u.keys(a),f=e.length,g={},h=0;f>h;h++)d=e[h],g[d]=b(a[d],d,a);return g},u.pairs=function(a){for(var b=u.keys(a),c=b.length,d=Array(c),e=0;c>e;e++)d[e]=[b[e],a[b[e]]];return d},u.invert=function(a){for(var b={},c=u.keys(a),d=0,e=c.length;e>d;d++)b[a[c[d]]]=c[d];return b},u.functions=u.methods=function(a){var b=[];for(var c in a)u.isFunction(a[c])&&b.push(c);return b.sort()},u.extend=x(u.allKeys),u.extendOwn=u.assign=x(u.keys),u.findKey=function(a,b,c){b=w(b,c);for(var d,e=u.keys(a),f=0,g=e.length;g>f;f++)if(d=e[f],b(a[d],d,a))return d},u.pick=function(a,b,c){var d,e,f={},g=a;if(null==g)return f;u.isFunction(b)?(e=u.allKeys(g),d=v(b,c)):(e=E(arguments,!1,!1,1),d=function(a,b,c){return b in c},g=Object(g));for(var h=0,i=e.length;i>h;h++){var j=e[h],k=g[j];d(k,j,g)&&(f[j]=k)}return f},u.omit=function(a,b,c){if(u.isFunction(b))b=u.negate(b);else{var d=u.map(E(arguments,!1,!1,1),String);b=function(a,b){return!u.contains(d,b)}}return u.pick(a,b,c)},u.defaults=x(u.allKeys,!0),u.create=function(a,b){var c=y(a);return b&&u.extendOwn(c,b),c},u.clone=function(a){return u.isObject(a)?u.isArray(a)?a.slice():u.extend({},a):a},u.tap=function(a,b){return b(a),a},u.isMatch=function(a,b){var c=u.keys(b),d=c.length;if(null==a)return!d;for(var e=Object(a),f=0;d>f;f++){var g=c[f];if(b[g]!==e[g]||!(g in e))return!1}return!0};var I=function(a,b,c,d){if(a===b)return 0!==a||1/a===1/b;if(null==a||null==b)return a===b;a instanceof u&&(a=a._wrapped),b instanceof u&&(b=b._wrapped);var e=n.call(a);if(e!==n.call(b))return!1;switch(e){case"[object RegExp]":case"[object String]":return""+a==""+b;case"[object Number]":return+a!==+a?+b!==+b:0===+a?1/+a===1/b:+a===+b;case"[object Date]":case"[object Boolean]":return+a===+b}var f="[object Array]"===e;if(!f){if("object"!=typeof a||"object"!=typeof b)return!1;var g=a.constructor,h=b.constructor;if(g!==h&&!(u.isFunction(g)&&g instanceof g&&u.isFunction(h)&&h instanceof h)&&"constructor"in a&&"constructor"in b)return!1}c=c||[],d=d||[];for(var i=c.length;i--;)if(c[i]===a)return d[i]===b;if(c.push(a),d.push(b),f){if(i=a.length,i!==b.length)return!1;for(;i--;)if(!I(a[i],b[i],c,d))return!1}else{var j,k=u.keys(a);if(i=k.length,u.keys(b).length!==i)return!1;for(;i--;)if(j=k[i],!u.has(b,j)||!I(a[j],b[j],c,d))return!1}return c.pop(),d.pop(),!0};u.isEqual=function(a,b){return I(a,b)},u.isEmpty=function(a){return null==a?!0:C(a)&&(u.isArray(a)||u.isString(a)||u.isArguments(a))?0===a.length:0===u.keys(a).length},u.isElement=function(a){return!(!a||1!==a.nodeType)},u.isArray=p||function(a){return"[object Array]"===n.call(a)},u.isObject=function(a){var b=typeof a;return"function"===b||"object"===b&&!!a},u.each(["Arguments","Function","String","Number","Date","RegExp","Error"],function(a){u["is"+a]=function(b){return n.call(b)==="[object "+a+"]"}}),u.isArguments(arguments)||(u.isArguments=function(a){return u.has(a,"callee")}),"function"!=typeof/./&&"object"!=typeof Int8Array&&(u.isFunction=function(a){return"function"==typeof a||!1}),u.isFinite=function(a){return isFinite(a)&&!isNaN(parseFloat(a))},u.isNaN=function(a){return u.isNumber(a)&&a!==+a},u.isBoolean=function(a){return a===!0||a===!1||"[object Boolean]"===n.call(a)},u.isNull=function(a){return null===a},u.isUndefined=function(a){return void 0===a},u.has=function(a,b){return null!=a&&o.call(a,b)},u.noConflict=function(){return g._=h,this},u.identity=function(a){return a},u.constant=function(a){return function(){return a}},u.noop=function(){},u.property=z,u.propertyOf=function(a){return null==a?function(){}:function(b){return a[b]}},u.matcher=u.matches=function(a){return a=u.extendOwn({},a),function(b){return u.isMatch(b,a)}},u.times=function(a,b,c){var d=Array(Math.max(0,a));b=v(b,c,1);for(var e=0;a>e;e++)d[e]=b(e);return d},u.random=function(a,b){return null==b&&(b=a,a=0),a+Math.floor(Math.random()*(b-a+1))},u.now=Date.now||function(){return(new Date).getTime()};var J={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},K=u.invert(J),L=function(a){var b=function(b){return a[b]},c="(?:"+u.keys(a).join("|")+")",d=RegExp(c),e=RegExp(c,"g");return function(a){return a=null==a?"":""+a,d.test(a)?a.replace(e,b):a}};u.escape=L(J),u.unescape=L(K),u.result=function(a,b,c){var d=null==a?void 0:a[b];return void 0===d&&(d=c),u.isFunction(d)?d.call(a):d};var M=0;u.uniqueId=function(a){var b=++M+"";return a?a+b:b},u.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var N=/(.)^/,O={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},P=/\\|'|\r|\n|\u2028|\u2029/g,Q=function(a){return"\\"+O[a]};u.template=function(a,b,c){!b&&c&&(b=c),b=u.defaults({},b,u.templateSettings);var d=RegExp([(b.escape||N).source,(b.interpolate||N).source,(b.evaluate||N).source].join("|")+"|$","g"),e=0,f="__p+='";a.replace(d,function(b,c,d,g,h){return f+=a.slice(e,h).replace(P,Q),e=h+b.length,c?f+="'+\n((__t=("+c+"))==null?'':_.escape(__t))+\n'":d?f+="'+\n((__t=("+d+"))==null?'':__t)+\n'":g&&(f+="';\n"+g+"\n__p+='"),b}),f+="';\n",b.variable||(f="with(obj||{}){\n"+f+"}\n"),f="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+f+"return __p;\n";try{var g=new Function(b.variable||"obj","_",f)}catch(h){throw h.source=f,h}var i=function(a){return g.call(this,a,u)},j=b.variable||"obj";return i.source="function("+j+"){\n"+f+"}",i},u.chain=function(a){var b=u(a);return b._chain=!0,b};var R=function(a,b){return a._chain?u(b).chain():b};u.mixin=function(a){u.each(u.functions(a),function(b){var c=u[b]=a[b];u.prototype[b]=function(){var a=[this._wrapped];return l.apply(a,arguments),R(this,c.apply(u,a))}})},u.mixin(u),u.each(["pop","push","reverse","shift","sort","splice","unshift"],function(a){var b=i[a];u.prototype[a]=function(){var c=this._wrapped;return b.apply(c,arguments),"shift"!==a&&"splice"!==a||0!==c.length||delete c[0],R(this,c)}}),u.each(["concat","join","slice"],function(a){var b=i[a];u.prototype[a]=function(){return R(this,b.apply(this._wrapped,arguments))}}),u.prototype.value=function(){return this._wrapped},u.prototype.valueOf=u.prototype.toJSON=u.prototype.value,u.prototype.toString=function(){return""+this._wrapped},"function"==typeof define&&define.amd&&define("underscore",[],function(){return u})}).call(this)}),global.DEFINE_MODULE("internal",function(){"use strict";function a(a){if(i.hasOwnProperty(a))return i[a];var b,c=a.charCodeAt(0);return b=16>c?"\\u000":256>c?"\\u00":4096>c?"\\u0":"\\u",b+=c.toString(16),i[a]=b,b}function b(b){return'"'+b.replace(n,a)+'"'}function c(a){var b,c="";if(a.prettyPrint)for(c+="\n",b=0;b=b.emit&&(h.output(b.output),b.output=""),b.path=i,f=", "}b.level=e-1,b.output+=" ",c(b),d&&(b.output+=j.COLOR_PUNCTUATION),b.output+="]",d&&(b.output+=j.COLOR_RESET)}}function e(a,d){var e=d.useColor,f=" ";e&&(d.output+=j.COLOR_PUNCTUATION),d.output+="{",e&&(d.output+=j.COLOR_RESET);var g=d.level+1;d.level=g;var i;try{i=Object.keys(a)}catch(k){i=[]}for(var l=0,n=i.length;n>l;++l){var o=i[l],p=a[o];e&&(d.output+=j.COLOR_PUNCTUATION),d.output+=f,e&&(d.output+=j.COLOR_RESET),c(d),e&&(d.output+=j.COLOR_INDEX),d.output+=b(o),e&&(d.output+=j.COLOR_RESET),d.output+=" : ";var q=d.path;d.path+="["+o+"]",m(p,d),d.path=q,f=", ",d.emit&&d.output.length>=d.emit&&(h.output(d.output),d.output="")}d.level=g-1,d.output+=" ",c(d),e&&(d.output+=j.COLOR_PUNCTUATION),d.output+="}",e&&(d.output+=j.COLOR_RESET)}function f(){for(var a=0;a0&&a(" "),"string"==typeof arguments[b])a(arguments[b]);else{var c={customInspect:!0,emit:16384,level:0,limitString:g.limitString,names:[],output:"",path:"~",prettyPrint:l,seen:[],showFunction:!1,useColor:k,useToString:!0};m(arguments[b],c),a(c.output)}a("\n")}var h={};global.ArangoError?(h.ArangoError=global.ArangoError,delete global.ArangoError):(h.ArangoError=function(a){void 0!==a&&(this.error=a.error,this.code=a.code,this.errorNum=a.errorNum,this.errorMessage=a.errorMessage)},h.ArangoError.prototype=new Error),Object.defineProperty(h.ArangoError.prototype,"message",{configurable:!0,enumerable:!0,get:function(){return this.errorMessage}}),h.ArangoError.prototype.name="ArangoError",h.ArangoError.prototype._PRINT=function(a){a.output+="["+this.toString()+"]"},h.ArangoError.prototype.toString=function(){return this.name+" "+this.errorNum+": "+this.message},h.threadNumber=0,global.THREAD_NUMBER&&(h.threadNumber=global.THREAD_NUMBER,delete global.THREAD_NUMBER),h.developmentMode=!1,h.quiet=!1,global.ARANGO_QUIET&&(h.quiet=global.ARANGO_QUIET,delete global.ARANGO_QUIET),h.valgrind=!1,global.VALGRIND&&(h.valgrind=global.VALGRIND,delete global.VALGRIND),h.coverage=!1,global.COVERAGE&&(h.coverage=global.COVERAGE,delete global.COVERAGE),h.version="unknown",global.VERSION&&(h.version=global.VERSION,delete global.VERSION),h.platform="unknown",global.SYS_PLATFORM&&(h.platform=global.SYS_PLATFORM,delete global.SYS_PLATFORM),h.bytesSentDistribution=[],global.BYTES_SENT_DISTRIBUTION&&(h.bytesSentDistribution=global.BYTES_SENT_DISTRIBUTION,delete global.BYTES_SENT_DISTRIBUTION),h.bytesReceivedDistribution=[],global.BYTES_RECEIVED_DISTRIBUTION&&(h.bytesReceivedDistribution=global.BYTES_RECEIVED_DISTRIBUTION,delete global.BYTES_RECEIVED_DISTRIBUTION),h.connectionTimeDistribution=[],global.CONNECTION_TIME_DISTRIBUTION&&(h.connectionTimeDistribution=global.CONNECTION_TIME_DISTRIBUTION,delete global.CONNECTION_TIME_DISTRIBUTION),h.requestTimeDistribution=[],global.REQUEST_TIME_DISTRIBUTION&&(h.requestTimeDistribution=global.REQUEST_TIME_DISTRIBUTION,delete global.REQUEST_TIME_DISTRIBUTION),h.startupPath="",global.STARTUP_PATH&&(h.startupPath=global.STARTUP_PATH,delete global.STARTUP_PATH),""===h.startupPath&&(h.startupPath="."),global.CONFIGURE_ENDPOINT&&(h.configureEndpoint=global.CONFIGURE_ENDPOINT,delete global.CONFIGURE_ENDPOINT),global.REMOVE_ENDPOINT&&(h.removeEndpoint=global.REMOVE_ENDPOINT,delete global.REMOVE_ENDPOINT),global.LIST_ENDPOINTS&&(h.listEndpoints=global.LIST_ENDPOINTS,delete global.LIST_ENDPOINTS),global.SYS_BASE64DECODE&&(h.base64Decode=global.SYS_BASE64DECODE,delete global.SYS_BASE64DECODE),global.SYS_BASE64ENCODE&&(h.base64Encode=global.SYS_BASE64ENCODE,delete global.SYS_BASE64ENCODE),global.SYS_DEBUG_SEGFAULT&&(h.debugSegfault=global.SYS_DEBUG_SEGFAULT,delete global.SYS_DEBUG_SEGFAULT),global.SYS_DEBUG_SET_FAILAT&&(h.debugSetFailAt=global.SYS_DEBUG_SET_FAILAT,delete global.SYS_DEBUG_SET_FAILAT),global.SYS_DEBUG_REMOVE_FAILAT&&(h.debugRemoveFailAt=global.SYS_DEBUG_REMOVE_FAILAT,delete global.SYS_DEBUG_REMOVE_FAILAT),global.SYS_DEBUG_CLEAR_FAILAT&&(h.debugClearFailAt=global.SYS_DEBUG_CLEAR_FAILAT,delete global.SYS_DEBUG_CLEAR_FAILAT),global.SYS_DEBUG_CAN_USE_FAILAT&&(h.debugCanUseFailAt=global.SYS_DEBUG_CAN_USE_FAILAT,delete global.SYS_DEBUG_CAN_USE_FAILAT),global.SYS_DOWNLOAD&&(h.download=global.SYS_DOWNLOAD,delete global.SYS_DOWNLOAD),global.SYS_EXECUTE&&(h.executeScript=global.SYS_EXECUTE,delete global.SYS_EXECUTE),global.SYS_GET_CURRENT_REQUEST&&(h.getCurrentRequest=global.SYS_GET_CURRENT_REQUEST,delete global.SYS_GET_CURRENT_REQUEST),global.SYS_GET_CURRENT_RESPONSE&&(h.getCurrentResponse=global.SYS_GET_CURRENT_RESPONSE,delete global.SYS_GET_CURRENT_RESPONSE),h.extend=function(a,b){return Object.getOwnPropertyNames(b).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))}),a},global.SYS_LOAD&&(h.load=global.SYS_LOAD,delete global.SYS_LOAD),global.SYS_LOG_LEVEL&&(h.logLevel=global.SYS_LOG_LEVEL,delete global.SYS_LOG_LEVEL),global.SYS_MD5&&(h.md5=global.SYS_MD5,delete global.SYS_MD5),global.SYS_GEN_RANDOM_NUMBERS&&(h.genRandomNumbers=global.SYS_GEN_RANDOM_NUMBERS,delete global.SYS_GEN_RANDOM_NUMBERS),global.SYS_GEN_RANDOM_ALPHA_NUMBERS&&(h.genRandomAlphaNumbers=global.SYS_GEN_RANDOM_ALPHA_NUMBERS,delete global.SYS_GEN_RANDOM_ALPHA_NUMBERS),global.SYS_GEN_RANDOM_SALT&&(h.genRandomSalt=global.SYS_GEN_RANDOM_SALT,delete global.SYS_GEN_RANDOM_SALT),global.SYS_HMAC&&(h.hmac=global.SYS_HMAC,delete global.SYS_HMAC),global.SYS_PBKDF2&&(h.pbkdf2=global.SYS_PBKDF2,delete global.SYS_PBKDF2),global.SYS_CREATE_NONCE&&(h.createNonce=global.SYS_CREATE_NONCE,delete global.SYS_CREATE_NONCE),global.SYS_CHECK_AND_MARK_NONCE&&(h.checkAndMarkNonce=global.SYS_CHECK_AND_MARK_NONCE,delete global.SYS_CHECK_AND_MARK_NONCE),global.SYS_OUTPUT&&(h.stdOutput=global.SYS_OUTPUT,h.output=h.stdOutput,delete global.SYS_OUTPUT),global.SYS_PARSE&&(h.parse=global.SYS_PARSE,delete global.SYS_PARSE),global.SYS_PARSE_FILE&&(h.parseFile=global.SYS_PARSE_FILE,delete global.SYS_PARSE_FILE),global.SYS_PROCESS_STATISTICS&&(h.processStatistics=global.SYS_PROCESS_STATISTICS,delete global.SYS_PROCESS_STATISTICS),global.SYS_RAND&&(h.rand=global.SYS_RAND,delete global.SYS_RAND),global.SYS_SHA512&&(h.sha512=global.SYS_SHA512,delete global.SYS_SHA512),global.SYS_SHA384&&(h.sha384=global.SYS_SHA384,delete global.SYS_SHA384),global.SYS_SHA256&&(h.sha256=global.SYS_SHA256,delete global.SYS_SHA256),global.SYS_SHA224&&(h.sha224=global.SYS_SHA224,delete global.SYS_SHA224),global.SYS_SHA1&&(h.sha1=global.SYS_SHA1,delete global.SYS_SHA1),global.SYS_SERVER_STATISTICS&&(h.serverStatistics=global.SYS_SERVER_STATISTICS,delete global.SYS_SERVER_STATISTICS),global.SYS_SLEEP&&(h.sleep=global.SYS_SLEEP,delete global.SYS_SLEEP),global.SYS_TIME&&(h.time=global.SYS_TIME,delete global.SYS_TIME),global.SYS_WAIT&&(h.wait=global.SYS_WAIT,delete global.SYS_WAIT),global.SYS_IMPORT_CSV_FILE&&(h.importCsvFile=global.SYS_IMPORT_CSV_FILE,delete global.SYS_IMPORT_CSV_FILE),global.SYS_IMPORT_JSON_FILE&&(h.importJsonFile=global.SYS_IMPORT_JSON_FILE,delete global.SYS_IMPORT_JSON_FILE),global.SYS_PROCESS_CSV_FILE&&(h.processCsvFile=global.SYS_PROCESS_CSV_FILE,delete global.SYS_PROCESS_CSV_FILE),global.SYS_PROCESS_JSON_FILE&&(h.processJsonFile=global.SYS_PROCESS_JSON_FILE,delete global.SYS_PROCESS_JSON_FILE),global.SYS_CLIENT_STATISTICS&&(h.clientStatistics=global.SYS_CLIENT_STATISTICS,delete global.SYS_CLIENT_STATISTICS),global.SYS_HTTP_STATISTICS&&(h.httpStatistics=global.SYS_HTTP_STATISTICS,delete global.SYS_HTTP_STATISTICS),global.SYS_EXECUTE_EXTERNAL&&(h.executeExternal=global.SYS_EXECUTE_EXTERNAL,delete global.SYS_EXECUTE_EXTERNAL),global.SYS_EXECUTE_EXTERNAL_AND_WAIT&&(h.executeExternalAndWait=global.SYS_EXECUTE_EXTERNAL_AND_WAIT,delete global.SYS_EXECUTE_EXTERNAL_AND_WAIT),global.SYS_KILL_EXTERNAL&&(h.killExternal=global.SYS_KILL_EXTERNAL,delete global.SYS_KILL_EXTERNAL),global.SYS_STATUS_EXTERNAL&&(h.statusExternal=global.SYS_STATUS_EXTERNAL,delete global.SYS_STATUS_EXTERNAL),global.SYS_REGISTER_TASK&&(h.registerTask=global.SYS_REGISTER_TASK,delete global.SYS_REGISTER_TASK),global.SYS_UNREGISTER_TASK&&(h.unregisterTask=global.SYS_UNREGISTER_TASK,delete global.SYS_UNREGISTER_TASK),global.SYS_GET_TASK&&(h.getTask=global.SYS_GET_TASK,delete global.SYS_GET_TASK),global.SYS_TEST_PORT&&(h.testPort=global.SYS_TEST_PORT,delete global.SYS_TEST_PORT),global.SYS_IS_IP&&(h.isIP=global.SYS_IS_IP,delete global.SYS_IS_IP),h.unitTests=function(){return global.SYS_UNIT_TESTS},h.setUnitTestsResult=function(a){global.SYS_UNIT_TESTS_RESULT=a},h.toArgv=function(a,b){"undefined"==typeof b&&(b=!1);var c=[];for(var d in a)if(a.hasOwnProperty(d))if("commandSwitches"===d){for(var e="",f=0;f1?c.push(a[d][f]):e+=a[d][f];e.length>0&&c.push(e)}else"flatCommands"===d?c=c.concat(a[d]):b?c.push("--"+d+"="+a[d]):(c.push("--"+d),a[d]!==!1?a[d]!==!0?c.push(a[d]):c.push("true"):c.push("false"));return c},h.parseArgv=function(a,b){function c(b,d,e){if(d.indexOf(":")>0){var f=d.indexOf(":"),h=d.slice(0,f);b.hasOwnProperty(h)||(b[h]={}),c(b[h],d.slice(f+1,d.length),e)}else"true"===a[g+1]?b[d]=!0:"false"===a[g+1]?b[d]=!1:isNaN(a[g+1])?b[d]=a[g+1]:b[d]=parseInt(a[g+1])}function d(a,b){a.hasOwnProperty("commandSwitches")||(a.commandSwitches=[]),a.commandSwitches.push(b)}function e(a,b){for(var c=0;c2&&"--"===j.slice(0,2)){var k=j.slice(2,j.length);a.length>g&&"-"!==a[g+1].slice(0,1)?(c(i,k,a[g+1]),g++):d(i,k)}else"--"===j?h=!0:j.length>1&&"-"===j.slice(0,1)?e(i,j.slice(1,j.length)):f(i,j)}return i},h.COLORS={},global.COLORS?(h.COLORS=global.COLORS,delete global.COLORS):["COLOR_RED","COLOR_BOLD_RED","COLOR_GREEN","COLOR_BOLD_GREEN","COLOR_BLUE","COLOR_BOLD_BLUE","COLOR_YELLOW","COLOR_BOLD_YELLOW","COLOR_WHITE","COLOR_BOLD_WHITE","COLOR_CYAN","COLOR_BOLD_CYAN","COLOR_MAGENTA","COLOR_BOLD_MAGENTA","COLOR_BLACK","COLOR_BOLD_BLACK","COLOR_BLINK","COLOR_BRIGHT","COLOR_RESET"].forEach(function(a){h.COLORS[a]=""}),h.COLORS.COLOR_PUNCTUATION=h.COLORS.COLOR_RESET,h.COLORS.COLOR_STRING=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_NUMBER=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_INDEX=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_TRUE=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_FALSE=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_NULL=h.COLORS.COLOR_BRIGHT,h.COLORS.COLOR_UNDEFINED=h.COLORS.COLOR_BRIGHT;var i={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},j=h.COLORS,k=!1;global.COLOR_OUTPUT&&(k=global.COLOR_OUTPUT,delete global.COLOR_OUTPUT);var l=!1;global.PRETTY_PRINT&&(l=global.PRETTY_PRINT,delete global.PRETTY_PRINT);var m,n=/[\\\"\x00-\x1f]/g,o=/function ([^\(]*)?\(\) \{ \[native code\] \}/,p=/function ([^\(]*)?\((.*)\) \{/;h.printRecursive=m=function(a,c){var f=c.useColor,g=c.customInspect,i=c.useToString,k=c.limitString,l=c.showFunction;"undefined"==typeof c.seen&&(c.seen=[],c.names=[]);var m=c.seen.indexOf(a);if(m>=0)c.output+=c.names[m];else if(a&&(a instanceof Object||"object"==typeof a&&null===Object.getPrototypeOf(a)))if(c.seen.push(a),c.names.push(c.path),g&&"function"==typeof a._PRINT)a._PRINT(c),c.emit&&c.output.length>=c.emit&&(h.output(c.output),c.output="");else if(a instanceof Array)d(a,c);else if(a.toString===Object.prototype.toString||"object"==typeof a&&null===Object.getPrototypeOf(a)){var n=!1;try{(a instanceof Set||a instanceof Map||a instanceof WeakSet||a instanceof WeakMap||"function"==typeof a[Symbol.iterator])&&(c.output+=a.toString(),n=!0)}catch(q){}n||e(a,c),c.emit&&c.output.length>=c.emit&&(h.output(c.output),c.output="")}else if("function"==typeof a)try{var r=a.toString();if(c.level>0&&!l){var s=r.split("\n"),t=s[0],u=o.exec(t);null!==u?void 0===u[1]?c.output+="function { [native code] }":c.output+="function "+u[1]+" { [native code] }":(u=p.exec(t),null!==u?void 0===u[1]?c.output+="function ("+u[2]+") { ... }":c.output+="function "+u[1]+" ("+u[2]+") { ... }":(t=t.substr(8,t.length-10).trim(),c.output+='[Function "'+t+'" ...]'))}else c.output+=r}catch(v){h.stdOutput(String(v)),c.output+="[Function]"}else if(i&&"function"==typeof a.toString)try{c.output+=a.toString()}catch(w){c.output+="[Object ",e(a,c),c.output+="]"}else c.output+="[Object ",e(a,c),c.output+="]";else void 0===a?(f&&(c.output+=j.COLOR_UNDEFINED),c.output+="undefined",f&&(c.output+=j.COLOR_RESET)):"string"==typeof a?(f&&(c.output+=j.COLOR_STRING),k&&k0&&a(" "),"string"==typeof arguments[c])a(arguments[c]);else{var d={names:[],seen:[],path:"~",level:0,output:"",prettyPrint:!1,useColor:!1,customInspect:!0};b(arguments[c],d),a(d.output)}a("\n")},global.start_pretty_print=function(){require("internal").startPrettyPrint()},global.stop_pretty_print=function(){require("internal").stopPrettyPrint()},global.start_color_print=function(a){require("internal").startColorPrint(a,!1)},global.stop_color_print=function(){require("internal").stopColorPrint()},global.EXPORTS_SLOW_BUFFER&&(Object.keys(global.EXPORTS_SLOW_BUFFER).forEach(function(a){h[a]=global.EXPORTS_SLOW_BUFFER[a]}),delete global.EXPORTS_SLOW_BUFFER),global.APP_PATH&&(h.appPath=global.APP_PATH,delete global.APP_PATH),h}()),function(){"use strict";var a=require("internal");a.errors={ERROR_NO_ERROR:{code:0,message:"no error"},ERROR_FAILED:{code:1,message:"failed"},ERROR_SYS_ERROR:{code:2,message:"system error"},ERROR_OUT_OF_MEMORY:{code:3,message:"out of memory"},ERROR_INTERNAL:{code:4,message:"internal error"},ERROR_ILLEGAL_NUMBER:{code:5,message:"illegal number"},ERROR_NUMERIC_OVERFLOW:{code:6,message:"numeric overflow"},ERROR_ILLEGAL_OPTION:{code:7,message:"illegal option"},ERROR_DEAD_PID:{code:8,message:"dead process identifier"},ERROR_NOT_IMPLEMENTED:{code:9,message:"not implemented"},ERROR_BAD_PARAMETER:{code:10,message:"bad parameter"},ERROR_FORBIDDEN:{code:11,message:"forbidden"},ERROR_OUT_OF_MEMORY_MMAP:{code:12,message:"out of memory in mmap"},ERROR_CORRUPTED_CSV:{code:13,message:"csv is corrupt"},ERROR_FILE_NOT_FOUND:{code:14,message:"file not found"},ERROR_CANNOT_WRITE_FILE:{code:15,message:"cannot write file"},ERROR_CANNOT_OVERWRITE_FILE:{code:16,message:"cannot overwrite file"},ERROR_TYPE_ERROR:{code:17,message:"type error"},ERROR_LOCK_TIMEOUT:{code:18,message:"lock timeout"},ERROR_CANNOT_CREATE_DIRECTORY:{code:19,message:"cannot create directory"},ERROR_CANNOT_CREATE_TEMP_FILE:{code:20,message:"cannot create temporary file"},ERROR_REQUEST_CANCELED:{code:21,message:"canceled request"},ERROR_DEBUG:{code:22,message:"intentional debug error"},ERROR_AID_NOT_FOUND:{code:23,message:"internal error with attribute ID in shaper"},ERROR_LEGEND_INCOMPLETE:{code:24,message:"internal error if a legend could not be created"},ERROR_IP_ADDRESS_INVALID:{code:25,message:"IP address is invalid"},ERROR_LEGEND_NOT_IN_WAL_FILE:{code:26,message:"internal error if a legend for a marker does not yet exist in the same WAL file"},ERROR_FILE_EXISTS:{code:27,message:"file exists"},ERROR_LOCKED:{code:28,message:"locked"},ERROR_DEADLOCK:{code:29,message:"deadlock detected"},ERROR_HTTP_BAD_PARAMETER:{code:400,message:"bad parameter"},ERROR_HTTP_UNAUTHORIZED:{code:401,message:"unauthorized"},ERROR_HTTP_FORBIDDEN:{code:403,message:"forbidden"},ERROR_HTTP_NOT_FOUND:{code:404,message:"not found"},ERROR_HTTP_METHOD_NOT_ALLOWED:{code:405,message:"method not supported"},ERROR_HTTP_PRECONDITION_FAILED:{code:412,message:"precondition failed"},ERROR_HTTP_SERVER_ERROR:{code:500,message:"internal server error"},ERROR_HTTP_CORRUPTED_JSON:{code:600,message:"invalid JSON object"},ERROR_HTTP_SUPERFLUOUS_SUFFICES:{code:601,message:"superfluous URL suffices"},ERROR_ARANGO_ILLEGAL_STATE:{code:1e3,message:"illegal state"},ERROR_ARANGO_SHAPER_FAILED:{code:1001,message:"could not shape document"},ERROR_ARANGO_DATAFILE_SEALED:{code:1002,message:"datafile sealed"},ERROR_ARANGO_UNKNOWN_COLLECTION_TYPE:{code:1003,message:"unknown type"},ERROR_ARANGO_READ_ONLY:{code:1004,message:"read only"},ERROR_ARANGO_DUPLICATE_IDENTIFIER:{code:1005,message:"duplicate identifier"},ERROR_ARANGO_DATAFILE_UNREADABLE:{code:1006,message:"datafile unreadable"},ERROR_ARANGO_DATAFILE_EMPTY:{code:1007,message:"datafile empty"},ERROR_ARANGO_RECOVERY:{code:1008,message:"logfile recovery error"},ERROR_ARANGO_CORRUPTED_DATAFILE:{code:1100,message:"corrupted datafile"},ERROR_ARANGO_ILLEGAL_PARAMETER_FILE:{code:1101,message:"illegal or unreadable parameter file" +},ERROR_ARANGO_CORRUPTED_COLLECTION:{code:1102,message:"corrupted collection"},ERROR_ARANGO_MMAP_FAILED:{code:1103,message:"mmap failed"},ERROR_ARANGO_FILESYSTEM_FULL:{code:1104,message:"filesystem full"},ERROR_ARANGO_NO_JOURNAL:{code:1105,message:"no journal"},ERROR_ARANGO_DATAFILE_ALREADY_EXISTS:{code:1106,message:"cannot create/rename datafile because it already exists"},ERROR_ARANGO_DATADIR_LOCKED:{code:1107,message:"database directory is locked"},ERROR_ARANGO_COLLECTION_DIRECTORY_ALREADY_EXISTS:{code:1108,message:"cannot create/rename collection because directory already exists"},ERROR_ARANGO_MSYNC_FAILED:{code:1109,message:"msync failed"},ERROR_ARANGO_DATADIR_UNLOCKABLE:{code:1110,message:"cannot lock database directory"},ERROR_ARANGO_SYNC_TIMEOUT:{code:1111,message:"sync timeout"},ERROR_ARANGO_CONFLICT:{code:1200,message:"conflict"},ERROR_ARANGO_DATADIR_INVALID:{code:1201,message:"invalid database directory"},ERROR_ARANGO_DOCUMENT_NOT_FOUND:{code:1202,message:"document not found"},ERROR_ARANGO_COLLECTION_NOT_FOUND:{code:1203,message:"collection not found"},ERROR_ARANGO_COLLECTION_PARAMETER_MISSING:{code:1204,message:"parameter 'collection' not found"},ERROR_ARANGO_DOCUMENT_HANDLE_BAD:{code:1205,message:"illegal document handle"},ERROR_ARANGO_MAXIMAL_SIZE_TOO_SMALL:{code:1206,message:"maximal size of journal too small"},ERROR_ARANGO_DUPLICATE_NAME:{code:1207,message:"duplicate name"},ERROR_ARANGO_ILLEGAL_NAME:{code:1208,message:"illegal name"},ERROR_ARANGO_NO_INDEX:{code:1209,message:"no suitable index known"},ERROR_ARANGO_UNIQUE_CONSTRAINT_VIOLATED:{code:1210,message:"unique constraint violated"},ERROR_ARANGO_INDEX_NOT_FOUND:{code:1212,message:"index not found"},ERROR_ARANGO_CROSS_COLLECTION_REQUEST:{code:1213,message:"cross collection request not allowed"},ERROR_ARANGO_INDEX_HANDLE_BAD:{code:1214,message:"illegal index handle"},ERROR_ARANGO_CAP_CONSTRAINT_ALREADY_DEFINED:{code:1215,message:"cap constraint already defined"},ERROR_ARANGO_DOCUMENT_TOO_LARGE:{code:1216,message:"document too large"},ERROR_ARANGO_COLLECTION_NOT_UNLOADED:{code:1217,message:"collection must be unloaded"},ERROR_ARANGO_COLLECTION_TYPE_INVALID:{code:1218,message:"collection type invalid"},ERROR_ARANGO_VALIDATION_FAILED:{code:1219,message:"validator failed"},ERROR_ARANGO_ATTRIBUTE_PARSER_FAILED:{code:1220,message:"parsing attribute name definition failed"},ERROR_ARANGO_DOCUMENT_KEY_BAD:{code:1221,message:"illegal document key"},ERROR_ARANGO_DOCUMENT_KEY_UNEXPECTED:{code:1222,message:"unexpected document key"},ERROR_ARANGO_DATADIR_NOT_WRITABLE:{code:1224,message:"server database directory not writable"},ERROR_ARANGO_OUT_OF_KEYS:{code:1225,message:"out of keys"},ERROR_ARANGO_DOCUMENT_KEY_MISSING:{code:1226,message:"missing document key"},ERROR_ARANGO_DOCUMENT_TYPE_INVALID:{code:1227,message:"invalid document type"},ERROR_ARANGO_DATABASE_NOT_FOUND:{code:1228,message:"database not found"},ERROR_ARANGO_DATABASE_NAME_INVALID:{code:1229,message:"database name invalid"},ERROR_ARANGO_USE_SYSTEM_DATABASE:{code:1230,message:"operation only allowed in system database"},ERROR_ARANGO_ENDPOINT_NOT_FOUND:{code:1231,message:"endpoint not found"},ERROR_ARANGO_INVALID_KEY_GENERATOR:{code:1232,message:"invalid key generator"},ERROR_ARANGO_INVALID_EDGE_ATTRIBUTE:{code:1233,message:"edge attribute missing"},ERROR_ARANGO_INDEX_DOCUMENT_ATTRIBUTE_MISSING:{code:1234,message:"index insertion warning - attribute missing in document"},ERROR_ARANGO_INDEX_CREATION_FAILED:{code:1235,message:"index creation failed"},ERROR_ARANGO_WRITE_THROTTLE_TIMEOUT:{code:1236,message:"write-throttling timeout"},ERROR_ARANGO_COLLECTION_TYPE_MISMATCH:{code:1237,message:"collection type mismatch"},ERROR_ARANGO_COLLECTION_NOT_LOADED:{code:1238,message:"collection not loaded"},ERROR_ARANGO_DATAFILE_FULL:{code:1300,message:"datafile full"},ERROR_ARANGO_EMPTY_DATADIR:{code:1301,message:"server database directory is empty"},ERROR_REPLICATION_NO_RESPONSE:{code:1400,message:"no response"},ERROR_REPLICATION_INVALID_RESPONSE:{code:1401,message:"invalid response"},ERROR_REPLICATION_MASTER_ERROR:{code:1402,message:"master error"},ERROR_REPLICATION_MASTER_INCOMPATIBLE:{code:1403,message:"master incompatible"},ERROR_REPLICATION_MASTER_CHANGE:{code:1404,message:"master change"},ERROR_REPLICATION_LOOP:{code:1405,message:"loop detected"},ERROR_REPLICATION_UNEXPECTED_MARKER:{code:1406,message:"unexpected marker"},ERROR_REPLICATION_INVALID_APPLIER_STATE:{code:1407,message:"invalid applier state"},ERROR_REPLICATION_UNEXPECTED_TRANSACTION:{code:1408,message:"invalid transaction"},ERROR_REPLICATION_INVALID_APPLIER_CONFIGURATION:{code:1410,message:"invalid replication applier configuration"},ERROR_REPLICATION_RUNNING:{code:1411,message:"cannot perform operation while applier is running"},ERROR_REPLICATION_APPLIER_STOPPED:{code:1412,message:"replication stopped"},ERROR_REPLICATION_NO_START_TICK:{code:1413,message:"no start tick"},ERROR_REPLICATION_START_TICK_NOT_PRESENT:{code:1414,message:"start tick not present"},ERROR_CLUSTER_NO_AGENCY:{code:1450,message:"could not connect to agency"},ERROR_CLUSTER_NO_COORDINATOR_HEADER:{code:1451,message:"missing coordinator header"},ERROR_CLUSTER_COULD_NOT_LOCK_PLAN:{code:1452,message:"could not lock plan in agency"},ERROR_CLUSTER_COLLECTION_ID_EXISTS:{code:1453,message:"collection ID already exists"},ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION_IN_PLAN:{code:1454,message:"could not create collection in plan"},ERROR_CLUSTER_COULD_NOT_READ_CURRENT_VERSION:{code:1455,message:"could not read version in current in agency"},ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION:{code:1456,message:"could not create collection"},ERROR_CLUSTER_TIMEOUT:{code:1457,message:"timeout in cluster operation"},ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_PLAN:{code:1458,message:"could not remove collection from plan"},ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_CURRENT:{code:1459,message:"could not remove collection from current"},ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE_IN_PLAN:{code:1460,message:"could not create database in plan"},ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE:{code:1461,message:"could not create database"},ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_PLAN:{code:1462,message:"could not remove database from plan"},ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_CURRENT:{code:1463,message:"could not remove database from current"},ERROR_CLUSTER_SHARD_GONE:{code:1464,message:"no responsible shard found"},ERROR_CLUSTER_CONNECTION_LOST:{code:1465,message:"cluster internal HTTP connection broken"},ERROR_CLUSTER_MUST_NOT_SPECIFY_KEY:{code:1466,message:"must not specify _key for this collection"},ERROR_CLUSTER_GOT_CONTRADICTING_ANSWERS:{code:1467,message:"got contradicting answers from different shards"},ERROR_CLUSTER_NOT_ALL_SHARDING_ATTRIBUTES_GIVEN:{code:1468,message:"not all sharding attributes given"},ERROR_CLUSTER_MUST_NOT_CHANGE_SHARDING_ATTRIBUTES:{code:1469,message:"must not change the value of a shard key attribute"},ERROR_CLUSTER_UNSUPPORTED:{code:1470,message:"unsupported operation or parameter"},ERROR_CLUSTER_ONLY_ON_COORDINATOR:{code:1471,message:"this operation is only valid on a coordinator in a cluster"},ERROR_CLUSTER_READING_PLAN_AGENCY:{code:1472,message:"error reading Plan in agency"},ERROR_CLUSTER_COULD_NOT_TRUNCATE_COLLECTION:{code:1473,message:"could not truncate collection"},ERROR_CLUSTER_AQL_COMMUNICATION:{code:1474,message:"error in cluster internal communication for AQL"},ERROR_ARANGO_DOCUMENT_NOT_FOUND_OR_SHARDING_ATTRIBUTES_CHANGED:{code:1475,message:"document not found or sharding attributes changed"},ERROR_CLUSTER_COULD_NOT_DETERMINE_ID:{code:1476,message:"could not determine my ID from my local info"},ERROR_CLUSTER_ONLY_ON_DBSERVER:{code:1477,message:"this operation is only valid on a DBserver in a cluster"},ERROR_QUERY_KILLED:{code:1500,message:"query killed"},ERROR_QUERY_PARSE:{code:1501,message:"%s"},ERROR_QUERY_EMPTY:{code:1502,message:"query is empty"},ERROR_QUERY_SCRIPT:{code:1503,message:"runtime error '%s'"},ERROR_QUERY_NUMBER_OUT_OF_RANGE:{code:1504,message:"number out of range"},ERROR_QUERY_VARIABLE_NAME_INVALID:{code:1510,message:"variable name '%s' has an invalid format"},ERROR_QUERY_VARIABLE_REDECLARED:{code:1511,message:"variable '%s' is assigned multiple times"},ERROR_QUERY_VARIABLE_NAME_UNKNOWN:{code:1512,message:"unknown variable '%s'"},ERROR_QUERY_COLLECTION_LOCK_FAILED:{code:1521,message:"unable to read-lock collection %s"},ERROR_QUERY_TOO_MANY_COLLECTIONS:{code:1522,message:"too many collections"},ERROR_QUERY_DOCUMENT_ATTRIBUTE_REDECLARED:{code:1530,message:"document attribute '%s' is assigned multiple times"},ERROR_QUERY_FUNCTION_NAME_UNKNOWN:{code:1540,message:"usage of unknown function '%s()'"},ERROR_QUERY_FUNCTION_ARGUMENT_NUMBER_MISMATCH:{code:1541,message:"invalid number of arguments for function '%s()', expected number of arguments: minimum: %d, maximum: %d"},ERROR_QUERY_FUNCTION_ARGUMENT_TYPE_MISMATCH:{code:1542,message:"invalid argument type in call to function '%s()'"},ERROR_QUERY_INVALID_REGEX:{code:1543,message:"invalid regex value"},ERROR_QUERY_BIND_PARAMETERS_INVALID:{code:1550,message:"invalid structure of bind parameters"},ERROR_QUERY_BIND_PARAMETER_MISSING:{code:1551,message:"no value specified for declared bind parameter '%s'"},ERROR_QUERY_BIND_PARAMETER_UNDECLARED:{code:1552,message:"bind parameter '%s' was not declared in the query"},ERROR_QUERY_BIND_PARAMETER_TYPE:{code:1553,message:"bind parameter '%s' has an invalid value or type"},ERROR_QUERY_INVALID_LOGICAL_VALUE:{code:1560,message:"invalid logical value"},ERROR_QUERY_INVALID_ARITHMETIC_VALUE:{code:1561,message:"invalid arithmetic value"},ERROR_QUERY_DIVISION_BY_ZERO:{code:1562,message:"division by zero"},ERROR_QUERY_ARRAY_EXPECTED:{code:1563,message:"array expected"},ERROR_QUERY_FAIL_CALLED:{code:1569,message:"FAIL(%s) called"},ERROR_QUERY_GEO_INDEX_MISSING:{code:1570,message:"no suitable geo index found for geo restriction on '%s'"},ERROR_QUERY_FULLTEXT_INDEX_MISSING:{code:1571,message:"no suitable fulltext index found for fulltext query on '%s'"},ERROR_QUERY_INVALID_DATE_VALUE:{code:1572,message:"invalid date value"},ERROR_QUERY_MULTI_MODIFY:{code:1573,message:"multi-modify query"},ERROR_QUERY_INVALID_AGGREGATE_EXPRESSION:{code:1574,message:"invalid aggregate expression"},ERROR_QUERY_COMPILE_TIME_OPTIONS:{code:1575,message:"query options must be readable at query compile time"},ERROR_QUERY_EXCEPTION_OPTIONS:{code:1576,message:"query options expected"},ERROR_QUERY_COLLECTION_USED_IN_EXPRESSION:{code:1577,message:"collection '%s' used as expression operand"},ERROR_QUERY_DISALLOWED_DYNAMIC_CALL:{code:1578,message:"disallowed dynamic call to '%s'"},ERROR_QUERY_ACCESS_AFTER_MODIFICATION:{code:1579,message:"access after data-modification"},ERROR_QUERY_FUNCTION_INVALID_NAME:{code:1580,message:"invalid user function name"},ERROR_QUERY_FUNCTION_INVALID_CODE:{code:1581,message:"invalid user function code"},ERROR_QUERY_FUNCTION_NOT_FOUND:{code:1582,message:"user function '%s()' not found"},ERROR_QUERY_FUNCTION_RUNTIME_ERROR:{code:1583,message:"user function runtime error: %s"},ERROR_QUERY_BAD_JSON_PLAN:{code:1590,message:"bad execution plan JSON"},ERROR_QUERY_NOT_FOUND:{code:1591,message:"query ID not found"},ERROR_QUERY_IN_USE:{code:1592,message:"query with this ID is in use"},ERROR_CURSOR_NOT_FOUND:{code:1600,message:"cursor not found"},ERROR_CURSOR_BUSY:{code:1601,message:"cursor is busy"},ERROR_TRANSACTION_INTERNAL:{code:1650,message:"internal transaction error"},ERROR_TRANSACTION_NESTED:{code:1651,message:"nested transactions detected"},ERROR_TRANSACTION_UNREGISTERED_COLLECTION:{code:1652,message:"unregistered collection used in transaction"},ERROR_TRANSACTION_DISALLOWED_OPERATION:{code:1653,message:"disallowed operation inside transaction"},ERROR_TRANSACTION_ABORTED:{code:1654,message:"transaction aborted"},ERROR_USER_INVALID_NAME:{code:1700,message:"invalid user name"},ERROR_USER_INVALID_PASSWORD:{code:1701,message:"invalid password"},ERROR_USER_DUPLICATE:{code:1702,message:"duplicate user"},ERROR_USER_NOT_FOUND:{code:1703,message:"user not found"},ERROR_USER_CHANGE_PASSWORD:{code:1704,message:"user must change his password"},ERROR_APPLICATION_INVALID_NAME:{code:1750,message:"invalid application name"},ERROR_APPLICATION_INVALID_MOUNT:{code:1751,message:"invalid mount"},ERROR_APPLICATION_DOWNLOAD_FAILED:{code:1752,message:"application download failed"},ERROR_APPLICATION_UPLOAD_FAILED:{code:1753,message:"application upload failed"},ERROR_KEYVALUE_INVALID_KEY:{code:1800,message:"invalid key declaration"},ERROR_KEYVALUE_KEY_EXISTS:{code:1801,message:"key already exists"},ERROR_KEYVALUE_KEY_NOT_FOUND:{code:1802,message:"key not found"},ERROR_KEYVALUE_KEY_NOT_UNIQUE:{code:1803,message:"key is not unique"},ERROR_KEYVALUE_KEY_NOT_CHANGED:{code:1804,message:"key value not changed"},ERROR_KEYVALUE_KEY_NOT_REMOVED:{code:1805,message:"key value not removed"},ERROR_KEYVALUE_NO_VALUE:{code:1806,message:"missing value"},ERROR_TASK_INVALID_ID:{code:1850,message:"invalid task id"},ERROR_TASK_DUPLICATE_ID:{code:1851,message:"duplicate task id"},ERROR_TASK_NOT_FOUND:{code:1852,message:"task not found"},ERROR_GRAPH_INVALID_GRAPH:{code:1901,message:"invalid graph"},ERROR_GRAPH_COULD_NOT_CREATE_GRAPH:{code:1902,message:"could not create graph"},ERROR_GRAPH_INVALID_VERTEX:{code:1903,message:"invalid vertex"},ERROR_GRAPH_COULD_NOT_CREATE_VERTEX:{code:1904,message:"could not create vertex"},ERROR_GRAPH_COULD_NOT_CHANGE_VERTEX:{code:1905,message:"could not change vertex"},ERROR_GRAPH_INVALID_EDGE:{code:1906,message:"invalid edge"},ERROR_GRAPH_COULD_NOT_CREATE_EDGE:{code:1907,message:"could not create edge"},ERROR_GRAPH_COULD_NOT_CHANGE_EDGE:{code:1908,message:"could not change edge"},ERROR_GRAPH_TOO_MANY_ITERATIONS:{code:1909,message:"too many iterations - try increasing the value of 'maxIterations'"},ERROR_GRAPH_INVALID_FILTER_RESULT:{code:1910,message:"invalid filter result"},ERROR_GRAPH_COLLECTION_MULTI_USE:{code:1920,message:"multi use of edge collection in edge def"},ERROR_GRAPH_COLLECTION_USE_IN_MULTI_GRAPHS:{code:1921,message:"edge collection already used in edge def"},ERROR_GRAPH_CREATE_MISSING_NAME:{code:1922,message:"missing graph name"},ERROR_GRAPH_CREATE_MALFORMED_EDGE_DEFINITION:{code:1923,message:"malformed edge definition"},ERROR_GRAPH_NOT_FOUND:{code:1924,message:"graph not found"},ERROR_GRAPH_DUPLICATE:{code:1925,message:"graph already exists"},ERROR_GRAPH_VERTEX_COL_DOES_NOT_EXIST:{code:1926,message:"vertex collection does not exist or is not part of the graph"},ERROR_GRAPH_WRONG_COLLECTION_TYPE_VERTEX:{code:1927,message:"not a vertex collection"},ERROR_GRAPH_NOT_IN_ORPHAN_COLLECTION:{code:1928,message:"not in orphan collection"},ERROR_GRAPH_COLLECTION_USED_IN_EDGE_DEF:{code:1929,message:"collection already used in edge def"},ERROR_GRAPH_EDGE_COLLECTION_NOT_USED:{code:1930,message:"edge collection not used in graph"},ERROR_GRAPH_NOT_AN_ARANGO_COLLECTION:{code:1931,message:" is not an ArangoCollection"},ERROR_GRAPH_NO_GRAPH_COLLECTION:{code:1932,message:"collection _graphs does not exist"},ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT_STRING:{code:1933,message:"Invalid example type. Has to be String, Array or Object"},ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT:{code:1934,message:"Invalid example type. Has to be Array or Object"},ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS:{code:1935,message:"Invalid number of arguments. Expected: "},ERROR_GRAPH_INVALID_PARAMETER:{code:1936,message:"Invalid parameter type."},ERROR_GRAPH_INVALID_ID:{code:1937,message:"Invalid id"},ERROR_GRAPH_COLLECTION_USED_IN_ORPHANS:{code:1938,message:"collection used in orphans"},ERROR_GRAPH_EDGE_COL_DOES_NOT_EXIST:{code:1939,message:"edge collection does not exist or is not part of the graph"},ERROR_GRAPH_EMPTY:{code:1940,message:"empty graph"},ERROR_SESSION_UNKNOWN:{code:1950,message:"unknown session"},ERROR_SESSION_EXPIRED:{code:1951,message:"session expired"},SIMPLE_CLIENT_UNKNOWN_ERROR:{code:2e3,message:"unknown client error"},SIMPLE_CLIENT_COULD_NOT_CONNECT:{code:2001,message:"could not connect to server"},SIMPLE_CLIENT_COULD_NOT_WRITE:{code:2002,message:"could not write to server"},SIMPLE_CLIENT_COULD_NOT_READ:{code:2003,message:"could not read from server"},ERROR_MALFORMED_MANIFEST_FILE:{code:3e3,message:"malformed manifest file"},ERROR_INVALID_APPLICATION_MANIFEST:{code:3001,message:"manifest file is invalid"},ERROR_INVALID_FOXX_OPTIONS:{code:3004,message:"invalid foxx options"},ERROR_INVALID_MOUNTPOINT:{code:3007,message:"mountpoint is invalid"},ERROR_APP_NOT_FOUND:{code:3009,message:"App not found"},ERROR_APP_NEEDS_CONFIGURATION:{code:3010,message:"App not configured"},ERROR_MODULE_NOT_FOUND:{code:3100,message:"cannot locate module"},ERROR_MODULE_FAILURE:{code:3103,message:"failed to invoke module"},RESULT_ELEMENT_EXISTS:{code:1e4,message:"element not inserted into structure, because it already exists"},RESULT_ELEMENT_NOT_FOUND:{code:10001,message:"element not found in structure"},ERROR_QUEUE_ALREADY_EXISTS:{code:21e3,message:"named queue already exists"},ERROR_DISPATCHER_IS_STOPPING:{code:21001,message:"dispatcher stopped"},ERROR_QUEUE_UNKNOWN:{code:21002,message:"named queue does not exist"},ERROR_QUEUE_FULL:{code:21003,message:"named queue is full"}}}(),global.DEFINE_MODULE("console",function(){"use strict";function a(a,b){j(a,h+b)}function b(a){var b=require("internal").ShapedJson,c=[];a.length>0&&"string"!=typeof a[0]&&c.push("%s");for(var d=0;d curl ","POST"===e?(i=a.arango.POST_RAW(f,g,h),j+="-X "+e+" "):"PUT"===e?(i=a.arango.PUT_RAW(f,g,h),j+="-X "+e+" "):"GET"===e?i=a.arango.GET_RAW(f,h):"DELETE"===e?(i=a.arango.DELETE_RAW(f,h),j+="-X "+e+" "):"PATCH"===e?(i=a.arango.PATCH_RAW(f,g,h),j+="-X "+e+" "):"HEAD"===e?(i=a.arango.HEAD_RAW(f,h),j+="-X "+e+" "):"OPTION"===e&&(i=a.arango.OPTION_RAW(f,g,h),j+="-X "+e+" "),void 0!==h&&""!==h)for(k in h)h.hasOwnProperty(k)&&(j+="--header '"+k+": "+h[k]+"' ");return void 0!==g&&""!==g&&(j+="--data-binary @- "),j+="--dump - http://localhost:8529"+f,b(j),void 0!==g&&""!==g&&g&&(d(" <<EOF\n"),l?c(g):d(g),d("\nEOF")),d("\n\n"),i}},a.appendRawResponse=function(b,c){return function(d){var e,f=d.headers;b("HTTP/1.1 "+f["http/1.1"]+"\n");for(e in f)f.hasOwnProperty(e)&&"http/1.1"!==e&&"server"!==e&&"connection"!==e&&"content-length"!==e&&b(e+": "+f[e]+"\n");b("\n"),void 0!==d.body&&(c(a.inspect(d.body)),b("\n"))}},a.appendJsonResponse=function(b,c){return function(b){var d=a.appendRawResponse(c,c),e=b.body;b.body=JSON.parse(b.body),d(b),b.body=e}},a.log=function(b,c){a.output(b,": ",c,"\n")};try{"undefined"!=typeof window&&(a.sprintf=function(a){var b=arguments.length;if(0===b)return"";if(1>=b)return String(a);var c,d=[];for(c=1;c col = db.mycoll; \n > col = db._create("mycoll"); \n \nAdministration Functions: \n name() collection name \n status() status of the collection \n type() type of the collection \n truncate() delete all documents \n properties() show collection properties \n drop() delete a collection \n load() load a collection \n unload() unload a collection \n rename() renames a collection \n getIndexes() return defined indexes \n refresh() refreshes the status and name \n _help() this help \n \nDocument Functions: \n count() return number of documents \n save() create document and return handle \n document() get document by handle (_id or _key)\n replace(, , ) overwrite document \n update(, , , partially update document \n ) \n remove() delete document \n exists() checks whether a document exists \n first() first inserted/updated document \n last() last inserted/updated document \n \nAttributes: \n _database database object \n _id collection identifier ';d.prototype._help=function(){e.print(h)},d.prototype.name=function(){return null===this._name&&this.refresh(),this._name},d.prototype.status=function(){var a;return null===this._status&&this.refresh(),a=this._status,this._status===d.STATUS_UNLOADING&&(this._status=null),a},d.prototype.type=function(){return null===this._type&&this.refresh(),this._type},d.prototype.properties=function(a){var b,c,d={doCompact:!0,journalSize:!0,isSystem:!1,isVolatile:!1,waitForSync:!0,shardKeys:!1,numberOfShards:!1,keyOptions:!1,indexBuckets:!0};if(void 0===a)c=this._database._connection.GET(this._baseurl("properties")),f.checkRequestResult(c);else{var e={};for(b in d)d.hasOwnProperty(b)&&d[b]&&a.hasOwnProperty(b)&&(e[b]=a[b]);c=this._database._connection.PUT(this._baseurl("properties"),JSON.stringify(e)),f.checkRequestResult(c)}var g={};for(b in d)d.hasOwnProperty(b)&&c.hasOwnProperty(b)&&void 0!==c[b]&&(g[b]=c[b]);return g},d.prototype.rotate=function(){var a=this._database._connection.PUT(this._baseurl("rotate"),"");return f.checkRequestResult(a),a.result},d.prototype.figures=function(){var a=this._database._connection.GET(this._baseurl("figures"));return f.checkRequestResult(a),a.figures},d.prototype.checksum=function(a,b){var c="";a&&(c+="?withRevisions=true"),b&&(c+=(""===c?"?":"&")+"withData=true");var d=this._database._connection.GET(this._baseurl("checksum")+c);return f.checkRequestResult(d),{checksum:d.checksum,revision:d.revision}},d.prototype.revision=function(){var a=this._database._connection.GET(this._baseurl("revision"));return f.checkRequestResult(a),a.revision},d.prototype.drop=function(){var a=this._database._connection.DELETE(this._baseurl());null!==a&&a.error===!0&&a.errorNum!==e.errors.ERROR_ARANGO_COLLECTION_NOT_FOUND.code&&f.checkRequestResult(a),this._status=d.STATUS_DELETED;var b,c=this._database;for(b in c)if(c.hasOwnProperty(b)){var g=c[b];g instanceof d&&g.name()===this.name()&&delete c[b]}},d.prototype.truncate=function(){var a=this._database._connection.PUT(this._baseurl("truncate"),"");f.checkRequestResult(a),this._status=null},d.prototype.load=function(a){var b={count:!0};void 0!==a&&(b.count=a);var c=this._database._connection.PUT(this._baseurl("load"),JSON.stringify(b));f.checkRequestResult(c),this._status=null},d.prototype.unload=function(){var a=this._database._connection.PUT(this._baseurl("unload"),"");f.checkRequestResult(a),this._status=null},d.prototype.rename=function(a){var b={name:a},c=this._database._connection.PUT(this._baseurl("rename"),JSON.stringify(b));f.checkRequestResult(c),delete this._database[this._name],this._database[a]=this,this._status=null,this._name=null},d.prototype.refresh=function(){var a=this._database._connection.GET(this._database._collectionurl(this._id)+"?useId=true");f.checkRequestResult(a),this._name=a.name,this._status=a.status,this._type=a.type},d.prototype.getIndexes=function(a){var b=this._database._connection.GET(this._indexurl()+"&withStats="+(a||!1));return f.checkRequestResult(b),b.indexes},d.prototype.index=function(a){a.hasOwnProperty("id")&&(a=a.id);var b=this._database._connection.GET(this._database._indexurl(a,this.name()));return f.checkRequestResult(b),b},d.prototype.dropIndex=function(a){a.hasOwnProperty("id")&&(a=a.id);var b=this._database._connection.DELETE(this._database._indexurl(a,this.name()));return null!==b&&b.error===!0&&b.errorNum===e.errors.ERROR_ARANGO_INDEX_NOT_FOUND.code?!1:(f.checkRequestResult(b),!0)},d.prototype.ensureCapConstraint=function(a,b){ +var c={type:"cap",size:a||void 0,byteSize:b||void 0},d=this._database._connection.POST(this._indexurl(),JSON.stringify(c));return f.checkRequestResult(d),d},d.prototype.ensureUniqueSkiplist=function(){var a=c({type:"skiplist",unique:!0},arguments),b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.ensureSkiplist=function(){var a=c({type:"skiplist",unique:!1},arguments),b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.ensureFulltextIndex=function(a,b){var c={type:"fulltext",minLength:b||void 0,fields:[a]},d=this._database._connection.POST(this._indexurl(),JSON.stringify(c));return f.checkRequestResult(d),d},d.prototype.ensureUniqueConstraint=function(){var a=c({type:"hash",unique:!0},arguments),b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.ensureHashIndex=function(){var a=c({type:"hash",unique:!1},arguments),b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.ensureGeoIndex=function(a,b){var c;if("string"!=typeof a)throw"usage: ensureGeoIndex(, ) or ensureGeoIndex([, ])";c="boolean"==typeof b?{type:"geo",fields:[a],geoJson:b}:void 0===b?{type:"geo",fields:[a],geoJson:!1}:{type:"geo",fields:[a,b],geoJson:!1};var d=this._database._connection.POST(this._indexurl(),JSON.stringify(c));return f.checkRequestResult(d),d},d.prototype.ensureGeoConstraint=function(a,b){return this.ensureGeoIndex(a,b)},d.prototype.ensureIndex=function(a){if("object"!=typeof a||Array.isArray(a))throw"usage: ensureIndex()";var b=this._database._connection.POST(this._indexurl(),JSON.stringify(a));return f.checkRequestResult(b),b},d.prototype.count=function(){var a=this._database._connection.GET(this._baseurl("count"));return f.checkRequestResult(a),a.count},d.prototype.document=function(a){var b,c=null;if(a.hasOwnProperty("_id")&&(a.hasOwnProperty("_rev")&&(c=a._rev),a=a._id),b=null===c?this._database._connection.GET(this._documenturl(a)):this._database._connection.GET(this._documenturl(a),{"if-match":JSON.stringify(c)}),null!==b&&b.error===!0&&b.errorNum===e.errors.ERROR_ARANGO_COLLECTION_NOT_FOUND.code)throw new g(b);return f.checkRequestResult(b),b},d.prototype.exists=function(a){var b,c=null;if(void 0===a||null===a)throw new g({errorNum:e.errors.ERROR_ARANGO_DOCUMENT_HANDLE_BAD.code,errorMessage:e.errors.ERROR_ARANGO_DOCUMENT_HANDLE_BAD.message});return a.hasOwnProperty("_id")&&(a.hasOwnProperty("_rev")&&(c=a._rev),a=a._id),b=null===c?this._database._connection.HEAD(this._documenturl(a)):this._database._connection.HEAD(this._documenturl(a),{"if-match":JSON.stringify(c)}),null===b||b.error!==!0||b.errorNum!==e.errors.ERROR_ARANGO_COLLECTION_NOT_FOUND.code&&b.errorNum!==e.errors.ERROR_HTTP_NOT_FOUND.code&&b.errorNum!==e.errors.ERROR_HTTP_PRECONDITION_FAILED.code?(f.checkRequestResult(b),!0):!1},d.prototype.any=function(){var a=this._database._connection.PUT(this._prefixurl("/_api/simple/any"),JSON.stringify({collection:this._name}));return f.checkRequestResult(a),a.document},d.prototype.firstExample=function(a){var b,c;if(1===arguments.length)b=a;else for(b={},c=0;c) get collection by identifier/name \n _create(, ) creates a new collection \n _createEdgeCollection() creates a new edge collection \n _drop() delete a collection \n \nDocument Functions: \n _document() get document by handle (_id) \n _replace(, , ) overwrite document \n _update(, , , partially update document \n ) \n _remove() delete document \n _exists() checks whether a document exists \n _truncate() delete all documents \n \nDatabase Management Functions: \n _createDatabase() creates a new database \n _dropDatabase() drops an existing database \n _useDatabase() switches into an existing database\n _drop() delete a collection \n _name() name of the current database \n \nQuery / Transaction Functions: \n _executeTransaction() execute transaction \n _query() execute AQL query \n _createStatement() create and return AQL query ";c.prototype._help=function(){e.print(i)},c.prototype.toString=function(){return'[object ArangoDatabase "'+this._name()+'"]'},c.prototype._collections=function(){var a=this._connection.GET(this._collectionurl());if(f.checkRequestResult(a),void 0!==a.collections){var b,c=a.collections,d=[];for(b=0;b1&&(a={query:a,bindVars:b,options:c}),require("@arangodb/aql/explainer").explain(a)},c.prototype._createDatabase=function(a,b,c){var d={name:a,options:b||{},users:c||[]},e=this._connection.POST("/_api/database",JSON.stringify(d));if(null!==e&&e.error===!0)throw new g(e);return f.checkRequestResult(e),e.result},c.prototype._dropDatabase=function(a){var b=this._connection.DELETE("/_api/database/"+encodeURIComponent(a));if(null!==b&&b.error===!0)throw new g(b);return f.checkRequestResult(b),b.result},c.prototype._listDatabases=function(){var a=this._connection.GET("/_api/database");if(null!==a&&a.error===!0)throw new g(a);return f.checkRequestResult(a),a.result},c.prototype._useDatabase=function(a){if(e.printBrowser)throw new g({error:!0,code:e.errors.ERROR_NOT_IMPLEMENTED.code,errorNum:e.errors.ERROR_NOT_IMPLEMENTED.code,errorMessage:"_useDatabase() is not supported in the web interface"});var b=this._connection.getDatabaseName();if(a===b)return!0;this._connection.setDatabaseName(a);try{this._queryProperties(!0),this._flushCache()}catch(c){if(this._connection.setDatabaseName(b),c.hasOwnProperty("errorNum"))throw c;throw new g({error:!0,code:e.errors.ERROR_BAD_PARAMETER.code,errorNum:e.errors.ERROR_BAD_PARAMETER.code,errorMessage:"cannot use database '"+a+"'"})}return!0},c.prototype._listEndpoints=function(){var a=this._connection.GET("/_api/endpoint");if(null!==a&&a.error===!0)throw new g(a);return f.checkRequestResult(a),a},c.prototype._executeTransaction=function(a){if(!a||"object"!=typeof a)throw new g({error:!0,code:e.errors.ERROR_HTTP_BAD_PARAMETER.code,errorNum:e.errors.ERROR_BAD_PARAMETER.code,errorMessage:"usage: _executeTransaction()"});if(!a.collections||"object"!=typeof a.collections)throw new g({error:!0,code:e.errors.ERROR_HTTP_BAD_PARAMETER.code,errorNum:e.errors.ERROR_BAD_PARAMETER.code,errorMessage:"missing/invalid collections definition for transaction"});if(!a.action||"string"!=typeof a.action&&"function"!=typeof a.action)throw new g({error:!0,code:e.errors.ERROR_HTTP_BAD_PARAMETER.code,errorNum:e.errors.ERROR_BAD_PARAMETER.code,errorMessage:"missing/invalid action definition for transaction"});"function"==typeof a.action&&(a.action=String(a.action));var b=this._connection.POST("/_api/transaction",JSON.stringify(a));if(null!==b&&b.error===!0)throw new g(b);return f.checkRequestResult(b),b.result}}),module.define("@arangodb/arango-query-cursor",function(a,b){function c(a,b){this._database=a,this._dbName=a._name(),this.data=b,this._hasNext=!1,this._hasMore=!1,this._pos=0,this._count=0,this._total=0,void 0!==b.result&&(this._count=b.result.length,this._pos0){if(a)d.print(b);else{var g=d.startCaptureMode();d.print(b),e+="\n\n"+d.stopCaptureMode(g)}this.hasNext()&&(e+="\ntype 'more' to show more documents\n",more=this)}return a||(d.print(e),e=""),e},c.prototype.toArray=function(){for(var a=[];this.hasNext();)a.push(this.next());return a};var f=e.createHelpHeadline("ArangoQueryCursor help")+'ArangoQueryCursor constructor: \n > cursor = stmt.execute() \nFunctions: \n hasNext() returns true if there are \n more results to fetch \n next() returns the next document \n toArray() returns all data from the cursor\n _help() this help \nAttributes: \n _database database object \nExample: \n > stmt = db._createStatement({ "query": "FOR c IN coll RETURN c" })\n > cursor = stmt.execute() \n > documents = cursor.toArray() \n > cursor = stmt.execute() \n > while (cursor.hasNext()) { print(cursor.next()) } ';c.prototype._help=function(){d.print(f)},c.prototype.hasNext=function(){return this._hasNext},c.prototype.next=function(){if(!this._hasNext)throw"No more results";var a=this.data.result[this._pos];if(this._pos++,this._pos===this._count&&(this._hasNext=!1,this._pos=0,this._hasMore&&this.data.id)){this._hasMore=!1;var b=this._database._connection.PUT(this._baseurl(),"");e.checkRequestResult(b),this.data=b,this._count=b.result.length,this._pos stmt = new ArangoStatement(db, { "query": "FOR..." }) \n > stmt = db._createStatement({ "query": "FOR..." }) \nSet query options: \n > stmt.setBatchSize() set the max. number of results \n to be transferred per roundtrip \n > stmt.setCount() set count flag (return number of\n results in "count" attribute) \nGet query options: \n > stmt.setBatchSize() return the max. number of results\n to be transferred per roundtrip \n > stmt.getCount() return count flag (return number\n of results in "count" attribute)\n > stmt.getQuery() return query string \n results in "count" attribute) \nBind parameters to a query: \n > stmt.bind(, ) bind single variable \n > stmt.bind() bind multiple variables \nExecute query: \n > cursor = stmt.execute() returns a cursor \nGet all results in an array: \n > docs = cursor.toArray() \nOr loop over the result set: \n > while (cursor.hasNext()) { print(cursor.next()) } ';e.prototype._help=function(){c.print(g)},e.prototype.parse=function(){var a={query:this._query},b=this._database._connection.POST("/_api/query",JSON.stringify(a));d.checkRequestResult(b);var c={bindVars:b.bindVars,collections:b.collections,ast:b.ast};return c},e.prototype.explain=function(a){var b=this._options||{};"object"==typeof b&&"object"==typeof a&&Object.keys(a).forEach(function(c){b[c]=a[c]});var c={query:this._query,bindVars:this._bindVars,options:b},e=this._database._connection.POST("/_api/explain",JSON.stringify(c));return d.checkRequestResult(e),b&&b.allPlans?{plans:e.plans,warnings:e.warnings,stats:e.stats}:{plan:e.plan,warnings:e.warnings,stats:e.stats,cacheable:e.cacheable}},e.prototype.execute=function(){var a={query:this._query,count:this._doCount,bindVars:this._bindVars};this._batchSize&&(a.batchSize=this._batchSize),this._options&&(a.options=this._options),void 0!==this._cache&&(a.cache=this._cache);var b=this._database._connection.POST("/_api/cursor",JSON.stringify(a));return d.checkRequestResult(b),new f(this._database,b)},a.ArangoStatement=e}),module.define("@arangodb/arangosh",function(a,b){var c=require("internal");a.getIdString=function(a,b){var c="[object "+b;return a._id?c+=":"+a._id:a.data&&a.data._id&&(c+=":"+a.data._id),c+="]"},a.createHelpHeadline=function(a){var b,c="",d=Math.abs(78-a.length)/2;for(b=0;d>b;++b)c+="-";return"\n"+c+" "+a+" "+c+"\n"};var d=require("@arangodb"),e=d.ArangoError;a.checkRequestResult=function(a){if(void 0===a)throw new e({error:!0,code:500,errorNum:d.ERROR_INTERNAL,errorMessage:"Unknown error. Request result is empty"});if(a.hasOwnProperty("error")){if(a.error){if(a.errorNum===d.ERROR_TYPE_ERROR)throw new TypeError(a.errorMessage);var b=new e(a);throw b.message=a.message,b}delete a.error}return a},a.HELP=a.createHelpHeadline("Help")+"Predefined objects: \n arango: ArangoConnection \n db: ArangoDatabase \n"+(c.printBrowser?"":" fm: FoxxManager \n")+"Examples: \n > db._collections() list all collections \n > db._query().toArray() execute an AQL query \n > db._explain() explain an AQL query \n > help show help pages \n > exit \nNote: collection names and statuses may be cached in arangosh. \nTo refresh the list of collections and their statuses, issue: \n > db._collections(); \n \n"+(c.printBrowser?"To cancel the current prompt, press CTRL + z. \n \nPlease note that all variables defined with the var keyword will \ndisappear when the command is finished. To introduce variables that\nare persisting until the next command, omit the var keyword. \n\nType 'tutorial' for a tutorial or 'help' to see common examples":"To cancel the current prompt, press CTRL + d. \n"),a.helpExtended=a.createHelpHeadline("More help")+"Pager: \n > stop_pager() stop the pager output \n > start_pager() start the pager \nPretty printing: \n > stop_pretty_print() stop pretty printing \n > start_pretty_print() start pretty printing \nColor output: \n > stop_color_print() stop color printing \n > start_color_print() start color printing \nPrint function: \n > print(x) std. print function \n > print_plain(x) print without prettifying \n and without colors \n > clear() clear screen "; }),module.define("@arangodb/graph-blueprint",function(a,b){var c=require("@arangodb"),d=require("@arangodb/is"),e=require("@arangodb/graph-common"),f=e.Edge,g=e.Graph,h=e.Vertex,i=e.GraphArray,j=e.Iterator,k=require("@arangodb/api/graph").GraphAPI;f.prototype.setProperty=function(a,b){var c,d=this._properties;return d[a]=b,this._graph.emptyCachedPredecessors(),c=k.putEdge(this._graph._properties._key,this._properties._key,d),this._properties=c.edge,a},h.prototype.edges=function(a,b){var c,d,e=new i;for(d=k.postEdges(this._graph._vertices._database,this._graph._properties._key,this,{filter:{direction:a,labels:b}});d.hasNext();)c=new f(this._graph,d.next()),e.push(c);return e},h.prototype.getInEdges=function(){var a=Array.prototype.slice.call(arguments);return this.edges("in",a)},h.prototype.getOutEdges=function(){var a=Array.prototype.slice.call(arguments);return this.edges("out",a)},h.prototype.getEdges=function(){var a=Array.prototype.slice.call(arguments);return this.edges("any",a)},h.prototype.inbound=function(){return this.getInEdges()},h.prototype.outbound=function(){return this.getOutEdges()},h.prototype.setProperty=function(a,b){var c,d=this._properties;return d[a]=b,c=k.putVertex(this._graph._properties._key,this._properties._key,d),this._properties=c.vertex,a},g.prototype.initialize=function(a,b,e){var f;return d.notExisty(b)&&d.notExisty(e)?f=k.getGraph(a):("object"==typeof b&&"function"==typeof b.name&&(b=b.name()),"object"==typeof e&&"function"==typeof e.name&&(e=e.name()),f=k.postGraph({_key:a,vertices:b,edges:e})),this._properties=f.graph,this._vertices=c.db._collection(this._properties.edgeDefinitions[0].from[0]),this._edges=c.db._collection(this._properties.edgeDefinitions[0].collection),this._verticesCache={},this._edgesCache={},this.predecessors={},this.distances={},this},g.getAll=function(){return k.getAllGraphs()},g.drop=function(a){k.deleteGraph(a)},g.prototype.drop=function(){k.deleteGraph(this._properties._key)},g.prototype._saveEdge=function(a,b,c,d){var e;return this.emptyCachedPredecessors(),d._key=a,d._from=b,d._to=c,e=k.postEdge(this._properties._key,d),new f(this,e.edge)},g.prototype._saveVertex=function(a,b){var c;return d.existy(a)&&(b._key=a),c=k.postVertex(this._properties._key,b),new h(this,c.vertex)},g.prototype._replaceVertex=function(a,b){k.putVertex(this._properties._key,a,b)},g.prototype._replaceEdge=function(a,b){k.putEdge(this._properties._key,a,b)},g.prototype.getVertex=function(a){var b=k.getVertex(this._properties._key,a);return d.notExisty(b)?null:new h(this,b.vertex)},g.prototype.getVertices=function(){var a=k.getVertices(this._vertices._database,this._properties._key,{}),b=this,c=function(a){return new h(b,a)};return new j(c,a,"[vertex iterator]")},g.prototype.getEdge=function(a){var b=k.getEdge(this._properties._key,a);return d.notExisty(b)?null:new f(this,b.edge)},g.prototype.getEdges=function(){var a=k.getEdges(this._vertices._database,this._properties._key,{}),b=this,c=function(a){return new f(b,a)};return new j(c,a,"[edge iterator]")},g.prototype.removeVertex=function(a){this.emptyCachedPredecessors(),k.deleteVertex(this._properties._key,a._properties._key),a._properties=void 0},g.prototype.removeEdge=function(a){this.emptyCachedPredecessors(),k.deleteEdge(this._properties._key,a._properties._key),this._edgesCache[a._properties._id]=void 0,a._properties=void 0},a.Edge=f,a.Graph=g,a.Vertex=h,a.GraphArray=i,require("@arangodb/graph/algorithms-common")}),module.define("@arangodb/index",function(a,b){"use strict";var c=require("internal"),d=require("@arangodb/common");if(Object.keys(d).forEach(function(b){a[b]=d[b]}),a.isServer=!1,a.isClient=!0,a.ArangoCollection=require("@arangodb/arango-collection").ArangoCollection,a.ArangoConnection=c.ArangoConnection,a.ArangoDatabase=require("@arangodb/arango-database").ArangoDatabase,a.ArangoStatement=require("@arangodb/arango-statement").ArangoStatement,a.ArangoQueryCursor=require("@arangodb/arango-query-cursor").ArangoQueryCursor,"undefined"!=typeof c.arango)try{a.arango=c.arango,a.db=new a.ArangoDatabase(c.arango),c.db=a.db}catch(e){c.print("cannot connect to server: "+String(e))}a.plainServerVersion=function(){if(c.arango){var a=c.arango.getVersion(),b=a.match(/(.*)-((alpha|beta|devel|rc)[0-9]*)$/);return null!==b&&(a=b[1]),a}return void 0}}),module.define("@arangodb/replication",function(a,b){"use strict";var c=require("internal"),d=require("@arangodb/arangosh"),e={},f={};e.state=function(){var a=c.db,b=a._connection.GET("/_api/replication/logger-state");return d.checkRequestResult(b),b},e.tickRanges=function(){var a=c.db,b=a._connection.GET("/_api/replication/logger-tick-ranges");return d.checkRequestResult(b),b},e.firstTick=function(){var a=c.db,b=a._connection.GET("/_api/replication/logger-first-tick");return d.checkRequestResult(b),b.firstTick},f.start=function(a,b){var e=c.db,f="";void 0!==a&&(f="?from="+encodeURIComponent(a)),void 0!==b&&(f+=""===f?"?":"&",f+="barrierId="+encodeURIComponent(b));var g=e._connection.PUT("/_api/replication/applier-start"+f,"");return d.checkRequestResult(g),g},f.stop=f.shutdown=function(){var a=c.db,b=a._connection.PUT("/_api/replication/applier-stop","");return d.checkRequestResult(b),b},f.state=function(){var a=c.db,b=a._connection.GET("/_api/replication/applier-state");return d.checkRequestResult(b),b},f.forget=function(){var a=c.db,b=a._connection.DELETE("/_api/replication/applier-state");return d.checkRequestResult(b),b},f.properties=function(a){var b,e=c.db;return b=void 0===a?e._connection.GET("/_api/replication/applier-config"):e._connection.PUT("/_api/replication/applier-config",JSON.stringify(a)),d.checkRequestResult(b),b};var g=function(a,b){var e=c.db;a.hasOwnProperty("progress")||(a.progress=!0),c.sleep(1);for(var g=0;;){var h=e._connection.PUT("/_api/job/"+encodeURIComponent(b),"");if(d.checkRequestResult(h),204!==h.code)return h;if(++g,6>g?c.sleep(2):c.sleep(3),a.progress&&g%3===0)try{var i=f.state().state.progress,j=i.time+": "+i.message;c.print("still sychronizing... last received status: "+j)}catch(k){}}},h=function(a){var b=c.db,e=JSON.stringify(a||{}),f={"X-Arango-Async":"store"},h=b._connection.PUT_RAW("/_api/replication/sync",e,f);return d.checkRequestResult(h),a.async?h.headers["x-arango-async-id"]:g(a,h.headers["x-arango-async-id"])},i=function(a,b){return b=b||{},b.restrictType="include",b.restrictCollections=[a],b.includeSystem=!0,h(b)},j=function(a){a=a||{},a.hasOwnProperty("autoStart")||(a.autoStart=!0),a.hasOwnProperty("includeSystem")||(a.includeSystem=!0),a.hasOwnProperty("verbose")||(a.verbose=!1);var b=c.db,e=JSON.stringify(a),f={"X-Arango-Async":"store"},h=b._connection.PUT_RAW("/_api/replication/make-slave",e,f);return d.checkRequestResult(h),a.async?h.headers["x-arango-async-id"]:g(a,h.headers["x-arango-async-id"])},k=function(a){var b=c.db,e=b._connection.PUT_RAW("/_api/job/"+encodeURIComponent(a),"");return d.checkRequestResult(e),e.headers.hasOwnProperty("x-arango-async-id")?JSON.parse(e.body):!1},l=function(){var a=c.db,b=a._connection.GET("/_api/replication/server-id");return d.checkRequestResult(b),b.serverId};a.logger=e,a.applier=f,a.sync=h,a.syncCollection=i,a.setupReplication=j,a.getSyncResult=k,a.serverId=l}),module.define("@arangodb/simple-query",function(a,b){var c=require("@arangodb/arangosh"),d=require("@arangodb/arango-query-cursor").ArangoQueryCursor,e=require("@arangodb/simple-query-common"),f=e.GeneralArrayCursor,g=e.SimpleQueryAll,h=e.SimpleQueryArray,i=e.SimpleQueryByExample,j=e.SimpleQueryByCondition,k=e.SimpleQueryFulltext,l=e.SimpleQueryGeo,m=e.SimpleQueryNear,n=e.SimpleQueryRange,o=e.SimpleQueryWithin,p=e.SimpleQueryWithinRectangle;g.prototype.execute=function(a){if(null===this._execution){void 0!==a&&a>0&&(this._batchSize=a);var b={collection:this._collection.name()};null!==this._limit&&(b.limit=this._limit),null!==this._skip&&(b.skip=this._skip),null!==this._batchSize&&(b.batchSize=this._batchSize);var e=this._collection._database._connection.PUT("/_api/simple/all",JSON.stringify(b));c.checkRequestResult(e),this._execution=new d(this._collection._database,e),e.hasOwnProperty("count")&&(this._countQuery=e.count)}},i.prototype.execute=function(a){if(null===this._execution){void 0!==a&&a>0&&(this._batchSize=a);var b={collection:this._collection.name(),example:this._example};null!==this._limit&&(b.limit=this._limit),null!==this._skip&&(b.skip=this._skip),null!==this._batchSize&&(b.batchSize=this._batchSize);var e="by-example";if(this.hasOwnProperty("_type"))switch(b.index=this._index,this._type){case"hash":e="by-example-hash";break;case"skiplist":e="by-example-skiplist"}var f=this._collection._database._connection.PUT("/_api/simple/"+e,JSON.stringify(b));c.checkRequestResult(f),this._execution=new d(this._collection._database,f),f.hasOwnProperty("count")&&(this._countQuery=f.count,this._countTotal=f.count)}},j.prototype.execute=function(a){if(null===this._execution){void 0!==a&&a>0&&(this._batchSize=a);var b={collection:this._collection.name(),condition:this._condition};null!==this._limit&&(b.limit=this._limit),null!==this._skip&&(b.skip=this._skip),null!==this._batchSize&&(b.batchSize=this._batchSize);var e="by-condition";if(this.hasOwnProperty("_type"))switch(b.index=this._index,this._type){case"skiplist":e="by-condition-skiplist"}var f=this._collection._database._connection.PUT("/_api/simple/"+e,JSON.stringify(b));c.checkRequestResult(f),this._execution=new d(this._collection._database,f),f.hasOwnProperty("count")&&(this._countQuery=f.count,this._countTotal=f.count)}},n.prototype.execute=function(a){if(null===this._execution){void 0!==a&&a>0&&(this._batchSize=a);var b={collection:this._collection.name(),attribute:this._attribute,right:this._right,left:this._left,closed:1===this._type};null!==this._limit&&(b.limit=this._limit),null!==this._skip&&(b.skip=this._skip),null!==this._batchSize&&(b.batchSize=this._batchSize);var e=this._collection._database._connection.PUT("/_api/simple/range",JSON.stringify(b));c.checkRequestResult(e),this._execution=new d(this._collection._database,e),e.hasOwnProperty("count")&&(this._countQuery=e.count)}},m.prototype.execute=function(a){if(null===this._execution){void 0!==a&&a>0&&(this._batchSize=a);var b={collection:this._collection.name(),latitude:this._latitude,longitude:this._longitude};null!==this._limit&&(b.limit=this._limit),null!==this._skip&&(b.skip=this._skip),null!==this._index&&(b.geo=this._index),null!==this._distance&&(b.distance=this._distance),null!==this._batchSize&&(b.batchSize=this._batchSize);var e=this._collection._database._connection.PUT("/_api/simple/near",JSON.stringify(b));c.checkRequestResult(e),this._execution=new d(this._collection._database,e),e.hasOwnProperty("count")&&(this._countQuery=e.count)}},o.prototype.execute=function(a){if(null===this._execution){void 0!==a&&a>0&&(this._batchSize=a);var b={collection:this._collection.name(),latitude:this._latitude,longitude:this._longitude,radius:this._radius};null!==this._limit&&(b.limit=this._limit),null!==this._skip&&(b.skip=this._skip),null!==this._index&&(b.geo=this._index),null!==this._distance&&(b.distance=this._distance),null!==this._batchSize&&(b.batchSize=this._batchSize);var e=this._collection._database._connection.PUT("/_api/simple/within",JSON.stringify(b));c.checkRequestResult(e),this._execution=new d(this._collection._database,e),e.hasOwnProperty("count")&&(this._countQuery=e.count)}},p.prototype.execute=function(a){if(null===this._execution){void 0!==a&&a>0&&(this._batchSize=a);var b={collection:this._collection.name(),latitude1:this._latitude1,longitude1:this._longitude1,latitude2:this._latitude2,longitude2:this._longitude2};null!==this._limit&&(b.limit=this._limit),null!==this._skip&&(b.skip=this._skip),null!==this._index&&(b.geo=this._index),null!==this._distance&&(b.distance=this._distance),null!==this._batchSize&&(b.batchSize=this._batchSize);var e=this._collection._database._connection.PUT("/_api/simple/within-rectangle",JSON.stringify(b));c.checkRequestResult(e),this._execution=new d(this._collection._database,e),e.hasOwnProperty("count")&&(this._countQuery=e.count)}},k.prototype.execute=function(a){if(null===this._execution){void 0!==a&&a>0&&(this._batchSize=a);var b={collection:this._collection.name(),attribute:this._attribute,query:this._query};null!==this._limit&&(b.limit=this._limit),null!==this._index&&(b.index=this._index),null!==this._skip&&(b.skip=this._skip),null!==this._batchSize&&(b.batchSize=this._batchSize);var e=this._collection._database._connection.PUT("/_api/simple/fulltext",JSON.stringify(b));c.checkRequestResult(e),this._execution=new d(this._collection._database,e),e.hasOwnProperty("count")&&(this._countQuery=e.count)}},a.GeneralArrayCursor=f,a.SimpleQueryAll=g,a.SimpleQueryArray=h,a.SimpleQueryByExample=i,a.SimpleQueryByCondition=j,a.SimpleQueryFulltext=k,a.SimpleQueryGeo=l,a.SimpleQueryNear=m,a.SimpleQueryRange=n,a.SimpleQueryWithin=o,a.SimpleQueryWithinRectangle=p}),module.define("@arangodb/tutorial",function(a,b){var c=0,d="Type 'tutorial' again to get to the next chapter.",e=[{title:"Welcome to the tutorial!",text:"This is a user-interactive tutorial on ArangoDB and the ArangoDB shell.\nIt will give you a first look into ArangoDB and how it works."},{title:"JavaScript Shell",text:"On this shell's prompt, you can issue arbitrary JavaScript commands.\nSo you are able to do things like...:\n\n number = 123;\n number = number * 10;"},{title:"Running Complex Instructions",text:"You can also run more complex instructions, such as for loops:\n\n for (i = 0; i < 10; i++) { number = number + 1; }"},{title:"Printing Results",text:'As you can see, the result of the last command executed is printed automatically. To explicitly print a value at any other time, there is the print function:\n\n for (i = 0; i < 5; ++i) { print("I am a JavaScript shell"); }'},{title:"Creating Collections",text:"ArangoDB is a document database. This means that we store data as documents (which are similar to JavaScript objects) in so-called 'collections'. Let's create a collection named 'places' now:\n\n db._create('places');\n\nNote: each collection is identified by a unique name. Trying to create a collection that already exists will produce an error."},{title:"Displaying Collections",text:"Now you can take a look at the collection(s) you just created:\n\n db._collections();\n\nPlease note that all collections will be returned, including ArangoDB's pre-defined system collections."},{title:"Creating Documents",text:'Now we have a collection, but it is empty. So let\'s create some documents!\n\n db.places.save({ _key : "foo", city : "foo-city" });\n for (i = 0; i <= 10; i++) { db.places.save({ _key: "example" + i, zipcode: i }) };'},{title:"Displaying All Documents",text:"You want to take a look at your docs? No problem:\n\n db.places.toArray();"},{title:"Counting Documents",text:"To see how many documents there are in a collection, use the 'count' method:\n\n db.places.count();"},{title:"Retrieving Single Documents",text:"As you can see, each document has some meta attributes '_id', '_key' and '_rev'.\nThe '_key' attribute can be used to quickly retrieve a single document from a collection:\n\n db.places.document(\"foo\");\n db.places.document(\"example5\");"},{title:"Retrieving Single Documents",text:"The '_id' attribute can also be used to retrieve documents using the 'db' object:\n\n db._document(\"places/foo\");\n db._document(\"places/example5\");"},{title:"Modifying Documents",text:'You can modify existing documents. Try to add a new attribute to a document and verify whether it has been added:\n\n db._update("places/foo", { zipcode: 39535 });\n db._document("places/foo");'},{title:"Document Revisions",text:"Note that after updating the document, its '_rev' attribute changed automatically.\nThe '_rev' attribute contains a document revision number, and it can be used for conditional modifications. Here's an example of how to avoid lost updates in case multiple clients are accessing the documents in parallel:\n\n doc = db._document(\"places/example1\");\n db._update(\"places/example1\", { someValue: 23 });\n db._update(doc, { someValue: 42 });\n\nNote that the first update will succeed because it was unconditional. The second update however is conditional because we're also passing the document's revision id in the first parameter to _update. As the revision id we're passing to update does not match the document's current revision anymore, the update is rejected."},{title:"Removing Documents",text:'Deleting single documents can be achieved by providing the document _id or _key:\n\n db._remove("places/example7");\n db.places.remove("example8");\n db.places.count();'},{title:"Searching Documents",text:'Searching for documents with specific attributes can be done by using the byExample method:\n\n db._create("users");\n for (i = 0; i < 10; ++i) { db.users.save({ name: "username" + i, active: (i % 3 == 0), age: 30 + i }); }\n db.users.byExample({ active: false }).toArray();\n db.users.byExample({ name: "username3", active: true }).toArray();\n'},{title:"Running AQL Queries",text:'ArangoDB also provides a query language for more complex matching:\n\n db._query("FOR u IN users FILTER u.active == true && u.age >= 33 RETURN { username: u.name, age: u.age }").toArray();'},{title:"Using Databases",text:"By default, the ArangoShell connects to the default database. The default database is named '_system'. To create another database, use the '_createDatabase' method of the 'db' object. To switch into an existing database, use '_useDatabase'. To get rid of a database and all of its collections, use '_dropDatabase':\n\n db._createDatabase(\"mydb\");\n db._useDatabase(\"mydb\");\n db._dropDatabase(\"mydb\");"}];a._PRINT=function(a){function b(a){return a.replace(/\n {2}(.+?)(?=\n)/g,"\n "+f.COLOR_MAGENTA+"$1"+f.COLOR_RESET)}var f=require("internal").COLORS,g=f.COLOR_BOLD_BLUE+(c+1)+". "+e[c].title+f.COLOR_RESET;a.output+="\n\n"+g+"\n\n"+b(e[c].text+"\n")+"\n",++c,c>=e.length?(a.output+="Congratulations! You finished the tutorial.\n",c=0):a.output+=d+"\n"}}),module.define("@arangodb/aql/explainer",function(a,b){function c(a){"use strict";["COLOR_RESET","COLOR_CYAN","COLOR_BLUE","COLOR_GREEN","COLOR_MAGENTA","COLOR_YELLOW","COLOR_RED","COLOR_WHITE","COLOR_BOLD_CYAN","COLOR_BOLD_BLUE","COLOR_BOLD_GREEN","COLOR_BOLD_MAGENTA","COLOR_BOLD_YELLOW","COLOR_BOLD_RED","COLOR_BOLD_WHITE"].forEach(function(b){C[b]=a?A[b]:""})}function d(a,b){"use strict";return a&&a.subNodes&&a.subNodes.length>1?"("+b+")":b}function e(a){"use strict";return"`"+a+"`"}function f(a){"use strict";return C.COLOR_CYAN+a+C.COLOR_RESET}function g(a){"use strict";return C.COLOR_BLUE+a+C.COLOR_RESET}function h(a){"use strict";return"string"==typeof a&&a.length>1024?C.COLOR_GREEN+a.substr(0,1024)+"..."+C.COLOR_RESET:C.COLOR_GREEN+a+C.COLOR_RESET}function i(a){"use strict";return"#"===a[0]?C.COLOR_MAGENTA+a+C.COLOR_RESET:C.COLOR_YELLOW+a+C.COLOR_RESET}function j(a){"use strict";return C.COLOR_GREEN+a+C.COLOR_RESET}function k(a){"use strict";return C.COLOR_RED+a+C.COLOR_RESET}function l(a){"use strict";return"`"+C.COLOR_YELLOW+a+C.COLOR_RESET+"`"}function m(a){"use strict";return C.COLOR_MAGENTA+a+C.COLOR_RESET}function n(a){"use strict";return C.COLOR_BOLD_BLUE+a+C.COLOR_RESET}function o(a){"use strict";return 0>a&&(a=0),new Array(a).join(" ")}function p(a,b){"use strict";var c=".{1,"+b+"}(\\s|$)|\\S+?(\\s|$)";return a.match(new RegExp(c,"g")).join("\n")}function q(a){"use strict";var b=4096;a.length>b?(D.appendLine(n("Query string (truncated):")),a=a.substr(0,b/2)+" ... "+a.substr(a.length-b/2)):D.appendLine(n("Query string:")),D.appendLine(" "+h(p(a,100).replace(/\n+/g,"\n ",a))),D.appendLine()}function r(a){"use strict";if(void 0!==a){D.appendLine(n("Write query options:"));var b=Object.keys(a),c="Option".length;b.forEach(function(a){a.length>c&&(c=a.length)}),D.appendLine(" "+m("Option")+o(1+c-"Option".length)+" "+m("Value")),b.forEach(function(b){D.appendLine(" "+f(b)+o(1+c-b.length)+" "+h(JSON.stringify(a[b])))}),D.appendLine()}}function s(a){"use strict";if(D.appendLine(n("Optimization rules applied:")),0===a.length)D.appendLine(" "+h("none"));else{var b=String("Id").length;D.appendLine(" "+o(1+b-String("Id").length)+m("Id")+" "+m("RuleName"));for(var c=0;cb&&(b=d),d=a.type.length,d>j&&(j=d),d=a.fields.map(e).join(", ").length+"[ ]".length,d>q&&(q=d),d=a.collection.length,d>c&&(c=d)});var r=" "+o(1+b-String("By").length)+m("By")+" "+m("Type")+o(1+j-"Type".length)+" "+m("Collection")+o(1+c-"Collection".length)+" "+m("Unique")+o(1+d-"Unique".length)+" "+m("Sparse")+o(1+g-"Sparse".length)+" "+m("Selectivity")+" "+m("Fields")+o(1+q-"Fields".length)+" "+m("Ranges");D.appendLine(r);for(var s=0;sb&&(b=g),a.minMaxDepthLen>c&&(c=a.minMaxDepthLen),a.hasOwnProperty("ConditionStr")&&a.ConditionStr.length>f&&(f=a.ConditionStr.length),a.hasOwnProperty("vertexCollectionNameStr")&&a.vertexCollectionNameStrLen>d&&(d=a.vertexCollectionNameStrLen),a.hasOwnProperty("edgeCollectionNameStr")&&a.edgeCollectionNameStrLen>e&&(e=a.edgeCollectionNameStrLen)});var g=" "+o(1+b-String("Id").length)+m("Id")+" "+m("Depth")+o(1+c-String("Depth").length)+" "+m("Vertex collections")+o(1+d-"Vertex collections".length)+" "+m("Edge collections")+o(1+e-"Edge collections".length)+" "+m("Filter conditions");D.appendLine(g);for(var h=0;hz&&(z=String(a.id).length),String(a.type).length>w&&(w=String(a.type).length),String(a.site).length>x&&(x=String(a.site).length),String(a.estimatedNrItems).length>A&&(A=String(a.estimatedNrItems).length)});for(var d=a.length,f="COOR";d>0;){--d;var g=a[d];g.site=f,"RemoteNode"===g.type&&(f="COOR"===f?"DBS":"COOR")}};F(C.nodes,0);var G,H={},I={},J={},K=[],L=[],M=!0,N=null,O=function(a){try{if(/^[0-9_]/.test(a.name))return i("#"+a.name)}catch(b){throw B(a),b}return I.hasOwnProperty(a.id)&&(J[a.name]=I[a.id]),i(a.name)},P=function(){},Q=function ga(a){var c=!0;a:for(;c;){var e=a;i=m=n=o=p=q=r=s=void 0,c=!1;var i=function(a,b){var c=ga(a.subNodes[0]),d=ga(a.subNodes[1]);return 3===a.subNodes.length&&(b=a.subNodes[2].quantifier+" "+b),a.sorted?c+" "+b+" "+g("/* sorted */")+" "+d:c+" "+b+" "+d};if(M=M&&-1!==["value","object","object element","array"].indexOf(e.type),"attribute access"!==e.type&&e.hasOwnProperty("subNodes"))for(var m=0;m20?"{ "+e.subNodes.slice(0,20).map(ga).join(", ")+", ... }":"{ "+e.subNodes.map(ga).join(", ")+" }":"{ }";case"object element":return h(JSON.stringify(e.name))+" : "+ga(e.subNodes[0]);case"calculated object element":return"[ "+ga(e.subNodes[0])+" ] : "+ga(e.subNodes[1]);case"array":return e.hasOwnProperty("subNodes")?e.subNodes.length>20?"[ "+e.subNodes.slice(0,20).map(ga).join(", ")+", ... ]":"[ "+e.subNodes.map(ga).join(", ")+" ]":"[ ]";case"unary not":return"! "+ga(e.subNodes[0]);case"unary plus":return"+ "+ga(e.subNodes[0]);case"unary minus":return"- "+ga(e.subNodes[0]);case"array limit":return ga(e.subNodes[0])+", "+ga(e.subNodes[1]);case"attribute access":if("reference"===e.subNodes[0].type&&I.hasOwnProperty(e.subNodes[0].id)){var p=I[e.subNodes[0].id],q=y._collection(p);if(null!==q){var r=3===q.type(),s="_"===e.name[0];(s&&-1===["_key","_id","_rev"].concat(r?["_from","_to"]:[]).indexOf(e.name)||!s&&r&&-1!==["from","to"].indexOf(e.name))&&P(b.warnings,N,"reference to potentially non-existing attribute '"+e.name+"'")}}return ga(e.subNodes[0])+"."+l(e.name);case"indexed access":return ga(e.subNodes[0])+"["+ga(e.subNodes[1])+"]";case"range":return ga(e.subNodes[0])+" .. "+ga(e.subNodes[1])+" "+g("/* range */");case"expand":case"expansion":e.subNodes.length>2?H[e.subNodes[0].subNodes[0].name]=[e.levels,e.subNodes[0].subNodes[1],e.subNodes[2],e.subNodes[3],e.subNodes[4]]:H[e.subNodes[0].subNodes[0].name]=e.subNodes[0].subNodes[1],a=e.subNodes[1],c=!0;continue a;case"user function call":return j(e.name)+"("+(e.subNodes&&e.subNodes[0].subNodes||[]).map(ga).join(", ")+") "+g("/* user-defined function */");case"function call":return j(e.name)+"("+(e.subNodes&&e.subNodes[0].subNodes||[]).map(ga).join(", ")+")";case"plus":return"("+i(e,"+")+")";case"minus":return"("+i(e,"-")+")";case"times":return"("+i(e,"*")+")";case"division":return"("+i(e,"/")+")";case"modulus":return"("+i(e,"%")+")";case"compare not in":case"array compare not in":return"("+i(e,"not in")+")";case"compare in":case"array compare in":return"("+i(e,"in")+")";case"compare ==":case"array compare ==":return"("+i(e,"==")+")";case"compare !=":case"array compare !=":return"("+i(e,"!=")+")";case"compare >":case"array compare >":return"("+i(e,">")+")";case"compare >=":case"array compare >=":return"("+i(e,">=")+")";case"compare <":case"array compare <":return"("+i(e,"<")+")";case"compare <=":case"array compare <=":return"("+i(e,"<=")+")";case"logical or":return"("+i(e,"||")+")";case"logical and":return"("+i(e,"&&")+")";case"ternary":return"("+ga(e.subNodes[0])+" ? "+ga(e.subNodes[1])+" : "+ga(e.subNodes[2])+")";case"n-ary or":return e.hasOwnProperty("subNodes")?d(e,e.subNodes.map(function(a){return ga(a)}).join(" || ")):"";case"n-ary and":return e.hasOwnProperty("subNodes")?d(e,e.subNodes.map(function(a){return ga(a)}).join(" && ")):"";default:return"unhandled node type ("+e.type+")"}}},R=function(a){var b="";for(var c in a)if(a.hasOwnProperty(c)){b.length>0&&(b+=" AND ");for(var d=0;d ",b+=Q(e.varAccess),b+=" "+e.comparisonTypeStr+" ",b+=Q(e.compareTo)}}return b},S=function(a,b,c){var d=c.isConstant?h(JSON.stringify(c.bound)):Q(c.bound);return l(a)+" "+b[c.include?1:0]+" "+d},T=function(a){var b=[];return a.forEach(function(a){var c=a.attr;a.lowConst.hasOwnProperty("bound")&&a.highConst.hasOwnProperty("bound")&&JSON.stringify(a.lowConst.bound)===JSON.stringify(a.highConst.bound)&&(a.equality=!0),a.equality?a.lowConst.hasOwnProperty("bound")?b.push(S(c,["==","=="],a.lowConst)):a.hasOwnProperty("lows")&&a.lows.forEach(function(a){b.push(S(c,["==","=="],a))}):(a.lowConst.hasOwnProperty("bound")&&b.push(S(c,[">",">="],a.lowConst)),a.highConst.hasOwnProperty("bound")&&b.push(S(c,["<","<="],a.highConst)),a.hasOwnProperty("lows")&&a.lows.forEach(function(a){b.push(S(c,[">",">="],a))}),a.hasOwnProperty("highs")&&a.highs.forEach(function(a){b.push(S(c,["<","<="],a))}))}),b.length>1?"("+b.join(" && ")+")":b[0]},U=function(a){switch(a.type){case"SingletonNode":return f("ROOT");case"NoResultsNode":return f("EMPTY")+" "+g("/* empty result set */");case"EnumerateCollectionNode":return I[a.outVariable.id]=a.collection,f("FOR")+" "+O(a.outVariable)+" "+f("IN")+" "+k(a.collection)+" "+g("/* full collection scan"+(a.random?", random order":"")+" */");case"EnumerateListNode":return f("FOR")+" "+O(a.outVariable)+" "+f("IN")+" "+O(a.inVariable)+" "+g("/* list iteration */");case"IndexNode":I[a.outVariable.id]=a.collection;var b=[];return a.indexes.forEach(function(c,d){var e=(a.reverse?"reverse ":"")+c.type+" index scan";(0===b.length||e!==b[b.length-1])&&b.push(e),c.collection=a.collection,c.node=a.id,a.condition.type&&"n-ary or"===a.condition.type?c.condition=Q(a.condition.subNodes[d]):c.condition="*",K.push(c)}),f("FOR")+" "+O(a.outVariable)+" "+f("IN")+" "+k(a.collection)+" "+g("/* "+b.join(", ")+" */");case"IndexRangeNode":I[a.outVariable.id]=a.collection;var c=a.index;return c.ranges=a.ranges.map(T).join(" || "),c.collection=a.collection,c.node=a.id,K.push(c),f("FOR")+" "+O(a.outVariable)+" "+f("IN")+" "+k(a.collection)+" "+g("/* "+(a.reverse?"reverse ":"")+a.index.type+" index scan */");case"TraversalNode":a.minMaxDepth=a.minDepth+".."+a.maxDepth,a.minMaxDepthLen=a.minMaxDepth.length;var d=f("FOR ")+O(a.vertexOutVariable)+" "+g("/* vertex */");a.hasOwnProperty("edgeOutVariable")&&(d+=" , "+O(a.edgeOutVariable)+" "+g("/* edge */")),a.hasOwnProperty("pathOutVariable")&&(d+=" , "+O(a.pathOutVariable)+" "+g("/* paths */")),d+=" "+f("IN")+" "+h(a.minMaxDepth)+" "+g("/* min..maxPathDepth */")+" ";var e=["ANY","INBOUND","OUTBOUND"],i=a.directions[0];d+=f(e[i]),d+=a.hasOwnProperty("vertexId")?" '"+h(a.vertexId)+"' ":" "+O(a.inVariable)+" ",d+=g("/* startnode */")+" ",d+=Array.isArray(a.graph)?a.graph.map(function(b,c){var d="";return a.directions[c]!==i&&(d+=f(e[a.directions[c]]),d+=" "),d+k(b)}).join(", "):f("GRAPH")+" '"+h(a.graph)+"'",L.push(a),a.hasOwnProperty("simpleExpressions")&&(a.ConditionStr=R(a.simpleExpressions));var l=[];if(a.hasOwnProperty("graphDefinition")){var m=[];a.graphDefinition.vertexCollectionNames.forEach(function(a){ m.push(k(a))}),a.vertexCollectionNameStr=m.join(", "),a.vertexCollectionNameStrLen=a.graphDefinition.vertexCollectionNames.join(", ").length,a.graphDefinition.edgeCollectionNames.forEach(function(a){l.push(k(a))}),a.edgeCollectionNameStr=l.join(", "),a.edgeCollectionNameStrLen=a.graphDefinition.edgeCollectionNames.join(", ").length}else{var n=a.graph||[];n.forEach(function(a){l.push(k(a))}),a.edgeCollectionNameStr=l.join(", "),a.edgeCollectionNameStrLen=n.join(", ").length,a.graph=""}return d;case"CalculationNode":return f("LET")+" "+O(a.outVariable)+" = "+Q(a.expression)+" "+g("/* "+a.expressionType+" expression */");case"FilterNode":return f("FILTER")+" "+O(a.inVariable);case"AggregateNode":return f("COLLECT")+" "+a.aggregates.map(function(a){return O(a.outVariable)+" = "+O(a.inVariable)}).join(", ")+(a.count?" "+f("WITH COUNT"):"")+(a.outVariable?" "+f("INTO")+" "+O(a.outVariable):"")+(a.keepVariables?" "+f("KEEP")+" "+a.keepVariables.map(function(a){return O(a)}).join(", "):"")+" "+g("/* "+a.aggregationOptions.method+" */");case"CollectNode":var o=f("COLLECT")+" "+a.groups.map(function(a){return O(a.outVariable)+" = "+O(a.inVariable)}).join(", ");return a.hasOwnProperty("aggregates")&&a.aggregates.length>0&&(a.groups.length>0&&(o+=" "),o+=f("AGGREGATE")+" "+a.aggregates.map(function(a){return O(a.outVariable)+" = "+j(a.type)+"("+O(a.inVariable)+")"}).join(", ")),o+=(a.count?" "+f("WITH COUNT"):"")+(a.outVariable?" "+f("INTO")+" "+O(a.outVariable):"")+(a.keepVariables?" "+f("KEEP")+" "+a.keepVariables.map(function(a){return O(a)}).join(", "):"")+" "+g("/* "+a.collectOptions.method+"*/");case"SortNode":return f("SORT")+" "+a.elements.map(function(a){return O(a.inVariable)+" "+f(a.ascending?"ASC":"DESC")}).join(", ");case"LimitNode":return f("LIMIT")+" "+h(JSON.stringify(a.offset))+", "+h(JSON.stringify(a.limit));case"ReturnNode":return f("RETURN")+" "+O(a.inVariable);case"SubqueryNode":return f("LET")+" "+O(a.outVariable)+" = ... "+g("/* subquery */");case"InsertNode":return G=a.modificationFlags,f("INSERT")+" "+O(a.inVariable)+" "+f("IN")+" "+k(a.collection);case"UpdateNode":return G=a.modificationFlags,a.hasOwnProperty("inKeyVariable")?f("UPDATE")+" "+O(a.inKeyVariable)+" "+f("WITH")+" "+O(a.inDocVariable)+" "+f("IN")+" "+k(a.collection):f("UPDATE")+" "+O(a.inDocVariable)+" "+f("IN")+" "+k(a.collection);case"ReplaceNode":return G=a.modificationFlags,a.hasOwnProperty("inKeyVariable")?f("REPLACE")+" "+O(a.inKeyVariable)+" "+f("WITH")+" "+O(a.inDocVariable)+" "+f("IN")+" "+k(a.collection):f("REPLACE")+" "+O(a.inDocVariable)+" "+f("IN")+" "+k(a.collection);case"UpsertNode":return G=a.modificationFlags,f("UPSERT")+" "+O(a.inDocVariable)+" "+f("INSERT")+" "+O(a.insertVariable)+" "+f(a.isReplace?"REPLACE":"UPDATE")+" "+O(a.updateVariable)+" "+f("IN")+" "+k(a.collection);case"RemoveNode":return G=a.modificationFlags,f("REMOVE")+" "+O(a.inVariable)+" "+f("IN")+" "+k(a.collection);case"RemoteNode":return f("REMOTE");case"DistributeNode":return f("DISTRIBUTE");case"ScatterNode":return f("SCATTER");case"GatherNode":return f("GATHER")}return"unhandled node type ("+a.type+")"},V=0,W=[],X=function(a,b){return o(1+a+a)+(b?"* ":"- ")},Y=function(a){J={},N=a.id,M=!0,"SubqueryNode"===a.type&&W.push(V)},Z=function(a){var b=!e.hasOwnProperty(a.id);-1!==["EnumerateCollectionNode","EnumerateListNode","IndexRangeNode","IndexNode","SubqueryNode"].indexOf(a.type)?V++:b&&W.length>0?V=W.pop():"SingletonNode"===a.type&&V++},$=function(){return M?" "+g("/* const assignment */"):""},_=function(){var a=[];for(var b in J)J.hasOwnProperty(b)&&a.push(i(b)+" : "+k(J[b]));return a.length>0?" "+g("/* collections used:")+" "+a.join(", ")+" "+g("*/"):""},aa=function(a){Y(a);var b=" "+o(1+z-String(a.id).length)+i(a.id)+" "+f(a.type)+o(1+w-String(a.type).length)+" ";E&&E.isCluster&&E.isCluster()&&(b+=i(a.site)+o(1+x-String(a.site).length)+" "),b+=o(1+A-String(a.estimatedNrItems).length)+h(a.estimatedNrItems)+" "+X(V,"SingletonNode"===a.type)+U(a),"CalculationNode"===a.type&&(b+=_()+$()),D.appendLine(b),Z(a)};q(a),D.appendLine(n("Execution plan:"));var ba=" "+o(1+z-String("Id").length)+m("Id")+" "+m("NodeType")+o(1+w-String("NodeType").length)+" ";E&&E.isCluster&&E.isCluster()&&(ba+=m("Site")+o(1+x-String("Site").length)+" "),ba+=o(1+A-String("Est.").length)+m("Est.")+" "+m("Comment"),D.appendLine(ba);for(var ca=[p];ca.length>0;){var da=ca.pop(),ea=c[da];aa(ea),e.hasOwnProperty(da)&&(ca=ca.concat(e[da])),"SubqueryNode"===ea.type&&(ca=ca.concat([ea.subquery.nodes[0].id]))}D.appendLine(),u(K),v(L),D.appendLine(),s(C.rules),r(G),t(b.warnings)}function x(a,b,d){"use strict";if("string"==typeof a&&(a={query:a}),!(a instanceof Object))throw"ArangoStatement needs initial data";void 0===b&&(b=a.options),b=b||{},c(void 0===b.colors?!0:b.colors);var e=y._createStatement(a),f=e.explain(b);return D.clearOutput(),w(a.query,f,!0),void 0===d||d?void B(D.getOutput()):D.getOutput()}var y=require("@arangodb").db,z=require("internal"),A=z.COLORS,B=z.print,C={};"function"==typeof z.printBrowser&&(B=z.printBrowser);var D={output:"",appendLine:function(a){a?this.output+=a+"\n":this.output+="\n"},getOutput:function(){return this.output},clearOutput:function(){this.output=""}};a.explain=x}),module.define("@arangodb/aql/functions",function(a,b){var c=require("internal"),d=require("@arangodb"),e=d.db,f=d.ArangoError,g=function(){"use strict";var a=e._collection("_aqlfunctions");if(null===a){var b=new f;throw b.errorNum=d.errors.ERROR_ARANGO_COLLECTION_NOT_FOUND.code,b.errorMessage="collection '_aqlfunctions' not found",b}return a},h=function(a){"use strict";var b=[];if(null!==a&&void 0!==a&&a.length>0){var c=a.toUpperCase();a.length>1&&"::"!==a.substr(a.length-2,2)&&(c+="::"),g().toArray().forEach(function(a){a.name.toUpperCase().substr(0,c.length)===c&&b.push(a)})}else b=g().toArray();return b},i=function(a){"use strict";if("string"!=typeof a||!a.match(/^[a-zA-Z0-9_]+(::[a-zA-Z0-9_]+)+$/)||"_"===a.substr(0,1)){var b=new f;throw b.errorNum=d.errors.ERROR_QUERY_FUNCTION_INVALID_NAME.code,b.errorMessage=d.errors.ERROR_QUERY_FUNCTION_INVALID_NAME.message,b}},j=function(a,b){"use strict";if("function"==typeof a&&(a=String(a)+"\n"),"string"==typeof a){if(a="("+a+"\n)",!c.parse)return a;try{if(c.parse(a,b))return a}catch(e){}}var g=new f;throw g.errorNum=d.errors.ERROR_QUERY_FUNCTION_INVALID_CODE.code,g.errorMessage=d.errors.ERROR_QUERY_FUNCTION_INVALID_CODE.message,g},k=function(a){"use strict";var b=null;i(a);try{b=g().document(a.toUpperCase())}catch(e){}if(null===b){var h=new f;throw h.errorNum=d.errors.ERROR_QUERY_FUNCTION_NOT_FOUND.code,h.errorMessage=c.sprintf(d.errors.ERROR_QUERY_FUNCTION_NOT_FOUND.message,a),h}return g().remove(b._id),c.reloadAqlFunctions(),!0},l=function(a){"use strict";if(0===a.length){var b=new f;throw b.errorNum=d.errors.ERROR_BAD_PARAMETER.code,b.errorMessage=d.errors.ERROR_BAD_PARAMETER.message,b}var e=0;return h(a).forEach(function(a){g().remove(a._id),e++}),e>0&&c.reloadAqlFunctions(),e},m=function(a,b,h){i(a),b=j(b,a);var k,l="(function() { var callback = "+b+"; return callback; })()";try{if(c&&c.hasOwnProperty("executeScript")){var m=c.executeScript(l,void 0,"(user function "+a+")");if("function"!=typeof m)throw k=new f,k.errorNum=d.errors.ERROR_QUERY_FUNCTION_INVALID_CODE.code,k.errorMessage=d.errors.ERROR_QUERY_FUNCTION_INVALID_CODE.message+": code must be contained in function",k}}catch(n){throw k=new f,k.errorNum=d.errors.ERROR_QUERY_FUNCTION_INVALID_CODE.code,k.errorMessage=d.errors.ERROR_QUERY_FUNCTION_INVALID_CODE.message,k}var o=e._executeTransaction({collections:{write:g().name()},action:function(a){var b=!1,c=require("internal").db._collection(a.collection),d=a.name;try{var e=c.document(d.toUpperCase());null!==e&&(c.remove(e._key),b=!0)}catch(f){}var g={_key:d.toUpperCase(),name:d,code:a.code,isDeterministic:a.isDeterministic||!1};return c.save(g),b},params:{name:a,code:b,isDeterministic:h,collection:g().name()}});return c.reloadAqlFunctions(),o},n=function(a){"use strict";var b=[];return h(a).forEach(function(a){b.push({name:a.name,code:a.code.substr(1,a.code.length-2).trim()})}),b};a.unregister=k,a.unregisterGroup=l,a.register=m,a.toArray=n}),module.define("@arangodb/arango-collection-common",function(a,b){var c=require("@arangodb/arango-collection").ArangoCollection,d=require("@arangodb"),e=d.ArangoError,f=d.sprintf,g=d.db,h=require("@arangodb/simple-query"),i=h.SimpleQueryAll,j=h.SimpleQueryByExample,k=h.SimpleQueryByCondition,l=h.SimpleQueryRange,m=h.SimpleQueryGeo,n=h.SimpleQueryNear,o=h.SimpleQueryWithin,p=h.SimpleQueryWithinRectangle,q=h.SimpleQueryFulltext;c.STATUS_CORRUPTED=0,c.STATUS_NEW_BORN=1,c.STATUS_UNLOADED=2,c.STATUS_LOADED=3,c.STATUS_UNLOADING=4,c.STATUS_DELETED=5,c.STATUS_LOADING=6,c.TYPE_DOCUMENT=2,c.TYPE_EDGE=3,c.prototype._PRINT=function(a){var b="unknown",d="unknown",e=this.name();switch(this.status()){case c.STATUS_NEW_BORN:b="new born";break;case c.STATUS_UNLOADED:b="unloaded";break;case c.STATUS_UNLOADING:b="unloading";break;case c.STATUS_LOADED:b="loaded";break;case c.STATUS_CORRUPTED:b="corrupted";break;case c.STATUS_DELETED:b="deleted"}switch(this.type()){case c.TYPE_DOCUMENT:d="document";break;case c.TYPE_EDGE:d="edge"}var f=require("internal").COLORS,g=a.useColor;a.output+="[ArangoCollection ",g&&(a.output+=f.COLOR_NUMBER),a.output+=this._id,g&&(a.output+=f.COLOR_RESET),a.output+=', "',g&&(a.output+=f.COLOR_STRING),a.output+=e||"unknown",g&&(a.output+=f.COLOR_RESET),a.output+='" (type '+d+", status "+b+")]"},c.prototype.toString=function(){return"[ArangoCollection: "+this._id+"]"},c.prototype.all=function(){return new i(this)},c.prototype.byExample=function(a){var b,c;if(1===arguments.length)b=a;else for(b={},c=0;c=1?h=this.all():(c=f("FOR d IN %s FILTER rand() >= @prob RETURN d",this.name()),c=g._createStatement({query:c}),1>j&&c.bind("prob",j),h=c.execute());else{if("number"!=typeof k){var l=new e;throw l.errorNum=d.errors.ERROR_ILLEGAL_NUMBER.code,l.errorMessage="expecting a number, got "+String(k),l}j>=1?h=this.all().limit(k):(c=f("FOR d IN %s FILTER rand() >= @prob LIMIT %d RETURN d",this.name(),k),c=g._createStatement({query:c}),1>j&&c.bind("prob",j),h=c.execute())}for(i=0;h.hasNext();){var m=h.next();a(m,i),i++}},c.prototype.removeByExample=function(a,b,c){throw"cannot call abstract removeByExample function"},c.prototype.replaceByExample=function(a,b,c,d){throw"cannot call abstract replaceByExample function"},c.prototype.updateByExample=function(a,b,c,d,e){throw"cannot call abstract updateExample function"}}),module.define("@arangodb/arango-statement-common",function(a,b){function c(a,b){if(this._database=a,this._doCount=!1,this._batchSize=null,this._bindVars={},this._options=void 0,this._cache=void 0,!b)throw"ArangoStatement needs initial data";if("string"==typeof b?b={query:b}:"object"==typeof b&&"function"==typeof b.toAQL&&(b={query:b.toAQL()}),!(b instanceof Object))throw"ArangoStatement needs initial data";if(void 0===b.query||""===b.query)throw"ArangoStatement needs a valid query attribute";this.setQuery(b.query),b.bindVars instanceof Object&&this.bind(b.bindVars),b.options instanceof Object&&this.setOptions(b.options),void 0!==b.count&&this.setCount(b.count),void 0!==b.batchSize&&this.setBatchSize(b.batchSize),void 0!==b.cache&&this.setCache(b.cache)}c.prototype.bind=function(a,b){if(a instanceof Object){if(void 0!==b)throw"invalid bind parameter declaration";this._bindVars=a}else if("string"==typeof a)this._bindVars[a]=b;else{if("number"!=typeof a)throw"invalid bind parameter declaration";var c=String(parseInt(a,10));if(c!==String(a))throw"invalid bind parameter declaration";this._bindVars[c]=b}},c.prototype.getBindVariables=function(){return this._bindVars},c.prototype.getCache=function(){return this._cache},c.prototype.getCount=function(){return this._doCount},c.prototype.getBatchSize=function(){return this._batchSize},c.prototype.getOptions=function(){return this._options},c.prototype.getQuery=function(){return this._query},c.prototype.setCache=function(a){this._cache=a?!0:!1},c.prototype.setCount=function(a){this._doCount=a?!0:!1},c.prototype.setBatchSize=function(a){var b=parseInt(a,10);b>0&&(this._batchSize=b)},c.prototype.setOptions=function(a){this._options=a},c.prototype.setQuery=function(a){this._query=a&&"function"==typeof a.toAQL?a.toAQL():a},c.prototype.parse=function(){throw"cannot call abstract method parse()"},c.prototype.explain=function(){throw"cannot call abstract method explain()"},c.prototype.execute=function(){throw"cannot call abstract method execute()"},a.ArangoStatement=c}),module.define("@arangodb/common",function(a,b){"use strict";var c=require("internal"),d=require("fs"),e=require("@arangodb/mimetypes").mimeTypes;Object.keys(c.errors).forEach(function(b){a[b]=c.errors[b].code}),a.errors=c.errors,a.ArangoError=c.ArangoError,a.defineModule=function(a,e){var f,g,h;f=d.read(e),h=c.db._collection("_modules"),null===h&&(h=c.db._create("_modules",{isSystem:!0})),a=b.normalize(a),g=h.firstExample({path:a}),null===g?h.save({path:a,content:f}):h.replace(g,{path:a,content:f})},a.guessContentType=function(a,b){var c=/\.([a-zA-Z0-9]+)$/,d=c.exec(a);if(null!==d){var f=d[1];if(e.hasOwnProperty(f)){var g=e[f];return g[1]?g[0]+"; charset=utf-8":g[0]}}return b?b:"text/plain; charset=utf-8"},a.normalizeURL=function(a){var b,c,d,e,f,g;if(""===a)return"./";for(d=a.split("/"),"."===d[0]||".."===d[0]?(f=d[0]+"/",d.shift(),e=d):""===d[0]?(f="/",d.shift(),e=d):(f="./",e=d),c=[],b=0;b0&&(l=d[h]>=k.length?d[h]:k.length);var m=h;e.hasOwnProperty("rename")&&e.rename.hasOwnProperty(h)&&(m=e.rename[h]),f.push({id:h,fixedLength:l,length:l||m.length}),g[0][j++]=m}b.forEach(function(a,b){g[b+1]=[],f.forEach(function(c){if(a.hasOwnProperty(c.id)){var d;d=e.prettyStrings&&"string"==typeof a[c.id]?a[c.id]:JSON.stringify(a[c.id])||"",g[b+1].push(d),d.length>c.length&&!c.fixedLength&&(c.length=Math.min(d.length,100))}else g[b+1].push("")})});var n=function(){var b=[];return f.forEach(function(c){b.push(a.stringPadding("",c.length,"-","r"))}),e.framed?"+-"+b.join("-+-")+"-+\n":b.join(" ")+"\n"},o=function(){var d="";return e.framed&&(d+=n()),g.forEach(function(b,c){var g=[];b.forEach(function(c,d){var e=f[d].length,h=b[d];h.length>e&&(h=h.substr(0,e-k.length)+k),g.push(a.stringPadding(h,e," ","r"))}),d+=e.framed?"| "+g.join(" | ")+" |\n":g.join(" ")+"\n",0===c&&(d+=n())}),d+=n(),e.hideTotal||(d+=c.sprintf(e.totalString,String(b.length))),d};Array.isArray(b)&&(0===b.length?a.print(e.emptyString||"no document(s)"):a.print(o()))},a.stringPadding=function(a,b,c,d){function e(a,b){var c,d="";for(c=0;a>c;++c)d+=b;return d}if("undefined"==typeof b&&(b=0),"undefined"==typeof c&&(c=" "),b+1>=a.length)switch(d||"r"){case"l":a=e(b+1-a.length,c)+a;break;case"b":var f=b-a.length,g=Math.ceil(f/2),h=f-g;a=e(h+1,c)+a+e(g+1,c);break;default:a+=e(b+1-a.length,c)}return a},a.throwDownloadError=function(b){throw new a.ArangoError({errorNum:a.errors.ERROR_APPLICATION_DOWNLOAD_FAILED.code,errorMessage:a.errors.ERROR_APPLICATION_DOWNLOAD_FAILED.message+": "+String(b)})},a.throwFileNotFound=function(b){throw new a.ArangoError({errorNum:a.errors.ERROR_FILE_NOT_FOUND.code,errorMessage:a.errors.ERROR_FILE_NOT_FOUND.message+": "+String(b)})},a.throwBadParameter=function(b){throw new a.ArangoError({errorNum:a.errors.ERROR_BAD_PARAMETER.code,errorMessage:a.errors.ERROR_BAD_PARAMETER.message+": "+String(b)})},a.checkParameter=function(b,c,d){var e;for(e=0;e0){var h=new f;throw h.errorNum=c.errors.ERROR_BAD_PARAMETER.code,h.errorMessage=d+": "+e.join(" and ")+" are not known to the graph",h}return!0},s=function(a,b){this.query=a,b&&(this.type=b)};s.prototype.printQuery=function(){return this.query},s.prototype.isPathQuery=function(){return"path"===this.type},s.prototype.isPathVerticesQuery=function(){return"pathVertices"===this.type},s.prototype.isPathEdgesQuery=function(){return"pathEdges"===this.type},s.prototype.isEdgeQuery=function(){return"edge"===this.type},s.prototype.isVertexQuery=function(){return"vertex"===this.type},s.prototype.isNeighborQuery=function(){return"neighbor"===this.type},s.prototype.allowsRestrict=function(){return this.isEdgeQuery()||this.isVertexQuery()||this.isNeighborQuery()};var t=function(a){this.stack=[],this.callStack=[],this.bindVars={graphName:a.__name},this.graph=a,this.cursor=null,this.lastVar="",this._path=[],this._pathVertices=[],this._pathEdges=[],this._getPath=!1};t.prototype._addToPrint=function(a){var b=Array.prototype.slice.call(arguments);b.shift();var c={};c.name=a,b.length>0&&void 0!==b[0]?c.params=b:c.params=[],this.callStack.push(c)},t.prototype._PRINT=function(a){a.output="[ GraphAQL ",a.output+=this.graph.__name,i.each(this.callStack,function(b){a.prettyPrint&&(a.output+="\n"),a.output+=".",a.output+=b.name,a.output+="(";var c=0;for(c=0;c0&&(a.output+=", "),d.printRecursive(b.params[c],a);a.output+=")"}),a.output+=" ] "},t.prototype._clearCursor=function(){this.cursor&&(this.cursor.dispose(),this.cursor=null)},t.prototype._createCursor=function(){this.cursor||(this.cursor=this.execute())},t.prototype._edges=function(a,b){this._clearCursor(),this.options=b||{};var c=q(a),d="edges_"+this.stack.length,e="FOR "+d+" IN GRAPH_EDGES(@graphName";e+=this.getLastVar()?","+this.getLastVar():",{}",e+=",@options_"+this.stack.length+")",Array.isArray(c)||(c=[c]),this.options.edgeExamples=c,this.options.includeData=!0,this.bindVars["options_"+this.stack.length]=this.options;var f=new s(e,"edge");return this.stack.push(f),this.lastVar=d,this._path.push(d),this._pathEdges.push(d),this},t.prototype.edges=function(a){return this._addToPrint("edges",a),this._edges(a,{direction:"any"})},t.prototype.outEdges=function(a){return this._addToPrint("outEdges",a),this._edges(a,{direction:"outbound"})},t.prototype.inEdges=function(a){return this._addToPrint("inEdges",a),this._edges(a,{direction:"inbound"})},t.prototype._vertices=function(a,b,c){this._clearCursor(),this.options=b||{};var d=q(a),e="vertices_"+this.stack.length,f="FOR "+e+" IN GRAPH_VERTICES(@graphName,";if(void 0!==c)if(Array.isArray(c)){var g;for(f+="[",g=0;g0&&(f+=","),f+="MERGE(@vertexExample_"+this.stack.length+","+c[g]+")";f+="]"}else f+=Array.isArray(d)?"@vertexExample_"+this.stack.length+" [ * RETURN MERGE(CURRENT,"+c+")]":"MERGE(@vertexExample_"+this.stack.length+","+c+")";else f+="@vertexExample_"+this.stack.length;f+=",@options_"+this.stack.length+")",this.bindVars["vertexExample_"+this.stack.length]=d,this.bindVars["options_"+this.stack.length]=this.options;var h=new s(f,"vertex");return this.stack.push(h),this.lastVar=e,this._path.push(e),this._pathVertices.push(e),this},t.prototype.vertices=function(a){if(this._addToPrint("vertices",a),!this.getLastVar())return this._vertices(a);var b=this.getLastVar();return this._vertices(a,void 0,["{'_id': "+b+"._from}","{'_id': "+b+"._to}"])},t.prototype.fromVertices=function(a){if(this._addToPrint("fromVertices",a),!this.getLastVar())return this._vertices(a);var b=this.getLastVar();return this._vertices(a,void 0,"{'_id': "+b+"._from}")},t.prototype.toVertices=function(a){if(this._addToPrint("toVertices",a),!this.getLastVar())return this._vertices(a);var b=this.getLastVar();return this._vertices(a,void 0,"{'_id': "+b+"._to}")},t.prototype.getLastVar=function(){return""===this.lastVar?!1:this.lastVar},t.prototype.path=function(){this._clearCursor();var a=new s("","path");return this.stack.push(a),this},t.prototype.pathVertices=function(){this._clearCursor();var a=new s("","pathVertices");return this.stack.push(a),this},t.prototype.pathEdges=function(){this._clearCursor();var a=new s("","pathEdges");return this.stack.push(a),this},t.prototype.neighbors=function(a,b){this._addToPrint("neighbors",a,b);var c,d=q(a),e="neighbors_"+this.stack.length,f="FOR "+e+" IN GRAPH_NEIGHBORS(@graphName,"+this.getLastVar()+",@options_"+this.stack.length+")";c=b?i.extend({},b):{},c.neighborExamples=d,c.includeData=!0,this.bindVars["options_"+this.stack.length]=c;var g=new s(f,"neighbor");return this.stack.push(g),this.lastVar=e,this._path.push(e),this._pathVertices.push(e),this},t.prototype._getLastRestrictableStatementInfo=function(){for(var a=this.stack.length-1;!this.stack[a].allowsRestrict();)a--;return{statement:this.stack[a],options:this.bindVars["options_"+a]}},t.prototype.restrict=function(a){var b=j(a);if(0===b.length)return this;this._addToPrint("restrict",a),this._clearCursor();var c,d=this._getLastRestrictableStatementInfo(),e=d.statement,f=d.options;return e.isEdgeQuery()?(r(this.graph._edgeCollections(),b,"edge collections"),c=f.edgeCollectionRestriction||[],f.edgeCollectionRestriction=c.concat(a)):(e.isVertexQuery()||e.isNeighborQuery())&&(r(this.graph._vertexCollections(),b,"vertex collections"),c=f.vertexCollectionRestriction||[],f.vertexCollectionRestriction=c.concat(a)),this},t.prototype.filter=function(a){this._addToPrint("filter",a),this._clearCursor();var b=[];if("[object Array]"!==Object.prototype.toString.call(a)){if("[object Object]"!==Object.prototype.toString.call(a)){var d=new f;throw d.errorNum=c.errors.ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT.code,d.errorMessage=c.errors.ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT.message,d}b=[a]}else b=a;var e="FILTER MATCHES("+this.getLastVar()+","+JSON.stringify(b)+")";return this.stack.push(new s(e)),this},t.prototype.printQuery=function(){return this.stack.map(function(a){return a.printQuery()}).join(" ")},t.prototype.execute=function(){this._clearCursor();var a=this.printQuery(),b=this.bindVars;return a+=this.stack[this.stack.length-1].isPathQuery()?" RETURN ["+this._path+"]":this.stack[this.stack.length-1].isPathVerticesQuery()?" RETURN FLATTEN(["+this._pathVertices+"])":this.stack[this.stack.length-1].isPathEdgesQuery()?" RETURN FLATTEN(["+this._pathEdges+"])":" RETURN "+this.getLastVar(),g._query(a,b,{count:!0})},t.prototype.toArray=function(){return this._createCursor(),this.cursor.toArray()},t.prototype.count=function(){return this._createCursor(),this.cursor.count()},t.prototype.hasNext=function(){return this._createCursor(),this.cursor.hasNext()},t.prototype.next=function(){return this._createCursor(),this.cursor.next()};var u=function(a,b){var d;if(arguments.length<2)throw d=new f,d.errorNum=c.errors.ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS.code,d.errorMessage=c.errors.ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS.message+"2",d;if("string"!=typeof a||""===a)throw d=new f,d.errorNum=c.errors.ERROR_GRAPH_INVALID_PARAMETER.code,d.errorMessage=c.errors.ERROR_GRAPH_INVALID_PARAMETER.message+" arg1 must not be empty",d;if(!k(b))throw d=new f,d.errorNum=c.errors.ERROR_GRAPH_INVALID_PARAMETER.code,d.errorMessage=c.errors.ERROR_GRAPH_INVALID_PARAMETER.message+" arg2 must not be empty",d;return{collection:a,from:j(b),to:j(b)}},v=function(a,b,d){var e;if(arguments.length<3)throw e=new f,e.errorNum=c.errors.ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS.code,e.errorMessage=c.errors.ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS.message+"3",e;if("string"!=typeof a||""===a)throw e=new f,e.errorNum=c.errors.ERROR_GRAPH_INVALID_PARAMETER.code,e.errorMessage=c.errors.ERROR_GRAPH_INVALID_PARAMETER.message+" arg1 must be non empty string",e;if(!k(b))throw e=new f,e.errorNum=c.errors.ERROR_GRAPH_INVALID_PARAMETER.code,e.errorMessage=c.errors.ERROR_GRAPH_INVALID_PARAMETER.message+" arg2 must be non empty string or array",e;if(!k(d))throw e=new f,e.errorNum=c.errors.ERROR_GRAPH_INVALID_PARAMETER.code,e.errorMessage=c.errors.ERROR_GRAPH_INVALID_PARAMETER.message+" arg3 must be non empty string or array",e;return{collection:a,from:j(b),to:j(d)}},w=function(){var a=n();return i.pluck(a.toArray(),"_key")},x=function(){return n().toArray()},y=function(){var a=[],b=arguments;return Object.keys(b).forEach(function(c){a.push(b[c])}),a},z=function(a){var b=arguments,c=0;Object.keys(b).forEach(function(d){c++,1!==c&&a.push(b[d])})},A=function(a){return a.from=a.from.sort(),a.to=a.to.sort(),a},B=function(a,b,d,g){Array.isArray(d)||(d=[]);var i,j,k,o=n(),p=!0;if(!a)throw i=new f,i.errorNum=c.errors.ERROR_GRAPH_CREATE_MISSING_NAME.code,i.errorMessage=c.errors.ERROR_GRAPH_CREATE_MISSING_NAME.message,i;if(b=b||[],!Array.isArray(b))throw i=new f,i.errorNum=c.errors.ERROR_GRAPH_CREATE_MALFORMED_EDGE_DEFINITION.code,i.errorMessage=c.errors.ERROR_GRAPH_CREATE_MALFORMED_EDGE_DEFINITION.message,i;var q=[],r={};b.forEach(function(a){var b=a.collection;if(-1!==q.indexOf(b))throw i=new f,i.errorNum=c.errors.ERROR_GRAPH_COLLECTION_MULTI_USE.code,i.errorMessage=c.errors.ERROR_GRAPH_COLLECTION_MULTI_USE.message,i;q.push(b),r[b]=a}),o.toArray().forEach(function(a){var b=a.edgeDefinitions;b.forEach(function(a){var b=a.collection;if(-1!==q.indexOf(b)&&JSON.stringify(a)!==JSON.stringify(r[b]))throw i=new f,i.errorNum=c.errors.ERROR_GRAPH_COLLECTION_USE_IN_MULTI_GRAPHS.code,i.errorMessage=b+" "+c.errors.ERROR_GRAPH_COLLECTION_USE_IN_MULTI_GRAPHS.message,i})});try{o.document(a)}catch(s){if(s.errorNum!==h.ERROR_ARANGO_DOCUMENT_NOT_FOUND.code)throw s;p=!1}if(p)throw i=new f,i.errorNum=c.errors.ERROR_GRAPH_DUPLICATE.code,i.errorMessage=c.errors.ERROR_GRAPH_DUPLICATE.message,i;j=m(b,!1),d.forEach(function(a){l(a,e.TYPE_DOCUMENT)}),b.forEach(function(a,c){var d=A(a);b[c]=d}),d=d.sort();var t=o.save({orphanCollections:d,edgeDefinitions:b,_key:a},g);return k=new H(a,b,j[0],j[1],d,t._rev,t._id)},C=function(a,b,c){Object.defineProperty(a,b,{enumerable:!1,writable:!0}),a[b]=c},D=function O(a,b,c,d){d.__idsToRemove[c]=1,a.forEach(function(e){var f=e.edgeDefinitions;e.edgeDefinitions&&f.forEach(function(e){var f=e.from,h=e.to,i=e.collection;if(-1!==f.indexOf(b)||-1!==h.indexOf(b)){var j=g._collection(i).edges(c);j.forEach(function(b){d.__idsToRemove.hasOwnProperty(b._id)||(d.__collectionsToLock[i]=1,O(a,i,b._id,d))})}})})},E=function(a,b){i.each(b,function(b){var d=g._collection(b),e=p(d),h=e.save;e.save=function(d,e,g){if("string"!=typeof d||-1===d.indexOf("/")||"string"!=typeof e||-1===e.indexOf("/")){var j=new f;throw j.errorNum=c.errors.ERROR_ARANGO_DOCUMENT_HANDLE_BAD.code,j.errorMessage=c.errors.ERROR_ARANGO_DOCUMENT_HANDLE_BAD.message,j}return a.__edgeDefinitions.forEach(function(a){if(a.collection===b){var g=d.split("/")[0],h=e.split("/")[0];if(!i.contains(a.from,g)||!i.contains(a.to,h)){var j=new f;throw j.errorNum=c.errors.ERROR_GRAPH_INVALID_EDGE.code,j.errorMessage=c.errors.ERROR_GRAPH_INVALID_EDGE.message+" between "+d+" and "+e+".",j}}}),h(d,e,g)},e.remove=function(c,d){-1===c.indexOf("/")&&(c=b+"/"+c);var e=n().toArray(),f=c.split("/")[0];a.__collectionsToLock[f]=1,D(e,f,c,a);try{g._executeTransaction({collections:{ write:Object.keys(a.__collectionsToLock)},embed:!0,action:function(a){var b=require("internal").db;a.ids.forEach(function(c){a.options?b._remove(c,a.options):b._remove(c)})},params:{ids:Object.keys(a.__idsToRemove),options:d}})}catch(h){throw a.__idsToRemove={},a.__collectionsToLock={},h}return a.__idsToRemove={},a.__collectionsToLock={},!0},a[b]=e})},F=function(a,b){i.each(b,function(b){var c=g._collection(b),d=p(c);d.remove=function(c,d){var e=n().toArray(),f=b;-1===c.indexOf("/")&&(c=b+"/"+c),a.__collectionsToLock[f]=1,e.forEach(function(b){var d=b.edgeDefinitions;b.edgeDefinitions&&d.forEach(function(b){var d=b.from,h=b.to,i=b.collection;if(-1!==d.indexOf(f)||-1!==h.indexOf(f)){var j=g._collection(i).edges(c);j.length>0&&(a.__collectionsToLock[i]=1,j.forEach(function(b){D(e,i,b._id,a)}))}})});try{g._executeTransaction({collections:{write:Object.keys(a.__collectionsToLock)},embed:!0,action:function(a){var b=require("internal").db;a.ids.forEach(function(c){a.options?b._remove(c,a.options):b._remove(c)}),a.options?b._remove(a.vertexId,a.options):b._remove(a.vertexId)},params:{ids:Object.keys(a.__idsToRemove),options:d,vertexId:c}})}catch(h){throw a.__idsToRemove={},a.__collectionsToLock={},h}return a.__idsToRemove={},a.__collectionsToLock={},!0},a[b]=d})},G=function(a){Object.keys(a).forEach(function(b){"_"!==b.substring(0,1)&&delete a[b]}),a.__edgeDefinitions.forEach(function(b){E(a,[b.collection]),F(a,b.from),F(a,b.to)}),F(a,a.__orphanCollections)},H=function(a,b,c,d,e,f,g){b.forEach(function(a,c){var d=A(a);b[c]=d}),e||(e=[]);var h="object"==typeof ArangoClusterComm;h&&require("@arangodb/cluster").isCoordinator()&&(h=!1);var i=this;C(this,"__useBuiltIn",h),C(this,"__name",a),C(this,"__vertexCollections",c),C(this,"__edgeCollections",d),C(this,"__edgeDefinitions",b),C(this,"__idsToRemove",{}),C(this,"__collectionsToLock",{}),C(this,"__id",g),C(this,"__rev",f),C(this,"__orphanCollections",e),G(i)},I=function(a){var b,d,e,g=n();try{b=g.document(a)}catch(i){if(i.errorNum!==h.ERROR_ARANGO_DOCUMENT_NOT_FOUND.code)throw i;var j=new f;throw j.errorNum=c.errors.ERROR_GRAPH_NOT_FOUND.code,j.errorMessage=c.errors.ERROR_GRAPH_NOT_FOUND.message,j}return d=m(b.edgeDefinitions,!0),e=b.orphanCollections,e||(e=[]),new H(a,b.edgeDefinitions,d[0],d[1],e,b._rev,b._id)},J=function(a){var b=n();return b.exists(a)},K=function(a,b){g._executeTransaction({collections:{write:"_graphs"},action:function(a){var b=n();b&&b.toArray().forEach(function(c){var d,e,f=i.extend({},c),g=!1;if(f.edgeDefinitions)for(d=0;dc;c++)this.hasOwnProperty(c)&&(e[c]=a.call(b,this[c],c,this));return e},f.prototype.getInVertex=function(){return this.map(function(a){return a.getInVertex()})},f.prototype.getOutVertex=function(){return this.map(function(a){return a.getOutVertex()})},f.prototype.getPeerVertex=function(a){return this.map(function(b){return b.getPeerVertex(a)})},f.prototype.setProperty=function(a,b){return this.map(function(c){return c.setProperty(a,b)})},f.prototype.edges=function(){return this.map(function(a){return a.edges()})},f.prototype.outbound=function(){return this.map(function(a){return a.outbound()})},f.prototype.inbound=function(){return this.map(function(a){return a.inbound()})},f.prototype.getInEdges=function(){var a=arguments;return this.map(function(b){return b.getInEdges.apply(b,a)})},f.prototype.getOutEdges=function(){var a=arguments;return this.map(function(b){return b.getOutEdges.apply(b,a)})},f.prototype.getEdges=function(){var a=arguments;return this.map(function(b){return b.getEdges.apply(b,a)})},f.prototype.degree=function(){return this.map(function(a){return a.degree()})},f.prototype.inDegree=function(){return this.map(function(a){return a.inDegree()})},f.prototype.inDegree=function(){return this.map(function(a){return a.outDegree()})},f.prototype.properties=function(){return this.map(function(a){return a.properties()})},c=function(a,b){this._graph=a,this._id=b._key,this._properties=b},c.prototype.getId=function(){return this._properties._key},c.prototype.getLabel=function(){return this._properties.$label},c.prototype.getProperty=function(a){return this._properties[a]},c.prototype.getPropertyKeys=function(){return this._properties.propertyKeys},c.prototype.properties=function(){return this._properties._shallowCopy},c.prototype.getInVertex=function(){return this._graph.getVertex(this._properties._to)},c.prototype.getOutVertex=function(){return this._graph.getVertex(this._properties._from)},c.prototype.getPeerVertex=function(a){return a._properties._id===this._properties._to?this._graph.getVertex(this._properties._from):a._properties._id===this._properties._from?this._graph.getVertex(this._properties._to):null},c.prototype._PRINT=function(a){this._properties._id?void 0!==this._properties._key?"string"==typeof this._properties._key?a.output+='Edge("'+this._properties._key+'")':a.output+="Edge("+this._properties._key+")":a.output+="Edge(<"+this._id+">)":a.output+="[deleted Edge]"},e=function(a,b){this._graph=a,this._id=b._key,this._properties=b},e.prototype.addInEdge=function(a,b,c,d){return this._graph.addEdge(a,this,b,c,d)},e.prototype.addOutEdge=function(a,b,c,d){return this._graph.addEdge(this,a,b,c,d)},e.prototype.degree=function(){return this.getEdges().length},e.prototype.inDegree=function(){return this.getInEdges().length},e.prototype.outDegree=function(){return this.getOutEdges().length},e.prototype.getId=function(){return this._properties._key},e.prototype.getProperty=function(a){return this._properties[a]},e.prototype.getPropertyKeys=function(){return this._properties.propertyKeys},e.prototype.properties=function(){return this._properties._shallowCopy},e.prototype._PRINT=function(a){this._properties._id?void 0!==this._properties._key?"string"==typeof this._properties._key?a.output+='Vertex("'+this._properties._key+'")':a.output+="Vertex("+this._properties._key+")":a.output+="Vertex(<"+this._id+">)":a.output+="[deleted Vertex]"},d=function(a,b,c,d){this.initialize(a,b,c,d)},d.prototype._prepareEdgeData=function(a,b){var c;return h.notExisty(a)&&h.object(b)&&(a=b,b=null),h.notExisty(b)&&h.existy(a)&&h.existy(a.$label)&&(b=a.$label),c=h.notExisty(a)||h.noObject(a)?{}:a._shallowCopy||{},c.$label=b,c},d.prototype._prepareVertexData=function(a){var b;return b=h.notExisty(a)||h.noObject(a)?{}:a._shallowCopy||{}},d.prototype.getOrAddVertex=function(a){var b=this.getVertex(a);return null===b&&(b=this.addVertex(a)),b},d.prototype.addEdge=function(a,b,c,d,e,f){var g,i;return g=h.string(a)?a:a._properties._id,i=h.string(b)?b:b._properties._id,this._saveEdge(c,g,i,this._prepareEdgeData(e,d),f)},d.prototype.addVertex=function(a,b,c){return this._saveVertex(a,this._prepareVertexData(b),c)},d.prototype.replaceVertex=function(a,b){this._replaceVertex(a,b)},d.prototype.replaceEdge=function(a,b){this._replaceEdge(a,b)},d.prototype.order=function(){return this._vertices.count()},d.prototype.size=function(){return this._edges.count()},d.prototype.emptyCachedPredecessors=function(){this.predecessors={}},d.prototype.getCachedPredecessors=function(a,b){var c;return this.predecessors[a.getId()]&&(c=this.predecessors[a.getId()][b.getId()]),c},d.prototype.setCachedPredecessors=function(a,b,c){this.predecessors[a.getId()]||(this.predecessors[a.getId()]={}),this.predecessors[a.getId()][b.getId()]=c},d.prototype.constructVertex=function(a){var b,c;"string"==typeof a?b=a:(b=a._id,c=a._rev);var d=this._verticesCache[b];if(void 0===d||d._rev!==c){var f=this._vertices.document(b);if(!f)throw"accessing a deleted vertex";this._verticesCache[b]=d=new e(this,f)}return d},d.prototype.constructEdge=function(a){var b,d,e,f;if("string"==typeof a?b=a:(b=a._id,d=a._rev),e=this._edgesCache[b],void 0===e||e._rev!==d){if(f=this._edges.document(b),!f)throw"accessing a deleted edge";this._edgesCache[b]=e=new c(this,f)}return e},d.prototype._PRINT=function(a){a.output+='Graph("'+this._properties._key+'")'},a.Edge=c,a.Graph=d,a.Vertex=e,a.GraphArray=f,a.Iterator=g}),module.define("@arangodb/graph",function(a,b){var c=require("@arangodb/graph-blueprint");Object.keys(c).forEach(function(b){a[b]=c[b]})}),module.define("@arangodb/graph/traversal",function(a,b){function c(a){if(null===a||"object"!=typeof a)return a;var b;if(Array.isArray(a))b=[],a.forEach(function(a){b.push(c(a))});else if(a instanceof Object){if(J&&a instanceof J)return a;b={},Object.keys(a).forEach(function(d){b[d]=c(a[d])})}return b}function d(a){for(var b in a)if(a.hasOwnProperty(b))return!1;return!0}function e(a){var b=a;"string"==typeof b&&(b=K._collection(b));var c="object"==typeof ArangoClusterComm;return c&&require("@arangodb/cluster").isCoordinator()&&(c=!1),{edgeCollection:b,useBuiltIn:c,getVertexId:function(a){return a._id},getPeerVertex:function(a,b){return a._from===b._id?K._document(a._to):a._to===b._id?K._document(a._from):null},getInVertex:function(a){return K._document(a._to)},getOutVertex:function(a){return K._document(a._from)},getEdgeId:function(a){return a._id},getEdgeFrom:function(a){return a._from},getEdgeTo:function(a){return a._to},getLabel:function(a){return a.$label},getAllEdges:function(a){return this.useBuiltIn?this.edgeCollection.EDGES(a._id):this.edgeCollection.edges(a._id)},getInEdges:function(a){return this.useBuiltIn?this.edgeCollection.INEDGES(a._id):this.edgeCollection.inEdges(a._id)},getOutEdges:function(a){return this.useBuiltIn?this.edgeCollection.OUTEDGES(a._id):this.edgeCollection.outEdges(a._id)}}}function f(a){var b=a;return"string"==typeof b&&(b=F._graph(b)),{graph:b,getVertexId:function(a){return a._id},getPeerVertex:function(a,b){return a._from===b._id?K._document(a._to):a._to===b._id?K._document(a._from):null},getInVertex:function(a){return K._document(a._to)},getOutVertex:function(a){return K._document(a._from)},getEdgeId:function(a){return a._id},getEdgeFrom:function(a){return a._from},getEdgeTo:function(a){return a._to},getLabel:function(a){return a.$label},getAllEdges:function(a){return this.graph._EDGES(a._id)},getInEdges:function(a){return this.graph._INEDGES(a._id)},getOutEdges:function(a){return this.graph._OUTEDGES(a._id)}}}function g(a){return{graph:new E.Graph(a),getVertexId:function(a){return a.getId()},getPeerVertex:function(a,b){return a.getPeerVertex(b)},getInVertex:function(a){return a.getInVertex()},getOutVertex:function(a){return a.getOutVertex()},getEdgeId:function(a){return a.getId()},getEdgeFrom:function(a){return a._properties._from},getEdgeTo:function(a){return a._properties._to},getLabel:function(a){return a.getLabel()},getAllEdges:function(a){return a.edges()},getInEdges:function(a){return a.inbound()},getOutEdges:function(a){return a.outbound()}}}function h(a,b,c){var d,e=a.datasource,f=[],g=e.getOutEdges(b);return g.length>1&&a.sort&&g.sort(a.sort),d=a.buildVertices?a.expandFilter?function(b){try{var d=e.getInVertex(b);a.expandFilter(a,d,b,c)&&f.push({edge:b,vertex:d})}catch(g){}}:function(a){try{var b=e.getInVertex(a);f.push({edge:a,vertex:b})}catch(c){}}:a.expandFilter?function(b){var d=e.getEdgeTo(b),g={_id:d,_key:d.substr(d.indexOf("/")+1)};a.expandFilter(a,g,b,c)&&f.push({edge:b,vertex:g})}:function(a){var b=e.getEdgeTo(a),c={_id:b,_key:b.substr(b.indexOf("/")+1)};f.push({edge:a,vertex:c})},g.forEach(d),f}function i(a,b,c){var d=a.datasource,e=[],f=d.getInEdges(b);f.length>1&&a.sort&&f.sort(a.sort);var g;return g=a.buildVertices?a.expandFilter?function(b){try{var f=d.getOutVertex(b);a.expandFilter(a,f,b,c)&&e.push({edge:b,vertex:f})}catch(g){}}:function(a){try{var b=d.getOutVertex(a);e.push({edge:a,vertex:b})}catch(c){}}:a.expandFilter?function(b){var f=d.getEdgeFrom(b),g={_id:f,_key:f.substr(f.indexOf("/")+1)};a.expandFilter(a,g,b,c)&&e.push({edge:b,vertex:g})}:function(a){var b=d.getEdgeFrom(a),c={_id:b,_key:b.substr(b.indexOf("/")+1)};e.push({edge:a,vertex:c})},f.forEach(g),e}function j(a,b,c){var d=a.datasource,e=[],f=d.getAllEdges(b);f.length>1&&a.sort&&f.sort(a.sort);var g;return g=a.buildVertices?a.expandFilter?function(f){try{var g=d.getPeerVertex(f,b);a.expandFilter(a,g,f,c)&&e.push({edge:f,vertex:g})}catch(h){}}:function(a){try{var c=d.getPeerVertex(a,b);e.push({edge:a,vertex:c})}catch(f){}}:a.expandFilter?function(f){var g=d.getEdgeFrom(f);g===b._id&&(g=d.getEdgeTo(f));var h={_id:g,_key:g.substr(g.indexOf("/")+1)};a.expandFilter(a,h,f,c)&&e.push({edge:f,vertex:h})}:function(a){var c=d.getEdgeFrom(a);c===b._id&&(c=d.getEdgeTo(a));var f={_id:c,_key:c.substr(c.indexOf("/")+1)};e.push({edge:a,vertex:f})},f.forEach(g),e}function k(a,b,c){var d,e=a.datasource,f=[];Array.isArray(a.labels)||(a.labels=[a.labels]);var g=e.getOutEdges(b);if(void 0!==g)for(d=0;d=0&&f.push({edge:h,vertex:e.getInVertex(h)})}return f}function l(a,b,c){var d,e=a.datasource,f=[];Array.isArray(a.labels)||(a.labels=[a.labels]);var g=a.datasource.getInEdges(b);if(void 0!==g)for(d=0;d=0&&f.push({edge:h,vertex:e.getOutVertex(h)})}return f}function m(a,b,c){var d,e=a.datasource,f=[];Array.isArray(a.labels)||(a.labels=[a.labels]);var g=a.datasource.getAllEdges(b);if(void 0!==g)for(d=0;d=0&&f.push({edge:h,vertex:e.getPeerVertex(h,b)})}return f}function n(a,b,d,e){b&&b.visited&&(b.visited.vertices&&b.visited.vertices.push(c(d)),b.visited.paths&&b.visited.paths.push(c(e)))}function o(a,b,c,d){b&&(b.hasOwnProperty("count")?++b.count:b.count=1)}function p(){}function q(){return""}function r(a,b,c){return c&&c.vertices&&c.vertices.length>a.maxDepth?D.PRUNE:void 0}function s(a,b,c){return c&&c.vertices&&c.vertices.length<=a.minDepth?D.EXCLUDE:void 0}function t(a,b,c){Array.isArray(a.matchingAttributes)||(a.matchingAttributes=[a.matchingAttributes]);var d=!1;a.matchingAttributes.forEach(function(a){var c=0,e=Object.keys(a);e.forEach(function(d){b[d]&&b[d]===a[d]&&c++}),c>0&&c===e.length&&(d=!0)});var e;return d||(e="exclude"),e}function u(a,b,c,d){var e=[];return a.forEach(function(a){var f=a(b,c,d);Array.isArray(f)||(f=[f]),e=e.concat(f)}),e}function v(a){function b(a){if(void 0!==a&&null!==a){var d=!1;if("string"==typeof a)a===D.EXCLUDE?(c.visit=!1,d=!0):a===D.PRUNE?(c.expand=!1,d=!0):""===a&&(d=!0);else if(Array.isArray(a)){var e;for(e=0;eb)break;d=a[b]}return c},run:function(a,b,c){for(var d=a.maxIterations,e=0,f=[{edge:null,vertex:c,parentIndex:-1}],g={edges:{},vertices:{}},h=0,i=1,j=x(a);1===i&&h=0;){var k,l=f[h],m=l.vertex,n=l.edge;if(e++>d){var o=new I;throw o.errorNum=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.code,o.errorMessage=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.message,o}if(L(),null===l.visit||void 0===l.visit){if(l.visit=!1,k=this.createPath(f,h),a.uniqueness.vertices===D.UNIQUE_PATH&&(g.vertices=this.getPathItems(a.datasource.getVertexId,k.vertices)),a.uniqueness.edges===D.UNIQUE_PATH&&(g.edges=this.getPathItems(a.datasource.getEdgeId,k.edges)),!w(a,g,m,n)){h0;){if(e++>d){var l=new I;throw l.errorNum=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.code,l.errorMessage=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.message,l}L();var m=f[f.length-1],n=m.vertex,o=m.edge;if(null===m.visit||void 0===m.visit){if(m.visit=!1,k&&(j.vertices===D.UNIQUE_PATH&&(h.vertices=this.getPathItems(a.datasource.getVertexId,g.vertices)),j.edges===D.UNIQUE_PATH&&(h.edges=this.getPathItems(a.datasource.getEdgeId,g.edges)),!w(a,h,n,o))){f.pop();continue}null!==o&&g.edges.push(o),g.vertices.push(n);var p=v(a.filter(a,n,g));if(a.order===D.PRE_ORDER&&p.visit?a.visitor(a,b,n,g):m.visit=p.visit||!1,p.expand){var q,r=a.expander(a,n,g);for(i&&r.reverse(),a.order===D.PRE_ORDER_EXPANDER&&p.visit&&a.visitor(a,b,n,g,r),q=0;q0&&g.edges.pop(),g.vertices.pop()}}}}function A(){return{nodes:{},requiresEndVertex:function(){return!0},makeNode:function(a){var b=a._id;return this.nodes.hasOwnProperty(b)||(this.nodes[b]={vertex:a,dist:1/0}),this.nodes[b]},vertexList:function(a){for(var b=[];a;)b.push(a),a=a.parent;return b},buildPath:function(a){for(var b={vertices:[a.vertex],edges:[]},c=a;c.parent;)b.vertices.unshift(c.parent.vertex),b.edges.unshift(c.parentEdge),c=c.parent;return b},run:function(a,b,c,d){var e=a.maxIterations,f=0,g=new H(function(a){return a.dist}),h=this.makeNode(c);for(h.dist=0,g.push(h);g.size()>0;){if(f++>e){var i=new I;throw i.errorNum=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.code,i.errorMessage=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.message,i}L();var j,k,l=g.pop();if(l.vertex._id===d._id){var m=this.vertexList(l).reverse();for(k=m.length,j=0;k>j;++j)m[j].hide||a.visitor(a,b,m[j].vertex,this.buildPath(m[j]));return}if(!l.visited){if(l.dist===1/0)break;l.visited=!0;var n=this.buildPath(l),o=v(a.filter(a,l.vertex,n));if(o.visit||(l.hide=!0),o.expand){var p=l.dist,q=a.expander(a,l.vertex,n);for(k=q.length,j=0;k>j;++j){var r=this.makeNode(q[j].vertex);if(!r.visited){var s=q[j].edge,t=1;a.distance?t=a.distance(a,l.vertex,r.vertex,s):a.weight&&(t="number"==typeof s[a.weight]?s[a.weight]:a.defaultWeight?a.defaultWeight:1/0);var u=p+t;u0;){if(g++>f){var j=new I;throw j.errorNum=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.code,j.errorMessage=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.message,j}var k,l,m=h.pop();if(e.hasOwnProperty(m.vertex._id)&&(delete e[m.vertex._id],a.visitor(a,b,m,this.buildPath(m)),d(e)))return;if(!m.visited){if(m.dist===1/0)break;m.visited=!0;var n=this.buildPath(m),o=v(a.filter(a,m.vertex,n));if(o.visit||(m.hide=!0),o.expand){var p=m.dist,q=a.expander(a,m.vertex,n);for(l=q.length,k=0;l>k;++k){var r=this.makeNode(q[k].vertex);if(!r.visited){var s=q[k].edge,t=1;a.distance?t=a.distance(a,m.vertex,r.vertex,s):a.weight&&(t="number"==typeof s[a.weight]?s[a.weight]:a.defaultWeight?a.defaultWeight:1/0);var u=p+t;u0;){if(f++>e){var h=new I;throw h.errorNum=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.code,h.errorMessage=G.errors.ERROR_GRAPH_TOO_MANY_ITERATIONS.message,h}L();var i,j,k=g.pop();if(k.vertex._id===d._id){var l=this.vertexList(k);for(a.order!==D.PRE_ORDER&&l.reverse(),j=l.length,i=0;j>i;++i)a.visitor(a,b,l[i].vertex,this.buildPath(l[i]));return}k.closed=!0;var m=this.buildPath(k),n=a.expander(a,k.vertex,m);for(j=n.length,i=0;j>i;++i){var o=this.makeNode(n[i].vertex);if(!o.closed){var p=k.g+1,q=o.visited;if(!q||p0&&f.push(s),void 0!==a.maxDepth&&null!==a.maxDepth&&a.maxDepth>0&&f.push(r),Array.isArray(a.filter)||("function"==typeof a.filter?a.filter=[a.filter]:a.filter=[]),a.filter.forEach(function(a){if("function"!=typeof a)throw d=new I,d.errorNum=G.errors.ERROR_BAD_PARAMETER.code,d.errorMessage="invalid filter function",d;f.push(a)}),f.length>1?a.filter=function(a,b,c){return u(f,a,b,c)}:1===f.length?a.filter=f[0]:a.filter=q,"function"!=typeof a.expander&&(a.expander=b(a.expander,{outbound:h,inbound:i,any:j},"expander")),"function"!=typeof a.expander)throw d=new I,d.errorNum=G.errors.ERROR_BAD_PARAMETER.code,d.errorMessage="invalid expander function",d;if("object"!=typeof a.datasource)throw d=new I,d.errorNum=G.errors.ERROR_BAD_PARAMETER.code,d.errorMessage="invalid datasource",d;this.config=a},D.prototype.traverse=function(a,b,c){var d;if(d=this.config.strategy===D.ASTAR_SEARCH?C():this.config.strategy===D.DIJKSTRA_SEARCH?A():this.config.strategy===D.DIJKSTRA_SEARCH_MULTI?B():this.config.strategy===D.BREADTH_FIRST?y():z(),void 0===b||null===b||"object"!=typeof b){var e=new I;throw e.errorNum=G.errors.ERROR_BAD_PARAMETER.code,e.errorMessage=G.errors.ERROR_BAD_PARAMETER.message+": invalid startVertex specified for traversal",e}if(d.requiresEndVertex()&&(void 0===c||null===c||"object"!=typeof c)){var f=new I;throw f.errorNum=G.errors.ERROR_BAD_PARAMETER.code,f.errorMessage=G.errors.ERROR_BAD_PARAMETER.message+": invalid endVertex specified for traversal",f}try{d.run(this.config,a,b,c)}catch(g){if("object"!=typeof g||!g._intentionallyAborted)throw g}},D.UNIQUE_NONE=0,D.UNIQUE_PATH=1,D.UNIQUE_GLOBAL=2,D.BREADTH_FIRST=0,D.DEPTH_FIRST=1,D.ASTAR_SEARCH=2,D.DIJKSTRA_SEARCH=3,D.DIJKSTRA_SEARCH_MULTI=4,D.PRE_ORDER=0,D.POST_ORDER=1,D.PRE_ORDER_EXPANDER=2,D.FORWARD=0,D.BACKWARD=1,D.PRUNE="prune",D.EXCLUDE="exclude",a.collectionDatasourceFactory=e,a.generalGraphDatasourceFactory=f,a.graphDatasourceFactory=g,a.outboundExpander=h,a.inboundExpander=i,a.anyExpander=j,a.expandOutEdgesWithLabels=k,a.expandInEdgesWithLabels=l,a.expandEdgesWithLabels=m,a.trackingVisitor=n,a.countingVisitor=o,a.doNothingVisitor=p,a.visitAllFilter=q,a.maxDepthFilter=r,a.minDepthFilter=s,a.includeMatchingAttributesFilter=t,a.abortedException=N,a.Traverser=D}),module.define("@arangodb/is",function(a,b){"use strict";function c(a){return null!==a&&void 0!==a}function d(a){return!c(a)}function e(a){return a!==!1&&c(a)}function f(a){return!e(a)}["Object","Array","Boolean","Date","Function","Number","String","RegExp"].forEach(function(b){a[b.toLowerCase()]=function(a){return Object.prototype.toString.call(a)==="[object "+b+"]"},a["no"+b]=function(a){return Object.prototype.toString.call(a)!=="[object "+b+"]"}}),a.existy=c,a.notExisty=d,a.truthy=e,a.falsy=f}),module.define("@arangodb/mimetypes",function(a,b){a.mimeTypes={gif:["image/gif",!1],jpg:["image/jpg",!1],png:["image/png",!1],tiff:["image/tiff",!1],ico:["image/x-icon",!1],css:["text/css",!0],js:["text/javascript",!0],json:["application/json",!0],html:["text/html",!0],htm:["text/html",!0],pdf:["application/pdf",!1],ps:["application/postscript",!1],txt:["text/plain",!0],text:["text/plain",!0],xml:["application/xml",!0],dtd:["application/xml-dtd",!0],svg:["image/svg+xml",!0],ttf:["application/x-font-ttf",!1],otf:["application/x-font-opentype",!1],woff:["application/font-woff",!1],eot:["application/vnd.ms-fontobject",!1],bz2:["application/x-bzip2",!1],gz:["application/x-gzip",!1],tgz:["application/x-tar",!1],zip:["application/x-compressed-zip",!1],doc:["application/msword",!1],docx:["application/vnd.openxmlformats-officedocument.wordprocessingml.document",!1],dotx:["application/vnd.openxmlformats-officedocument.wordprocessingml.template",!1],potx:["application/vnd.openxmlformats-officedocument.presentationml.template",!1],ppsx:["application/vnd.openxmlformats-officedocument.presentationml.slideshow",!1],ppt:["application/vnd.ms-powerpoint",!1],pptx:["application/vnd.openxmlformats-officedocument.presentationml.presentation",!1],xls:["application/vnd.ms-excel",!1],xlsb:["application/vnd.ms-excel.sheet.binary.macroEnabled.12",!1],xlsx:["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",!1],xltx:["application/vnd.openxmlformats-officedocument.spreadsheetml.template",!1],swf:["application/x-shockwave-flash",!1]},a.extensions={"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":["xlsx"],"image/svg+xml":["svg"],"application/postscript":["ps"],"image/png":["png"],"application/x-font-ttf":["ttf"],"application/vnd.ms-excel.sheet.binary.macroEnabled.12":["xlsb"],"application/x-font-opentype":["otf"],"application/vnd.openxmlformats-officedocument.wordprocessingml.document":["docx"],"application/x-bzip2":["bz2"],"application/json":["json"],"application/pdf":["pdf"],"application/vnd.openxmlformats-officedocument.presentationml.presentation":["pptx"],"application/vnd.ms-fontobject":["eot"],"application/xml-dtd":["dtd"],"application/x-shockwave-flash":["swf"],"image/gif":["gif"],"image/jpg":["jpg"],"application/xml":["xml"],"application/vnd.ms-excel":["xls"],"image/tiff":["tiff"],"application/vnd.ms-powerpoint":["ppt"],"application/font-woff":["woff"],"application/vnd.openxmlformats-officedocument.presentationml.template":["potx"],"text/plain":["txt","text"],"application/x-tar":["tgz"],"application/vnd.openxmlformats-officedocument.spreadsheetml.template":["xltx"],"application/x-gzip":["gz"],"text/javascript":["js"],"text/html":["html","htm"],"application/vnd.openxmlformats-officedocument.wordprocessingml.template":["dotx"],"image/x-icon":["ico"],"application/x-compressed-zip":["zip"],"application/vnd.openxmlformats-officedocument.presentationml.slideshow":["ppsx"],"text/css":["css"],"application/msword":["doc"]}}),module.define("@arangodb/simple-query-common",function(a,b){function c(a,b,c,d){this._documents=a,this._countTotal=a.length,this._skip=b,this._limit=c,this._cached=!1,this._extra={};var e=this;null!==d&&void 0!==d&&"object"==typeof d&&(["stats","warnings","profile"].forEach(function(a){d.hasOwnProperty(a)&&(e._extra[a]=d[a])}),this._cached=d.cached||!1),this.execute()}function d(){this._execution=null,this._skip=0,this._limit=null,this._countQuery=null,this._countTotal=null,this._batchSize=null}function e(a,b){return 0===a._limit?a=a.clone():0===b?(a=a.clone(),a._limit=0):null===a._limit?(a=a.clone(),a._limit=b):(a=a.clone(),bc&&(b=c);else if(this._skip<0){var d=-this._skip;c>d&&(b=c-d)}null!==this._limit&&b+this._limita){var b=new q;throw b.errorNum=p.ERROR_BAD_PARAMETER,b.errorMessage="limit must be non-negative",b}return e(this,a)},d.prototype.skip=function(a){var b,c;if((void 0===a||null===a)&&(a=0),null!==this._execution)throw"query is already executing";return null===this._limit?(b=this.clone(),null===this._skip||0===this._skip?b._skip=a:b._skip+=a):(c=this.clone().toArray(),b=new l(c),b._skip=a,b._countTotal=c._countTotal),b},d.prototype.toArray=function(){var a;for(this.execute(),a=[];this.hasNext();)a.push(this.next());return a},d.prototype.getBatchSize=function(){return this._batchSize},d.prototype.setBatchSize=function(a){a>=1&&(this._batchSize=a)},d.prototype.count=function(a){return this.execute(),void 0!==a&&a?this._countQuery:this._countTotal},d.prototype.hasNext=function(){return this.execute(),this._execution.hasNext()},d.prototype.next=function(){return this.execute(),this._execution.next()},d.prototype.dispose=function(){null!==this._execution&&this._execution.dispose(),this._execution=null,this._countQuery=null,this._countTotal=null},f.prototype=new d,f.prototype.constructor=f,f.prototype.clone=function(){var a;return a=new f(this._collection),a._skip=this._skip,a._limit=this._limit,a},f.prototype._PRINT=function(a){var b;b="SimpleQueryAll("+this._collection.name()+")",null!==this._skip&&0!==this._skip&&(b+=".skip("+this._skip+")"),null!==this._limit&&(b+=".limit("+this._limit+")"),a.output+=b},l=function(a){this._documents=a},l.prototype=new d,l.prototype.constructor=l,l.prototype.clone=function(){var a;return a=new l(this._documents),a._skip=this._skip,a._limit=this._limit,a},l.prototype.execute=function(){null===this._execution&&(null===this._skip&&(this._skip=0),this._execution=new c(this._documents,this._skip,this._limit))},l.prototype._PRINT=function(a){var b;b="SimpleQueryArray(documents)",null!==this._skip&&0!==this._skip&&(b+=".skip("+this._skip+")"),null!==this._limit&&(b+=".limit("+this._limit+")"),a.output+=b},g.prototype=new d,g.prototype.constructor=g,g.prototype.clone=function(){var a;return a=new g(this._collection,this._example),a._skip=this._skip,a._limit=this._limit,a._type=this._type,a._index=this._index,a},g.prototype._PRINT=function(a){var b;b="SimpleQueryByExample("+this._collection.name()+")",null!==this._skip&&0!==this._skip&&(b+=".skip("+this._skip+")"),null!==this._limit&&(b+=".limit("+this._limit+")"),a.output+=b},h.prototype=new d,h.prototype.constructor=h,h.prototype.clone=function(){var a;return a=new h(this._collection,this._condition),a._skip=this._skip,a._limit=this._limit,a._type=this._type,a._index=this._index,a},h.prototype._PRINT=function(a){var b;b="SimpleQueryByCondition("+this._collection.name()+")",null!==this._skip&&0!==this._skip&&(b+=".skip("+this._skip+")"),null!==this._limit&&(b+=".limit("+this._limit+")"),a.output+=b},i.prototype=new d,i.prototype.constructor=i,i.prototype.clone=function(){var a;return a=new i(this._collection,this._attribute,this._left,this._right,this._type),a._skip=this._skip,a._limit=this._limit,a},i.prototype._PRINT=function(a){var b;b="SimpleQueryRange("+this._collection.name()+")",null!==this._skip&&0!==this._skip&&(b+=".skip("+this._skip+")"),null!==this._limit&&(b+=".limit("+this._limit+")"),a.output+=b},j.prototype._PRINT=function(a){var b;b="GeoIndex("+this._collection.name()+", "+this._index+")",a.output+=b},j.prototype.near=function(a,b){return new m(this._collection,a,b,this._index)},j.prototype.within=function(a,b,c){return new n(this._collection,a,b,c,this._index)},j.prototype.withinRectangle=function(a,b,c,d){return new o(this._collection,a,b,c,d,this._index)},m=function(a,b,c,d){var e,f;if(this._collection=a,this._latitude=b,this._longitude=c,this._index=void 0===d?null:d,this._distance=null,void 0===d)for(e=a.getIndexes(),f=0;f=0&&g>f;f+=a){var h=e?e[f]:f;d=c(d,b[h],h,b)}return d}return function(c,d,e,f){d=v(d,f,4);var g=!C(c)&&u.keys(c),h=(g||c).length,i=a>0?0:h-1;return arguments.length<3&&(e=c[g?g[i]:i],i+=a),b(c,d,e,g,i,h)}}function d(a){return function(b,c,d){c=w(c,d);for(var e=B(b),f=a>0?0:e-1;f>=0&&e>f;f+=a)if(c(b[f],f,b))return f;return-1}}function e(a,b,c){return function(d,e,f){var g=0,h=B(d);if("number"==typeof f)a>0?g=f>=0?f:Math.max(f+h,g):h=f>=0?Math.min(f+1,h):f+h+1;else if(c&&f&&h)return f=c(d,e),d[f]===e?f:-1;if(e!==e)return f=b(m.call(d,g,h),u.isNaN),f>=0?f+g:-1;for(f=a>0?g:h-1;f>=0&&h>f;f+=a)if(d[f]===e)return f;return-1}}function f(a,b){var c=H.length,d=a.constructor,e=u.isFunction(d)&&d.prototype||j,f="constructor";for(u.has(a,f)&&!u.contains(b,f)&&b.push(f);c--;)f=H[c],f in a&&a[f]!==e[f]&&!u.contains(b,f)&&b.push(f)}var g=this,h=g._,i=Array.prototype,j=Object.prototype,k=Function.prototype,l=i.push,m=i.slice,n=j.toString,o=j.hasOwnProperty,p=Array.isArray,q=Object.keys,r=k.bind,s=Object.create,t=function(){},u=function S(a){return a instanceof S?a:this instanceof S?void(this._wrapped=a):new S(a)};"undefined"!=typeof a?("undefined"!=typeof b&&b.exports&&(a=b.exports=u),a._=u):g._=u,u.VERSION="1.8.3";var v=function(a,b,c){if(void 0===b)return a;switch(null==c?3:c){case 1:return function(c){return a.call(b,c)};case 2:return function(c,d){return a.call(b,c,d)};case 3:return function(c,d,e){return a.call(b,c,d,e)};case 4:return function(c,d,e,f){return a.call(b,c,d,e,f)}}return function(){return a.apply(b,arguments)}},w=function(a,b,c){return null==a?u.identity:u.isFunction(a)?v(a,b,c):u.isObject(a)?u.matcher(a):u.property(a)};u.iteratee=function(a,b){return w(a,b,1/0)};var x=function(a,b){return function(c){var d=arguments.length;if(2>d||null==c)return c;for(var e=1;d>e;e++)for(var f=arguments[e],g=a(f),h=g.length,i=0;h>i;i++){var j=g[i];b&&void 0!==c[j]||(c[j]=f[j])}return c}},y=function(a){if(!u.isObject(a))return{};if(s)return s(a);t.prototype=a;var b=new t;return t.prototype=null,b},z=function(a){return function(b){return null==b?void 0:b[a]}},A=Math.pow(2,53)-1,B=z("length"),C=function(a){var b=B(a);return"number"==typeof b&&b>=0&&A>=b};u.each=u.forEach=function(a,b,c){b=v(b,c);var d,e;if(C(a))for(d=0,e=a.length;e>d;d++)b(a[d],d,a);else{var f=u.keys(a);for(d=0,e=f.length;e>d;d++)b(a[f[d]],f[d],a)}return a},u.map=u.collect=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=Array(e),g=0;e>g;g++){var h=d?d[g]:g;f[g]=b(a[h],h,a)}return f},u.reduce=u.foldl=u.inject=c(1),u.reduceRight=u.foldr=c(-1),u.find=u.detect=function(a,b,c){var d;return d=C(a)?u.findIndex(a,b,c):u.findKey(a,b,c),void 0!==d&&-1!==d?a[d]:void 0},u.filter=u.select=function(a,b,c){var d=[];return b=w(b,c),u.each(a,function(a,c,e){b(a,c,e)&&d.push(a)}),d},u.reject=function(a,b,c){return u.filter(a,u.negate(w(b)),c)},u.every=u.all=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=0;e>f;f++){var g=d?d[f]:f;if(!b(a[g],g,a))return!1}return!0},u.some=u.any=function(a,b,c){b=w(b,c);for(var d=!C(a)&&u.keys(a),e=(d||a).length,f=0;e>f;f++){var g=d?d[f]:f;if(b(a[g],g,a))return!0}return!1},u.contains=u.includes=u.include=function(a,b,c,d){return C(a)||(a=u.values(a)),("number"!=typeof c||d)&&(c=0),u.indexOf(a,b,c)>=0},u.invoke=function(a,b){var c=m.call(arguments,2),d=u.isFunction(b);return u.map(a,function(a){var e=d?b:a[b];return null==e?e:e.apply(a,c)})},u.pluck=function(a,b){return u.map(a,u.property(b))},u.where=function(a,b){return u.filter(a,u.matcher(b))},u.findWhere=function(a,b){return u.find(a,u.matcher(b))},u.max=function(a,b,c){var d,e,f=-(1/0),g=-(1/0);if(null==b&&null!=a){a=C(a)?a:u.values(a);for(var h=0,i=a.length;i>h;h++)d=a[h],d>f&&(f=d)}else b=w(b,c),u.each(a,function(a,c,d){e=b(a,c,d),(e>g||e===-(1/0)&&f===-(1/0))&&(f=a,g=e)});return f},u.min=function(a,b,c){var d,e,f=1/0,g=1/0;if(null==b&&null!=a){a=C(a)?a:u.values(a);for(var h=0,i=a.length;i>h;h++)d=a[h],f>d&&(f=d)}else b=w(b,c),u.each(a,function(a,c,d){e=b(a,c,d),(g>e||e===1/0&&f===1/0)&&(f=a,g=e)});return f},u.shuffle=function(a){for(var b,c=C(a)?a:u.values(a),d=c.length,e=Array(d),f=0;d>f;f++)b=u.random(0,f),b!==f&&(e[f]=e[b]),e[b]=c[f];return e},u.sample=function(a,b,c){return null==b||c?(C(a)||(a=u.values(a)),a[u.random(a.length-1)]):u.shuffle(a).slice(0,Math.max(0,b))},u.sortBy=function(a,b,c){return b=w(b,c),u.pluck(u.map(a,function(a,c,d){return{value:a,index:c,criteria:b(a,c,d)}}).sort(function(a,b){var c=a.criteria,d=b.criteria;if(c!==d){if(c>d||void 0===c)return 1;if(d>c||void 0===d)return-1}return a.index-b.index}),"value")};var D=function(a){return function(b,c,d){var e={};return c=w(c,d),u.each(b,function(d,f){var g=c(d,f,b);a(e,d,g)}),e}};u.groupBy=D(function(a,b,c){u.has(a,c)?a[c].push(b):a[c]=[b]}),u.indexBy=D(function(a,b,c){a[c]=b}),u.countBy=D(function(a,b,c){u.has(a,c)?a[c]++:a[c]=1}),u.toArray=function(a){return a?u.isArray(a)?m.call(a):C(a)?u.map(a,u.identity):u.values(a):[]},u.size=function(a){return null==a?0:C(a)?a.length:u.keys(a).length},u.partition=function(a,b,c){b=w(b,c);var d=[],e=[];return u.each(a,function(a,c,f){(b(a,c,f)?d:e).push(a)}),[d,e]},u.first=u.head=u.take=function(a,b,c){return null==a?void 0:null==b||c?a[0]:u.initial(a,a.length-b)},u.initial=function(a,b,c){return m.call(a,0,Math.max(0,a.length-(null==b||c?1:b)))},u.last=function(a,b,c){return null==a?void 0:null==b||c?a[a.length-1]:u.rest(a,Math.max(0,a.length-b))},u.rest=u.tail=u.drop=function(a,b,c){return m.call(a,null==b||c?1:b)},u.compact=function(a){return u.filter(a,u.identity)};var E=function T(a,b,c,d){for(var e=[],f=0,g=d||0,h=B(a);h>g;g++){var i=a[g];if(C(i)&&(u.isArray(i)||u.isArguments(i))){b||(i=T(i,b,c));var j=0,k=i.length;for(e.length+=k;k>j;)e[f++]=i[j++]}else c||(e[f++]=i)}return e};u.flatten=function(a,b){return E(a,b,!1)},u.without=function(a){return u.difference(a,m.call(arguments,1))},u.uniq=u.unique=function(a,b,c,d){u.isBoolean(b)||(d=c,c=b,b=!1),null!=c&&(c=w(c,d));for(var e=[],f=[],g=0,h=B(a);h>g;g++){var i=a[g],j=c?c(i,g,a):i;b?(g&&f===j||e.push(i),f=j):c?u.contains(f,j)||(f.push(j),e.push(i)):u.contains(e,i)||e.push(i)}return e},u.union=function(){return u.uniq(E(arguments,!0,!0))},u.intersection=function(a){for(var b=[],c=arguments.length,d=0,e=B(a);e>d;d++){var f=a[d];if(!u.contains(b,f)){for(var g=1;c>g&&u.contains(arguments[g],f);g++);g===c&&b.push(f)}}return b},u.difference=function(a){var b=E(arguments,!0,!0,1);return u.filter(a,function(a){return!u.contains(b,a)})},u.zip=function(){return u.unzip(arguments)},u.unzip=function(a){for(var b=a&&u.max(a,B).length||0,c=Array(b),d=0;b>d;d++)c[d]=u.pluck(a,d);return c},u.object=function(a,b){for(var c={},d=0,e=B(a);e>d;d++)b?c[a[d]]=b[d]:c[a[d][0]]=a[d][1];return c},u.findIndex=d(1),u.findLastIndex=d(-1),u.sortedIndex=function(a,b,c,d){c=w(c,d,1);for(var e=c(b),f=0,g=B(a);g>f;){var h=Math.floor((f+g)/2);c(a[h])f;f++,a+=c)e[f]=a;return e};var F=function(a,b,c,d,e){if(!(d instanceof b))return a.apply(c,e);var f=y(a.prototype),g=a.apply(f,e);return u.isObject(g)?g:f};u.bind=function(a,b){if(r&&a.bind===r)return r.apply(a,m.call(arguments,1));if(!u.isFunction(a))throw new TypeError("Bind must be called on a function");var c=m.call(arguments,2),d=function e(){return F(a,e,b,this,c.concat(m.call(arguments)))};return d},u.partial=function(a){var b=m.call(arguments,1),c=function d(){for(var c=0,e=b.length,f=Array(e),g=0;e>g;g++)f[g]=b[g]===u?arguments[c++]:b[g];for(;c=d)throw new Error("bindAll must be passed function names");for(b=1;d>b;b++)c=arguments[b],a[c]=u.bind(a[c],a);return a},u.memoize=function(a,b){var c=function d(c){var e=d.cache,f=""+(b?b.apply(this,arguments):c);return u.has(e,f)||(e[f]=a.apply(this,arguments)),e[f]};return c.cache={},c},u.delay=function(a,b){var c=m.call(arguments,2);return setTimeout(function(){return a.apply(null,c)},b)},u.defer=u.partial(u.delay,u,1),u.throttle=function(a,b,c){var d,e,f,g=null,h=0;c||(c={});var i=function(){h=c.leading===!1?0:u.now(),g=null,f=a.apply(d,e),g||(d=e=null)};return function(){var j=u.now();h||c.leading!==!1||(h=j);var k=b-(j-h);return d=this,e=arguments,0>=k||k>b?(g&&(clearTimeout(g),g=null),h=j,f=a.apply(d,e),g||(d=e=null)):g||c.trailing===!1||(g=setTimeout(i,k)),f}},u.debounce=function(a,b,c){var d,e,f,g,h,i=function j(){var i=u.now()-g;b>i&&i>=0?d=setTimeout(j,b-i):(d=null,c||(h=a.apply(f,e),d||(f=e=null)))};return function(){f=this,e=arguments,g=u.now();var j=c&&!d;return d||(d=setTimeout(i,b)),j&&(h=a.apply(f,e),f=e=null),h}},u.wrap=function(a,b){return u.partial(b,a)},u.negate=function(a){return function(){return!a.apply(this,arguments)}},u.compose=function(){var a=arguments,b=a.length-1;return function(){for(var c=b,d=a[b].apply(this,arguments);c--;)d=a[c].call(this,d);return d}},u.after=function(a,b){return function(){return--a<1?b.apply(this,arguments):void 0}},u.before=function(a,b){var c;return function(){return--a>0&&(c=b.apply(this,arguments)),1>=a&&(b=null),c}},u.once=u.partial(u.before,2);var G=!{toString:null}.propertyIsEnumerable("toString"),H=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"]; -u.keys=function(a){if(!u.isObject(a))return[];if(q)return q(a);var b=[];for(var c in a)u.has(a,c)&&b.push(c);return G&&f(a,b),b},u.allKeys=function(a){if(!u.isObject(a))return[];var b=[];for(var c in a)b.push(c);return G&&f(a,b),b},u.values=function(a){for(var b=u.keys(a),c=b.length,d=Array(c),e=0;c>e;e++)d[e]=a[b[e]];return d},u.mapObject=function(a,b,c){b=w(b,c);for(var d,e=u.keys(a),f=e.length,g={},h=0;f>h;h++)d=e[h],g[d]=b(a[d],d,a);return g},u.pairs=function(a){for(var b=u.keys(a),c=b.length,d=Array(c),e=0;c>e;e++)d[e]=[b[e],a[b[e]]];return d},u.invert=function(a){for(var b={},c=u.keys(a),d=0,e=c.length;e>d;d++)b[a[c[d]]]=c[d];return b},u.functions=u.methods=function(a){var b=[];for(var c in a)u.isFunction(a[c])&&b.push(c);return b.sort()},u.extend=x(u.allKeys),u.extendOwn=u.assign=x(u.keys),u.findKey=function(a,b,c){b=w(b,c);for(var d,e=u.keys(a),f=0,g=e.length;g>f;f++)if(d=e[f],b(a[d],d,a))return d},u.pick=function(a,b,c){var d,e,f={},g=a;if(null==g)return f;u.isFunction(b)?(e=u.allKeys(g),d=v(b,c)):(e=E(arguments,!1,!1,1),d=function(a,b,c){return b in c},g=Object(g));for(var h=0,i=e.length;i>h;h++){var j=e[h],k=g[j];d(k,j,g)&&(f[j]=k)}return f},u.omit=function(a,b,c){if(u.isFunction(b))b=u.negate(b);else{var d=u.map(E(arguments,!1,!1,1),String);b=function(a,b){return!u.contains(d,b)}}return u.pick(a,b,c)},u.defaults=x(u.allKeys,!0),u.create=function(a,b){var c=y(a);return b&&u.extendOwn(c,b),c},u.clone=function(a){return u.isObject(a)?u.isArray(a)?a.slice():u.extend({},a):a},u.tap=function(a,b){return b(a),a},u.isMatch=function(a,b){var c=u.keys(b),d=c.length;if(null==a)return!d;for(var e=Object(a),f=0;d>f;f++){var g=c[f];if(b[g]!==e[g]||!(g in e))return!1}return!0};var I=function U(a,b,c,d){if(a===b)return 0!==a||1/a===1/b;if(null==a||null==b)return a===b;a instanceof u&&(a=a._wrapped),b instanceof u&&(b=b._wrapped);var e=n.call(a);if(e!==n.call(b))return!1;switch(e){case"[object RegExp]":case"[object String]":return""+a==""+b;case"[object Number]":return+a!==+a?+b!==+b:0===+a?1/+a===1/b:+a===+b;case"[object Date]":case"[object Boolean]":return+a===+b}var f="[object Array]"===e;if(!f){if("object"!=typeof a||"object"!=typeof b)return!1;var g=a.constructor,h=b.constructor;if(g!==h&&!(u.isFunction(g)&&g instanceof g&&u.isFunction(h)&&h instanceof h)&&"constructor"in a&&"constructor"in b)return!1}c=c||[],d=d||[];for(var i=c.length;i--;)if(c[i]===a)return d[i]===b;if(c.push(a),d.push(b),f){if(i=a.length,i!==b.length)return!1;for(;i--;)if(!U(a[i],b[i],c,d))return!1}else{var j,k=u.keys(a);if(i=k.length,u.keys(b).length!==i)return!1;for(;i--;)if(j=k[i],!u.has(b,j)||!U(a[j],b[j],c,d))return!1}return c.pop(),d.pop(),!0};u.isEqual=function(a,b){return I(a,b)},u.isEmpty=function(a){return null==a?!0:C(a)&&(u.isArray(a)||u.isString(a)||u.isArguments(a))?0===a.length:0===u.keys(a).length},u.isElement=function(a){return!(!a||1!==a.nodeType)},u.isArray=p||function(a){return"[object Array]"===n.call(a)},u.isObject=function(a){var b=typeof a;return"function"===b||"object"===b&&!!a},u.each(["Arguments","Function","String","Number","Date","RegExp","Error"],function(a){u["is"+a]=function(b){return n.call(b)==="[object "+a+"]"}}),u.isArguments(arguments)||(u.isArguments=function(a){return u.has(a,"callee")}),"function"!=typeof/./&&"object"!=typeof Int8Array&&(u.isFunction=function(a){return"function"==typeof a||!1}),u.isFinite=function(a){return isFinite(a)&&!isNaN(parseFloat(a))},u.isNaN=function(a){return u.isNumber(a)&&a!==+a},u.isBoolean=function(a){return a===!0||a===!1||"[object Boolean]"===n.call(a)},u.isNull=function(a){return null===a},u.isUndefined=function(a){return void 0===a},u.has=function(a,b){return null!=a&&o.call(a,b)},u.noConflict=function(){return g._=h,this},u.identity=function(a){return a},u.constant=function(a){return function(){return a}},u.noop=function(){},u.property=z,u.propertyOf=function(a){return null==a?function(){}:function(b){return a[b]}},u.matcher=u.matches=function(a){return a=u.extendOwn({},a),function(b){return u.isMatch(b,a)}},u.times=function(a,b,c){var d=Array(Math.max(0,a));b=v(b,c,1);for(var e=0;a>e;e++)d[e]=b(e);return d},u.random=function(a,b){return null==b&&(b=a,a=0),a+Math.floor(Math.random()*(b-a+1))},u.now=Date.now||function(){return(new Date).getTime()};var J={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},K=u.invert(J),L=function(a){var b=function(b){return a[b]},c="(?:"+u.keys(a).join("|")+")",d=RegExp(c),e=RegExp(c,"g");return function(a){return a=null==a?"":""+a,d.test(a)?a.replace(e,b):a}};u.escape=L(J),u.unescape=L(K),u.result=function(a,b,c){var d=null==a?void 0:a[b];return void 0===d&&(d=c),u.isFunction(d)?d.call(a):d};var M=0;u.uniqueId=function(a){var b=++M+"";return a?a+b:b},u.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var N=/(.)^/,O={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},P=/\\|'|\r|\n|\u2028|\u2029/g,Q=function(a){return"\\"+O[a]};u.template=function(a,b,c){!b&&c&&(b=c),b=u.defaults({},b,u.templateSettings);var d=RegExp([(b.escape||N).source,(b.interpolate||N).source,(b.evaluate||N).source].join("|")+"|$","g"),e=0,f="__p+='";a.replace(d,function(b,c,d,g,h){return f+=a.slice(e,h).replace(P,Q),e=h+b.length,c?f+="'+\n((__t=("+c+"))==null?'':_.escape(__t))+\n'":d?f+="'+\n((__t=("+d+"))==null?'':__t)+\n'":g&&(f+="';\n"+g+"\n__p+='"),b}),f+="';\n",b.variable||(f="with(obj||{}){\n"+f+"}\n"),f="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+f+"return __p;\n";try{var g=new Function(b.variable||"obj","_",f)}catch(h){throw h.source=f,h}var i=function(a){return g.call(this,a,u)},j=b.variable||"obj";return i.source="function("+j+"){\n"+f+"}",i},u.chain=function(a){var b=u(a);return b._chain=!0,b};var R=function(a,b){return a._chain?u(b).chain():b};u.mixin=function(a){u.each(u.functions(a),function(b){var c=u[b]=a[b];u.prototype[b]=function(){var a=[this._wrapped];return l.apply(a,arguments),R(this,c.apply(u,a))}})},u.mixin(u),u.each(["pop","push","reverse","shift","sort","splice","unshift"],function(a){var b=i[a];u.prototype[a]=function(){var c=this._wrapped;return b.apply(c,arguments),"shift"!==a&&"splice"!==a||0!==c.length||delete c[0],R(this,c)}}),u.each(["concat","join","slice"],function(a){var b=i[a];u.prototype[a]=function(){return R(this,b.apply(this._wrapped,arguments))}}),u.prototype.value=function(){return this._wrapped},u.prototype.valueOf=u.prototype.toJSON=u.prototype.value,u.prototype.toString=function(){return""+this._wrapped},"function"==typeof define&&define.amd&&define("underscore",[],function(){return u})}).call(this)}),"undefined"==typeof global&&"undefined"!=typeof window&&(global=window),global.Buffer=require("buffer").Buffer,global.process=require("process"),global.setInterval=global.setInterval||function(){},global.clearInterval=global.clearInterval||function(){},global.setTimeout=global.setTimeout||function(){},global.clearTimeout=global.clearTimeout||function(){},global.aqlQuery=function(){var a,b,c,d=arguments[0],e={},f=d[0];for(c=1;cc;++c)b+="\n";a.print(b)},global.console=global.console||require("console"),global.db=require("@arangodb").db,global.arango=require("@arangodb").arango,global.fm=require("@arangodb/foxx/manager"),global.ArangoStatement=require("@arangodb/arango-statement").ArangoStatement,global.tutorial=require("@arangodb/tutorial");var initHelp=function(){var a=require("internal");if(a.db)try{a.db._collections()}catch(b){}a.quiet!==!0&&(require("@arangodb").checkAvailableVersions(),a.arango&&a.arango.isConnected&&a.arango.isConnected()&&a.print("Type 'tutorial' for a tutorial or 'help' to see common examples"))};if("undefined"==typeof window){if(initHelp(),!(global.IS_EXECUTE_SCRIPT||global.IS_EXECUTE_STRING||global.IS_CHECK_SCRIPT||global.IS_UNIT_TESTS||global.IS_JS_LINT))try{var __fs__=require("fs"),__rcf__=__fs__.join(__fs__.home(),".arangosh.rc");if(__fs__.exists(__rcf__)){var __content__=__fs__.read(__rcf__);eval(__content__)}}catch(e){require("console").warn("arangosh.rc: %s",String(e))}try{delete global.IS_EXECUTE_SCRIPT,delete global.IS_EXECUTE_STRING,delete global.IS_CHECK_SCRIPT,delete global.IS_UNIT_TESTS,delete global.IS_JS_LINT}catch(e){}}!function(){"use strict";window.arangoCollectionModel=Backbone.Model.extend({initialize:function(){},idAttribute:"name",urlRoot:"/_api/collection",defaults:{id:"",name:"",status:"",type:"",isSystem:!1,picture:""},getProperties:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/collection/"+encodeURIComponent(this.get("id"))+"/properties",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},getFigures:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/collection/"+this.get("id")+"/figures",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},getRevision:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/collection/"+this.get("id")+"/revision",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},getIndex:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/index/?collection="+this.get("id"),contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},addJobToSystem:function(a){console.log(a)},createIndex:function(a,b){var c=this;$.ajax({cache:!1,type:"POST",url:"/_api/index?collection="+this.get("id"),headers:{"x-arango-async":"store"},data:JSON.stringify(a),contentType:"application/json",processData:!1,async:!0,success:function(a,d,e){e.getResponseHeader("x-arango-async-id")?(c.addJobToSystem(e.getResponseHeader("x-arango-async-id")),b(!1,a)):b(!0,a)},error:function(a){b(!0,a)}}),b()},deleteIndex:function(a,b){$.ajax({cache:!1,type:"DELETE",url:"/_api/index/"+this.get("name")+"/"+encodeURIComponent(a),async:!1,success:function(){b(!1)},error:function(a){b(!0,a)}}),b()},truncateCollection:function(){$.ajax({async:!1,cache:!1,type:"PUT",url:"/_api/collection/"+this.get("id")+"/truncate",success:function(){arangoHelper.arangoNotification("Collection truncated")},error:function(){arangoHelper.arangoError("Collection error")}})},loadCollection:function(a){$.ajax({async:!0,cache:!1,type:"PUT",url:"/_api/collection/"+this.get("id")+"/load",success:function(){a(!1)},error:function(){a(!0)}}),a()},unloadCollection:function(a){$.ajax({async:!0,cache:!1,type:"PUT",url:"/_api/collection/"+this.get("id")+"/unload?flush=true",success:function(){a(!1)},error:function(){a(!0)}}),a()},renameCollection:function(a){var b=this,c=!1;return $.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/collection/"+this.get("id")+"/rename",data:JSON.stringify({name:a}),contentType:"application/json",processData:!1,success:function(){b.set("name",a),c=!0},error:function(){try{console.log("error")}catch(a){c=!1}}}),c},changeCollection:function(a,b,c){var d=!1;"true"===a?a=!0:"false"===a&&(a=!1);var e={waitForSync:a,journalSize:parseInt(b),indexBuckets:parseInt(c)};return $.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/collection/"+this.get("id")+"/properties",data:JSON.stringify(e),contentType:"application/json",processData:!1,success:function(){d=!0},error:function(a){try{var b=JSON.parse(a.responseText);d=b.errorMessage}catch(c){d=!1}}}),d}})}(),window.DatabaseModel=Backbone.Model.extend({idAttribute:"name",initialize:function(){"use strict"},isNew:function(){"use strict";return!1},sync:function(a,b,c){"use strict";return"update"===a&&(a="create"),Backbone.sync(a,b,c)},url:"/_api/database",defaults:{}}),window.arangoDocumentModel=Backbone.Model.extend({initialize:function(){"use strict"},urlRoot:"/_api/document",defaults:{_id:"",_rev:"",_key:""},getSorted:function(){"use strict";var a=this,b=Object.keys(a.attributes).sort(function(a,b){var c=arangoHelper.isSystemAttribute(a),d=arangoHelper.isSystemAttribute(b);return c!==d?c?-1:1:b>a?-1:1}),c={};return _.each(b,function(b){c[b]=a.attributes[b]}),c}}),function(){"use strict";window.ArangoQuery=Backbone.Model.extend({urlRoot:"/_api/user",defaults:{name:"",type:"custom",value:""}})}(),window.Replication=Backbone.Model.extend({defaults:{state:{},server:{}},initialize:function(){}}),window.Statistics=Backbone.Model.extend({defaults:{},url:function(){"use strict";return"/_admin/statistics"}}),window.StatisticsDescription=Backbone.Model.extend({defaults:{figures:"",groups:""},url:function(){"use strict";return"/_admin/statistics-description"}}),window.Users=Backbone.Model.extend({defaults:{user:"",active:!1,extra:{}},idAttribute:"user",parse:function(a){return this.isNotNew=!0,a},isNew:function(){return!this.isNotNew},url:function(){return this.isNew()?"/_api/user":""!==this.get("user")?"/_api/user/"+this.get("user"):"/_api/user"},checkPassword:function(a){var b=!1;return $.ajax({cache:!1,type:"POST",async:!1,url:"/_api/user/"+this.get("user"),data:JSON.stringify({passwd:a}),contentType:"application/json",processData:!1,success:function(a){b=a.result}}),b},setPassword:function(a){$.ajax({cache:!1,type:"PATCH",async:!1,url:"/_api/user/"+this.get("user"),data:JSON.stringify({passwd:a}),contentType:"application/json",processData:!1})},setExtras:function(a,b){$.ajax({cache:!1,type:"PATCH",async:!1,url:"/_api/user/"+this.get("user"),data:JSON.stringify({extra:{name:a,img:b}}),contentType:"application/json",processData:!1})}}),function(){"use strict";window.CurrentDatabase=Backbone.Model.extend({url:"/_api/database/current",parse:function(a){return a.result}})}(),function(){"use strict";var a=function(a,b,c,d,e,f){var g={contentType:"application/json",processData:!1,type:c};b=b||function(){},f=_.extend({mount:a.encodedMount()},f);var h=_.reduce(f,function(a,b,c){return a+encodeURIComponent(c)+"="+encodeURIComponent(b)+"&"},"?");g.url="/_admin/aardvark/foxxes"+(d?"/"+d:"")+h.slice(0,h.length-1),void 0!==e&&(g.data=JSON.stringify(e)),$.ajax(g).then(function(a){b(null,a)},function(a){window.xhr=a,b(_.extend(a.status?new Error(a.responseJSON?a.responseJSON.errorMessage:a.responseText):new Error("Network Error"),{statusCode:a.status}))})};window.Foxx=Backbone.Model.extend({idAttribute:"mount",defaults:{author:"Unknown Author",name:"",version:"Unknown Version",description:"No description",license:"Unknown License",contributors:[],scripts:{},config:{},deps:{},git:"",system:!1,development:!1},isNew:function(){return!1},encodedMount:function(){return encodeURIComponent(this.get("mount"))},destroy:function(b,c){a(this,c,"DELETE",void 0,void 0,b)},isBroken:function(){return!1},needsAttention:function(){return this.isBroken()||this.needsConfiguration()||this.hasUnconfiguredDependencies()},needsConfiguration:function(){return _.any(this.get("config"),function(a){return void 0===a.current&&a.required!==!1})},hasUnconfiguredDependencies:function(){return _.any(this.get("deps"),function(a){return void 0===a.current&&a.definition.required!==!1})},getConfiguration:function(b){a(this,function(a,c){a||this.set("config",c),"function"==typeof b&&b(a,c)}.bind(this),"GET","config")},setConfiguration:function(b,c){a(this,c,"PATCH","config",b)},getDependencies:function(b){a(this,function(a,c){a||this.set("deps",c),"function"==typeof b&&b(a,c)}.bind(this),"GET","deps")},setDependencies:function(b,c){a(this,c,"PATCH","deps",b)},toggleDevelopment:function(b,c){a(this,function(a,d){a||this.set("development",b),"function"==typeof c&&c(a,d)}.bind(this),"PATCH","devel",b)},runScript:function(b,c,d){a(this,d,"POST","scripts/"+b,c)},runTests:function(b,c){a(this,function(a,b){"function"==typeof c&&c(a?a.responseJSON:a,b)}.bind(this),"POST","tests",b)},isSystem:function(){return this.get("system")},isDevelopment:function(){return this.get("development")},download:function(){window.open("/_db/"+arango.getDatabaseName()+"/_admin/aardvark/foxxes/download/zip?mount="+this.encodedMount())}})}(),function(){"use strict";window.Graph=Backbone.Model.extend({idAttribute:"_key",urlRoot:"/_api/gharial",isNew:function(){return!this.get("_id")},parse:function(a){return a.graph||a},addEdgeDefinition:function(a){$.ajax({async:!1,type:"POST",url:this.urlRoot+"/"+this.get("_key")+"/edge",data:JSON.stringify(a)})},deleteEdgeDefinition:function(a){$.ajax({async:!1,type:"DELETE",url:this.urlRoot+"/"+this.get("_key")+"/edge/"+a})},modifyEdgeDefinition:function(a){$.ajax({async:!1,type:"PUT",url:this.urlRoot+"/"+this.get("_key")+"/edge/"+a.collection,data:JSON.stringify(a)})},addVertexCollection:function(a){$.ajax({async:!1,type:"POST",url:this.urlRoot+"/"+this.get("_key")+"/vertex",data:JSON.stringify({collection:a})})},deleteVertexCollection:function(a){$.ajax({async:!1,type:"DELETE",url:this.urlRoot+"/"+this.get("_key")+"/vertex/"+a})},defaults:{name:"",edgeDefinitions:[],orphanCollections:[]}})}(),function(){"use strict";window.newArangoLog=Backbone.Model.extend({defaults:{lid:"",level:"",timestamp:"",text:"",totalAmount:""},getLogStatus:function(){switch(this.get("level")){case 1:return"Error";case 2:return"Warning";case 3:return"Info";case 4:return"Debug";default:return"Unknown"}}})}(),function(){"use strict";window.Notification=Backbone.Model.extend({defaults:{title:"",date:0,content:"",priority:"",tags:"",seen:!1}})}(),function(){"use strict";window.queryManagementModel=Backbone.Model.extend({defaults:{id:"",query:"",started:"",runTime:""}})}(),function(){"use strict";window.workMonitorModel=Backbone.Model.extend({defaults:{name:"",number:"",status:"",type:""}})}(),function(){"use strict";window.PaginatedCollection=Backbone.Collection.extend({page:0,pagesize:10,totalAmount:0,getPage:function(){return this.page+1},setPage:function(a){return a>=this.getLastPageNumber()?void(this.page=this.getLastPageNumber()-1):1>a?void(this.page=0):void(this.page=a-1)},getLastPageNumber:function(){return Math.max(Math.ceil(this.totalAmount/this.pagesize),1)},getOffset:function(){return this.page*this.pagesize},getPageSize:function(){return this.pagesize},setPageSize:function(a){if("all"===a)this.pagesize="all";else try{a=parseInt(a,10),this.pagesize=a}catch(b){}},setToFirst:function(){this.page=0},setToLast:function(){this.setPage(this.getLastPageNumber())},setToPrev:function(){this.setPage(this.getPage()-1)},setToNext:function(){this.setPage(this.getPage()+1)},setTotal:function(a){this.totalAmount=a},getTotal:function(){return this.totalAmount},setTotalMinusOne:function(){this.totalAmount--}})}(),function(){"use strict";window.arangoCollections=Backbone.Collection.extend({url:"/_api/collection",model:arangoCollectionModel,searchOptions:{searchPhrase:null,includeSystem:!1,includeDocument:!0,includeEdge:!0,includeLoaded:!0,includeUnloaded:!0,sortBy:"name",sortOrder:1},translateStatus:function(a){switch(a){case 0:return"corrupted";case 1:return"new born collection";case 2:return"unloaded";case 3:return"loaded";case 4:return"will be unloaded";case 5:return"deleted";case 6:return"loading";default:return}},translateTypePicture:function(a){var b="";switch(a){case"document":b+="fa-file-text-o";break;case"edge":b+="fa-share-alt";break;case"unknown":b+="fa-question";break;default:b+="fa-cogs"}return b},parse:function(a){var b=this;return _.each(a.collections,function(a){a.isSystem=arangoHelper.isSystemCollection(a),a.type=arangoHelper.collectionType(a),a.status=b.translateStatus(a.status),a.picture=b.translateTypePicture(a.type)}),a.collections},getPosition:function(a){var b,c=this.getFiltered(this.searchOptions),d=null,e=null;for(b=0;b0&&(d=c[b-1]),b0){var e,f=d.get("name").toLowerCase();for(e=0;ed?-1:1):0}),b},newCollection:function(a,b,c,d,e,f,g){var h={},i={};return i.name=a,i.waitForSync=b,d>0&&(i.journalSize=d),i.isSystem=c,i.type=parseInt(e,10),f&&(i.numberOfShards=f,i.shardKeys=g),h.status=!1,$.ajax({cache:!1,type:"POST",url:"/_api/collection",data:JSON.stringify(i),contentType:"application/json",processData:!1,async:!1,success:function(a){h.status=!0,h.data=a},error:function(a){h.status=!1,h.errorMessage=JSON.parse(a.responseText).errorMessage}}),h}})}(),function(){"use strict";window.ArangoDatabase=Backbone.Collection.extend({model:window.DatabaseModel,sortOptions:{desc:!1},url:"/_api/database",comparator:function(a,b){var c=a.get("name").toLowerCase(),d=b.get("name").toLowerCase();return this.sortOptions.desc===!0?d>c?1:c>d?-1:0:c>d?1:d>c?-1:0},parse:function(a){return a?_.map(a.result,function(a){return{name:a}}):void 0},initialize:function(){var a=this;this.fetch().done(function(){a.sort()})},setSortingDesc:function(a){this.sortOptions.desc=a},getDatabases:function(){var a=this;return this.fetch().done(function(){a.sort()}),this.models},getDatabasesForUser:function(){var a;return $.ajax({type:"GET",cache:!1,url:this.url+"/user",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b.result},error:function(){a=[]}}),a.sort()},createDatabaseURL:function(a,b,c){var d=window.location,e=window.location.hash;b=b?"SSL"===b||"https:"===b?"https:":"http:":d.protocol,c=c||d.port;var f=b+"//"+window.location.hostname+":"+c+"/_db/"+encodeURIComponent(a)+"/_admin/aardvark/standalone.html";if(e){var g=e.split("/")[0];0===g.indexOf("#collection")&&(g="#collections"),0===g.indexOf("#application")&&(g="#applications"),f+=g}return f},getCurrentDatabase:function(){var a;return $.ajax({type:"GET",cache:!1,url:this.url+"/current",contentType:"application/json",processData:!1,async:!1,success:function(b){return 200===b.code?void(a=b.result.name):void(a=b)},error:function(b){a=b}}),a},hasSystemAccess:function(){var a=this.getDatabasesForUser();return _.contains(a,"_system")}})}(),window.arangoDocument=Backbone.Collection.extend({url:"/_api/document/",model:arangoDocumentModel,collectionInfo:{},deleteEdge:function(a,b){var c=!1;try{$.ajax({cache:!1,type:"DELETE",async:!1,contentType:"application/json",url:"/_api/edge/"+a+"/"+b,success:function(){c=!0},error:function(){c=!1}})}catch(d){c=!1}return c},deleteDocument:function(a,b){var c=!1;try{$.ajax({cache:!1,type:"DELETE",async:!1,contentType:"application/json",url:"/_api/document/"+a+"/"+b,success:function(){c=!0},error:function(){c=!1}})}catch(d){c=!1}return c},addDocument:function(a,b){var c=this;c.createTypeDocument(a,b)},createTypeEdge:function(a,b,c,d){var e,f=!1;return e=d?JSON.stringify({_key:d}):JSON.stringify({}),$.ajax({cache:!1,type:"POST",async:!1,url:"/_api/edge?collection="+a+"&from="+b+"&to="+c,data:e,contentType:"application/json",processData:!1,success:function(a){f=a._id},error:function(a){f=!1}}),f},createTypeDocument:function(a,b){var c,d=!1;return c=b?JSON.stringify({_key:b}):JSON.stringify({}),$.ajax({cache:!1,type:"POST",async:!1,url:"/_api/document?collection="+encodeURIComponent(a),data:c,contentType:"application/json",processData:!1,success:function(a){d=a._id},error:function(a){d=!1}}),d},getCollectionInfo:function(a){var b=this;return $.ajax({cache:!1,type:"GET",url:"/_api/collection/"+a+"?"+arangoHelper.getRandomToken(),contentType:"application/json",processData:!1,async:!1,success:function(a){b.collectionInfo=a},error:function(a){}}),b.collectionInfo},getEdge:function(a,b){var c=!1,d=this;return this.clearDocument(),$.ajax({cache:!1,type:"GET",async:!1,url:"/_api/edge/"+a+"/"+b,contentType:"application/json",processData:!1,success:function(a){d.add(a),c=!0},error:function(a){c=!1}}),c},getDocument:function(a,b){var c=!1,d=this;return this.clearDocument(),$.ajax({cache:!1,type:"GET",async:!1,url:"/_api/document/"+a+"/"+b,contentType:"application/json",processData:!1,success:function(a){d.add(a),c=!0},error:function(a){c=!1}}),c},saveEdge:function(a,b,c){var d=!1;return $.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/edge/"+a+"/"+b,data:c,contentType:"application/json",processData:!1,success:function(a){d=!0},error:function(a){d=!1}}),d},saveDocument:function(a,b,c){var d=!1;return $.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/document/"+a+"/"+b,data:c,contentType:"application/json",processData:!1,success:function(a){d=!0},error:function(a){d=!1}}),d},updateLocalDocument:function(a){this.clearDocument(),this.add(a)},clearDocument:function(){this.reset()}}),function(){"use strict";window.arangoDocuments=window.PaginatedCollection.extend({collectionID:1,filters:[],MAX_SORT:12e3,lastQuery:{},sortAttribute:"_key",url:"/_api/documents",model:window.arangoDocumentModel,loadTotal:function(){var a=this;$.ajax({cache:!1,type:"GET",url:"/_api/collection/"+this.collectionID+"/count",contentType:"application/json",processData:!1,async:!1,success:function(b){a.setTotal(b.count)}})},setCollection:function(a){this.resetFilter(),this.collectionID=a,this.setPage(1),this.loadTotal()},setSort:function(a){this.sortAttribute=a},getSort:function(){return this.sortAttribute},addFilter:function(a,b,c){this.filters.push({attr:a,op:b,val:c})},setFiltersForQuery:function(a){if(0===this.filters.length)return"";var b=" FILTER",c="",d=_.map(this.filters,function(b,d){return"LIKE"===b.op?(c=" "+b.op+"(x.`"+b.attr+"`, @param",c+=d,c+=")"):(c="IN"===b.op||"NOT IN"===b.op?" ":" x.`",c+=b.attr,c+="IN"===b.op||"NOT IN"===b.op?" ":"` ",c+=b.op,c+="IN"===b.op||"NOT IN"===b.op?" x.@param":" @param",c+=d),a["param"+d]=b.val,c});return b+d.join(" &&")},setPagesize:function(a){this.setPageSize(a)},resetFilter:function(){this.filters=[]},moveDocument:function(a,b,c,d){var e,f,g,h,i={"@collection":b,filterid:a};e="FOR x IN @@collection",e+=" FILTER x._key == @filterid",e+=" INSERT x IN ",e+=c,f="FOR x in @@collection",f+=" FILTER x._key == @filterid",f+=" REMOVE x IN @@collection",g={query:e,bindVars:i},h={query:f,bindVars:i},window.progressView.show(),$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(g),contentType:"application/json",success:function(a){$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(h),contentType:"application/json",success:function(a){d&&d(),window.progressView.hide()},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Documents inserted, but could not be removed.")}})},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not move selected documents.")}})},getDocuments:function(a){window.progressView.showWithDelay(300,"Fetching documents...");var b,c,d,e,f=this;c={"@collection":this.collectionID,offset:this.getOffset(),count:this.getPageSize()},b="FOR x IN @@collection LET att = SLICE(ATTRIBUTES(x), 0, 25)",b+=this.setFiltersForQuery(c),this.getTotal()0)&&(e.options={fullCount:!0}),$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(e),contentType:"application/json",success:function(b){window.progressView.toShow=!1,f.clearDocuments(),b.extra&&void 0!==b.extra.stats.fullCount&&f.setTotal(b.extra.stats.fullCount),0!==f.getTotal()&&_.each(b.result,function(a){f.add({id:a._id,rev:a._rev,key:a._key,content:a})}),f.lastQuery=e,a(),window.progressView.hide()},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not fetch requested documents.")}})},clearDocuments:function(){this.reset()},buildDownloadDocumentQuery:function(){var a,b,c;return c={"@collection":this.collectionID},a="FOR x in @@collection",a+=this.setFiltersForQuery(c),this.getTotal()0&&(b="At least one error occurred during upload")}catch(d){}}}),b}})}(),function(){"use strict";window.ArangoLogs=window.PaginatedCollection.extend({upto:!1,loglevel:0,totalPages:0,parse:function(a){var b=[];return _.each(a.lid,function(c,d){b.push({level:a.level[d],lid:c,text:a.text[d],timestamp:a.timestamp[d],totalAmount:a.totalAmount})}),this.totalAmount=a.totalAmount,this.totalPages=Math.ceil(this.totalAmount/this.pagesize),b},initialize:function(a){a.upto===!0&&(this.upto=!0),this.loglevel=a.loglevel},model:window.newArangoLog,url:function(){var a,b,c,d;c=this.page*this.pagesize;var e=this.totalAmount-(this.page+1)*this.pagesize;return 0>e&&this.page===this.totalPages-1?(e=0,d=this.totalAmount%this.pagesize):d=this.pagesize,0===this.totalAmount&&(d=1),a=this.upto?"upto":"level",b="/_admin/log?"+a+"="+this.loglevel+"&size="+d+"&offset="+e}})}(),function(){"use strict";window.ArangoQueries=Backbone.Collection.extend({initialize:function(a,b){var c;$.ajax("whoAmI?_="+Date.now(),{async:!1}).done(function(a){c=a.user}),this.activeUser=c,this.activeUser===!1&&(this.activeUser="root")},url:"/_api/user/",model:ArangoQuery,activeUser:null,parse:function(a){var b,c=this;return _.each(a.result,function(a){if(a.user===c.activeUser)try{a.extra.queries&&(b=a.extra.queries)}catch(d){}}),b},saveCollectionQueries:function(){if(0===this.activeUser)return!1;var a=!1,b=[];return this.each(function(a){b.push({value:a.attributes.value,parameter:a.attributes.parameter,name:a.attributes.name})}),$.ajax({cache:!1,type:"PATCH",async:!1,url:"/_api/user/"+encodeURIComponent(this.activeUser),data:JSON.stringify({extra:{queries:b}}),contentType:"application/json",processData:!1,success:function(){a=!0},error:function(){a=!1}}),a},saveImportQueries:function(a,b){return 0===this.activeUser?!1:(window.progressView.show("Fetching documents..."),void $.ajax({cache:!1,type:"POST",async:!1,url:"query/upload/"+encodeURIComponent(this.activeUser),data:a,contentType:"application/json",processData:!1,success:function(){window.progressView.hide(),arangoHelper.arangoNotification("Queries successfully imported."),b()},error:function(){window.progressView.hide(),arangoHelper.arangoError("Query error","queries could not be imported")}}))}})}(),window.ArangoReplication=Backbone.Collection.extend({model:window.Replication,url:"../api/user",getLogState:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/replication/logger-state",contentType:"application/json",processData:!1, -async:!1,success:function(b){a=b},error:function(b){a=b}}),a},getApplyState:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/replication/applier-state",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a}}),window.StatisticsCollection=Backbone.Collection.extend({model:window.Statistics,url:"/_admin/statistics"}),window.StatisticsDescriptionCollection=Backbone.Collection.extend({model:window.StatisticsDescription,url:"/_admin/statistics-description",parse:function(a){return a}}),window.ArangoUsers=Backbone.Collection.extend({model:window.Users,activeUser:null,activeUserSettings:{query:{},shell:{},testing:!0},sortOptions:{desc:!1},url:"/_api/user",comparator:function(a,b){var c=a.get("user").toLowerCase(),d=b.get("user").toLowerCase();return this.sortOptions.desc===!0?d>c?1:c>d?-1:0:c>d?1:d>c?-1:0},login:function(a,b){var c=null;return $.ajax("login",{async:!1,method:"POST",data:JSON.stringify({username:a,password:b}),dataType:"json"}).done(function(a){c=a.user}),this.activeUser=c,this.activeUser},setSortingDesc:function(a){this.sortOptions.desc=a},logout:function(){$.ajax("logout",{async:!1,method:"POST"}),this.activeUser=null,this.reset(),window.App.navigate(""),window.location.reload()},setUserSettings:function(a,b){this.activeUserSettings.identifier=b},loadUserSettings:function(){var a=this;$.ajax({type:"GET",cache:!1,url:"/_api/user/"+encodeURIComponent(a.activeUser),contentType:"application/json",processData:!1,async:!1,success:function(b){a.activeUserSettings=b.extra},error:function(a){}})},saveUserSettings:function(){var a=this;$.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/user/"+encodeURIComponent(a.activeUser),data:JSON.stringify({extra:a.activeUserSettings}),contentType:"application/json",processData:!1,success:function(a){},error:function(a){}})},parse:function(a){var b=[];return _.each(a.result,function(a){b.push(a)}),b},whoAmI:function(){if(this.activeUser)return this.activeUser;var a;return $.ajax("whoAmI?_="+Date.now(),{async:!1}).done(function(b){a=b.user}),this.activeUser=a,this.activeUser}}),function(){"use strict";window.FoxxCollection=Backbone.Collection.extend({model:window.Foxx,sortOptions:{desc:!1},url:"/_admin/aardvark/foxxes",comparator:function(a,b){var c,d;return this.sortOptions.desc===!0?(c=a.get("mount"),d=b.get("mount"),d>c?1:c>d?-1:0):(c=a.get("mount"),d=b.get("mount"),c>d?1:d>c?-1:0)},setSortingDesc:function(a){this.sortOptions.desc=a},installFromGithub:function(a,b,c,d){var e="/_admin/aardvark/foxxes/git?mount="+encodeURIComponent(b);void 0!==d&&(e+=d?"&replace=true":"&upgrade=true"),$.ajax({cache:!1,type:"PUT",url:e,data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a){c(a)},error:function(a){c(a)}})},installFromStore:function(a,b,c,d){var e="/_admin/aardvark/foxxes/store?mount="+encodeURIComponent(b);void 0!==d&&(e+=d?"&replace=true":"&upgrade=true"),$.ajax({cache:!1,type:"PUT",url:e,data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a){c(a)},error:function(a){c(a)}})},installFromZip:function(a,b,c,d){var e="/_admin/aardvark/foxxes/zip?mount="+encodeURIComponent(b);void 0!==d&&(e+=d?"&replace=true":"&upgrade=true"),$.ajax({cache:!1,type:"PUT",url:e,data:JSON.stringify({zipFile:a}),contentType:"application/json",processData:!1,success:function(a){c(a)},error:function(a){c(a)}})},generate:function(a,b,c,d){var e="/_admin/aardvark/foxxes/generate?mount="+encodeURIComponent(b);void 0!==d&&(e+=d?"&replace=true":"&upgrade=true"),$.ajax({cache:!1,type:"PUT",url:e,data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a){c(a)},error:function(a){c(a)}})}})}(),function(){"use strict";window.GraphCollection=Backbone.Collection.extend({model:window.Graph,sortOptions:{desc:!1},url:"/_api/gharial",dropAndDeleteGraph:function(a,b){$.ajax({type:"DELETE",url:"/_api/gharial/"+encodeURIComponent(a)+"?dropCollections=true",contentType:"application/json",processData:!0,async:!1,success:function(){return arangoHelper.arangoNotification("Graph deleted."),b(!0),!0},error:function(a){try{var c=JSON.parse(a.responseText).errorMessage;arangoHelper.arangoError("Graph",c)}catch(d){arangoHelper.arangoError("Graph","Could not delete Graph.")}return b(!1),!1}})},comparator:function(a,b){var c=a.get("_key")||"",d=b.get("_key")||"";return c=c.toLowerCase(),d=d.toLowerCase(),this.sortOptions.desc===!0?d>c?1:c>d?-1:0:c>d?1:d>c?-1:0},setSortingDesc:function(a){this.sortOptions.desc=a},parse:function(a){return a.error?void 0:a.graphs}})}(),function(){"use strict";window.NotificationCollection=Backbone.Collection.extend({model:window.Notification,url:""})}(),function(){"use strict";window.QueryManagementActive=Backbone.Collection.extend({model:window.queryManagementModel,url:function(){return"/_api/query/current"},killRunningQuery:function(a,b){$.ajax({url:"/_api/query/"+encodeURIComponent(a),type:"DELETE",success:function(a){b()}})}})}(),function(){"use strict";window.QueryManagementSlow=Backbone.Collection.extend({model:window.queryManagementModel,url:"/_api/query/slow",deleteSlowQueryHistory:function(a){var b=this;$.ajax({url:b.url,type:"DELETE",success:function(b){a()}})}})}(),function(){"use strict";window.WorkMonitorCollection=Backbone.Collection.extend({model:window.workMonitorModel,url:"/_admin/work-monitor",parse:function(a){return a.work}})}(),function(){"use strict";window.PaginationView=Backbone.View.extend({collection:null,paginationDiv:"",idPrefix:"",rerender:function(){},jumpTo:function(a){this.collection.setPage(a),this.rerender()},firstPage:function(){this.jumpTo(1)},lastPage:function(){this.jumpTo(this.collection.getLastPageNumber())},firstDocuments:function(){this.jumpTo(1)},lastDocuments:function(){this.jumpTo(this.collection.getLastPageNumber())},prevDocuments:function(){this.jumpTo(this.collection.getPage()-1)},nextDocuments:function(){this.jumpTo(this.collection.getPage()+1)},renderPagination:function(){$(this.paginationDiv).html("");var a=this,b=this.collection.getPage(),c=this.collection.getLastPageNumber(),d=$(this.paginationDiv),e={page:b,lastPage:c,click:function(b){var c=window.location.hash.split("/");"documents"===c[2]?(e.page=b,window.location.hash=c[0]+"/"+c[1]+"/"+c[2]+"/"+b):(a.jumpTo(b),e.page=b)}};d.html(""),d.pagination(e),$(this.paginationDiv).prepend('
    '),$(this.paginationDiv).append('
    ')}})}(),function(){"use strict";window.ApplicationDetailView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("applicationDetailView.ejs"),events:{"click .open":"openApp","click .delete":"deleteApp","click #app-config":"showConfigDialog","click #app-deps":"showDepsDialog","click #app-switch-mode":"toggleDevelopment","click #app-scripts [data-script]":"runScript","click #app-tests":"runTests","click #app-replace":"replaceApp","click #download-app":"downloadApp","click #app-show-swagger":"showSwagger","click #app-show-readme":"showReadme","mouseenter #app-scripts":"showDropdown","mouseleave #app-scripts":"hideDropdown"},downloadApp:function(){this.model.isSystem()||this.model.download()},replaceApp:function(){var a=this.model.get("mount");window.foxxInstallView.upgrade(a,function(){window.App.applicationDetail(encodeURIComponent(a))}),$(".createModalDialog .arangoHeader").html("Replace Service"),$("#infoTab").click()},updateConfig:function(){this.model.getConfiguration(function(){$("#app-warning")[this.model.needsAttention()?"show":"hide"](),$("#app-warning-config")[this.model.needsConfiguration()?"show":"hide"](),this.model.needsConfiguration()?$("#app-config").addClass("error"):$("#app-config").removeClass("error")}.bind(this))},updateDeps:function(){this.model.getDependencies(function(){$("#app-warning")[this.model.needsAttention()?"show":"hide"](),$("#app-warning-deps")[this.model.hasUnconfiguredDependencies()?"show":"hide"](),this.model.hasUnconfiguredDependencies()?$("#app-deps").addClass("error"):$("#app-deps").removeClass("error")}.bind(this))},toggleDevelopment:function(){this.model.toggleDevelopment(!this.model.isDevelopment(),function(){this.model.isDevelopment()?($("#app-switch-mode").val("Set Production"),$("#app-development-indicator").css("display","inline"),$("#app-development-path").css("display","inline")):($("#app-switch-mode").val("Set Development"),$("#app-development-indicator").css("display","none"),$("#app-development-path").css("display","none"))}.bind(this))},runScript:function(a){a.preventDefault();var b=$(a.currentTarget).attr("data-script"),c=[window.modalView.createBlobEntry("app_script_arguments","Script arguments","",null,"optional",!1,[{rule:function(a){return a&&JSON.parse(a)},msg:"Must be well-formed JSON or empty"}])],d=[window.modalView.createSuccessButton("Run script",function(){var a=$("#app_script_arguments").val();a=a&&JSON.parse(a),window.modalView.hide(),this.model.runScript(b,a,function(a,c){var d;d=a?"

    The script failed with an error"+(a.statusCode?" (HTTP "+a.statusCode+")":"")+":

    "+a.message+"
    ":c?"

    Script results:

    "+JSON.stringify(c,null,2)+"
    ":"

    The script ran successfully.

    ",window.modalView.show("modalTable.ejs",'Result of script "'+b+'"',void 0,void 0,void 0,d)})}.bind(this))];window.modalView.show("modalTable.ejs",'Run script "'+b+'" on "'+this.model.get("mount")+'"',d,c)},showSwagger:function(a){a.preventDefault(),this.render("swagger")},showReadme:function(a){a.preventDefault(),this.render("readme")},runTests:function(a){a.preventDefault();var b="

    WARNING: Running tests may result in destructive side-effects including data loss. Please make sure not to run tests on a production database.

    ";this.model.isDevelopment()&&(b+="

    WARNING: This app is running in development mode. If any of the tests access the app's HTTP API they may become non-deterministic.

    ");var c=[window.modalView.createSuccessButton("Run tests",function(){window.modalView.hide(),this.model.runTests({reporter:"suite"},function(a,b){window.modalView.show("modalTestResults.ejs","Test results",void 0,void 0,void 0,a||b)})}.bind(this))];window.modalView.show("modalTable.ejs",'Run tests for app "'+this.model.get("mount")+'"',c,void 0,void 0,b)},render:function(a){var b=this;return $(this.el).html(this.template.render({app:this.model,db:arangoHelper.currentDatabase(),mode:a})),$.get(this.appUrl()).success(function(){$(".open",this.el).prop("disabled",!1)}.bind(this)),this.updateConfig(),this.updateDeps(),"swagger"===a&&$.get("./foxxes/docs/swagger.json?mount="+encodeURIComponent(this.model.get("mount")),function(a){Object.keys(a.paths).length<1&&(b.render("readme"),$("#app-show-swagger").attr("disabled","true"))}),$(this.el)},openApp:function(){window.open(this.appUrl(),this.model.get("title")).focus()},deleteApp:function(){var a=[window.modalView.createDeleteButton("Delete",function(){var a={teardown:$("#app_delete_run_teardown").is(":checked")};this.model.destroy(a,function(a,b){a||b.error!==!1||(window.modalView.hide(),window.App.navigate("applications",{trigger:!0}))})}.bind(this))],b=[window.modalView.createCheckboxEntry("app_delete_run_teardown","Run teardown?",!0,"Should this app's teardown script be executed before removing the app?",!0)];window.modalView.show("modalTable.ejs",'Delete Foxx App mounted at "'+this.model.get("mount")+'"',a,b,void 0,"

    Are you sure? There is no way back...

    ",!0)},appUrl:function(){return window.location.origin+"/_db/"+encodeURIComponent(arangoHelper.currentDatabase())+this.model.get("mount")},applyConfig:function(){var a={};_.each(this.model.get("config"),function(b,c){var d=$("#app_config_"+c),e=d.val();if("boolean"===b.type||"bool"===b.type)return void(a[c]=d.is(":checked"));if(""===e&&b.hasOwnProperty("default"))return a[c]=b["default"],void("json"===b.type&&(a[c]=JSON.stringify(b["default"])));if("number"===b.type)a[c]=parseFloat(e);else if("integer"===b.type||"int"===b.type)a[c]=parseInt(e,10);else{if("json"!==b.type)return void(a[c]=window.arangoHelper.escapeHtml(e));a[c]=e&&JSON.stringify(JSON.parse(e))}}),this.model.setConfiguration(a,function(){window.modalView.hide(),this.updateConfig()}.bind(this))},showConfigDialog:function(){if(!_.isEmpty(this.model.get("config"))){var a=_.map(this.model.get("config"),function(a,b){var c=void 0===a["default"]?"":String(a["default"]),d=void 0===a.current?"":String(a.current),e="createTextEntry",f=!1,g=[];return"boolean"===a.type||"bool"===a.type?(e="createCheckboxEntry",a["default"]=a["default"]||!1,c=a["default"]||!1,d=a.current||!1):"json"===a.type?(e="createBlobEntry",c=void 0===a["default"]?"":JSON.stringify(a["default"]),d=void 0===a.current?"":a.current,g.push({rule:function(a){return a&&JSON.parse(a)},msg:"Must be well-formed JSON or empty."})):"integer"===a.type||"int"===a.type?g.push({rule:Joi.number().integer().optional().allow(""),msg:"Has to be an integer."}):"number"===a.type?g.push({rule:Joi.number().optional().allow(""),msg:"Has to be a number."}):("password"===a.type&&(e="createPasswordEntry"),g.push({rule:Joi.string().optional().allow(""),msg:"Has to be a string."})),void 0===a["default"]&&a.required!==!1&&(f=!0,g.unshift({rule:Joi.any().required(),msg:"This field is required."})),window.modalView[e]("app_config_"+b,b,d,a.description,c,f,g)}),b=[window.modalView.createSuccessButton("Apply",this.applyConfig.bind(this))];window.modalView.show("modalTable.ejs","Configuration",b,a)}},applyDeps:function(){var a={};_.each(this.model.get("deps"),function(b,c){var d=$("#app_deps_"+c);a[c]=window.arangoHelper.escapeHtml(d.val())}),this.model.setDependencies(a,function(){window.modalView.hide(),this.updateDeps()}.bind(this))},showDepsDialog:function(){if(!_.isEmpty(this.model.get("deps"))){var a=_.map(this.model.get("deps"),function(a,b){var c=void 0===a.current?"":String(a.current),d="",e=a.definition.name;"*"!==a.definition.version&&(e+="@"+a.definition.version);var f=[{rule:Joi.string().optional().allow(""),msg:"Has to be a string."}];return a.definition.required&&f.push({rule:Joi.string().required(),msg:"This value is required."}),window.modalView.createTextEntry("app_deps_"+b,a.title,c,e,d,a.definition.required,f)}),b=[window.modalView.createSuccessButton("Apply",this.applyDeps.bind(this))];window.modalView.show("modalTable.ejs","Dependencies",b,a)}},showDropdown:function(){_.isEmpty(this.model.get("scripts"))||$("#scripts_dropdown").show(200)},hideDropdown:function(){$("#scripts_dropdown").hide()}})}(),function(){"use strict";window.ApplicationsView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("applicationsView.ejs"),events:{"click #addApp":"createInstallModal","click #foxxToggle":"slideToggle","click #checkDevel":"toggleDevel","click #checkProduction":"toggleProduction","click #checkSystem":"toggleSystem"},fixCheckboxes:function(){this._showDevel?$("#checkDevel").attr("checked","checked"):$("#checkDevel").removeAttr("checked"),this._showSystem?$("#checkSystem").attr("checked","checked"):$("#checkSystem").removeAttr("checked"),this._showProd?$("#checkProduction").attr("checked","checked"):$("#checkProduction").removeAttr("checked"),$("#checkDevel").next().removeClass("fa fa-check-square-o fa-square-o").addClass("fa"),$("#checkSystem").next().removeClass("fa fa-check-square-o fa-square-o").addClass("fa"),$("#checkProduction").next().removeClass("fa fa-check-square-o fa-square-o").addClass("fa"),arangoHelper.setCheckboxStatus("#foxxDropdown")},toggleDevel:function(){var a=this;this._showDevel=!this._showDevel,_.each(this._installedSubViews,function(b){b.toggle("devel",a._showDevel)}),this.fixCheckboxes()},toggleProduction:function(){var a=this;this._showProd=!this._showProd,_.each(this._installedSubViews,function(b){b.toggle("production",a._showProd)}),this.fixCheckboxes()},toggleSystem:function(){this._showSystem=!this._showSystem;var a=this;_.each(this._installedSubViews,function(b){b.toggle("system",a._showSystem)}),this.fixCheckboxes()},reload:function(){var a=this;_.each(this._installedSubViews,function(a){a.undelegateEvents()}),this.collection.fetch({success:function(){a.createSubViews(),a.render()}})},createSubViews:function(){var a=this;this._installedSubViews={},a.collection.each(function(b){var c=new window.FoxxActiveView({model:b,appsView:a});a._installedSubViews[b.get("mount")]=c})},initialize:function(){this._installedSubViews={},this._showDevel=!0,this._showProd=!0,this._showSystem=!1,this.reload()},slideToggle:function(){$("#foxxToggle").toggleClass("activated"),$("#foxxDropdownOut").slideToggle(200)},createInstallModal:function(a){a.preventDefault(),window.foxxInstallView.install(this.reload.bind(this))},render:function(){this.collection.sort(),$(this.el).html(this.template.render({})),_.each(this._installedSubViews,function(a){$("#installedList").append(a.render())}),this.delegateEvents(),$("#checkDevel").attr("checked",this._showDevel),$("#checkProduction").attr("checked",this._showProd),$("#checkSystem").attr("checked",this._showSystem),arangoHelper.setCheckboxStatus("#foxxDropdown");var a=this;return _.each(this._installedSubViews,function(b){b.toggle("devel",a._showDevel),b.toggle("system",a._showSystem)}),arangoHelper.fixTooltips("icon_arangodb","left"),this}})}(),function(){"use strict";window.CollectionListItemView=Backbone.View.extend({tagName:"div",className:"tile",template:templateEngine.createTemplate("collectionsItemView.ejs"),initialize:function(){this.collectionsView=this.options.collectionsView},events:{"click .iconSet.icon_arangodb_settings2":"createEditPropertiesModal","click .pull-left":"noop","click .icon_arangodb_settings2":"editProperties","click .spanInfo":"showProperties",click:"selectCollection"},render:function(){return $(this.el).html(this.template.render({model:this.model})),$(this.el).attr("id","collection_"+this.model.get("name")),this},editProperties:function(a){a.stopPropagation(),this.createEditPropertiesModal()},showProperties:function(a){a.stopPropagation(),this.createInfoModal()},selectCollection:function(a){return $(a.target).hasClass("disabled")?0:void window.App.navigate("collection/"+encodeURIComponent(this.model.get("name"))+"/documents/1",{trigger:!0})},noop:function(a){a.stopPropagation()},unloadCollection:function(){var a=function(a){a?arangoHelper.arangoError("Collection error",this.model.get("name")+" could not be unloaded."):void 0===a?(this.model.set("status","unloading"),this.render()):"#collections"===window.location.hash?(this.model.set("status","unloaded"),this.render()):arangoHelper.arangoNotification("Collection "+this.model.get("name")+" unloaded.")}.bind(this);this.model.unloadCollection(a),window.modalView.hide()},loadCollection:function(){var a=function(a){a?arangoHelper.arangoError("Collection error",this.model.get("name")+" could not be loaded."):void 0===a?(this.model.set("status","loading"),this.render()):"#collections"===window.location.hash?(this.model.set("status","loaded"),this.render()):arangoHelper.arangoNotification("Collection "+this.model.get("name")+" loaded.")}.bind(this);this.model.loadCollection(a),window.modalView.hide()},truncateCollection:function(){this.model.truncateCollection(),this.render(),window.modalView.hide()},deleteCollection:function(){this.model.destroy({error:function(){arangoHelper.arangoError("Could not delete collection.")},success:function(){window.modalView.hide()}}),this.collectionsView.render()},saveModifiedCollection:function(){var a;a=window.isCoordinator()?this.model.get("name"):$("#change-collection-name").val();var b=this.model.get("status");if("loaded"===b){var c;try{c=JSON.parse(1024*$("#change-collection-size").val()*1024)}catch(d){return arangoHelper.arangoError("Please enter a valid number"),0}var e;try{if(e=JSON.parse($("#change-index-buckets").val()),1>e||parseInt(e)!==Math.pow(2,Math.log2(e)))throw"invalid indexBuckets value"}catch(d){return arangoHelper.arangoError("Please enter a valid number of index buckets"),0}var f;if(this.model.get("name")!==a&&(f=this.model.renameCollection(a)),f!==!0&&void 0!==f)return arangoHelper.arangoError("Collection error: "+f),0;var g=$("#change-collection-sync").val(),h=this.model.changeCollection(g,c,e);if(h!==!0)return arangoHelper.arangoNotification("Collection error",h),0;this.collectionsView.render(),window.modalView.hide()}else if("unloaded"===b)if(this.model.get("name")!==a){var i=this.model.renameCollection(a);i===!0?(this.collectionsView.render(),window.modalView.hide()):arangoHelper.arangoError("Collection error: "+i)}else window.modalView.hide()},createEditPropertiesModal:function(){var a=!1;"loaded"===this.model.get("status")&&(a=!0);var b=[],c=[];if(window.isCoordinator()||c.push(window.modalView.createTextEntry("change-collection-name","Name",this.model.get("name"),!1,"",!0,[{rule:Joi.string().regex(/^[a-zA-Z]/),msg:"Collection name must always start with a letter."},{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only Symbols "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No collection name given."}])),a){var d=this.model.getProperties().journalSize;d/=1048576,c.push(window.modalView.createTextEntry("change-collection-size","Journal size",d,"The maximal size of a journal or datafile (in MB). Must be at least 1.","",!0,[{rule:Joi.string().allow("").optional().regex(/^[0-9]*$/),msg:"Must be a number."}]));var e=this.model.getProperties().indexBuckets;c.push(window.modalView.createTextEntry("change-index-buckets","Index buckets",e,"The number of index buckets for this collection. Must be at least 1 and a power of 2.","",!0,[{rule:Joi.string().allow("").optional().regex(/^[1-9][0-9]*$/),msg:"Must be a number greater than 1 and a power of 2."}]));var f=this.model.getProperties().waitForSync;c.push(window.modalView.createSelectEntry("change-collection-sync","Wait for sync",f,"Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}]))}c.push(window.modalView.createReadOnlyEntry("change-collection-id","ID",this.model.get("id"),"")),c.push(window.modalView.createReadOnlyEntry("change-collection-type","Type",this.model.get("type"),"")),c.push(window.modalView.createReadOnlyEntry("change-collection-status","Status",this.model.get("status"),"")),b.push(window.modalView.createDeleteButton("Delete",this.deleteCollection.bind(this))),b.push(window.modalView.createDeleteButton("Truncate",this.truncateCollection.bind(this))),a?b.push(window.modalView.createNotificationButton("Unload",this.unloadCollection.bind(this))):b.push(window.modalView.createNotificationButton("Load",this.loadCollection.bind(this))),b.push(window.modalView.createSuccessButton("Save",this.saveModifiedCollection.bind(this)));var g=["General","Indices"],h=["modalTable.ejs","indicesView.ejs"];window.modalView.show(h,"Modify Collection",b,c,null,null,this.events,null,g),this.getIndex(),this.bindIndexEvents()},bindIndexEvents:function(){this.unbindIndexEvents();var a=this;$("#indexEditView #addIndex").bind("click",function(){a.toggleNewIndexView(),$("#cancelIndex").unbind("click"),$("#cancelIndex").bind("click",function(){a.toggleNewIndexView()}),$("#createIndex").unbind("click"),$("#createIndex").bind("click",function(){a.createIndex()})}),$("#newIndexType").bind("change",function(){a.selectIndexType()}),$(".deleteIndex").bind("click",function(b){a.prepDeleteIndex(b)}),$("#infoTab a").bind("click",function(a){"Indices"===$(a.currentTarget).html()?($(".modal-footer .button-danger").hide(),$(".modal-footer .button-success").hide(),$(".modal-footer .button-notification").hide()):($(".modal-footer .button-danger").show(),$(".modal-footer .button-success").show(),$(".modal-footer .button-notification").show())})},unbindIndexEvents:function(){$("#indexEditView #addIndex").unbind("click"),$("#newIndexType").unbind("change"),$("#infoTab a").unbind("click"),$(".deleteIndex").unbind("click")},createInfoModal:function(){var a=[],b=this.model;window.modalView.show("modalCollectionInfo.ejs","Collection: "+this.model.get("name"),a,b)},resetIndexForms:function(){$("#indexHeader input").val("").prop("checked",!1),$("#newIndexType").val("Cap").prop("selected",!0),this.selectIndexType()},createIndex:function(){var a,b,c,d=this,e=$("#newIndexType").val(),f={};switch(e){case"Cap":var g=parseInt($("#newCapSize").val(),10)||0,h=parseInt($("#newCapByteSize").val(),10)||0;f={type:"cap",size:g,byteSize:h};break;case"Geo":a=$("#newGeoFields").val();var i=d.checkboxToValue("#newGeoJson"),j=d.checkboxToValue("#newGeoConstraint"),k=d.checkboxToValue("#newGeoIgnoreNull");f={type:"geo",fields:d.stringToArray(a),geoJson:i,constraint:j,ignoreNull:k};break;case"Hash":a=$("#newHashFields").val(),b=d.checkboxToValue("#newHashUnique"),c=d.checkboxToValue("#newHashSparse"),f={type:"hash",fields:d.stringToArray(a),unique:b,sparse:c};break;case"Fulltext":a=$("#newFulltextFields").val();var l=parseInt($("#newFulltextMinLength").val(),10)||0;f={type:"fulltext",fields:d.stringToArray(a),minLength:l};break;case"Skiplist":a=$("#newSkiplistFields").val(),b=d.checkboxToValue("#newSkiplistUnique"),c=d.checkboxToValue("#newSkiplistSparse"),f={type:"skiplist",fields:d.stringToArray(a),unique:b,sparse:c}}var m=function(a,b){if(a)if(b){var c=JSON.parse(b.responseText);arangoHelper.arangoError("Document error",c.errorMessage)}else arangoHelper.arangoError("Document error","Could not create index.")};window.modalView.hide(),this.getIndex(),this.createEditPropertiesModal(),$($("#infoTab").children()[1]).find("a").click(),d.model.createIndex(f,m)},lastTarget:null,prepDeleteIndex:function(a){var b=this;this.lastTarget=a,this.lastId=$(this.lastTarget.currentTarget).parent().parent().first().children().first().text(),window.modalView.hide(),$("#indexDeleteModal").modal("show"),$("#confirmDeleteIndexBtn").unbind("click"),$("#confirmDeleteIndexBtn").bind("click",function(){b.deleteIndex()})},deleteIndex:function(){var a=function(a){a&&arangoHelper.arangoError("Could not delete index")};$("#indexDeleteModal").modal("hide"),this.model.deleteIndex(this.lastId,a),this.createEditPropertiesModal(),$($("#infoTab").children()[1]).find("a").click()},selectIndexType:function(){$(".newIndexClass").hide();var a=$("#newIndexType").val();$("#newIndexType"+a).show()},getIndex:function(){this.index=this.model.getIndex();var a="collectionInfoTh modal-text";if(this.index){var b="",c="";_.each(this.index.indexes,function(d){c="primary"===d.type||"edge"===d.type?'':'',void 0!==d.fields&&(b=d.fields.join(", "));var e=d.id.indexOf("/"),f=d.id.substr(e+1,d.id.length),g=d.hasOwnProperty("selectivityEstimate")?(100*d.selectivityEstimate).toFixed(2)+"%":"n/a",h=d.hasOwnProperty("sparse")?d.sparse:"n/a";$("#collectionEditIndexTable").append(""+f+""+d.type+""+d.unique+""+h+""+g+""+b+""+c+"")})}},toggleNewIndexView:function(){$("#indexEditView").is(":visible")?($("#indexEditView").hide(),$("#newIndexView").show()):($("#indexEditView").show(),$("#newIndexView").hide()),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","right"),this.resetIndexForms()},stringToArray:function(a){var b=[];return a.split(",").forEach(function(a){a=a.replace(/(^\s+|\s+$)/g,""),""!==a&&b.push(a)}),b},checkboxToValue:function(a){return $(a).prop("checked")}})}(),function(){"use strict";window.CollectionsView=Backbone.View.extend({el:"#content",el2:"#collectionsThumbnailsIn",searchTimeout:null,template:templateEngine.createTemplate("collectionsView.ejs"),render:function(){var a=!1;$("#collectionsDropdown").is(":visible")&&(a=!0),$(this.el).html(this.template.render({})),this.setFilterValues(),a===!0&&$("#collectionsDropdown2").show();var b=this.collection.searchOptions;this.collection.getFiltered(b).forEach(function(a){$("#collectionsThumbnailsIn",this.el).append(new window.CollectionListItemView({model:a,collectionsView:this}).render().el)},this),"none"===$("#collectionsDropdown2").css("display")?$("#collectionsToggle").removeClass("activated"):$("#collectionsToggle").addClass("activated");var c;arangoHelper.setCheckboxStatus("#collectionsDropdown");try{c=b.searchPhrase.length}catch(d){}return $("#searchInput").val(b.searchPhrase),$("#searchInput").focus(),$("#searchInput")[0].setSelectionRange(c,c),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","left"),this},events:{"click #createCollection":"createCollection","keydown #searchInput":"restrictToSearchPhraseKey","change #searchInput":"restrictToSearchPhrase","click #searchSubmit":"restrictToSearchPhrase","click .checkSystemCollections":"checkSystem","click #checkLoaded":"checkLoaded","click #checkUnloaded":"checkUnloaded","click #checkDocument":"checkDocument","click #checkEdge":"checkEdge","click #sortName":"sortName","click #sortType":"sortType","click #sortOrder":"sortOrder","click #collectionsToggle":"toggleView","click .css-label":"checkBoxes"},updateCollectionsView:function(){var a=this;this.collection.fetch({success:function(){a.render()}})},toggleView:function(){$("#collectionsToggle").toggleClass("activated"),$("#collectionsDropdown2").slideToggle(200)},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},checkSystem:function(){var a=this.collection.searchOptions,b=a.includeSystem;a.includeSystem=$(".checkSystemCollections").is(":checked")===!0,b!==a.includeSystem&&this.render()},checkEdge:function(){var a=this.collection.searchOptions,b=a.includeEdge;a.includeEdge=$("#checkEdge").is(":checked")===!0,b!==a.includeEdge&&this.render()},checkDocument:function(){var a=this.collection.searchOptions,b=a.includeDocument;a.includeDocument=$("#checkDocument").is(":checked")===!0,b!==a.includeDocument&&this.render()},checkLoaded:function(){var a=this.collection.searchOptions,b=a.includeLoaded;a.includeLoaded=$("#checkLoaded").is(":checked")===!0,b!==a.includeLoaded&&this.render()},checkUnloaded:function(){var a=this.collection.searchOptions,b=a.includeUnloaded;a.includeUnloaded=$("#checkUnloaded").is(":checked")===!0,b!==a.includeUnloaded&&this.render()},sortName:function(){var a=this.collection.searchOptions,b=a.sortBy;a.sortBy=$("#sortName").is(":checked")===!0?"name":"type",b!==a.sortBy&&this.render()},sortType:function(){var a=this.collection.searchOptions,b=a.sortBy;a.sortBy=$("#sortType").is(":checked")===!0?"type":"name",b!==a.sortBy&&this.render()},sortOrder:function(){var a=this.collection.searchOptions,b=a.sortOrder;a.sortOrder=$("#sortOrder").is(":checked")===!0?-1:1,b!==a.sortOrder&&this.render()},setFilterValues:function(){var a=this.collection.searchOptions;$("#checkLoaded").attr("checked",a.includeLoaded),$("#checkUnloaded").attr("checked",a.includeUnloaded),$(".checkSystemCollections").attr("checked",a.includeSystem),$("#checkEdge").attr("checked",a.includeEdge),$("#checkDocument").attr("checked",a.includeDocument),$("#sortName").attr("checked","type"!==a.sortBy),$("#sortType").attr("checked","type"===a.sortBy),$("#sortOrder").attr("checked",1!==a.sortOrder)},search:function(){var a=this.collection.searchOptions,b=$("#searchInput").val();b!==a.searchPhrase&&(a.searchPhrase=b,this.render())},resetSearch:function(){this.searchTimeout&&(clearTimeout(this.searchTimeout),this.searchTimeout=null);var a=this.collection.searchOptions;a.searchPhrase=null},restrictToSearchPhraseKey:function(){var a=this;this.resetSearch(),a.searchTimeout=setTimeout(function(){ -a.search()},200)},restrictToSearchPhrase:function(){this.resetSearch(),this.search()},createCollection:function(a){a.preventDefault(),this.createNewCollectionModal()},submitCreateCollection:function(){var a=$("#new-collection-name").val(),b=$("#new-collection-size").val(),c=$("#new-collection-type").val(),d=$("#new-collection-sync").val(),e=1,f=[];if(window.isCoordinator()){if(e=$("#new-collection-shards").val(),""===e&&(e=1),e=parseInt(e,10),1>e)return arangoHelper.arangoError("Number of shards has to be an integer value greater or equal 1"),0;f=_.pluck($("#new-collection-shardBy").select2("data"),"text"),0===f.length&&f.push("_key")}if("_"===a.substr(0,1))return arangoHelper.arangoError('No "_" allowed as first character!'),0;var g=!1,h="true"===d;if(b>0)try{b=1024*JSON.parse(b)*1024}catch(i){return arangoHelper.arangoError("Please enter a valid number"),0}if(""===a)return arangoHelper.arangoError("No collection name entered!"),0;var j=this.collection.newCollection(a,h,g,b,c,e,f);j.status!==!0&&(console.log(j),arangoHelper.arangoError("Collection error",j.errorMessage)),this.updateCollectionsView(),window.modalView.hide()},createNewCollectionModal:function(){var a=[],b=[],c={},d=[];b.push(window.modalView.createTextEntry("new-collection-name","Name","",!1,"",!0,[{rule:Joi.string().regex(/^[a-zA-Z]/),msg:"Collection name must always start with a letter."},{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only symbols, "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No collection name given."}])),b.push(window.modalView.createSelectEntry("new-collection-type","Type","","The type of the collection to create.",[{value:2,label:"Document"},{value:3,label:"Edge"}])),window.isCoordinator()&&(b.push(window.modalView.createTextEntry("new-collection-shards","Shards","","The number of shards to create. You cannot change this afterwards. Recommended: DBServers squared","",!0)),b.push(window.modalView.createSelect2Entry("new-collection-shardBy","shardBy","","The keys used to distribute documents on shards. Type the key and press return to add it.","_key",!1))),a.push(window.modalView.createSuccessButton("Save",this.submitCreateCollection.bind(this))),d.push(window.modalView.createTextEntry("new-collection-size","Journal size","","The maximal size of a journal or datafile (in MB). Must be at least 1.","",!1,[{rule:Joi.string().allow("").optional().regex(/^[0-9]*$/),msg:"Must be a number."}])),d.push(window.modalView.createSelectEntry("new-collection-sync","Sync","","Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}])),c.header="Advanced",c.content=d,window.modalView.show("modalTable.ejs","New Collection",a,b,c)}})}(),function(){"use strict";function a(a,b){return(void 0===a||null===a)&&(a=0),a.toFixed(b)}window.DashboardView=Backbone.View.extend({el:"#content",interval:1e4,defaultTimeFrame:12e5,defaultDetailFrame:1728e5,history:{},graphs:{},events:{},tendencies:{asyncPerSecondCurrent:["asyncPerSecondCurrent","asyncPerSecondPercentChange"],syncPerSecondCurrent:["syncPerSecondCurrent","syncPerSecondPercentChange"],clientConnectionsCurrent:["clientConnectionsCurrent","clientConnectionsPercentChange"],clientConnectionsAverage:["clientConnections15M","clientConnections15MPercentChange"],numberOfThreadsCurrent:["numberOfThreadsCurrent","numberOfThreadsPercentChange"],numberOfThreadsAverage:["numberOfThreads15M","numberOfThreads15MPercentChange"],virtualSizeCurrent:["virtualSizeCurrent","virtualSizePercentChange"],virtualSizeAverage:["virtualSize15M","virtualSize15MPercentChange"]},barCharts:{totalTimeDistribution:["queueTimeDistributionPercent","requestTimeDistributionPercent"],dataTransferDistribution:["bytesSentDistributionPercent","bytesReceivedDistributionPercent"]},barChartsElementNames:{queueTimeDistributionPercent:"Queue",requestTimeDistributionPercent:"Computation",bytesSentDistributionPercent:"Bytes sent",bytesReceivedDistributionPercent:"Bytes received"},getDetailFigure:function(a){var b=$(a.currentTarget).attr("id").replace(/ChartButton/g,"");return b},showDetail:function(a){var b,c=this,d=this.getDetailFigure(a);b=this.dygraphConfig.getDetailChartConfig(d),this.getHistoryStatistics(d),this.detailGraphFigure=d,window.modalView.hideFooter=!0,window.modalView.hide(),window.modalView.show("modalGraph.ejs",b.header,void 0,void 0,void 0,void 0,this.events),window.modalView.hideFooter=!1,$("#modal-dialog").on("hidden",function(){c.hidden()}),$("#modal-dialog").toggleClass("modal-chart-detail",!0),b.height=.7*$(window).height(),b.width=$(".modal-inner-detail").width(),b.labelsDiv=$(b.labelsDiv)[0],this.detailGraph=new Dygraph(document.getElementById("lineChartDetail"),this.history[this.server][d],b)},hidden:function(){this.detailGraph.destroy(),delete this.detailGraph,delete this.detailGraphFigure},getCurrentSize:function(a){"#"!==a.substr(0,1)&&(a="#"+a);var b,c;return $(a).attr("style",""),b=$(a).height(),c=$(a).width(),{height:b,width:c}},prepareDygraphs:function(){var a,b=this;this.dygraphConfig.getDashBoardFigures().forEach(function(c){a=b.dygraphConfig.getDefaultConfig(c);var d=b.getCurrentSize(a.div);a.height=d.height,a.width=d.width,b.graphs[c]=new Dygraph(document.getElementById(a.div),b.history[b.server][c]||[],a)})},initialize:function(){this.dygraphConfig=this.options.dygraphConfig,this.d3NotInitialized=!0,this.events["click .dashboard-sub-bar-menu-sign"]=this.showDetail.bind(this),this.events["mousedown .dygraph-rangesel-zoomhandle"]=this.stopUpdating.bind(this),this.events["mouseup .dygraph-rangesel-zoomhandle"]=this.startUpdating.bind(this),this.serverInfo=this.options.serverToShow,this.serverInfo?this.server=this.serverInfo.target:this.server="-local-",this.history[this.server]={}},updateCharts:function(){var a=this;return this.detailGraph?void this.updateLineChart(this.detailGraphFigure,!0):(this.prepareD3Charts(this.isUpdating),this.prepareResidentSize(this.isUpdating),this.updateTendencies(),void Object.keys(this.graphs).forEach(function(b){a.updateLineChart(b,!1)}))},updateTendencies:function(){var a=this,b=this.tendencies,c="";Object.keys(b).forEach(function(b){var d="",e=0;a.history.hasOwnProperty(a.server)&&a.history[a.server].hasOwnProperty(b)&&(e=a.history[a.server][b][1]),0>e?c="#d05448":(c="#7da817",d="+"),a.history.hasOwnProperty(a.server)&&a.history[a.server].hasOwnProperty(b)?$("#"+b).html(a.history[a.server][b][0]+'
    '+d+e+"%"):$("#"+b).html('
    data not ready yet')})},updateDateWindow:function(a,b){var c,d,e=(new Date).getTime();return b&&a.dateWindow_?(c=a.dateWindow_[0],d=e-a.dateWindow_[1]-5*this.interval>0?a.dateWindow_[1]:e,[c,d]):[e-this.defaultTimeFrame,e]},updateLineChart:function(a,b){var c=b?this.detailGraph:this.graphs[a],d={file:this.history[this.server][a],dateWindow:this.updateDateWindow(c,b)},e=0,f=[];_.each(d.file,function(a){var b=a[0].getSeconds()-a[0].getSeconds()%10;d.file[e][0].setSeconds(b),f.push(d.file[e][0]),e++});for(var g=new Date(Math.max.apply(null,f)),h=new Date(Math.min.apply(null,f)),i=new Date(h.getTime()),j=[],k=[];g>i;)i=new Date(i.setSeconds(i.getSeconds()+10)),k.push(i);_.each(k,function(a){var b=!1;_.each(d.file,function(c){Math.floor(a.getTime()/1e3)===Math.floor(c[0].getTime()/1e3)&&(b=!0)}),b===!1&&a1&&d.history[d.server][e].push(c))})},cutOffHistory:function(a,b){for(var c=this;0!==c.history[c.server][a].length;){var d=c.history[c.server][a][0][0];if(d>=b)break;c.history[c.server][a].shift()}},cutOffDygraphHistory:function(a){var b=this,c=new Date(a);this.dygraphConfig.getDashBoardFigures(!0).forEach(function(a){b.dygraphConfig.mapStatToFigure[a]&&b.history[b.server][a]&&b.cutOffHistory(a,c)})},mergeHistory:function(b){var c,d=this;for(c=0;c=0;--c)d.values.push({label:this.getLabel(b[a[0]].cuts,c),value:b[a[0]].values[c]}),e.values.push({label:this.getLabel(b[a[1]].cuts,c),value:b[a[1]].values[c]});return[d,e]},getLabel:function(a,b){return a[b]?0===b?"0 - "+a[b]:a[b-1]+" - "+a[b]:">"+a[b-1]},renderReplicationStatistics:function(a){$("#repl-numbers table tr:nth-child(1) > td:nth-child(2)").html(a.state.totalEvents),$("#repl-numbers table tr:nth-child(2) > td:nth-child(2)").html(a.state.totalRequests),$("#repl-numbers table tr:nth-child(3) > td:nth-child(2)").html(a.state.totalFailedConnects),a.state.lastAppliedContinuousTick?$("#repl-ticks table tr:nth-child(1) > td:nth-child(2)").html(a.state.lastAppliedContinuousTick):$("#repl-ticks table tr:nth-child(1) > td:nth-child(2)").html("no data available").addClass("no-data"),a.state.lastProcessedContinuousTick?$("#repl-ticks table tr:nth-child(2) > td:nth-child(2)").html(a.state.lastProcessedContinuousTick):$("#repl-ticks table tr:nth-child(2) > td:nth-child(2)").html("no data available").addClass("no-data"),a.state.lastAvailableContinuousTick?$("#repl-ticks table tr:nth-child(3) > td:nth-child(2)").html(a.state.lastAvailableContinuousTick):$("#repl-ticks table tr:nth-child(3) > td:nth-child(2)").html("no data available").addClass("no-data"),$("#repl-progress table tr:nth-child(1) > td:nth-child(2)").html(a.state.progress.message),$("#repl-progress table tr:nth-child(2) > td:nth-child(2)").html(a.state.progress.time),$("#repl-progress table tr:nth-child(3) > td:nth-child(2)").html(a.state.progress.failedConnects)},getReplicationStatistics:function(){var a=this;$.ajax("/_api/replication/applier-state",{async:!0}).done(function(b){if(b.hasOwnProperty("state")){var c;c=b.state.running?"active":"inactive",c=''+c+"",$("#replication-chart .dashboard-sub-bar").html("Replication "+c),a.renderReplicationStatistics(b)}})},getStatistics:function(a){var b=this,c="/_db/_system/_admin/aardvark/statistics/short",d="?start=";d+=b.nextStart?b.nextStart:((new Date).getTime()-b.defaultTimeFrame)/1e3,"-local-"!==b.server&&(c=b.serverInfo.endpoint+"/_admin/aardvark/statistics/cluster",d+="&type=short&DBserver="+b.serverInfo.target,b.history.hasOwnProperty(b.server)||(b.history[b.server]={})),$.ajax(c+d,{async:!0}).done(function(c){c.times.length>0&&(b.isUpdating=!0,b.mergeHistory(c)),b.isUpdating!==!1&&(a&&a(),b.updateCharts())}),this.getReplicationStatistics()},getHistoryStatistics:function(a){var b=this,c="statistics/long",d="?filter="+this.dygraphConfig.mapStatToFigure[a].join();"-local-"!==b.server&&(c=b.server.endpoint+"/_admin/aardvark/statistics/cluster",d+="&type=long&DBserver="+b.server.target,b.history.hasOwnProperty(b.server)||(b.history[b.server]={}));var e=window.location.href.split("/"),f=e[0]+"//"+e[2]+"/"+e[3]+"/_system/"+e[5]+"/"+e[6]+"/";$.ajax(f+c+d,{async:!0}).done(function(c){var d;for(b.history[b.server][a]=[],d=0;d data not ready yet

    '),$("#totalTimeDistribution").prepend('

    data not ready yet

    '),$(".dashboard-bar-chart-title").prepend('

    data not ready yet

    '))},removeEmptyDataLabels:function(){$(".dataNotReadyYet").remove()},prepareResidentSize:function(b){var c=this,d=this.getCurrentSize("#residentSizeChartContainer"),e=c.history[c.server].residentSizeCurrent/1024/1024,f="";f=1025>e?a(e,2)+" MB":a(e/1024,2)+" GB";var g=a(100*c.history[c.server].residentSizePercent,2),h=[a(c.history[c.server].physicalMemory/1024/1024/1024,0)+" GB"];return void 0===c.history[c.server].residentSizeChart?void this.addEmptyDataLabels():(this.removeEmptyDataLabels(),void nv.addGraph(function(){var a=nv.models.multiBarHorizontalChart().x(function(a){return a.label}).y(function(a){return a.value}).width(d.width).height(d.height).margin({top:($("residentSizeChartContainer").outerHeight()-$("residentSizeChartContainer").height())/2,right:1,bottom:($("residentSizeChartContainer").outerHeight()-$("residentSizeChartContainer").height())/2,left:1}).showValues(!1).showYAxis(!1).showXAxis(!1).transitionDuration(100).tooltips(!1).showLegend(!1).showControls(!1).stacked(!0);return a.yAxis.tickFormat(function(a){return a+"%"}).showMaxMin(!1),a.xAxis.showMaxMin(!1),d3.select("#residentSizeChart svg").datum(c.history[c.server].residentSizeChart).call(a),d3.select("#residentSizeChart svg").select(".nv-zeroLine").remove(),b&&(d3.select("#residentSizeChart svg").select("#total").remove(),d3.select("#residentSizeChart svg").select("#percentage").remove()),d3.select(".dashboard-bar-chart-title .percentage").html(f+" ("+g+" %)"),d3.select(".dashboard-bar-chart-title .absolut").html(h[0]),nv.utils.windowResize(a.update),a},function(){d3.selectAll("#residentSizeChart .nv-bar").on("click",function(){})}))},prepareD3Charts:function(b){var c=this,d={totalTimeDistribution:["queueTimeDistributionPercent","requestTimeDistributionPercent"],dataTransferDistribution:["bytesSentDistributionPercent","bytesReceivedDistributionPercent"]};this.d3NotInitialized&&(b=!1,this.d3NotInitialized=!1),_.each(Object.keys(d),function(b){var d=c.getCurrentSize("#"+b+"Container .dashboard-interior-chart"),e="#"+b+"Container svg";return void 0===c.history[c.server].residentSizeChart?void c.addEmptyDataLabels():(c.removeEmptyDataLabels(),void nv.addGraph(function(){var f=[0,.25,.5,.75,1],g=75,h=23,i=6;d.width<219?(f=[0,.5,1],g=72,h=21,i=5):d.width<299?(f=[0,.3334,.6667,1],g=77):d.width<379?g=87:d.width<459?g=95:d.width<539?g=100:d.width<619&&(g=105);var j=nv.models.multiBarHorizontalChart().x(function(a){return a.label}).y(function(a){return a.value}).width(d.width).height(d.height).margin({top:5,right:20,bottom:h,left:g}).showValues(!1).showYAxis(!0).showXAxis(!0).transitionDuration(100).tooltips(!1).showLegend(!1).showControls(!1).forceY([0,1]);j.yAxis.showMaxMin(!1);d3.select(".nv-y.nv-axis").selectAll("text").attr("transform","translate (0, "+i+")");return j.yAxis.tickValues(f).tickFormat(function(b){return a(100*b*100/100,0)+"%"}),d3.select(e).datum(c.history[c.server][b]).call(j),nv.utils.windowResize(j.update),j},function(){d3.selectAll(e+" .nv-bar").on("click",function(){})}))})},stopUpdating:function(){this.isUpdating=!1},startUpdating:function(){var a=this;a.timer||(a.timer=window.setInterval(function(){a.getStatistics()},a.interval))},resize:function(){if(this.isUpdating){var a,b=this;_.each(this.graphs,function(c){a=b.getCurrentSize(c.maindiv_.id),c.resize(a.width,a.height)}),this.detailGraph&&(a=this.getCurrentSize(this.detailGraph.maindiv_.id),this.detailGraph.resize(a.width,a.height)),this.prepareD3Charts(!0),this.prepareResidentSize(!0)}},template:templateEngine.createTemplate("dashboardView.ejs"),render:function(a){a||$(this.el).html(this.template.render());var b=function(){this.prepareDygraphs(),this.isUpdating&&(this.prepareD3Charts(),this.prepareResidentSize(),this.updateTendencies()),this.startUpdating()}.bind(this),c=this.options.database.hasSystemAccess();c?this.getStatistics(b):($(".contentDiv").remove(),$(".headerBar").remove(),$(".dashboard-headerbar").remove(),$(".dashboard-row").remove(),$("#content").append('
    You do not have permission to view this page.
    '),$("#content").append("
    You can switch to '_system' to see the dashboard.
    "))}})}(),function(){"use strict";window.databaseView=Backbone.View.extend({users:null,el:"#content",template:templateEngine.createTemplate("databaseView.ejs"),dropdownVisible:!1,currentDB:"",events:{"click #createDatabase":"createDatabase","click #submitCreateDatabase":"submitCreateDatabase","click .editDatabase":"editDatabase","click .icon":"editDatabase","click #selectDatabase":"updateDatabase","click #submitDeleteDatabase":"submitDeleteDatabase","click .contentRowInactive a":"changeDatabase","keyup #databaseSearchInput":"search","click #databaseSearchSubmit":"search","click #databaseToggle":"toggleSettingsDropdown","click .css-label":"checkBoxes","click #dbSortDesc":"sorting","click .tile":"switchDatabase"},sorting:function(){$("#dbSortDesc").is(":checked")?this.collection.setSortingDesc(!0):this.collection.setSortingDesc(!1),$("#databaseDropdown").is(":visible")?this.dropdownVisible=!0:this.dropdownVisible=!1,this.render()},initialize:function(){this.collection.fetch({async:!1})},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},render:function(){return this.currentDatabase(),this.collection.sort(),$(this.el).html(this.template.render({collection:this.collection,searchString:"",currentDB:this.currentDB})),this.dropdownVisible===!0&&($("#dbSortDesc").attr("checked",this.collection.sortOptions.desc),$("#databaseToggle").toggleClass("activated"),$("#databaseDropdown2").show()),arangoHelper.setCheckboxStatus("#databaseDropdown"),this.replaceSVGs(),this},toggleSettingsDropdown:function(){$("#dbSortDesc").attr("checked",this.collection.sortOptions.desc),$("#databaseToggle").toggleClass("activated"),$("#databaseDropdown2").slideToggle(200)},selectedDatabase:function(){return $("#selectDatabases").val()},handleError:function(a,b,c){return 409===a?void arangoHelper.arangoError("DB","Database "+c+" already exists."):400===a?void arangoHelper.arangoError("DB","Invalid Parameters"):403===a?void arangoHelper.arangoError("DB","Insufficent rights. Execute this from _system database"):void 0},validateDatabaseInfo:function(a,b,c){return""===b?(arangoHelper.arangoError("DB","You have to define an owner for the new database"),!1):""===a?(arangoHelper.arangoError("DB","You have to define a name for the new database"),!1):0===a.indexOf("_")?(arangoHelper.arangoError("DB ","Databasename should not start with _"),!1):a.match(/^[a-zA-Z][a-zA-Z0-9_\-]*$/)?!0:(arangoHelper.arangoError("DB","Databasename may only contain numbers, letters, _ and -"),!1)},createDatabase:function(a){a.preventDefault(),this.createAddDatabaseModal()},switchDatabase:function(a){if(!$(a.target).parent().hasClass("iconSet")){var b=$(a.currentTarget).find("h5").text();if(""!==b){var c=this.collection.createDatabaseURL(b);window.location.replace(c)}}},submitCreateDatabase:function(){var a,b=this,c=$("#newDatabaseName").val(),d=$("#newUser").val();if(a="true"===$("#useDefaultPassword").val()?"ARANGODB_DEFAULT_ROOT_PASSWORD":$("#newPassword").val(),this.validateDatabaseInfo(c,d,a)){var e={name:c,users:[{username:d,passwd:a,active:!0}]};this.collection.create(e,{wait:!0,error:function(a,d){b.handleError(d.status,d.statusText,c)},success:function(a){b.updateDatabases(),window.modalView.hide(),window.App.naviView.dbSelectionView.render($("#dbSelect"))}})}},submitDeleteDatabase:function(a){var b=this.collection.where({name:a});b[0].destroy({wait:!0,url:"/_api/database/"+a}),this.updateDatabases(),window.App.naviView.dbSelectionView.render($("#dbSelect")),window.modalView.hide()},currentDatabase:function(){this.currentDB=this.collection.getCurrentDatabase()},changeDatabase:function(a){var b=$(a.currentTarget).attr("id"),c=this.collection.createDatabaseURL(b);window.location.replace(c)},updateDatabases:function(){var a=this;this.collection.fetch({success:function(){a.render(),window.App.handleSelectDatabase()}})},editDatabase:function(a){var b=this.evaluateDatabaseName($(a.currentTarget).attr("id"),"_edit-database"),c=!0;b===this.currentDB&&(c=!1),this.createEditDatabaseModal(b,c)},search:function(){var a,b,c,d;a=$("#databaseSearchInput"),b=$("#databaseSearchInput").val(),d=this.collection.filter(function(a){return-1!==a.get("name").indexOf(b)}),$(this.el).html(this.template.render({collection:d,searchString:b,currentDB:this.currentDB})),this.replaceSVGs(),a=$("#databaseSearchInput"),c=a.val().length,a.focus(),a[0].setSelectionRange(c,c)},replaceSVGs:function(){$(".svgToReplace").each(function(){var a=$(this),b=a.attr("id"),c=a.attr("src");$.get(c,function(c){var d=$(c).find("svg");d.attr("id",b).attr("class","tile-icon-svg").removeAttr("xmlns:a"),a.replaceWith(d)},"xml")})},evaluateDatabaseName:function(a,b){var c=a.lastIndexOf(b);return a.substring(0,c)},createEditDatabaseModal:function(a,b){var c=[],d=[];d.push(window.modalView.createReadOnlyEntry("id_name","Name",a,"")),b?c.push(window.modalView.createDeleteButton("Delete",this.submitDeleteDatabase.bind(this,a))):c.push(window.modalView.createDisabledButton("Delete")),window.modalView.show("modalTable.ejs","Delete database",c,d)},createAddDatabaseModal:function(){var a=[],b=[];b.push(window.modalView.createTextEntry("newDatabaseName","Name","",!1,"Database Name",!0,[{rule:Joi.string().regex(/^[a-zA-Z]/),msg:"Database name must start with a letter."},{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only Symbols "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No database name given."}])),b.push(window.modalView.createTextEntry("newUser","Username",null!==this.users?this.users.whoAmI():"root","Please define the owner of this database. This will be the only user having initial access to this database if authentication is turned on. Please note that if you specify a username different to your account you will not be able to access the database with your account after having creating it. Specifying a username is mandatory even with authentication turned off. If there is a failure you will be informed.","Database Owner",!0,[{rule:Joi.string().required(),msg:"No username given."}])),b.push(window.modalView.createSelectEntry("useDefaultPassword","Use default password",!0,"Read the password from the environment variable ARANGODB_DEFAULT_ROOT_PASSWORD.",[{value:!1,label:"No"},{value:!0,label:"Yes"}])),b.push(window.modalView.createPasswordEntry("newPassword","Password","",!1,"",!1)),a.push(window.modalView.createSuccessButton("Create",this.submitCreateDatabase.bind(this))),window.modalView.show("modalTable.ejs","Create Database",a,b),$("#useDefaultPassword").change(function(){"true"===$("#useDefaultPassword").val()?$("#row_newPassword").hide():$("#row_newPassword").show()}),$("#row_newPassword").hide()}})}(),function(){"use strict";window.DBSelectionView=Backbone.View.extend({template:templateEngine.createTemplate("dbSelectionView.ejs"),events:{"click .dbSelectionLink":"changeDatabase"},initialize:function(a){this.current=a.current},changeDatabase:function(a){var b=$(a.currentTarget).closest(".dbSelectionLink.tab").attr("id"),c=this.collection.createDatabaseURL(b);window.location.replace(c)},render:function(a){return this.$el=a,this.$el.html(this.template.render({list:this.collection.getDatabasesForUser(),current:this.current.get("name")})),this.delegateEvents(),this.el}})}(),function(){"use strict";var a=function(a){var b=a.split("/");return"collection/"+encodeURIComponent(b[0])+"/"+encodeURIComponent(b[1])};window.DocumentView=Backbone.View.extend({el:"#content",colid:0,docid:0,customView:!1,template:templateEngine.createTemplate("documentView.ejs"),events:{"click #saveDocumentButton":"saveDocument","click #deleteDocumentButton":"deleteDocumentModal","click #confirmDeleteDocument":"deleteDocument","click #document-from":"navigateToDocument","click #document-to":"navigateToDocument","keydown #documentEditor .ace_editor":"keyPress","keyup .jsoneditor .search input":"checkSearchBox"},checkSearchBox:function(a){""===$(a.currentTarget).val()&&this.editor.expandAll()},keyPress:function(a){a.ctrlKey&&13===a.keyCode?(a.preventDefault(),this.saveDocument()):a.metaKey&&13===a.keyCode&&(a.preventDefault(),this.saveDocument())},editor:0,setType:function(a){var b,c;return"edge"===a?(b=this.collection.getEdge(this.colid,this.docid),c="Edge: "):"document"===a&&(b=this.collection.getDocument(this.colid,this.docid),c="Document: "),b===!0?(this.type=a,this.fillInfo(c),this.fillEditor(),!0):void 0},deleteDocumentModal:function(){var a=[],b=[];b.push(window.modalView.createReadOnlyEntry("doc-delete-button","Delete","Delete this "+this.type+"?",void 0,void 0,!1,/[<>&'"]/)),a.push(window.modalView.createDeleteButton("Delete",this.deleteDocument.bind(this))),window.modalView.show("modalTable.ejs","Delete Document",a,b)},deleteDocument:function(){var a;if("document"===this.type){if(a=this.collection.deleteDocument(this.colid,this.docid),a===!1)return void arangoHelper.arangoError("Document error:","Could not delete")}else if("edge"===this.type&&(a=this.collection.deleteEdge(this.colid,this.docid),a===!1))return void arangoHelper.arangoError("Edge error:","Could not delete");if(a===!0)if(this.customView)this.customDeleteFunction();else{var b="collection/"+encodeURIComponent(this.colid)+"/documents/1";window.modalView.hide(),window.App.navigate(b,{trigger:!0})}},navigateToDocument:function(a){var b=$(a.target).attr("documentLink");b&&window.App.navigate(b,{trigger:!0})},fillInfo:function(b){var c=this.collection.first(),d=c.get("_id"),e=c.get("_key"),f=c.get("_rev"),g=c.get("_from"),h=c.get("_to");if($("#document-type").text(b),$("#document-id").text(d),$("#document-key").text(e),$("#document-rev").text(f),g&&h){var i=a(g),j=a(h);$("#document-from").text(g),$("#document-from").attr("documentLink",i),$("#document-to").text(h),$("#document-to").attr("documentLink",j)}else $(".edge-info-container").hide()},fillEditor:function(){var a=this.removeReadonlyKeys(this.collection.first().attributes);this.editor.set(a),$(".ace_content").attr("font-size","11pt")},jsonContentChanged:function(){this.enableSaveButton()},render:function(){$(this.el).html(this.template.render({})),this.disableSaveButton(),this.breadcrumb();var a=this,b=document.getElementById("documentEditor"),c={change:function(){a.jsonContentChanged()},search:!0,mode:"tree",modes:["tree","code"],iconlib:"fontawesome4"};return this.editor=new JSONEditor(b,c),this},removeReadonlyKeys:function(a){return _.omit(a,["_key","_id","_from","_to","_rev"])},saveDocument:function(){var a,b;if(void 0===$("#saveDocumentButton").attr("disabled")){try{a=this.editor.get()}catch(c){return this.errorConfirmation(c),void this.disableSaveButton()}if(a=JSON.stringify(a),"document"===this.type){if(b=this.collection.saveDocument(this.colid,this.docid,a),b===!1)return void arangoHelper.arangoError("Document error:","Could not save")}else if("edge"===this.type&&(b=this.collection.saveEdge(this.colid,this.docid,a),b===!1))return void arangoHelper.arangoError("Edge error:","Could not save");b===!0&&(this.successConfirmation(),this.disableSaveButton())}},successConfirmation:function(){arangoHelper.arangoNotification("Document saved."),$("#documentEditor .tree").animate({backgroundColor:"#C6FFB0"},500),$("#documentEditor .tree").animate({backgroundColor:"#FFFFF"},500),$("#documentEditor .ace_content").animate({backgroundColor:"#C6FFB0"},500),$("#documentEditor .ace_content").animate({backgroundColor:"#FFFFF"},500)},errorConfirmation:function(a){arangoHelper.arangoError("Document editor: ",a),$("#documentEditor .tree").animate({backgroundColor:"#FFB0B0"},500),$("#documentEditor .tree").animate({backgroundColor:"#FFFFF"},500),$("#documentEditor .ace_content").animate({backgroundColor:"#FFB0B0"},500),$("#documentEditor .ace_content").animate({backgroundColor:"#FFFFF"},500)},enableSaveButton:function(){$("#saveDocumentButton").prop("disabled",!1),$("#saveDocumentButton").addClass("button-success"),$("#saveDocumentButton").removeClass("button-close")},disableSaveButton:function(){$("#saveDocumentButton").prop("disabled",!0),$("#saveDocumentButton").addClass("button-close"),$("#saveDocumentButton").removeClass("button-success")},breadcrumb:function(){var a=window.location.hash.split("/");$("#transparentHeader").append('")},escaped:function(a){return a.replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}})}(),function(){"use strict";window.DocumentsView=window.PaginationView.extend({filters:{0:!0},filterId:0,paginationDiv:"#documentsToolbarF",idPrefix:"documents",addDocumentSwitch:!0,activeFilter:!1,lastCollectionName:void 0,restoredFilters:[],editMode:!1,allowUpload:!1,el:"#content",table:"#documentsTableID",template:templateEngine.createTemplate("documentsView.ejs"),collectionContext:{prev:null,next:null},editButtons:["#deleteSelected","#moveSelected"],initialize:function(){this.documentStore=this.options.documentStore,this.collectionsStore=this.options.collectionsStore,this.tableView=new window.TableView({el:this.table,collection:this.collection}),this.tableView.setRowClick(this.clicked.bind(this)),this.tableView.setRemoveClick(this.remove.bind(this))},setCollectionId:function(a,b){this.collection.setCollection(a),this.collection.setPage(b);var c=arangoHelper.collectionApiType(a);this.page=b,this.type=c,this.checkCollectionState(),this.collection.getDocuments(this.getDocsCallback.bind(this)),this.collectionModel=this.collectionsStore.get(a)},getDocsCallback:function(){$("#documents_last").css("visibility","hidden"),$("#documents_first").css("visibility","hidden"),this.drawTable(),this.renderPaginationElements()},events:{"click #collectionPrev":"prevCollection","click #collectionNext":"nextCollection","click #filterCollection":"filterCollection","click #markDocuments":"editDocuments","click #importCollection":"importCollection","click #exportCollection":"exportCollection","click #filterSend":"sendFilter","click #addFilterItem":"addFilterItem","click .removeFilterItem":"removeFilterItem","click #deleteSelected":"deleteSelectedDocs","click #moveSelected":"moveSelectedDocs","click #addDocumentButton":"addDocumentModal","click #documents_first":"firstDocuments","click #documents_last":"lastDocuments","click #documents_prev":"prevDocuments","click #documents_next":"nextDocuments","click #confirmDeleteBtn":"confirmDelete","click .key":"nop",keyup:"returnPressedHandler","keydown .queryline input":"filterValueKeydown","click #importModal":"showImportModal","click #resetView":"resetView","click #confirmDocImport":"startUpload","click #exportDocuments":"startDownload", -"change #documentSize":"setPagesize","change #docsSort":"setSorting"},showSpinner:function(){$("#uploadIndicator").show()},hideSpinner:function(){$("#uploadIndicator").hide()},showImportModal:function(){$("#docImportModal").modal("show")},hideImportModal:function(){$("#docImportModal").modal("hide")},setPagesize:function(){var a=$("#documentSize").find(":selected").val();this.collection.setPagesize(a),this.collection.getDocuments(this.getDocsCallback.bind(this))},setSorting:function(){var a=$("#docsSort").val();(""===a||void 0===a||null===a)&&(a="_key"),this.collection.setSort(a)},returnPressedHandler:function(a){13===a.keyCode&&$(a.target).is($("#docsSort"))&&this.collection.getDocuments(this.getDocsCallback.bind(this)),13===a.keyCode&&$("#confirmDeleteBtn").attr("disabled")===!1&&this.confirmDelete()},nop:function(a){a.stopPropagation()},resetView:function(){$("input").val(""),$("select").val("=="),this.removeAllFilterItems(),$("#documentSize").val(this.collection.getPageSize()),$("#documents_last").css("visibility","visible"),$("#documents_first").css("visibility","visible"),this.addDocumentSwitch=!0,this.collection.resetFilter(),this.collection.loadTotal(),this.restoredFilters=[],this.allowUpload=!1,this.files=void 0,this.file=void 0,$("#confirmDocImport").attr("disabled",!0),this.markFilterToggle(),this.collection.getDocuments(this.getDocsCallback.bind(this))},startDownload:function(){var a=this.collection.buildDownloadDocumentQuery();""!==a||void 0!==a||null!==a?window.open(encodeURI("query/result/download/"+btoa(JSON.stringify(a)))):arangoHelper.arangoError("Document error","could not download documents")},startUpload:function(){var a;return this.allowUpload===!0?(this.showSpinner(),a=this.collection.uploadDocuments(this.file),a!==!0?(this.hideSpinner(),this.hideImportModal(),this.resetView(),void arangoHelper.arangoError(a)):(this.hideSpinner(),this.hideImportModal(),void this.resetView())):void 0},uploadSetup:function(){var a=this;$("#importDocuments").change(function(b){a.files=b.target.files||b.dataTransfer.files,a.file=a.files[0],$("#confirmDocImport").attr("disabled",!1),a.allowUpload=!0})},buildCollectionLink:function(a){return"collection/"+encodeURIComponent(a.get("name"))+"/documents/1"},markFilterToggle:function(){this.restoredFilters.length>0?$("#filterCollection").addClass("activated"):$("#filterCollection").removeClass("activated")},editDocuments:function(){$("#importCollection").removeClass("activated"),$("#exportCollection").removeClass("activated"),this.markFilterToggle(),$("#markDocuments").toggleClass("activated"),this.changeEditMode(),$("#filterHeader").hide(),$("#importHeader").hide(),$("#editHeader").slideToggle(200),$("#exportHeader").hide()},filterCollection:function(){$("#importCollection").removeClass("activated"),$("#exportCollection").removeClass("activated"),$("#markDocuments").removeClass("activated"),this.changeEditMode(!1),this.markFilterToggle(),this.activeFilter=!0,$("#importHeader").hide(),$("#editHeader").hide(),$("#exportHeader").hide(),$("#filterHeader").slideToggle(200);var a;for(a in this.filters)if(this.filters.hasOwnProperty(a))return void $("#attribute_name"+a).focus()},exportCollection:function(){$("#importCollection").removeClass("activated"),$("#filterHeader").removeClass("activated"),$("#markDocuments").removeClass("activated"),this.changeEditMode(!1),$("#exportCollection").toggleClass("activated"),this.markFilterToggle(),$("#exportHeader").slideToggle(200),$("#importHeader").hide(),$("#filterHeader").hide(),$("#editHeader").hide()},importCollection:function(){this.markFilterToggle(),$("#markDocuments").removeClass("activated"),this.changeEditMode(!1),$("#importCollection").toggleClass("activated"),$("#exportCollection").removeClass("activated"),$("#importHeader").slideToggle(200),$("#filterHeader").hide(),$("#editHeader").hide(),$("#exportHeader").hide()},changeEditMode:function(a){a===!1||this.editMode===!0?($("#documentsTableID tbody tr").css("cursor","default"),$(".deleteButton").fadeIn(),$(".addButton").fadeIn(),$(".selected-row").removeClass("selected-row"),this.editMode=!1,this.tableView.setRowClick(this.clicked.bind(this))):($("#documentsTableID tbody tr").css("cursor","copy"),$(".deleteButton").fadeOut(),$(".addButton").fadeOut(),$(".selectedCount").text(0),this.editMode=!0,this.tableView.setRowClick(this.editModeClick.bind(this)))},getFilterContent:function(){var a,b=[];for(a in this.filters)if(this.filters.hasOwnProperty(a)){var c=$("#attribute_value"+a).val();try{c=JSON.parse(c)}catch(d){c=String(c)}""!==$("#attribute_name"+a).val()&&b.push({attribute:$("#attribute_name"+a).val(),operator:$("#operator"+a).val(),value:c})}return b},sendFilter:function(){this.restoredFilters=this.getFilterContent();var a=this;this.collection.resetFilter(),this.addDocumentSwitch=!1,_.each(this.restoredFilters,function(b){void 0!==b.operator&&a.collection.addFilter(b.attribute,b.operator,b.value)}),this.collection.setToFirst(),this.collection.getDocuments(this.getDocsCallback.bind(this)),this.markFilterToggle()},restoreFilter:function(){var a=this,b=0;this.filterId=0,$("#docsSort").val(this.collection.getSort()),_.each(this.restoredFilters,function(c){0!==b&&a.addFilterItem(),void 0!==c.operator&&($("#attribute_name"+b).val(c.attribute),$("#operator"+b).val(c.operator),$("#attribute_value"+b).val(c.value)),b++,a.collection.addFilter(c.attribute,c.operator,c.value)})},addFilterItem:function(){var a=++this.filterId;$("#filterHeader").append('
    '),this.filters[a]=!0},filterValueKeydown:function(a){13===a.keyCode&&this.sendFilter()},removeFilterItem:function(a){var b=a.currentTarget,c=b.id.replace(/^removeFilter/,"");delete this.filters[c],delete this.restoredFilters[c],$(b.parentElement).remove()},removeAllFilterItems:function(){var a,b=$("#filterHeader").children().length;for(a=1;b>=a;a++)$("#removeFilter"+a).parent().remove();this.filters={0:!0},this.filterId=0},addDocumentModal:function(){var a=window.location.hash.split("/")[1],b=[],c=[],d=arangoHelper.collectionApiType(a,!0);return"edge"===d?(c.push(window.modalView.createTextEntry("new-edge-from-attr","_from","","document _id: document handle of the linked vertex (incoming relation)",void 0,!1,[{rule:Joi.string().required(),msg:"No _from attribute given."}])),c.push(window.modalView.createTextEntry("new-edge-to","_to","","document _id: document handle of the linked vertex (outgoing relation)",void 0,!1,[{rule:Joi.string().required(),msg:"No _to attribute given."}])),c.push(window.modalView.createTextEntry("new-edge-key-attr","_key",void 0,"the edges unique key(optional attribute, leave empty for autogenerated key","is optional: leave empty for autogenerated key",!1,[{rule:Joi.string().allow("").optional(),msg:""}])),b.push(window.modalView.createSuccessButton("Create",this.addEdge.bind(this))),void window.modalView.show("modalTable.ejs","Create edge",b,c)):(c.push(window.modalView.createTextEntry("new-document-key-attr","_key",void 0,"the documents unique key(optional attribute, leave empty for autogenerated key","is optional: leave empty for autogenerated key",!1,[{rule:Joi.string().allow("").optional(),msg:""}])),b.push(window.modalView.createSuccessButton("Create",this.addDocument.bind(this))),window.modalView.show("modalTable.ejs","Create document",b,c),void 0)},addEdge:function(){var a,b=window.location.hash.split("/")[1],c=$(".modal-body #new-edge-from-attr").last().val(),d=$(".modal-body #new-edge-to").last().val(),e=$(".modal-body #new-edge-key-attr").last().val();a=""!==e||void 0!==e?this.documentStore.createTypeEdge(b,c,d,e):this.documentStore.createTypeEdge(b,c,d),a!==!1?(window.modalView.hide(),window.location.hash="collection/"+a):arangoHelper.arangoError("Edge error","Creation failed.")},addDocument:function(){var a,b=window.location.hash.split("/")[1],c=$(".modal-body #new-document-key-attr").last().val();a=""!==c||void 0!==c?this.documentStore.createTypeDocument(b,c):this.documentStore.createTypeDocument(b),a!==!1?(window.modalView.hide(),window.location.hash="collection/"+a):arangoHelper.arangoError("Document error","Creation failed.")},moveSelectedDocs:function(){var a=[],b=[],c=this.getSelectedDocs();0!==c.length&&(b.push(window.modalView.createTextEntry("move-documents-to","Move to","",!1,"collection-name",!0,[{rule:Joi.string().regex(/^[a-zA-Z]/),msg:"Collection name must always start with a letter."},{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only Symbols "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No collection name given."}])),a.push(window.modalView.createSuccessButton("Move",this.confirmMoveSelectedDocs.bind(this))),window.modalView.show("modalTable.ejs","Move documents",a,b))},confirmMoveSelectedDocs:function(){var a=this.getSelectedDocs(),b=this,c=$(".modal-body").last().find("#move-documents-to").val(),d=function(){this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#markDocuments").click(),window.modalView.hide()}.bind(this);_.each(a,function(a){b.collection.moveDocument(a,b.collection.collectionID,c,d)})},deleteSelectedDocs:function(){var a=[],b=[],c=this.getSelectedDocs();0!==c.length&&(b.push(window.modalView.createReadOnlyEntry(void 0,c.length+" documents selected","Do you want to delete all selected documents?",void 0,void 0,!1,void 0)),a.push(window.modalView.createDeleteButton("Delete",this.confirmDeleteSelectedDocs.bind(this))),window.modalView.show("modalTable.ejs","Delete documents",a,b))},confirmDeleteSelectedDocs:function(){var a=this.getSelectedDocs(),b=[],c=this;_.each(a,function(a){var d=!1;"document"===c.type?(d=c.documentStore.deleteDocument(c.collection.collectionID,a),d?(b.push(!0),c.collection.setTotalMinusOne()):(b.push(!1),arangoHelper.arangoError("Document error","Could not delete document."))):"edge"===c.type&&(d=c.documentStore.deleteEdge(c.collection.collectionID,a),d===!0?(c.collection.setTotalMinusOne(),b.push(!0)):(b.push(!1),arangoHelper.arangoError("Edge error","Could not delete edge")))}),this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#markDocuments").click(),window.modalView.hide()},getSelectedDocs:function(){var a=[];return _.each($("#documentsTableID tbody tr"),function(b){$(b).hasClass("selected-row")&&a.push($($(b).children()[1]).find(".key").text())}),a},remove:function(a){this.docid=$(a.currentTarget).closest("tr").attr("id").substr(4),$("#confirmDeleteBtn").attr("disabled",!1),$("#docDeleteModal").modal("show")},confirmDelete:function(){$("#confirmDeleteBtn").attr("disabled",!0);var a=window.location.hash.split("/"),b=a[3];"source"!==b&&this.reallyDelete()},reallyDelete:function(){var a,b=this,c=($(b.target).closest("tr").get(0),!1);"document"===this.type?(a=this.documentStore.deleteDocument(this.collection.collectionID,this.docid),a?(this.collection.setTotalMinusOne(),c=!0):arangoHelper.arangoError("Doc error")):"edge"===this.type&&(a=this.documentStore.deleteEdge(this.collection.collectionID,this.docid),a===!0?(this.collection.setTotalMinusOne(),c=!0):arangoHelper.arangoError("Edge error")),c===!0&&(this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#docDeleteModal").modal("hide"))},editModeClick:function(a){var b=$(a.currentTarget);b.hasClass("selected-row")?b.removeClass("selected-row"):b.addClass("selected-row");var c=this.getSelectedDocs();$(".selectedCount").text(c.length),_.each(this.editButtons,function(a){c.length>0?($(a).prop("disabled",!1),$(a).removeClass("button-neutral"),$(a).removeClass("disabled"),"#moveSelected"===a?$(a).addClass("button-success"):$(a).addClass("button-danger")):($(a).prop("disabled",!0),$(a).addClass("disabled"),$(a).addClass("button-neutral"),"#moveSelected"===a?$(a).removeClass("button-success"):$(a).removeClass("button-danger"))})},clicked:function(a){var b=a.currentTarget;window.App.navigate("collection/"+this.collection.collectionID+"/"+$(b).attr("id").substr(4),!0)},drawTable:function(){this.tableView.setElement($(this.table)).render(),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","top"),$(".prettify").snippet("javascript",{style:"nedit",menu:!1,startText:!1,transparent:!0,showNum:!1})},checkCollectionState:function(){this.lastCollectionName===this.collectionName?this.activeFilter&&(this.filterCollection(),this.restoreFilter()):void 0!==this.lastCollectionName&&(this.collection.resetFilter(),this.collection.setSort("_key"),this.restoredFilters=[],this.activeFilter=!1)},render:function(){return $(this.el).html(this.template.render({})),this.tableView.setElement($(this.table)).drawLoading(),this.collectionContext=this.collectionsStore.getPosition(this.collection.collectionID),this.breadcrumb(),this.checkCollectionState(),this.lastCollectionName=this.collectionName,this.uploadSetup(),$("[data-toggle=tooltip]").tooltip(),$(".upload-info").tooltip(),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","top"),this.renderPaginationElements(),this.selectActivePagesize(),this.markFilterToggle(),this},rerender:function(){this.collection.getDocuments(this.getDocsCallback.bind(this))},selectActivePagesize:function(){$("#documentSize").val(this.collection.getPageSize())},renderPaginationElements:function(){this.renderPagination();var a=$("#totalDocuments");0===a.length&&($("#documentsToolbarFL").append(''),a=$("#totalDocuments")),"document"===this.type&&a.html(this.collection.getTotal()+" document(s)"),"edge"===this.type&&a.html(this.collection.getTotal()+" edge(s)")},breadcrumb:function(){this.collectionName=window.location.hash.split("/")[1],$("#transparentHeader").append('")}})}(),function(){"use strict";window.EditListEntryView=Backbone.View.extend({template:templateEngine.createTemplate("editListEntryView.ejs"),initialize:function(a){this.key=a.key,this.value=a.value,this.render()},events:{"click .deleteAttribute":"removeRow"},render:function(){$(this.el).html(this.template.render({key:this.key,value:JSON.stringify(this.value),isReadOnly:this.isReadOnly()}))},isReadOnly:function(){return 0===this.key.indexOf("_")},getKey:function(){return $(".key").val()},getValue:function(){var val=$(".val").val();try{val=JSON.parse(val)}catch(e){try{return eval("val = "+val),val}catch(e2){return $(".val").val()}}return val},removeRow:function(){this.remove()}})}(),function(){"use strict";window.FooterView=Backbone.View.extend({el:"#footerBar",system:{},isOffline:!0,isOfflineCounter:0,firstLogin:!0,events:{"click .footer-center p":"showShortcutModal"},initialize:function(){var a=this;window.setInterval(function(){a.getVersion()},15e3),a.getVersion()},template:templateEngine.createTemplate("footerView.ejs"),showServerStatus:function(a){a===!0?($(".serverStatusIndicator").addClass("isOnline"),$(".serverStatusIndicator").addClass("fa-check-circle-o"),$(".serverStatusIndicator").removeClass("fa-times-circle-o")):($(".serverStatusIndicator").removeClass("isOnline"),$(".serverStatusIndicator").removeClass("fa-check-circle-o"),$(".serverStatusIndicator").addClass("fa-times-circle-o"))},showShortcutModal:function(){window.arangoHelper.hotkeysFunctions.showHotkeysModal()},getVersion:function(){var a=this;$.ajax({type:"GET",cache:!1,url:"/_api/version",contentType:"application/json",processData:!1,async:!0,success:function(b){a.showServerStatus(!0),a.isOffline===!0&&(a.isOffline=!1,a.isOfflineCounter=0,a.firstLogin?a.firstLogin=!1:window.setTimeout(function(){a.showServerStatus(!0)},1e3),a.system.name=b.server,a.system.version=b.version,a.render())},error:function(b){a.isOffline=!0,a.isOfflineCounter++,a.isOfflineCounter>=1&&a.showServerStatus(!1)}}),a.system.hasOwnProperty("database")||$.ajax({type:"GET",cache:!1,url:"/_api/database/current",contentType:"application/json",processData:!1,async:!0,success:function(b){var c=b.result.name;a.system.database=c;var d=window.setInterval(function(){var b=$("#databaseNavi");b&&(window.clearTimeout(d),d=null,"_system"===c?($(".logs-menu").css("visibility","visible"),$(".logs-menu").css("display","inline"),$("#databaseNavi").css("display","inline")):($(".logs-menu").css("visibility","hidden"),$(".logs-menu").css("display","none")),a.render())},50)}})},renderVersion:function(){this.system.hasOwnProperty("database")&&this.system.hasOwnProperty("name")&&$(this.el).html(this.template.render({name:this.system.name,version:this.system.version,database:this.system.database}))},render:function(){return this.system.version||this.getVersion(),$(this.el).html(this.template.render({name:this.system.name,version:this.system.version})),this}})}(),function(){"use strict";window.FoxxActiveView=Backbone.View.extend({tagName:"div",className:"tile",template:templateEngine.createTemplate("foxxActiveView.ejs"),_show:!0,events:{click:"openAppDetailView"},openAppDetailView:function(){window.App.navigate("applications/"+encodeURIComponent(this.model.get("mount")),{trigger:!0})},toggle:function(a,b){switch(a){case"devel":this.model.isDevelopment()&&(this._show=b);break;case"production":this.model.isDevelopment()||this.model.isSystem()||(this._show=b);break;case"system":this.model.isSystem()&&(this._show=b)}this._show?$(this.el).show():$(this.el).hide()},render:function(){return $(this.el).html(this.template.render({model:this.model})),$(this.el)}})}(),function(){"use strict";var a=require("internal").errors,b=templateEngine.createTemplate("applicationListView.ejs"),c=function(a){this.collection=a.collection},d=function(b){if(b.error===!1)this.collection.fetch({async:!1}),window.modalView.hide(),this.reload();else{var c=b;switch(b.hasOwnProperty("responseJSON")&&(c=b.responseJSON),c.errorNum){case a.ERROR_APPLICATION_DOWNLOAD_FAILED.code:alert("Unable to download application from the given repository.");break;default:alert("Error: "+c.errorNum+". "+c.errorMessage)}}},e=function(){window.modalView.modalBindValidation({id:"new-app-mount",validateInput:function(){return[{rule:Joi.string().regex(/^(\/(APP[^\/]+|(?!APP)[a-zA-Z0-9_\-%]+))+$/i),msg:"May not contain /APP"},{rule:Joi.string().regex(/^(\/[a-zA-Z0-9_\-%]+)+$/),msg:"Can only contain [a-zA-Z0-9_-%]"},{rule:Joi.string().regex(/^\/([^_]|_open\/)/),msg:"Mountpoints with _ are reserved for internal use"},{rule:Joi.string().regex(/[^\/]$/),msg:"May not end with /"},{rule:Joi.string().regex(/^\//),msg:"Has to start with /"},{rule:Joi.string().required().min(2),msg:"Has to be non-empty"}]}})},f=function(){window.modalView.modalBindValidation({id:"repository",validateInput:function(){return[{rule:Joi.string().required().regex(/^[a-zA-Z0-9_\-]+\/[a-zA-Z0-9_\-]+$/),msg:"No valid Github account and repository."}]}})},g=function(){window.modalView.modalBindValidation({id:"new-app-author",validateInput:function(){return[{rule:Joi.string().required().min(1),msg:"Has to be non empty."}]}}),window.modalView.modalBindValidation({id:"new-app-name",validateInput:function(){return[{rule:Joi.string().required().regex(/^[a-zA-Z\-_][a-zA-Z0-9\-_]*$/),msg:"Can only contain a to z, A to Z, 0-9, '-' and '_'."}]}}),window.modalView.modalBindValidation({id:"new-app-description",validateInput:function(){return[{rule:Joi.string().required().min(1),msg:"Has to be non empty."}]}}),window.modalView.modalBindValidation({id:"new-app-license",validateInput:function(){return[{rule:Joi.string().required().regex(/^[a-zA-Z0-9 \.,;\-]+$/),msg:"Has to be non empty."}]}}),window.modalView.modalTestAll()},h=function(a){window.modalView.clearValidators();var b=$("#modalButton1");switch(this._upgrade||e(),a){case"newApp":b.html("Generate"),b.prop("disabled",!1),g();break;case"appstore":b.html("Install"),b.prop("disabled",!0);break;case"github":f(),b.html("Install"),b.prop("disabled",!1);break;case"zip":b.html("Install"),b.prop("disabled",!1)}b.prop("disabled")||window.modalView.modalTestAll()||b.prop("disabled",!0)},i=function(a){var b=$(a.currentTarget).attr("href").substr(1);h.call(this,b)},j=function(a){if(h.call(this,"appstore"),window.modalView.modalTestAll()){var b,c;this._upgrade?(b=this.mount,c=$("#new-app-teardown").prop("checked")):b=window.arangoHelper.escapeHtml($("#new-app-mount").val());var e=$(a.currentTarget).attr("appId"),f=$(a.currentTarget).attr("appVersion");void 0!==c?this.collection.installFromStore({name:e,version:f},b,d.bind(this),c):this.collection.installFromStore({name:e,version:f},b,d.bind(this))}},k=function(a,b){if(void 0===b?b=this._uploadData:this._uploadData=b,b&&window.modalView.modalTestAll()){var c,e;this._upgrade?(c=this.mount,e=$("#new-app-teardown").prop("checked")):c=window.arangoHelper.escapeHtml($("#new-app-mount").val()),void 0!==e?this.collection.installFromZip(b.filename,c,d.bind(this),e):this.collection.installFromZip(b.filename,c,d.bind(this))}},l=function(){if(window.modalView.modalTestAll()){var a,b,c,e;this._upgrade?(c=this.mount,e=$("#new-app-teardown").prop("checked")):c=window.arangoHelper.escapeHtml($("#new-app-mount").val()),a=window.arangoHelper.escapeHtml($("#repository").val()),b=window.arangoHelper.escapeHtml($("#tag").val()),""===b&&(b="master");var f={url:window.arangoHelper.escapeHtml($("#repository").val()),version:window.arangoHelper.escapeHtml($("#tag").val())};try{Joi.assert(a,Joi.string().regex(/^[a-zA-Z0-9_\-]+\/[a-zA-Z0-9_\-]+$/))}catch(g){return}void 0!==e?this.collection.installFromGithub(f,c,d.bind(this),e):this.collection.installFromGithub(f,c,d.bind(this))}},m=function(){if(window.modalView.modalTestAll()){var a,b;this._upgrade?(a=this.mount,b=$("#new-app-teardown").prop("checked")):a=window.arangoHelper.escapeHtml($("#new-app-mount").val());var c={name:window.arangoHelper.escapeHtml($("#new-app-name").val()),collectionNames:_.map($("#new-app-collections").select2("data"),function(a){return window.arangoHelper.escapeHtml(a.text)}),author:window.arangoHelper.escapeHtml($("#new-app-author").val()),license:window.arangoHelper.escapeHtml($("#new-app-license").val()),description:window.arangoHelper.escapeHtml($("#new-app-description").val())};void 0!==b?this.collection.generate(c,a,d.bind(this),b):this.collection.generate(c,a,d.bind(this))}},n=function(){var a=$(".modal-body .tab-pane.active").attr("id");switch(a){case"newApp":m.apply(this);break;case"github":l.apply(this);break;case"zip":k.apply(this)}},o=function(a,c){var d=[],e={"click #infoTab a":i.bind(a),"click .install-app":j.bind(a)};d.push(window.modalView.createSuccessButton("Generate",n.bind(a))),window.modalView.show("modalApplicationMount.ejs","Install Service",d,c,void 0,void 0,e),$("#new-app-collections").select2({tags:[],showSearchBox:!1,minimumResultsForSearch:-1,width:"336px"});var f=function(){var a=$("#modalButton1");a.prop("disabled")||window.modalView.modalTestAll()?a.prop("disabled",!1):a.prop("disabled",!0)};$(".select2-search-field input").focusout(function(){f(),window.setTimeout(function(){$(".select2-drop").is(":visible")&&($("#select2-search-field input").is(":focus")||($("#s2id_new-app-collections").select2("close"),f()))},80)}),$(".select2-search-field input").focusin(function(){if($(".select2-drop").is(":visible")){var a=$("#modalButton1");a.prop("disabled",!0)}}),$("#upload-foxx-zip").uploadFile({url:"/_api/upload?multipart=true",allowedTypes:"zip",multiple:!1,onSuccess:k.bind(a)}),$.get("foxxes/fishbowl",function(a){var c=$("#appstore-content");c.html(""),_.each(_.sortBy(a,"name"),function(a){c.append(b.render(a))})}).fail(function(){var a=$("#appstore-content");a.append("Store is not available. ArangoDB is not able to connect to github.com")})};c.prototype.install=function(a){this.reload=a,this._upgrade=!1,this._uploadData=void 0,delete this.mount,o(this,!1),window.modalView.clearValidators(),e(),g()},c.prototype.upgrade=function(a,b){this.reload=b,this._upgrade=!0,this._uploadData=void 0,this.mount=a,o(this,!0),window.modalView.clearValidators(),g()},window.FoxxInstallView=c}(),function(){"use strict";window.GraphManagementView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("graphManagementView.ejs"),edgeDefintionTemplate:templateEngine.createTemplate("edgeDefinitionTable.ejs"),eCollList:[],removedECollList:[],dropdownVisible:!1,events:{"click #deleteGraph":"deleteGraph","click .icon_arangodb_settings2.editGraph":"editGraph","click #createGraph":"addNewGraph","keyup #graphManagementSearchInput":"search","click #graphManagementSearchSubmit":"search","click .tile-graph":"redirectToGraphViewer","click #graphManagementToggle":"toggleGraphDropdown","click .css-label":"checkBoxes","change #graphSortDesc":"sorting"},toggleTab:function(a){var b=a.currentTarget.id;b=b.replace("tab-",""),$("#tab-content-create-graph .tab-pane").removeClass("active"),$("#tab-content-create-graph #"+b).addClass("active"),"exampleGraphs"===b?$("#modal-dialog .modal-footer button").css("display","none"):$("#modal-dialog .modal-footer button").css("display","block")},redirectToGraphViewer:function(a){var b=$(a.currentTarget).attr("id");b=b.substr(0,b.length-5),window.location=window.location+"/"+encodeURIComponent(b)},loadGraphViewer:function(a){var b=this.collection.get(a).get("edgeDefinitions");if(b&&0!==b.length){var c={type:"gharial",graphName:a,baseUrl:require("internal").arango.databasePrefix("/")},d=$("#content").width()-75;$("#content").html("");var e=arangoHelper.calculateCenterDivHeight();this.ui=new GraphViewerUI($("#content")[0],c,d,e,{nodeShaper:{label:"_key",color:{type:"attribute",key:"_key"}}},!0),$(".contentDiv").height(e)}},handleResize:function(a){this.width&&this.width===a||(this.width=a,this.ui&&this.ui.changeWidth(a))},addNewGraph:function(a){a.preventDefault(),this.createEditGraphModal()},deleteGraph:function(){var a=this,b=$("#editGraphName")[0].value;if($("#dropGraphCollections").is(":checked")){var c=function(c){c?(a.collection.remove(a.collection.get(b)),a.updateGraphManagementView(),window.modalView.hide()):window.modalView.hide()};this.collection.dropAndDeleteGraph(b,c)}else this.collection.get(b).destroy({success:function(){a.updateGraphManagementView(),window.modalView.hide()},error:function(a,b){var c=JSON.parse(b.responseText),d=c.errorMessage;arangoHelper.arangoError(d),window.modalView.hide()}})},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},toggleGraphDropdown:function(){$("#graphSortDesc").attr("checked",this.collection.sortOptions.desc),$("#graphManagementToggle").toggleClass("activated"),$("#graphManagementDropdown2").slideToggle(200)},sorting:function(){$("#graphSortDesc").is(":checked")?this.collection.setSortingDesc(!0):this.collection.setSortingDesc(!1),$("#graphManagementDropdown").is(":visible")?this.dropdownVisible=!0:this.dropdownVisible=!1,this.render()},createExampleGraphs:function(a){var b=$(a.currentTarget).attr("graph-id"),c=this;$.ajax({type:"POST",url:"/_admin/aardvark/graph-examples/create/"+encodeURIComponent(b),success:function(){window.modalView.hide(),c.updateGraphManagementView(),arangoHelper.arangoNotification("Example Graphs","Graph: "+b+" created.")},error:function(a){if(window.modalView.hide(),console.log(a),a.responseText)try{var c=JSON.parse(a.responseText);arangoHelper.arangoError("Example Graphs",c.errorMessage)}catch(d){arangoHelper.arangoError("Example Graphs","Could not create example graph: "+b)}else arangoHelper.arangoError("Example Graphs","Could not create example graph: "+b)}})},render:function(){return this.collection.fetch({async:!1}),this.collection.sort(),$(this.el).html(this.template.render({graphs:this.collection,searchString:""})),this.dropdownVisible===!0&&($("#graphManagementDropdown2").show(),$("#graphSortDesc").attr("checked",this.collection.sortOptions.desc),$("#graphManagementToggle").toggleClass("activated"),$("#graphManagementDropdown").show()),this.events["click .tableRow"]=this.showHideDefinition.bind(this),this.events['change tr[id*="newEdgeDefinitions"]']=this.setFromAndTo.bind(this),this.events["click .graphViewer-icon-button"]=this.addRemoveDefinition.bind(this),this.events["click #graphTab a"]=this.toggleTab.bind(this),this.events["click .createExampleGraphs"]=this.createExampleGraphs.bind(this),arangoHelper.setCheckboxStatus("#graphManagementDropdown"),this},setFromAndTo:function(a){a.stopPropagation();var b,c=this.calculateEdgeDefinitionMap();if(a.added){if(-1===this.eCollList.indexOf(a.added.id)&&-1!==this.removedECollList.indexOf(a.added.id))return b=a.currentTarget.id.split("row_newEdgeDefinitions")[1],$('input[id*="newEdgeDefinitions'+b+'"]').select2("val",null),void $('input[id*="newEdgeDefinitions'+b+'"]').attr("placeholder","The collection "+a.added.id+" is already used.");this.removedECollList.push(a.added.id),this.eCollList.splice(this.eCollList.indexOf(a.added.id),1)}else this.eCollList.push(a.removed.id),this.removedECollList.splice(this.removedECollList.indexOf(a.removed.id),1);c[a.val]?(b=a.currentTarget.id.split("row_newEdgeDefinitions")[1],$("#s2id_fromCollections"+b).select2("val",c[a.val].from),$("#fromCollections"+b).attr("disabled",!0),$("#s2id_toCollections"+b).select2("val",c[a.val].to),$("#toCollections"+b).attr("disabled",!0)):(b=a.currentTarget.id.split("row_newEdgeDefinitions")[1],$("#s2id_fromCollections"+b).select2("val",null),$("#fromCollections"+b).attr("disabled",!1),$("#s2id_toCollections"+b).select2("val",null),$("#toCollections"+b).attr("disabled",!1))},editGraph:function(a){a.stopPropagation(),this.collection.fetch(),this.graphToEdit=this.evaluateGraphName($(a.currentTarget).attr("id"),"_settings");var b=this.collection.findWhere({_key:this.graphToEdit});this.createEditGraphModal(b)},saveEditedGraph:function(){var a,b,c,d,e,f=$("#editGraphName")[0].value,g=_.pluck($("#newVertexCollections").select2("data"),"text"),h=[],i={};if(e=$("[id^=s2id_newEdgeDefinitions]").toArray(),e.forEach(function(e){if(d=$(e).attr("id"),d=d.replace("s2id_newEdgeDefinitions",""),a=_.pluck($("#s2id_newEdgeDefinitions"+d).select2("data"),"text")[0],a&&""!==a&&(b=_.pluck($("#s2id_fromCollections"+d).select2("data"),"text"),c=_.pluck($("#s2id_toCollections"+d).select2("data"),"text"),0!==b.length&&0!==c.length)){var f={collection:a,from:b,to:c};h.push(f),i[a]=f}}),0===h.length)return void $("#s2id_newEdgeDefinitions0 .select2-choices").css("border-color","red");var j=this.collection.findWhere({_key:f}),k=j.get("edgeDefinitions"),l=j.get("orphanCollections"),m=[];l.forEach(function(a){-1===g.indexOf(a)&&j.deleteVertexCollection(a)}),g.forEach(function(a){-1===l.indexOf(a)&&j.addVertexCollection(a)});var n=[],o=[],p=[];k.forEach(function(a){var b=a.collection;m.push(b);var c=i[b];void 0===c?p.push(b):JSON.stringify(c)!==JSON.stringify(a)&&o.push(b)}),h.forEach(function(a){var b=a.collection;-1===m.indexOf(b)&&n.push(b)}),n.forEach(function(a){j.addEdgeDefinition(i[a])}),o.forEach(function(a){j.modifyEdgeDefinition(i[a])}),p.forEach(function(a){j.deleteEdgeDefinition(a)}),this.updateGraphManagementView(),window.modalView.hide()},evaluateGraphName:function(a,b){var c=a.lastIndexOf(b);return a.substring(0,c)},search:function(){var a,b,c,d;a=$("#graphManagementSearchInput"),b=$("#graphManagementSearchInput").val(),d=this.collection.filter(function(a){return-1!==a.get("_key").indexOf(b)}),$(this.el).html(this.template.render({graphs:d,searchString:b})),a=$("#graphManagementSearchInput"),c=a.val().length,a.focus(),a[0].setSelectionRange(c,c)},updateGraphManagementView:function(){ -var a=this;this.collection.fetch({success:function(){a.render()}})},createNewGraph:function(){var a,b,c,d,e,f=$("#createNewGraphName").val(),g=_.pluck($("#newVertexCollections").select2("data"),"text"),h=[],i=this;return f?this.collection.findWhere({_key:f})?(arangoHelper.arangoError("The graph '"+f+"' already exists."),0):(e=$("[id^=s2id_newEdgeDefinitions]").toArray(),e.forEach(function(e){d=$(e).attr("id"),d=d.replace("s2id_newEdgeDefinitions",""),a=_.pluck($("#s2id_newEdgeDefinitions"+d).select2("data"),"text")[0],a&&""!==a&&(b=_.pluck($("#s2id_fromCollections"+d).select2("data"),"text"),c=_.pluck($("#s2id_toCollections"+d).select2("data"),"text"),1!==b&&1!==c&&h.push({collection:a,from:b,to:c}))}),void this.collection.create({name:f,edgeDefinitions:h,orphanCollections:g},{success:function(){i.updateGraphManagementView(),window.modalView.hide()},error:function(a,b){var c=JSON.parse(b.responseText),d=c.errorMessage;d=d.replace("<",""),d=d.replace(">",""),arangoHelper.arangoError(d)}})):(arangoHelper.arangoError("A name for the graph has to be provided."),0)},createEditGraphModal:function(a){var b,c=[],d=[],e=[],f=this.options.collectionCollection.models,g=this,h="",i=[{collection:"",from:"",to:""}],j="",k=function(a,b){return a=a.toLowerCase(),b=b.toLowerCase(),b>a?-1:a>b?1:0};if(this.eCollList=[],this.removedECollList=[],f.forEach(function(a){a.get("isSystem")||("edge"===a.get("type")?g.eCollList.push(a.id):d.push(a.id))}),window.modalView.enableHotKeys=!1,this.counter=0,a?(b="Edit Graph",h=a.get("_key"),i=a.get("edgeDefinitions"),i&&0!==i.length||(i=[{collection:"",from:"",to:""}]),j=a.get("orphanCollections"),e.push(window.modalView.createReadOnlyEntry("editGraphName","Name",h,"The name to identify the graph. Has to be unique")),c.push(window.modalView.createDeleteButton("Delete",this.deleteGraph.bind(this))),c.push(window.modalView.createSuccessButton("Save",this.saveEditedGraph.bind(this)))):(b="Create Graph",e.push(window.modalView.createTextEntry("createNewGraphName","Name","","The name to identify the graph. Has to be unique.","graphName",!0)),c.push(window.modalView.createSuccessButton("Create",this.createNewGraph.bind(this)))),i.forEach(function(a){0===g.counter?(a.collection&&(g.removedECollList.push(a.collection),g.eCollList.splice(g.eCollList.indexOf(a.collection),1)),e.push(window.modalView.createSelect2Entry("newEdgeDefinitions"+g.counter,"Edge definitions",a.collection,"An edge definition defines a relation of the graph","Edge definitions",!0,!1,!0,1,g.eCollList.sort(k)))):e.push(window.modalView.createSelect2Entry("newEdgeDefinitions"+g.counter,"Edge definitions",a.collection,"An edge definition defines a relation of the graph","Edge definitions",!1,!0,!1,1,g.eCollList.sort(k))),e.push(window.modalView.createSelect2Entry("fromCollections"+g.counter,"fromCollections",a.from,"The collections that contain the start vertices of the relation.","fromCollections",!0,!1,!1,10,d.sort(k))),e.push(window.modalView.createSelect2Entry("toCollections"+g.counter,"toCollections",a.to,"The collections that contain the end vertices of the relation.","toCollections",!0,!1,!1,10,d.sort(k))),g.counter++}),e.push(window.modalView.createSelect2Entry("newVertexCollections","Vertex collections",j,"Collections that are part of a graph but not used in an edge definition","Vertex Collections",!1,!1,!1,10,d.sort(k))),window.modalView.show("modalGraphTable.ejs",b,c,e,void 0,void 0,this.events),a){$(".modal-body table").css("border-collapse","separate");var l;for($(".modal-body .spacer").remove(),l=0;l<=this.counter;l++)$("#row_fromCollections"+l).show(),$("#row_toCollections"+l).show(),$("#row_newEdgeDefinitions"+l).addClass("first"),$("#row_fromCollections"+l).addClass("middle"),$("#row_toCollections"+l).addClass("last"),$("#row_toCollections"+l).after('');$("#graphTab").hide(),$("#modal-dialog .modal-delete-confirmation").append('
    ')}},showHideDefinition:function(a){},addRemoveDefinition:function(a){var b=[],c=this.options.collectionCollection.models;c.forEach(function(a){a.get("isSystem")||b.push(a.id)}),a.stopPropagation();var d,e=$(a.currentTarget).attr("id");if(-1===e.indexOf("addAfter_newEdgeDefinitions"))-1!==e.indexOf("remove_newEdgeDefinitions")&&(d=e.split("remove_newEdgeDefinitions")[1],$("#row_newEdgeDefinitions"+d).remove(),$("#row_fromCollections"+d).remove(),$("#row_toCollections"+d).remove(),$("#spacer"+d).remove());else{this.counter++,$("#row_newVertexCollections").before(this.edgeDefintionTemplate.render({number:this.counter})),$("#newEdgeDefinitions"+this.counter).select2({tags:this.eCollList,showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:1}),$("#fromCollections"+this.counter).select2({tags:b,showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:10}),$("#toCollections"+this.counter).select2({tags:b,showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:10}),window.modalView.undelegateEvents(),window.modalView.delegateEvents(this.events);var f;for($(".modal-body .spacer").remove(),f=0;f<=this.counter;f++)$("#row_fromCollections"+f).show(),$("#row_toCollections"+f).show(),$("#row_newEdgeDefinitions"+f).addClass("first"),$("#row_fromCollections"+f).addClass("middle"),$("#row_toCollections"+f).addClass("last"),$("#row_toCollections"+f).after('')}},calculateEdgeDefinitionMap:function(){var a={};return this.collection.models.forEach(function(b){b.get("edgeDefinitions").forEach(function(b){a[b.collection]={from:b.from,to:b.to}})}),a}})}(),function(){"use strict";window.loginView=Backbone.View.extend({el:"#content",el2:".header",el3:".footer",events:{"submit #loginForm":"login","keypress #loginForm input":"clear","change #loginForm input":"clear"},template:templateEngine.createTemplate("loginView.ejs"),render:function(){return $(this.el).html(this.template.render({})),$(this.el2).hide(),$(this.el3).hide(),$("#loginUsername").focus(),this},clear:function(){$("#loginForm input").removeClass("form-error"),$(".wrong-credentials").hide()},login:function(a){a.preventDefault();var b=$("#loginUsername").val(),c=$("#loginPassword").val();b&&(b=this.collection.login(b,c),b?($(this.el2).show(),$(this.el3).show(),window.location.reload(),$("#currentUser").text(b),this.collection.loadUserSettings()):($("#loginForm input").addClass("form-error"),$(".wrong-credentials").show()))}})}(),function(){"use strict";window.LogsView=window.PaginationView.extend({el:"#content",id:"#logContent",paginationDiv:"#logPaginationDiv",idPrefix:"logTable",fetchedAmount:!1,initialize:function(){this.convertModelToJSON()},currentLoglevel:"logall",events:{"click #arangoLogTabbar button":"setActiveLoglevel","click #logTable_first":"firstPage","click #logTable_last":"lastPage"},template:templateEngine.createTemplate("logsView.ejs"),tabbar:templateEngine.createTemplate("arangoTabbar.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),tabbarElements:{id:"arangoLogTabbar",titles:[["Debug","logdebug"],["Warning","logwarning"],["Error","logerror"],["Info","loginfo"],["All","logall"]]},tableDescription:{id:"arangoLogTable",titles:["Loglevel","Date","Message"],rows:[]},convertedRows:null,setActiveLoglevel:function(a){$(".arangodb-tabbar").removeClass("arango-active-tab"),this.currentLoglevel!==a.currentTarget.id&&(this.currentLoglevel=a.currentTarget.id,this.convertModelToJSON())},initTotalAmount:function(){var a=this;this.collection=this.options[this.currentLoglevel],this.collection.fetch({data:$.param({test:!0}),success:function(){a.convertModelToJSON()}}),this.fetchedAmount=!0},invertArray:function(a){var b,c=[],d=0;for(b=a.length-1;b>=0;b--)c[d]=a[b],d++;return c},convertModelToJSON:function(){if(!this.fetchedAmount)return void this.initTotalAmount();var a,b=this,c=[];this.collection=this.options[this.currentLoglevel],this.collection.fetch({success:function(){b.collection.each(function(b){a=new Date(1e3*b.get("timestamp")),c.push([b.getLogStatus(),arangoHelper.formatDT(a),b.get("text")])}),b.tableDescription.rows=b.invertArray(c),b.render()}})},render:function(){return $(this.el).html(this.template.render({})),$(this.id).html(this.tabbar.render({content:this.tabbarElements})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#"+this.currentLoglevel).addClass("arango-active-tab"),$("#logContent").append('
    '),this.renderPagination(),this},rerender:function(){this.convertModelToJSON()}})}(),function(){"use strict";var a=function(a,b,c,d){return{type:a,title:b,callback:c,confirm:d}},b=function(a,b,c,d,e,f,g,h,i,j,k){var l={type:a,label:b};return void 0!==c&&(l.value=c),void 0!==d&&(l.info=d),void 0!==e&&(l.placeholder=e),void 0!==f&&(l.mandatory=f),void 0!==h&&(l.addDelete=h),void 0!==i&&(l.addAdd=i),void 0!==j&&(l.maxEntrySize=j),void 0!==k&&(l.tags=k),g&&(l.validateInput=function(){return g}),l};window.ModalView=Backbone.View.extend({_validators:[],_validateWatchers:[],baseTemplate:templateEngine.createTemplate("modalBase.ejs"),tableTemplate:templateEngine.createTemplate("modalTable.ejs"),el:"#modalPlaceholder",contentEl:"#modalContent",hideFooter:!1,confirm:{list:"#modal-delete-confirmation",yes:"#modal-confirm-delete",no:"#modal-abort-delete"},enabledHotkey:!1,enableHotKeys:!0,buttons:{SUCCESS:"success",NOTIFICATION:"notification",DELETE:"danger",NEUTRAL:"neutral",CLOSE:"close"},tables:{READONLY:"readonly",TEXT:"text",BLOB:"blob",PASSWORD:"password",SELECT:"select",SELECT2:"select2",CHECKBOX:"checkbox"},initialize:function(){Object.freeze(this.buttons),Object.freeze(this.tables)},createModalHotkeys:function(){$(this.el).unbind("keydown"),$(this.el).unbind("return"),$(this.el).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()}),$(".modal-body input").unbind("keydown"),$(".modal-body input").unbind("return"),$(".modal-body input",$(this.el)).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()}),$(".modal-body select").unbind("keydown"),$(".modal-body select").unbind("return"),$(".modal-body select",$(this.el)).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()})},createInitModalHotkeys:function(){var a=this;$(this.el).bind("keydown","left",function(){a.navigateThroughButtons("left")}),$(this.el).bind("keydown","right",function(){a.navigateThroughButtons("right")})},navigateThroughButtons:function(a){var b=$(".createModalDialog .modal-footer button").is(":focus");b===!1?"left"===a?$(".createModalDialog .modal-footer button").first().focus():"right"===a&&$("..createModalDialog .modal-footer button").last().focus():b===!0&&("left"===a?$(":focus").prev().focus():"right"===a&&$(":focus").next().focus())},createCloseButton:function(b,c){var d=this;return a(this.buttons.CLOSE,b,function(){d.hide(),c&&c()})},createSuccessButton:function(b,c){return a(this.buttons.SUCCESS,b,c)},createNotificationButton:function(b,c){return a(this.buttons.NOTIFICATION,b,c)},createDeleteButton:function(b,c,d){return a(this.buttons.DELETE,b,c,d)},createNeutralButton:function(b,c){return a(this.buttons.NEUTRAL,b,c)},createDisabledButton:function(b){var c=a(this.buttons.NEUTRAL,b);return c.disabled=!0,c},createReadOnlyEntry:function(a,c,d,e,f,g){var h=b(this.tables.READONLY,c,d,e,void 0,void 0,void 0,f,g);return h.id=a,h},createTextEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.TEXT,c,d,e,f,g,h);return i.id=a,i},createBlobEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.BLOB,c,d,e,f,g,h);return i.id=a,i},createSelect2Entry:function(a,c,d,e,f,g,h,i,j,k){var l=b(this.tables.SELECT2,c,d,e,f,g,void 0,h,i,j,k);return l.id=a,l},createPasswordEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.PASSWORD,c,d,e,f,g,h);return i.id=a,i},createCheckboxEntry:function(a,c,d,e,f){var g=b(this.tables.CHECKBOX,c,d,e);return g.id=a,f&&(g.checked=f),g},createSelectEntry:function(a,c,d,e,f){var g=b(this.tables.SELECT,c,null,e);return g.id=a,d&&(g.selected=d),g.options=f,g},createOptionEntry:function(a,b){return{label:a,value:b||a}},show:function(a,b,c,d,e,f,g,h,i){var j,k,l=this,m=!1;c=c||[],h=Boolean(h),this.clearValidators(),c.length>0?(c.forEach(function(a){a.type===l.buttons.CLOSE&&(m=!0),a.type===l.buttons.DELETE&&(k=k||a.confirm)}),m||(j=c.pop(),c.push(l.createCloseButton("Cancel")),c.push(j))):c.push(l.createCloseButton("Close")),$(this.el).html(this.baseTemplate.render({title:b,buttons:c,hideFooter:this.hideFooter,confirm:k,tabBar:i})),_.each(c,function(a,b){return!a.disabled&&a.callback?a.type!==l.buttons.DELETE||h?void $("#modalButton"+b).bind("click",a.callback):void $("#modalButton"+b).bind("click",function(){$(l.confirm.yes).unbind("click"),$(l.confirm.yes).bind("click",a.callback),$(l.confirm.list).css("display","block")}):void 0}),$(this.confirm.no).bind("click",function(){$(l.confirm.list).css("display","none")});var n;if("string"==typeof a)n=templateEngine.createTemplate(a),$(".createModalDialog .modal-body").html(n.render({content:d,advancedContent:e,info:f}));else{var o=0;_.each(a,function(a){n=templateEngine.createTemplate(a),$(".createModalDialog .modal-body .tab-content #"+i[o]).html(n.render({content:d,advancedContent:e,info:f})),o++})}$(".createModalDialog .modalTooltips").tooltip({position:{my:"left top",at:"right+55 top-1"}});var p=d||[];e&&e.content&&(p=p.concat(e.content)),_.each(p,function(a){l.modalBindValidation(a),a.type===l.tables.SELECT2&&$("#"+a.id).select2({tags:a.tags||[],showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:a.maxEntrySize||8})}),g&&(this.events=g,this.delegateEvents()),$("#accordion2")&&($("#accordion2 .accordion-toggle").bind("click",function(){$("#collapseOne").is(":visible")?($("#collapseOne").hide(),setTimeout(function(){$(".accordion-toggle").addClass("collapsed")},100)):($("#collapseOne").show(),setTimeout(function(){$(".accordion-toggle").removeClass("collapsed")},100))}),$("#collapseOne").hide(),setTimeout(function(){$(".accordion-toggle").addClass("collapsed")},100)),$("#modal-dialog").modal("show"),this.enabledHotkey===!1&&(this.createInitModalHotkeys(),this.enabledHotkey=!0),this.enableHotKeys&&this.createModalHotkeys();var q=$("#modal-dialog").find("input");q&&setTimeout(function(){var a=$("#modal-dialog");a.length>0&&(a=a.find("input"),a.length>0&&$(a[0]).focus())},800)},modalBindValidation:function(a){var b=this;if(a.hasOwnProperty("id")&&a.hasOwnProperty("validateInput")){var c=function(){var b=$("#"+a.id),c=a.validateInput(b),d=!1;return _.each(c,function(a){var c=b.val();if(a.rule||(a={rule:a}),"function"==typeof a.rule)try{a.rule(c)}catch(e){d=a.msg||e.message}else{var f=Joi.validate(c,a.rule);f.error&&(d=a.msg||f.error.message)}return d?!1:void 0}),d?d:void 0},d=$("#"+a.id);d.on("keyup focusout",function(){var a=c(),e=d.next()[0];a?(d.addClass("invalid-input"),e?$(e).text(a):d.after('

    '+a+"

    "),$(".createModalDialog .modal-footer .button-success").prop("disabled",!0).addClass("disabled")):(d.removeClass("invalid-input"),e&&$(e).remove(),b.modalTestAll())}),this._validators.push(c),this._validateWatchers.push(d)}},modalTestAll:function(){var a=_.map(this._validators,function(a){return a()}),b=_.any(a);return b?$(".createModalDialog .modal-footer .button-success").prop("disabled",!0).addClass("disabled"):$(".createModalDialog .modal-footer .button-success").prop("disabled",!1).removeClass("disabled"),!b},clearValidators:function(){this._validators=[],_.each(this._validateWatchers,function(a){a.unbind("keyup focusout")}),this._validateWatchers=[]},hide:function(){this.clearValidators(),$("#modal-dialog").modal("hide")}})}(),function(){"use strict";window.NavigationView=Backbone.View.extend({el:"#navigationBar",events:{"change #arangoCollectionSelect":"navigateBySelect","click .tab":"navigateByTab","mouseenter .dropdown > *":"showDropdown","mouseleave .dropdown":"hideDropdown"},initialize:function(){this.userCollection=this.options.userCollection,this.currentDB=this.options.currentDB,this.dbSelectionView=new window.DBSelectionView({collection:this.options.database,current:this.currentDB}),this.userBarView=new window.UserBarView({userCollection:this.userCollection}),this.notificationView=new window.NotificationView({collection:this.options.notificationCollection}),this.statisticBarView=new window.StatisticBarView({currentDB:this.currentDB}),this.handleKeyboardHotkeys()},handleSelectDatabase:function(){this.dbSelectionView.render($("#dbSelect"))},template:templateEngine.createTemplate("navigationView.ejs"),render:function(){return $(this.el).html(this.template.render({currentDB:this.currentDB})),this.dbSelectionView.render($("#dbSelect")),this.notificationView.render($("#notificationBar")),this.userCollection.whoAmI()&&this.userBarView.render(),this.statisticBarView.render($("#statisticBar")),window.App.arangoCollectionsStore.findWhere({name:"arangodbflightsdemo"})||$(".demo-menu").css("display","none"),this},navigateBySelect:function(){var a=$("#arangoCollectionSelect").find("option:selected").val();window.App.navigate(a,{trigger:!0})},handleKeyboardHotkeys:function(){arangoHelper.enableKeyboardHotkeys(!0)},navigateByTab:function(a){var b=a.target||a.srcElement,c=b.id,d=!1;""===c&&(c=$(b).attr("class")),"links"===c?(d=!0,$("#link_dropdown").slideToggle(1),a.preventDefault()):"tools"===c?(d=!0,$("#tools_dropdown").slideToggle(1),a.preventDefault()):"dbselection"===c&&(d=!0,$("#dbs_dropdown").slideToggle(1),a.preventDefault()),d||(window.App.navigate(c,{trigger:!0}),a.preventDefault())},handleSelectNavigation:function(){var a=this;$("#arangoCollectionSelect").change(function(){a.navigateBySelect()})},selectMenuItem:function(a){$(".navlist li").removeClass("active"),a&&$("."+a).addClass("active")},showDropdown:function(a){var b=a.target||a.srcElement,c=b.id;"links"===c||"link_dropdown"===c||"links"===a.currentTarget.id?$("#link_dropdown").fadeIn(1):"tools"===c||"tools_dropdown"===c||"tools"===a.currentTarget.id?$("#tools_dropdown").fadeIn(1):("dbselection"===c||"dbs_dropdown"===c||"dbselection"===a.currentTarget.id)&&$("#dbs_dropdown").fadeIn(1)},hideDropdown:function(a){var b=a.target||a.srcElement;b=$(b).parent(),$("#link_dropdown").fadeOut(1),$("#tools_dropdown").fadeOut(1),$("#dbs_dropdown").fadeOut(1)}})}(),function(){"use strict";window.NotificationView=Backbone.View.extend({events:{"click .navlogo #stat_hd":"toggleNotification","click .notificationItem .fa":"removeNotification","click #removeAllNotifications":"removeAllNotifications"},initialize:function(){this.collection.bind("add",this.renderNotifications.bind(this)),this.collection.bind("remove",this.renderNotifications.bind(this)),this.collection.bind("reset",this.renderNotifications.bind(this))},notificationItem:templateEngine.createTemplate("notificationItem.ejs"),el:"#notificationBar",template:templateEngine.createTemplate("notificationView.ejs"),toggleNotification:function(){var a=this.collection.length;0!==a&&$("#notification_menu").toggle()},removeAllNotifications:function(){$.noty.clearQueue(),$.noty.closeAll(),this.collection.reset(),$("#notification_menu").hide()},removeNotification:function(a){var b=a.target.id;this.collection.get(b).destroy()},renderNotifications:function(a,b,c){if(c&&c.add){var d=this.collection.at(this.collection.length-1),e=d.get("title"),f=3e3;if(d.get("content")&&(e=e+": "+d.get("content")),"error"===d.get("type")&&(f=!1),$.noty.clearQueue(),$.noty.closeAll(),noty({theme:"relax",text:e,template:'
    ',maxVisible:1,closeWith:["click"],type:d.get("type"),layout:"bottom",timeout:f,animation:{open:{height:"show"},close:{height:"hide"},easing:"swing",speed:200}}),"success"===d.get("type"))return void d.destroy()}$("#stat_hd_counter").text(this.collection.length),0===this.collection.length?($("#stat_hd").removeClass("fullNotification"),$("#notification_menu").hide()):$("#stat_hd").addClass("fullNotification"),$(".innerDropdownInnerUL").html(this.notificationItem.render({notifications:this.collection})),$(".notificationInfoIcon").tooltip({position:{my:"left top",at:"right+55 top-1"}})},render:function(){return $(this.el).html(this.template.render({notifications:this.collection})),this.renderNotifications(),this.delegateEvents(),this.el}})}(),function(){"use strict";window.ProgressView=Backbone.View.extend({template:templateEngine.createTemplate("progressBase.ejs"),el:"#progressPlaceholder",el2:"#progressPlaceholderIcon",toShow:!1,lastDelay:0,action:function(){},events:{"click .progress-action button":"performAction"},performAction:function(){this.action(),window.progressView.hide()},initialize:function(){},showWithDelay:function(a,b,c,d){var e=this;e.toShow=!0,e.lastDelay=a,setTimeout(function(){e.toShow===!0&&e.show(b,c,d)},e.lastDelay)},show:function(a,b,c){$(this.el).html(this.template.render({})),$(".progress-text").text(a),c?$(".progress-action").html('"):$(".progress-action").html(''),b?this.action=b:this.action=this.hide(),$(this.el).show()},hide:function(){var a=this;a.toShow=!1,$(this.el).hide(),this.action=function(){}}})}(),function(){"use strict";window.queryManagementView=Backbone.View.extend({el:"#content",id:"#queryManagementContent",templateActive:templateEngine.createTemplate("queryManagementViewActive.ejs"),templateSlow:templateEngine.createTemplate("queryManagementViewSlow.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),tabbar:templateEngine.createTemplate("arangoTabbar.ejs"),initialize:function(){this.activeCollection=new window.QueryManagementActive,this.slowCollection=new window.QueryManagementSlow,this.convertModelToJSON(!0)},events:{"click #arangoQueryManagementTabbar button":"switchTab","click #deleteSlowQueryHistory":"deleteSlowQueryHistoryModal","click #arangoQueryManagementTable .fa-minus-circle":"deleteRunningQueryModal"},tabbarElements:{id:"arangoQueryManagementTabbar",titles:[["Active","activequeries"],["Slow","slowqueries"]]},tableDescription:{id:"arangoQueryManagementTable",titles:["ID","Query String","Runtime","Started",""],rows:[],unescaped:[!1,!1,!1,!1,!0]},switchTab:function(a){"activequeries"===a.currentTarget.id?this.convertModelToJSON(!0):"slowqueries"===a.currentTarget.id&&this.convertModelToJSON(!1)},deleteRunningQueryModal:function(a){this.killQueryId=$(a.currentTarget).attr("data-id");var b=[],c=[];c.push(window.modalView.createReadOnlyEntry(void 0,"Running Query","Do you want to kill the running query?",void 0,void 0,!1,void 0)),b.push(window.modalView.createDeleteButton("Kill",this.killRunningQuery.bind(this))),window.modalView.show("modalTable.ejs","Kill Running Query",b,c),$(".modal-delete-confirmation strong").html("Really kill?")},killRunningQuery:function(){this.collection.killRunningQuery(this.killQueryId,this.killRunningQueryCallback.bind(this)),window.modalView.hide()},killRunningQueryCallback:function(){this.convertModelToJSON(!0),this.renderActive()},deleteSlowQueryHistoryModal:function(){var a=[],b=[];b.push(window.modalView.createReadOnlyEntry(void 0,"Slow Query Log","Do you want to delete the slow query log entries?",void 0,void 0,!1,void 0)),a.push(window.modalView.createDeleteButton("Delete",this.deleteSlowQueryHistory.bind(this))),window.modalView.show("modalTable.ejs","Delete Slow Query Log",a,b)},deleteSlowQueryHistory:function(){this.collection.deleteSlowQueryHistory(this.slowQueryCallback.bind(this)),window.modalView.hide()},slowQueryCallback:function(){this.convertModelToJSON(!1),this.renderSlow()},render:function(){this.convertModelToJSON(!0)},renderActive:function(){this.$el.html(this.templateActive.render({})),$(this.id).html(this.tabbar.render({content:this.tabbarElements})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#activequeries").addClass("arango-active-tab")},renderSlow:function(){this.$el.html(this.templateSlow.render({})),$(this.id).html(this.tabbar.render({content:this.tabbarElements})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#slowqueries").addClass("arango-active-tab")},convertModelToJSON:function(a){var b=this,c=[];a===!0?this.collection=this.activeCollection:this.collection=this.slowCollection,this.collection.fetch({success:function(){b.collection.each(function(b){var d="";a&&(d=''),c.push([b.get("id"),b.get("query"),b.get("runTime").toFixed(2)+" s",b.get("started"),d])});var d="No running queries.";a||(d="No slow queries."),0===c.length&&c.push([d,"","",""]),b.tableDescription.rows=c,a?b.renderActive():b.renderSlow()}})}})}(),function(){"use strict";window.queryView=Backbone.View.extend({el:"#content",id:"#customsDiv",warningTemplate:templateEngine.createTemplate("warningList.ejs"),tabArray:[],execPending:!1,initialize:function(){this.refreshAQL(),this.tableDescription.rows=this.customQueries},events:{"click #result-switch":"switchTab","click #query-switch":"switchTab","click #customs-switch":"switchTab","click #submitQueryButton":"submitQuery","click #explainQueryButton":"explainQuery","click #commentText":"commentText","click #uncommentText":"uncommentText","click #undoText":"undoText","click #redoText":"redoText","click #smallOutput":"smallOutput","click #bigOutput":"bigOutput","click #clearOutput":"clearOutput","click #clearInput":"clearInput","click #clearQueryButton":"clearInput","click #addAQL":"addAQL","mouseover #querySelect":function(){this.refreshAQL(!0)},"change #querySelect":"importSelected","keypress #aqlEditor":"aqlShortcuts","click #arangoQueryTable .table-cell0":"editCustomQuery","click #arangoQueryTable .table-cell1":"editCustomQuery","click #arangoQueryTable .table-cell2 a":"deleteAQL","click #confirmQueryImport":"importCustomQueries","click #confirmQueryExport":"exportCustomQueries","click #export-query":"exportCustomQueries","click #import-query":"openExportDialog","click #closeQueryModal":"closeExportDialog","click #downloadQueryResult":"downloadQueryResult"},openExportDialog:function(){$("#queryImportDialog").modal("show")},closeExportDialog:function(){$("#queryImportDialog").modal("hide")},createCustomQueryModal:function(){var a=[],b=[];b.push(window.modalView.createTextEntry("new-query-name","Name","",void 0,void 0,!1,[{rule:Joi.string().required(),msg:"No query name given."}])),a.push(window.modalView.createSuccessButton("Save",this.saveAQL.bind(this))),window.modalView.show("modalTable.ejs","Save Query",a,b,void 0,void 0,{"keyup #new-query-name":this.listenKey.bind(this)})},updateTable:function(){this.tableDescription.rows=this.customQueries,_.each(this.tableDescription.rows,function(a){a.thirdRow='',a.hasOwnProperty("parameter")&&delete a.parameter}),this.tableDescription.unescaped=[!1,!1,!0],this.$(this.id).html(this.table.render({content:this.tableDescription}))},editCustomQuery:function(a){var b=$(a.target).parent().children().first().text(),c=ace.edit("aqlEditor"),d=ace.edit("varsEditor");c.setValue(this.getCustomQueryValueByName(b)),d.setValue(JSON.stringify(this.getCustomQueryParameterByName(b))),this.deselect(d),this.deselect(c),$("#querySelect").val(b),this.switchTab("query-switch")},initTabArray:function(){var a=this;$(".arango-tab").children().each(function(){a.tabArray.push($(this).children().first().attr("id"))})},listenKey:function(a){13===a.keyCode&&this.saveAQL(a),this.checkSaveName()},checkSaveName:function(){var a=$("#new-query-name").val();if("Insert Query"===a)return void $("#new-query-name").val("");var b=this.customQueries.some(function(b){return b.name===a});b?($("#modalButton1").removeClass("button-success"),$("#modalButton1").addClass("button-warning"),$("#modalButton1").text("Update")):($("#modalButton1").removeClass("button-warning"),$("#modalButton1").addClass("button-success"),$("#modalButton1").text("Save"))},clearOutput:function(){var a=ace.edit("queryOutput");a.setValue("")},clearInput:function(){var a=ace.edit("aqlEditor"),b=ace.edit("varsEditor");this.setCachedQuery(a.getValue(),b.getValue()),a.setValue(""),b.setValue("")},smallOutput:function(){var a=ace.edit("queryOutput");a.getSession().foldAll()},bigOutput:function(){var a=ace.edit("queryOutput");a.getSession().unfold()},aqlShortcuts:function(a){a.ctrlKey&&13===a.keyCode?this.submitQuery():a.metaKey&&!a.ctrlKey&&13===a.keyCode&&this.submitQuery()},queries:[],customQueries:[],tableDescription:{id:"arangoQueryTable",titles:["Name","Content",""],rows:[]},template:templateEngine.createTemplate("queryView.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),render:function(){var a=this;this.$el.html(this.template.render({})),this.$(this.id).html(this.table.render({content:this.tableDescription}));var b=1e3,c=$("#querySize");c.empty(),[100,250,500,1e3,2500,5e3,1e4,"all"].forEach(function(a){c.append('")});var d=ace.edit("queryOutput");d.setReadOnly(!0),d.setHighlightActiveLine(!1),d.getSession().setMode("ace/mode/json"),d.setFontSize("13px"),d.setValue("");var e=ace.edit("aqlEditor");e.getSession().setMode("ace/mode/aql"),e.setFontSize("13px"),e.commands.addCommand({name:"togglecomment",bindKey:{win:"Ctrl-Shift-C",linux:"Ctrl-Shift-C",mac:"Command-Shift-C"},exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEach"});var f=ace.edit("varsEditor");f.getSession().setMode("ace/mode/aql"),f.setFontSize("13px"),f.commands.addCommand({name:"togglecomment",bindKey:{win:"Ctrl-Shift-C",linux:"Ctrl-Shift-C",mac:"Command-Shift-C"},exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEach"});var g=this.getCachedQuery();null!==g&&void 0!==g&&""!==g&&(e.setValue(g.query),""===g.parameter||void 0===g?f.setValue("{}"):f.setValue(g.parameter));var h=function(){var b=e.getSession(),c=e.getCursorPosition(),d=b.getTokenAt(c.row,c.column);d&&("comment"===d.type?$("#commentText i").removeClass("fa-comment").addClass("fa-comment-o").attr("data-original-title","Uncomment"):$("#commentText i").removeClass("fa-comment-o").addClass("fa-comment").attr("data-original-title","Comment"));var g=e.getValue(),h=f.getValue();1===g.length&&(g=""),1===h.length&&(h=""),a.setCachedQuery(g,h)};e.getSession().selection.on("changeCursor",function(){h()}),f.getSession().selection.on("changeCursor",function(){h()}),$("#queryOutput").resizable({handles:"s",ghost:!0,stop:function(){setTimeout(function(){var a=ace.edit("queryOutput");a.resize()},200)}}),arangoHelper.fixTooltips(".vars-editor-header i, .queryTooltips, .icon_arangodb","top"),$("#aqlEditor .ace_text-input").focus();var i=$(window).height()-295;return $("#aqlEditor").height(i-100-29),$("#varsEditor").height(100),$("#queryOutput").height(i),e.resize(),d.resize(),this.initTabArray(),this.renderSelectboxes(),this.deselect(f),this.deselect(d),this.deselect(e),$("#queryDiv").show(),$("#customsDiv").show(),this.initQueryImport(),this.switchTab("query-switch"),this},getCachedQuery:function(){if("undefined"!==Storage){var a=localStorage.getItem("cachedQuery");if(void 0!==a){var b=JSON.parse(a);return b}}},setCachedQuery:function(a,b){if("undefined"!==Storage){var c={query:a,parameter:b};localStorage.setItem("cachedQuery",JSON.stringify(c))}},initQueryImport:function(){var a=this;a.allowUpload=!1,$("#importQueries").change(function(b){a.files=b.target.files||b.dataTransfer.files,a.file=a.files[0],a.allowUpload=!0,$("#confirmQueryImport").removeClass("disabled")})},importCustomQueries:function(){var a=this;if(this.allowUpload===!0){var b=function(){this.collection.fetch({ -async:!1}),this.updateLocalQueries(),this.renderSelectboxes(),this.updateTable(),a.allowUpload=!1,$("#customs-switch").click()};a.collection.saveImportQueries(a.file,b.bind(this)),$("#confirmQueryImport").addClass("disabled"),$("#queryImportDialog").modal("hide")}},downloadQueryResult:function(){var a=ace.edit("aqlEditor"),b=a.getValue();""!==b||void 0!==b||null!==b?window.open("query/result/download/"+encodeURIComponent(btoa(JSON.stringify({query:b})))):arangoHelper.arangoError("Query error","could not query result.")},exportCustomQueries:function(){var a,b={},c=[];_.each(this.customQueries,function(a){c.push({name:a.name,value:a.value,parameter:a.parameter})}),b={extra:{queries:c}},$.ajax("whoAmI?_="+Date.now(),{async:!1}).done(function(b){a=b.user,(null===a||a===!1)&&(a="root")}),window.open("query/download/"+encodeURIComponent(a))},deselect:function(a){var b=a.getSelection(),c=b.lead.row,d=b.lead.column;b.setSelectionRange({start:{row:c,column:d},end:{row:c,column:d}}),a.focus()},addAQL:function(){this.refreshAQL(!0),this.createCustomQueryModal(),$("#new-query-name").val($("#querySelect").val()),setTimeout(function(){$("#new-query-name").focus()},500),this.checkSaveName()},getAQL:function(){var a,b=this;this.collection.fetch({async:!1});var c=localStorage.getItem("customQueries");if(c){var d=JSON.parse(c);_.each(d,function(a){b.collection.add({value:a.value,name:a.name})}),a=b.collection.saveCollectionQueries(),a===!0&&localStorage.removeItem("customQueries")}this.updateLocalQueries()},deleteAQL:function(a){var b=$(a.target).parent().parent().parent().children().first().text(),c=this.collection.findWhere({name:b});this.collection.remove(c),this.collection.saveCollectionQueries(),this.updateLocalQueries(),this.renderSelectboxes(),this.updateTable()},updateLocalQueries:function(){var a=this;this.customQueries=[],this.collection.each(function(b){a.customQueries.push({name:b.get("name"),value:b.get("value"),parameter:b.get("parameter")})})},saveAQL:function(a){a.stopPropagation(),this.refreshAQL();var b=ace.edit("aqlEditor"),c=ace.edit("varsEditor"),d=$("#new-query-name").val(),e=c.getValue();if(!$("#new-query-name").hasClass("invalid-input")&&""!==d.trim()){var f=b.getValue(),g=!1;if($.each(this.customQueries,function(a,b){return b.name===d?(b.value=f,void(g=!0)):void 0}),g===!0)this.collection.findWhere({name:d}).set("value",f);else{if((""===e||void 0===e)&&(e="{}"),"string"==typeof e)try{e=JSON.parse(e)}catch(h){console.log("could not parse bind parameter")}this.collection.add({name:d,parameter:e,value:f})}this.collection.saveCollectionQueries(),window.modalView.hide(),this.updateLocalQueries(),this.renderSelectboxes(),$("#querySelect").val(d)}},getSystemQueries:function(){var a=this;$.ajax({type:"GET",cache:!1,url:"js/arango/aqltemplates.json",contentType:"application/json",processData:!1,async:!1,success:function(b){a.queries=b},error:function(){arangoHelper.arangoNotification("Query","Error while loading system templates")}})},getCustomQueryValueByName:function(a){return this.collection.findWhere({name:a}).get("value")},getCustomQueryParameterByName:function(a){return this.collection.findWhere({name:a}).get("parameter")},refreshAQL:function(a){if(this.getAQL(),this.getSystemQueries(),this.updateLocalQueries(),a){var b=$("#querySelect").val();this.renderSelectboxes(),$("#querySelect").val(b)}},importSelected:function(a){var b=ace.edit("aqlEditor"),c=ace.edit("varsEditor");$.each(this.queries,function(d,e){$("#"+a.currentTarget.id).val()===e.name&&(b.setValue(e.value),e.hasOwnProperty("parameter")?((""===e.parameter||void 0===e.parameter)&&(e.parameter="{}"),"object"==typeof e.parameter?c.setValue(JSON.stringify(e.parameter)):c.setValue(e.parameter)):c.setValue("{}"))}),$.each(this.customQueries,function(d,e){$("#"+a.currentTarget.id).val()===e.name&&(b.setValue(e.value),e.hasOwnProperty("parameter")?((""===e.parameter||void 0===e.parameter)&&(e.parameter="{}"),c.setValue(e.parameter)):c.setValue("{}"))}),this.deselect(ace.edit("varsEditor")),this.deselect(ace.edit("aqlEditor"))},renderSelectboxes:function(){this.sortQueries();var a="";a="#querySelect",$(a).empty(),$(a).append(''),$(a).append(''),jQuery.each(this.queries,function(b,c){$(a).append('")}),$(a).append(""),this.customQueries.length>0&&($(a).append(''),jQuery.each(this.customQueries,function(b,c){$(a).append('")}),$(a).append(""))},undoText:function(){var a=ace.edit("aqlEditor");a.undo()},redoText:function(){var a=ace.edit("aqlEditor");a.redo()},commentText:function(){var a=ace.edit("aqlEditor");a.toggleCommentLines()},sortQueries:function(){this.queries=_.sortBy(this.queries,"name"),this.customQueries=_.sortBy(this.customQueries,"name")},readQueryData:function(){var a=ace.edit("aqlEditor"),b=ace.edit("varsEditor"),c=a.session.getTextRange(a.getSelectionRange()),d=$("#querySize"),e={query:c||a.getValue(),id:"currentFrontendQuery"};"all"!==d.val()&&(e.batchSize=parseInt(d.val(),10));var f=b.getValue();if(f.length>0)try{var g=JSON.parse(f);0!==Object.keys(g).length&&(e.bindVars=g)}catch(h){return arangoHelper.arangoError("Query error","Could not parse bind parameters."),!1}return JSON.stringify(e)},heatmapColors:["#313695","#4575b4","#74add1","#abd9e9","#e0f3f8","#ffffbf","#fee090","#fdae61","#f46d43","#d73027","#a50026"],heatmap:function(a){return this.heatmapColors[Math.floor(10*a)]},followQueryPath:function(a,b){var c={},d=0;c[b[0].id]=a;var e,f,g,h;for(e=1;e0&&(b+="Warnings:\r\n\r\n",a.extra.warnings.forEach(function(a){b+="["+a.code+"], '"+a.message+"'\r\n"})),""!==b&&(b+="\r\nResult:\r\n\r\n"),d.setValue(b+JSON.stringify(a.result,void 0,2))},g=function(a){f(a),c.switchTab("result-switch"),window.progressView.hide();var e="Execution time: "+c.timer.getTimeAndReset()/1e3+" s";$(".queryExecutionTime").text(e),c.deselect(d),$("#downloadQueryResult").show(),"function"==typeof b&&b()},h=function(){$.ajax({type:"PUT",url:"/_api/job/"+encodeURIComponent(a),contentType:"application/json",processData:!1,success:function(a,b,d){201===d.status?g(a):204===d.status&&(c.checkQueryTimer=window.setTimeout(function(){h()},500))},error:function(a){try{var b=JSON.parse(a.responseText);b.errorMessage&&arangoHelper.arangoError("Query",b.errorMessage)}catch(c){arangoHelper.arangoError("Query","Something went wrong.")}window.progressView.hide()}})};h()},fillResult:function(a){var b=this,c=ace.edit("queryOutput");c.setValue("");var d=this.readQueryData();d&&$.ajax({type:"POST",url:"/_api/cursor",headers:{"x-arango-async":"store"},data:d,contentType:"application/json",processData:!1,success:function(c,d,e){e.getResponseHeader("x-arango-async-id")&&b.queryCallbackFunction(e.getResponseHeader("x-arango-async-id"),a)},error:function(d){b.switchTab("result-switch"),$("#downloadQueryResult").hide();try{var e=JSON.parse(d.responseText);c.setValue("["+e.errorNum+"] "+e.errorMessage)}catch(f){c.setValue("ERROR"),arangoHelper.arangoError("Query error","ERROR")}window.progressView.hide(),"function"==typeof a&&a()}})},submitQuery:function(){var a=ace.edit("queryOutput");this.fillResult(this.switchTab.bind(this,"result-switch")),a.resize();var b=ace.edit("aqlEditor");this.deselect(b),$("#downloadQueryResult").show()},explainQuery:function(){this.fillExplain()},switchTab:function(a){var b;b="string"==typeof a?a:a.target.id;var c=this,d=function(a){var d="#"+a.replace("-switch",""),e="#tabContent"+d.charAt(1).toUpperCase()+d.substr(2);a===b?($("#"+a).parent().addClass("active"),$(d).addClass("active"),$(e).show(),"query-switch"===b?$("#aqlEditor .ace_text-input").focus():"result-switch"===b&&c.execPending&&c.fillResult()):($("#"+a).parent().removeClass("active"),$(d).removeClass("active"),$(e).hide())};this.tabArray.forEach(d),this.updateTable()}})}(),function(){"use strict";window.shellView=Backbone.View.extend({resizing:!1,el:"#content",template:templateEngine.createTemplate("shellView.ejs"),render:function(){$(this.el).html(this.template.render({})),this.replShell(),$("#shell_workspace").trigger("resize",[150]),this.resize();var a=this;return $(window).resize(function(){a.resize()}),this.executeJs("start_pretty_print(); try { db._collections(); } catch (err) { } undefined;"),this},resize:function(){if(!this.resizing){this.resizing=!0;var a=$(window).height()-250;$("#shell_workspace").height(a),this.resizing=!1}},executeJs:function(a){var b=require("internal");try{var c=window.eval(a);void 0!==c&&(b.browserOutputBuffer="",b.printShell(c),jqconsole.Write("==> "+b.browserOutputBuffer+"\n","jssuccess")),b.browserOutputBuffer=""}catch(d){d instanceof b.ArangoError?d.hasOwnProperty("errorMessage")?jqconsole.Write(d.errorMessage+"\n","jserror"):jqconsole.Write(d.message+"\n","jserror"):jqconsole.Write(d.name+": "+d.message+"\n","jserror")}},replShellPromptHelper:function(a){try{new Function(a)}catch(b){return/[\[\{\(]$/.test(a)?1:0}return!1},replShellHandlerHelper:function(a){},replShell:function(){var a=this,b=require("internal"),c=require("@arangodb/arangosh"),d="Welcome to arangosh. Copyright (c) ArangoDB GmbH\n";window.jqconsole=$("#replShell").jqconsole(d,"JSH> ","...>"),this.executeJs(b.print(c.HELP)),jqconsole.RegisterShortcut("Z",function(){jqconsole.AbortPrompt(),e()}),jqconsole.RegisterShortcut("E",function(){jqconsole.MoveToEnd(),e()}),jqconsole.RegisterMatching("{","}","brace"),jqconsole.RegisterMatching("(",")","paren"),jqconsole.RegisterMatching("[","]","bracket");var e=function(b){"help"===b&&(b=help()),"exit"===b&&location.reload(),a.executeJs(b),jqconsole.Prompt(!0,e,a.replShellPromptHelper(b))};e()}})}(),function(){"use strict";window.StatisticBarView=Backbone.View.extend({el:"#statisticBar",events:{"change #arangoCollectionSelect":"navigateBySelect","click .tab":"navigateByTab"},template:templateEngine.createTemplate("statisticBarView.ejs"),initialize:function(){this.currentDB=this.options.currentDB},replaceSVG:function(a){var b=a.attr("id"),c=a.attr("class"),d=a.attr("src");$.get(d,function(d){var e=$(d).find("svg");void 0===b&&(e=e.attr("id",b)),void 0===c&&(e=e.attr("class",c+" replaced-svg")),e=e.removeAttr("xmlns:a"),a.replaceWith(e)},"xml")},render:function(){var a=this;return $(this.el).html(this.template.render({isSystem:this.currentDB.get("isSystem")})),$("img.svg").each(function(){a.replaceSVG($(this))}),this},navigateBySelect:function(){var a=$("#arangoCollectionSelect").find("option:selected").val();window.App.navigate(a,{trigger:!0})},navigateByTab:function(a){var b=a.target||a.srcElement,c=b.id;return"links"===c?($("#link_dropdown").slideToggle(200),void a.preventDefault()):"tools"===c?($("#tools_dropdown").slideToggle(200),void a.preventDefault()):(window.App.navigate(c,{trigger:!0}),void a.preventDefault())},handleSelectNavigation:function(){$("#arangoCollectionSelect").change(function(){var a=$(this).find("option:selected").val();window.App.navigate(a,{trigger:!0})})},selectMenuItem:function(a){$(".navlist li").removeClass("active"),a&&$("."+a).addClass("active")}})}(),function(){"use strict";window.TableView=Backbone.View.extend({template:templateEngine.createTemplate("tableView.ejs"),loading:templateEngine.createTemplate("loadingTableView.ejs"),initialize:function(){this.rowClickCallback=this.options.rowClick},events:{"click tbody tr":"rowClick","click .deleteButton":"removeClick"},rowClick:function(a){this.hasOwnProperty("rowClickCallback")&&this.rowClickCallback(a)},removeClick:function(a){this.hasOwnProperty("removeClickCallback")&&(this.removeClickCallback(a),a.stopPropagation())},setRowClick:function(a){this.rowClickCallback=a},setRemoveClick:function(a){this.removeClickCallback=a},render:function(){$(this.el).html(this.template.render({docs:this.collection}))},drawLoading:function(){$(this.el).html(this.loading.render({}))}})}(),function(){"use strict";window.testView=Backbone.View.extend({el:"#content",graph:{edges:[],nodes:[]},events:{},initialize:function(){console.log(void 0)},template:templateEngine.createTemplate("testView.ejs"),render:function(){return $(this.el).html(this.template.render({})),this.renderGraph(),this},renderGraph:function(){this.convertData(),console.log(this.graph),this.s=new sigma({graph:this.graph,container:"graph-container",verbose:!0,renderers:[{container:document.getElementById("graph-container"),type:"webgl"}]})},convertData:function(){var a=this;return _.each(this.dump,function(b){_.each(b.p,function(c){a.graph.nodes.push({id:c.verticesvalue.v._id,label:b.v._key,x:Math.random(),y:Math.random(),size:Math.random()}),a.graph.edges.push({id:b.e._id,source:b.e._from,target:b.e._to})})}),null},dump:[{v:{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},e:{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"}]}},{v:{label:"8",_id:"circles/H",_rev:"1841664067459",_key:"H"},e:{theFalse:!1,theTruth:!0,label:"right_blob",_id:"edges/1841666295683",_rev:"1841666295683",_key:"1841666295683",_from:"circles/G",_to:"circles/H"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},{label:"8",_id:"circles/H",_rev:"1841664067459",_key:"H"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},{theFalse:!1,theTruth:!0,label:"right_blob",_id:"edges/1841666295683",_rev:"1841666295683",_key:"1841666295683",_from:"circles/G",_to:"circles/H"}]}},{v:{label:"9",_id:"circles/I",_rev:"1841664264067",_key:"I"},e:{theFalse:!1,theTruth:!0,label:"right_blub",_id:"edges/1841666492291",_rev:"1841666492291",_key:"1841666492291",_from:"circles/H",_to:"circles/I"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},{label:"8",_id:"circles/H",_rev:"1841664067459",_key:"H"},{label:"9",_id:"circles/I",_rev:"1841664264067",_key:"I"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},{theFalse:!1,theTruth:!0,label:"right_blob",_id:"edges/1841666295683",_rev:"1841666295683",_key:"1841666295683",_from:"circles/G",_to:"circles/H"},{theFalse:!1,theTruth:!0,label:"right_blub",_id:"edges/1841666492291",_rev:"1841666492291",_key:"1841666492291",_from:"circles/H",_to:"circles/I"}]}},{v:{label:"10",_id:"circles/J",_rev:"1841664460675",_key:"J"},e:{theFalse:!1,theTruth:!0,label:"right_zip",_id:"edges/1841666688899",_rev:"1841666688899",_key:"1841666688899",_from:"circles/G",_to:"circles/J"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},{label:"10",_id:"circles/J",_rev:"1841664460675",_key:"J"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},{theFalse:!1,theTruth:!0,label:"right_zip",_id:"edges/1841666688899",_rev:"1841666688899",_key:"1841666688899",_from:"circles/G",_to:"circles/J"}]}},{v:{label:"11",_id:"circles/K",_rev:"1841664657283",_key:"K"},e:{theFalse:!1,theTruth:!0,label:"right_zup",_id:"edges/1841666885507",_rev:"1841666885507",_key:"1841666885507",_from:"circles/J",_to:"circles/K"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},{label:"10",_id:"circles/J",_rev:"1841664460675",_key:"J"},{label:"11",_id:"circles/K",_rev:"1841664657283",_key:"K"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},{theFalse:!1,theTruth:!0,label:"right_zip",_id:"edges/1841666688899",_rev:"1841666688899",_key:"1841666688899",_from:"circles/G",_to:"circles/J"},{theFalse:!1,theTruth:!0,label:"right_zup",_id:"edges/1841666885507",_rev:"1841666885507",_key:"1841666885507",_from:"circles/J",_to:"circles/K"}]}},{v:{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},e:{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"}]}},{v:{label:"5",_id:"circles/E",_rev:"1841663477635",_key:"E"},e:{theFalse:!1,theTruth:!0,label:"left_blub",_id:"edges/1841665705859",_rev:"1841665705859",_key:"1841665705859",_from:"circles/B",_to:"circles/E"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},{label:"5",_id:"circles/E",_rev:"1841663477635",_key:"E"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},{theFalse:!1,theTruth:!0,label:"left_blub",_id:"edges/1841665705859",_rev:"1841665705859",_key:"1841665705859",_from:"circles/B",_to:"circles/E"}]}},{v:{label:"6",_id:"circles/F",_rev:"1841663674243",_key:"F"},e:{theFalse:!1,theTruth:!0,label:"left_schubi",_id:"edges/1841665902467",_rev:"1841665902467",_key:"1841665902467",_from:"circles/E",_to:"circles/F"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},{label:"5",_id:"circles/E",_rev:"1841663477635",_key:"E"},{label:"6",_id:"circles/F",_rev:"1841663674243",_key:"F"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},{theFalse:!1,theTruth:!0,label:"left_blub",_id:"edges/1841665705859",_rev:"1841665705859",_key:"1841665705859",_from:"circles/B",_to:"circles/E"},{theFalse:!1,theTruth:!0,label:"left_schubi",_id:"edges/1841665902467",_rev:"1841665902467",_key:"1841665902467",_from:"circles/E",_to:"circles/F"}]}},{v:{label:"3",_id:"circles/C",_rev:"1841663084419",_key:"C"},e:{theFalse:!1,theTruth:!0,label:"left_blarg",_id:"edges/1841665312643",_rev:"1841665312643",_key:"1841665312643",_from:"circles/B",_to:"circles/C"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},{label:"3",_id:"circles/C",_rev:"1841663084419",_key:"C"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},{theFalse:!1,theTruth:!0,label:"left_blarg",_id:"edges/1841665312643",_rev:"1841665312643",_key:"1841665312643",_from:"circles/B",_to:"circles/C"}]}},{v:{label:"4",_id:"circles/D",_rev:"1841663281027",_key:"D"},e:{theFalse:!1,theTruth:!0,label:"left_blorg",_id:"edges/1841665509251",_rev:"1841665509251",_key:"1841665509251",_from:"circles/C",_to:"circles/D"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},{label:"3",_id:"circles/C",_rev:"1841663084419",_key:"C"},{label:"4",_id:"circles/D",_rev:"1841663281027",_key:"D"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},{theFalse:!1,theTruth:!0,label:"left_blarg",_id:"edges/1841665312643",_rev:"1841665312643",_key:"1841665312643",_from:"circles/B",_to:"circles/C"},{theFalse:!1,theTruth:!0,label:"left_blorg",_id:"edges/1841665509251",_rev:"1841665509251",_key:"1841665509251",_from:"circles/C",_to:"circles/D"}]}}]})}(),function(){"use strict";window.UserBarView=Backbone.View.extend({events:{"change #userBarSelect":"navigateBySelect","click .tab":"navigateByTab","mouseenter .dropdown":"showDropdown","mouseleave .dropdown":"hideDropdown","click #userLogout":"userLogout"},initialize:function(){this.userCollection=this.options.userCollection,this.userCollection.fetch({async:!1}),this.userCollection.bind("change:extra",this.render.bind(this))},template:templateEngine.createTemplate("userBarView.ejs"),navigateBySelect:function(){var a=$("#arangoCollectionSelect").find("option:selected").val();window.App.navigate(a,{trigger:!0})},navigateByTab:function(a){var b=a.target||a.srcElement;b=$(b).closest("a");var c=b.attr("id");return"user"===c?($("#user_dropdown").slideToggle(200),void a.preventDefault()):(window.App.navigate(c,{trigger:!0}),void a.preventDefault())},showDropdown:function(){$("#user_dropdown").fadeIn(1)},hideDropdown:function(){$("#user_dropdown").fadeOut(1)},render:function(){var a=this.userCollection.whoAmI(),b=null,c=null,d=!1,e=null;return a&&(e=this.userCollection.findWhere({user:a}),e.set({loggedIn:!0}),c=e.get("extra").name,b=e.get("extra").img,d=e.get("active")),b=b?"https://s.gravatar.com/avatar/"+b+"?s=24":"img/default_user.png",c||(c=""),this.$el=$("#userBar"),this.$el.html(this.template.render({img:b,name:c,username:a,active:d})),this.delegateEvents(),this.$el},userLogout:function(){this.userCollection.whoAmI(),this.userCollection.logout()}})}(),function(){"use strict";window.userManagementView=Backbone.View.extend({el:"#content",el2:"#userManagementThumbnailsIn",template:templateEngine.createTemplate("userManagementView.ejs"),events:{"click #createUser":"createUser","click #submitCreateUser":"submitCreateUser","click #userManagementThumbnailsIn .tile":"editUser","click #submitEditUser":"submitEditUser","click #userManagementToggle":"toggleView","keyup #userManagementSearchInput":"search","click #userManagementSearchSubmit":"search","click #callEditUserPassword":"editUserPassword","click #submitEditUserPassword":"submitEditUserPassword","click #submitEditCurrentUserProfile":"submitEditCurrentUserProfile","click .css-label":"checkBoxes","change #userSortDesc":"sorting"},dropdownVisible:!1,initialize:function(){this.collection.fetch({async:!1}),this.currentUser=this.collection.findWhere({user:this.collection.whoAmI()})},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},sorting:function(){$("#userSortDesc").is(":checked")?this.collection.setSortingDesc(!0):this.collection.setSortingDesc(!1),$("#userManagementDropdown").is(":visible")?this.dropdownVisible=!0:this.dropdownVisible=!1,this.render()},render:function(a){var b=!1;return $("#userManagementDropdown").is(":visible")&&(b=!0),this.collection.sort(),$(this.el).html(this.template.render({collection:this.collection,searchString:""})),b===!0&&($("#userManagementDropdown2").show(),$("#userSortDesc").attr("checked",this.collection.sortOptions.desc),$("#userManagementToggle").toggleClass("activated"),$("#userManagementDropdown").show()),a&&this.editCurrentUser(),arangoHelper.setCheckboxStatus("#userManagementDropdown"),this},search:function(){var a,b,c,d;a=$("#userManagementSearchInput"),b=$("#userManagementSearchInput").val(),d=this.collection.filter(function(a){return-1!==a.get("user").indexOf(b)}),$(this.el).html(this.template.render({collection:d,searchString:b})),a=$("#userManagementSearchInput"),c=a.val().length,a.focus(),a[0].setSelectionRange(c,c)},createUser:function(a){a.preventDefault(),this.createCreateUserModal()},submitCreateUser:function(){var a=this,b=$("#newUsername").val(),c=$("#newName").val(),d=$("#newPassword").val(),e=$("#newStatus").is(":checked");if(this.validateUserInfo(c,b,d,e)){var f={user:b,passwd:d,active:e,extra:{name:c}};this.collection.create(f,{wait:!0,error:function(a,b){},success:function(b){a.updateUserManagement(),window.modalView.hide()}})}},validateUserInfo:function(a,b,c,d){return""===b?(arangoHelper.arangoError("You have to define an username"),$("#newUsername").closest("th").css("backgroundColor","red"),!1):!0},updateUserManagement:function(){var a=this;this.collection.fetch({success:function(){a.render()}})},submitDeleteUser:function(a){var b=this.collection.findWhere({user:a});b.destroy({wait:!0}),window.modalView.hide(),this.updateUserManagement()},editUser:function(a){$(a.currentTarget).hasClass("tile")&&(a.currentTarget=$(a.currentTarget).find("img")),this.collection.fetch();var b=this.evaluateUserName($(a.currentTarget).attr("id"),"_edit-user");""===b&&(b=$(a.currentTarget).attr("id"));var c=this.collection.findWhere({user:b});c.get("loggedIn")?this.editCurrentUser():this.createEditUserModal(c.get("user"),c.get("extra").name,c.get("active"))},editCurrentUser:function(){this.createEditCurrentUserModal(this.currentUser.get("user"),this.currentUser.get("extra").name,this.currentUser.get("extra").img)},submitEditUser:function(a){var b=$("#editName").val(),c=$("#editStatus").is(":checked");if(!this.validateStatus(c))return void $("#editStatus").closest("th").css("backgroundColor","red");if(!this.validateName(b))return void $("#editName").closest("th").css("backgroundColor","red");var d=this.collection.findWhere({user:a});d.save({extra:{name:b},active:c},{type:"PATCH"}),window.modalView.hide(),this.updateUserManagement()},validateUsername:function(a){return""===a?(arangoHelper.arangoError("You have to define an username"),$("#newUsername").closest("th").css("backgroundColor","red"),!1):a.match(/^[a-zA-Z][a-zA-Z0-9_\-]*$/)?!0:(arangoHelper.arangoError("Wrong Username","Username may only contain numbers, letters, _ and -"),!1)},validatePassword:function(a){return!0},validateName:function(a){return""===a?!0:a.match(/^[a-zA-Z][a-zA-Z0-9_\-\ ]*$/)?!0:(arangoHelper.arangoError("Wrong Username","Username may only contain numbers, letters, _ and -"),!1)},validateStatus:function(a){return""===a?!1:!0},toggleView:function(){$("#userSortDesc").attr("checked",this.collection.sortOptions.desc),$("#userManagementToggle").toggleClass("activated"),$("#userManagementDropdown2").slideToggle(200)},setFilterValues:function(){},evaluateUserName:function(a,b){var c=a.lastIndexOf(b);return a.substring(0,c)},editUserPassword:function(){window.modalView.hide(),this.createEditUserPasswordModal()},submitEditUserPassword:function(){var a=$("#oldCurrentPassword").val(),b=$("#newCurrentPassword").val(),c=$("#confirmCurrentPassword").val();$("#oldCurrentPassword").val(""),$("#newCurrentPassword").val(""),$("#confirmCurrentPassword").val(""),$("#oldCurrentPassword").closest("th").css("backgroundColor","white"),$("#newCurrentPassword").closest("th").css("backgroundColor","white"),$("#confirmCurrentPassword").closest("th").css("backgroundColor","white");var d=!1;this.validateCurrentPassword(a)||($("#oldCurrentPassword").closest("th").css("backgroundColor","red"),d=!0),b!==c&&($("#confirmCurrentPassword").closest("th").css("backgroundColor","red"),d=!0),this.validatePassword(b)||($("#newCurrentPassword").closest("th").css("backgroundColor","red"),d=!0),d||(this.currentUser.setPassword(b),window.modalView.hide())},validateCurrentPassword:function(a){return this.currentUser.checkPassword(a)},submitEditCurrentUserProfile:function(){var a=$("#editCurrentName").val(),b=$("#editCurrentUserProfileImg").val();b=this.parseImgString(b),this.currentUser.setExtras(a,b),this.updateUserProfile(),window.modalView.hide()},updateUserProfile:function(){var a=this;this.collection.fetch({success:function(){a.render()}})},parseImgString:function(a){return-1===a.indexOf("@")?a:CryptoJS.MD5(a).toString()},createEditUserModal:function(a,b,c){var d,e;e=[{type:window.modalView.tables.READONLY,label:"Username",value:_.escape(a)},{type:window.modalView.tables.TEXT,label:"Name",value:b,id:"editName",placeholder:"Name"},{type:window.modalView.tables.CHECKBOX,label:"Active",value:"active",checked:c,id:"editStatus"}],d=[{title:"Delete",type:window.modalView.buttons.DELETE,callback:this.submitDeleteUser.bind(this,a)},{title:"Save",type:window.modalView.buttons.SUCCESS,callback:this.submitEditUser.bind(this,a)}],window.modalView.show("modalTable.ejs","Edit User",d,e)},createCreateUserModal:function(){var a=[],b=[];b.push(window.modalView.createTextEntry("newUsername","Username","",!1,"Username",!0,[{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only symbols, "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No username given."}])),b.push(window.modalView.createTextEntry("newName","Name","",!1,"Name",!1)),b.push(window.modalView.createPasswordEntry("newPassword","Password","",!1,"",!1)),b.push(window.modalView.createCheckboxEntry("newStatus","Active","active",!1,!0)),a.push(window.modalView.createSuccessButton("Create",this.submitCreateUser.bind(this))),window.modalView.show("modalTable.ejs","Create New User",a,b)},createEditCurrentUserModal:function(a,b,c){var d=[],e=[];e.push(window.modalView.createReadOnlyEntry("id_username","Username",a)),e.push(window.modalView.createTextEntry("editCurrentName","Name",b,!1,"Name",!1)),e.push(window.modalView.createTextEntry("editCurrentUserProfileImg","Gravatar account (Mail)",c,"Mailaddress or its md5 representation of your gravatar account. The address will be converted into a md5 string. Only the md5 string will be stored, not the mailaddress.","myAccount(at)gravatar.com")),d.push(window.modalView.createNotificationButton("Change Password",this.editUserPassword.bind(this))),d.push(window.modalView.createSuccessButton("Save",this.submitEditCurrentUserProfile.bind(this))),window.modalView.show("modalTable.ejs","Edit User Profile",d,e)},createEditUserPasswordModal:function(){var a=[],b=[];b.push(window.modalView.createPasswordEntry("oldCurrentPassword","Old Password","",!1,"old password",!1)), -b.push(window.modalView.createPasswordEntry("newCurrentPassword","New Password","",!1,"new password",!1)),b.push(window.modalView.createPasswordEntry("confirmCurrentPassword","Confirm New Password","",!1,"confirm new password",!1)),a.push(window.modalView.createSuccessButton("Save",this.submitEditUserPassword.bind(this))),window.modalView.show("modalTable.ejs","Edit User Password",a,b)}})}(),function(){"use strict";window.workMonitorView=Backbone.View.extend({el:"#content",id:"#workMonitorContent",template:templateEngine.createTemplate("workMonitorView.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),initialize:function(){},events:{},tableDescription:{id:"workMonitorTable",titles:["Type","Database","Task ID","Started","Url","User","Description","Method"],rows:[],unescaped:[!1,!1,!1,!1,!1,!1,!1,!1]},render:function(){var a=this;this.$el.html(this.template.render({})),this.collection.fetch({success:function(){a.parseTableData(),$(a.id).append(a.table.render({content:a.tableDescription}))}})},parseTableData:function(){var a=this;this.collection.each(function(b){if("AQL query"===b.get("type")){var c=b.get("parent");if(c)try{a.tableDescription.rows.push([b.get("type"),"(p) "+c.database,"(p) "+c.taskId,"(p) "+c.startTime,"(p) "+c.url,"(p) "+c.user,b.get("description"),"(p) "+c.method])}catch(d){console.log("some parse error")}}else"thread"!==b.get("type")&&a.tableDescription.rows.push([b.get("type"),b.get("database"),b.get("taskId"),b.get("startTime"),b.get("url"),b.get("user"),b.get("description"),b.get("method")])})}})}(),function(){"use strict";window.Router=Backbone.Router.extend({routes:{"":"dashboard",dashboard:"dashboard",collections:"collections","new":"newCollection",login:"login","collection/:colid/documents/:pageid":"documents","collection/:colid/:docid":"document",shell:"shell",query:"query",queryManagement:"queryManagement",workMonitor:"workMonitor",databases:"databases",applications:"applications","applications/:mount":"applicationDetail",graph:"graphManagement","graph/:name":"showGraph",userManagement:"userManagement",userProfile:"userProfile",logs:"logs",test:"test"},initialize:function(){window.modalView=new window.ModalView,this.foxxList=new window.FoxxCollection,window.foxxInstallView=new window.FoxxInstallView({collection:this.foxxList}),window.progressView=new window.ProgressView;var a=this;this.userCollection=new window.ArangoUsers,this.initOnce=function(){this.initOnce=function(){},this.arangoDatabase=new window.ArangoDatabase,this.currentDB=new window.CurrentDatabase,this.currentDB.fetch({async:!1}),this.arangoCollectionsStore=new window.arangoCollections,this.arangoDocumentStore=new window.arangoDocument,arangoHelper.setDocumentStore(this.arangoDocumentStore),this.arangoCollectionsStore.fetch({async:!1}),this.footerView=new window.FooterView,this.notificationList=new window.NotificationCollection,this.naviView=new window.NavigationView({database:this.arangoDatabase,currentDB:this.currentDB,notificationCollection:a.notificationList,userCollection:this.userCollection}),this.queryCollection=new window.ArangoQueries,this.footerView.render(),this.naviView.render(),window.checkVersion()}.bind(this),$(window).resize(function(){a.handleResize()})},checkUser:function(){return null===this.userCollection.whoAmI()?(this.navigate("login",{trigger:!0}),!1):(this.initOnce(),!0)},logs:function(){if(this.checkUser()){if(!this.logsView){var a=new window.ArangoLogs({upto:!0,loglevel:4}),b=new window.ArangoLogs({loglevel:4}),c=new window.ArangoLogs({loglevel:3}),d=new window.ArangoLogs({loglevel:2}),e=new window.ArangoLogs({loglevel:1});this.logsView=new window.LogsView({logall:a,logdebug:b,loginfo:c,logwarning:d,logerror:e})}this.logsView.render(),this.naviView.selectMenuItem("tools-menu")}},applicationDetail:function(a){this.checkUser()&&(this.naviView.selectMenuItem("applications-menu"),0===this.foxxList.length&&this.foxxList.fetch({async:!1}),this.hasOwnProperty("applicationDetailView")||(this.applicationDetailView=new window.ApplicationDetailView({model:this.foxxList.get(decodeURIComponent(a))})),this.applicationDetailView.model=this.foxxList.get(decodeURIComponent(a)),this.applicationDetailView.render("swagger"))},login:function(){return null!==this.userCollection.whoAmI()?(this.navigate("",{trigger:!0}),!1):(this.loginView||(this.loginView=new window.loginView({collection:this.userCollection})),void this.loginView.render())},collections:function(){if(this.checkUser()){var a=this.naviView,b=this;this.collectionsView||(this.collectionsView=new window.CollectionsView({collection:this.arangoCollectionsStore})),this.arangoCollectionsStore.fetch({success:function(){b.collectionsView.render(),a.selectMenuItem("collections-menu")}})}},documents:function(a,b){this.checkUser()&&(this.documentsView||(this.documentsView=new window.DocumentsView({collection:new window.arangoDocuments,documentStore:this.arangoDocumentStore,collectionsStore:this.arangoCollectionsStore})),this.documentsView.setCollectionId(a,b),this.documentsView.render())},document:function(a,b){if(this.checkUser()){this.documentView||(this.documentView=new window.DocumentView({collection:this.arangoDocumentStore})),this.documentView.colid=a,this.documentView.docid=b,this.documentView.render();var c=arangoHelper.collectionApiType(a);this.documentView.setType(c)}},shell:function(){this.checkUser()&&(this.shellView||(this.shellView=new window.shellView),this.shellView.render(),this.naviView.selectMenuItem("tools-menu"))},query:function(){this.checkUser()&&(this.queryView||(this.queryView=new window.queryView({collection:this.queryCollection})),this.queryView.render(),this.naviView.selectMenuItem("query-menu"))},test:function(){this.checkUser()&&(this.testView||(this.testView=new window.testView({})),this.testView.render())},workMonitor:function(){this.checkUser()&&(this.workMonitorCollection||(this.workMonitorCollection=new window.WorkMonitorCollection),this.workMonitorView||(this.workMonitorView=new window.workMonitorView({collection:this.workMonitorCollection})),this.workMonitorView.render(),this.naviView.selectMenuItem("tools-menu"))},queryManagement:function(){this.checkUser()&&(this.queryManagementView||(this.queryManagementView=new window.queryManagementView({collection:void 0})),this.queryManagementView.render(),this.naviView.selectMenuItem("tools-menu"))},databases:function(){this.checkUser()&&(arangoHelper.databaseAllowed()===!0?(this.databaseView||(this.databaseView=new window.databaseView({users:this.userCollection,collection:this.arangoDatabase})),this.databaseView.render(),this.naviView.selectMenuItem("databases-menu")):(this.navigate("#",{trigger:!0}),this.naviView.selectMenuItem("dashboard-menu"),$("#databaseNavi").css("display","none"),$("#databaseNaviSelect").css("display","none")))},dashboard:function(){this.checkUser()&&(this.naviView.selectMenuItem("dashboard-menu"),void 0===this.dashboardView&&(this.dashboardView=new window.DashboardView({dygraphConfig:window.dygraphConfig,database:this.arangoDatabase})),this.dashboardView.render())},graphManagement:function(){this.checkUser()&&(this.graphManagementView||(this.graphManagementView=new window.GraphManagementView({collection:new window.GraphCollection,collectionCollection:this.arangoCollectionsStore})),this.graphManagementView.render(),this.naviView.selectMenuItem("graphviewer-menu"))},showGraph:function(a){this.checkUser()&&(this.graphManagementView||(this.graphManagementView=new window.GraphManagementView({collection:new window.GraphCollection,collectionCollection:this.arangoCollectionsStore})),this.graphManagementView.render(),this.graphManagementView.loadGraphViewer(a),this.naviView.selectMenuItem("graphviewer-menu"))},applications:function(){this.checkUser()&&(void 0===this.applicationsView&&(this.applicationsView=new window.ApplicationsView({collection:this.foxxList})),this.applicationsView.reload(),this.naviView.selectMenuItem("applications-menu"))},handleSelectDatabase:function(){this.checkUser()&&this.naviView.handleSelectDatabase()},handleResize:function(){this.dashboardView&&this.dashboardView.resize(),this.graphManagementView&&this.graphManagementView.handleResize($("#content").width()),this.queryView&&this.queryView.resize()},userManagement:function(){this.checkUser()&&(this.userManagementView||(this.userManagementView=new window.userManagementView({collection:this.userCollection})),this.userManagementView.render(),this.naviView.selectMenuItem("tools-menu"))},userProfile:function(){this.checkUser()&&(this.userManagementView||(this.userManagementView=new window.userManagementView({collection:this.userCollection})),this.userManagementView.render(!0),this.naviView.selectMenuItem("tools-menu"))}})}(),function(){"use strict";var a=function(){$.ajax({type:"POST",url:"/_admin/aardvark/disableVersionCheck"})},b=function(a){$.ajax({type:"GET",url:"/_admin/aardvark/shouldCheckVersion",success:function(b){b===!0&&a()}})},c=function(b,c){var d=[];d.push(window.modalView.createNotificationButton("Don't ask again",function(){a(),window.modalView.hide()})),d.push(window.modalView.createSuccessButton("Download Page",function(){window.open("https://www.arangodb.com/download","_blank"),window.modalView.hide()}));var e=[],f=window.modalView.createReadOnlyEntry.bind(window.modalView);e.push(f("current","Current",b.toString())),c.major&&e.push(f("major","Major",c.major.version)),c.minor&&e.push(f("minor","Minor",c.minor.version)),c.bugfix&&e.push(f("bugfix","Bugfix",c.bugfix.version)),window.modalView.show("modalTable.ejs","New Version Available",d,e)};window.checkVersion=function(){$.ajax({type:"GET",cache:!1,url:"/_api/version",contentType:"application/json",processData:!1,async:!0,success:function(a){var d=window.versionHelper.fromString(a.version);window.parseVersions=function(e){_.isEmpty(e)||/-devel$/.test(a.version)||b(c.bind(window,d,e))},$.ajax({type:"GET",async:!0,crossDomain:!0,timeout:3e3,dataType:"jsonp",url:"https://www.arangodb.com/repositories/versions.php?jsonp=parseVersions&version="+encodeURIComponent(d.toString())})}})}}(),function(){"use strict";window.hasOwnProperty("TEST_BUILD")||$(document).ready(function(){window.App=new window.Router,Backbone.history.start(),window.App.handleResize()})}(); \ No newline at end of file +u.keys=function(a){if(!u.isObject(a))return[];if(q)return q(a);var b=[];for(var c in a)u.has(a,c)&&b.push(c);return G&&f(a,b),b},u.allKeys=function(a){if(!u.isObject(a))return[];var b=[];for(var c in a)b.push(c);return G&&f(a,b),b},u.values=function(a){for(var b=u.keys(a),c=b.length,d=Array(c),e=0;c>e;e++)d[e]=a[b[e]];return d},u.mapObject=function(a,b,c){b=w(b,c);for(var d,e=u.keys(a),f=e.length,g={},h=0;f>h;h++)d=e[h],g[d]=b(a[d],d,a);return g},u.pairs=function(a){for(var b=u.keys(a),c=b.length,d=Array(c),e=0;c>e;e++)d[e]=[b[e],a[b[e]]];return d},u.invert=function(a){for(var b={},c=u.keys(a),d=0,e=c.length;e>d;d++)b[a[c[d]]]=c[d];return b},u.functions=u.methods=function(a){var b=[];for(var c in a)u.isFunction(a[c])&&b.push(c);return b.sort()},u.extend=x(u.allKeys),u.extendOwn=u.assign=x(u.keys),u.findKey=function(a,b,c){b=w(b,c);for(var d,e=u.keys(a),f=0,g=e.length;g>f;f++)if(d=e[f],b(a[d],d,a))return d},u.pick=function(a,b,c){var d,e,f={},g=a;if(null==g)return f;u.isFunction(b)?(e=u.allKeys(g),d=v(b,c)):(e=E(arguments,!1,!1,1),d=function(a,b,c){return b in c},g=Object(g));for(var h=0,i=e.length;i>h;h++){var j=e[h],k=g[j];d(k,j,g)&&(f[j]=k)}return f},u.omit=function(a,b,c){if(u.isFunction(b))b=u.negate(b);else{var d=u.map(E(arguments,!1,!1,1),String);b=function(a,b){return!u.contains(d,b)}}return u.pick(a,b,c)},u.defaults=x(u.allKeys,!0),u.create=function(a,b){var c=y(a);return b&&u.extendOwn(c,b),c},u.clone=function(a){return u.isObject(a)?u.isArray(a)?a.slice():u.extend({},a):a},u.tap=function(a,b){return b(a),a},u.isMatch=function(a,b){var c=u.keys(b),d=c.length;if(null==a)return!d;for(var e=Object(a),f=0;d>f;f++){var g=c[f];if(b[g]!==e[g]||!(g in e))return!1}return!0};var I=function U(a,b,c,d){if(a===b)return 0!==a||1/a===1/b;if(null==a||null==b)return a===b;a instanceof u&&(a=a._wrapped),b instanceof u&&(b=b._wrapped);var e=n.call(a);if(e!==n.call(b))return!1;switch(e){case"[object RegExp]":case"[object String]":return""+a==""+b;case"[object Number]":return+a!==+a?+b!==+b:0===+a?1/+a===1/b:+a===+b;case"[object Date]":case"[object Boolean]":return+a===+b}var f="[object Array]"===e;if(!f){if("object"!=typeof a||"object"!=typeof b)return!1;var g=a.constructor,h=b.constructor;if(g!==h&&!(u.isFunction(g)&&g instanceof g&&u.isFunction(h)&&h instanceof h)&&"constructor"in a&&"constructor"in b)return!1}c=c||[],d=d||[];for(var i=c.length;i--;)if(c[i]===a)return d[i]===b;if(c.push(a),d.push(b),f){if(i=a.length,i!==b.length)return!1;for(;i--;)if(!U(a[i],b[i],c,d))return!1}else{var j,k=u.keys(a);if(i=k.length,u.keys(b).length!==i)return!1;for(;i--;)if(j=k[i],!u.has(b,j)||!U(a[j],b[j],c,d))return!1}return c.pop(),d.pop(),!0};u.isEqual=function(a,b){return I(a,b)},u.isEmpty=function(a){return null==a?!0:C(a)&&(u.isArray(a)||u.isString(a)||u.isArguments(a))?0===a.length:0===u.keys(a).length},u.isElement=function(a){return!(!a||1!==a.nodeType)},u.isArray=p||function(a){return"[object Array]"===n.call(a)},u.isObject=function(a){var b=typeof a;return"function"===b||"object"===b&&!!a},u.each(["Arguments","Function","String","Number","Date","RegExp","Error"],function(a){u["is"+a]=function(b){return n.call(b)==="[object "+a+"]"}}),u.isArguments(arguments)||(u.isArguments=function(a){return u.has(a,"callee")}),"function"!=typeof/./&&"object"!=typeof Int8Array&&(u.isFunction=function(a){return"function"==typeof a||!1}),u.isFinite=function(a){return isFinite(a)&&!isNaN(parseFloat(a))},u.isNaN=function(a){return u.isNumber(a)&&a!==+a},u.isBoolean=function(a){return a===!0||a===!1||"[object Boolean]"===n.call(a)},u.isNull=function(a){return null===a},u.isUndefined=function(a){return void 0===a},u.has=function(a,b){return null!=a&&o.call(a,b)},u.noConflict=function(){return g._=h,this},u.identity=function(a){return a},u.constant=function(a){return function(){return a}},u.noop=function(){},u.property=z,u.propertyOf=function(a){return null==a?function(){}:function(b){return a[b]}},u.matcher=u.matches=function(a){return a=u.extendOwn({},a),function(b){return u.isMatch(b,a)}},u.times=function(a,b,c){var d=Array(Math.max(0,a));b=v(b,c,1);for(var e=0;a>e;e++)d[e]=b(e);return d},u.random=function(a,b){return null==b&&(b=a,a=0),a+Math.floor(Math.random()*(b-a+1))},u.now=Date.now||function(){return(new Date).getTime()};var J={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},K=u.invert(J),L=function(a){var b=function(b){return a[b]},c="(?:"+u.keys(a).join("|")+")",d=RegExp(c),e=RegExp(c,"g");return function(a){return a=null==a?"":""+a,d.test(a)?a.replace(e,b):a}};u.escape=L(J),u.unescape=L(K),u.result=function(a,b,c){var d=null==a?void 0:a[b];return void 0===d&&(d=c),u.isFunction(d)?d.call(a):d};var M=0;u.uniqueId=function(a){var b=++M+"";return a?a+b:b},u.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var N=/(.)^/,O={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},P=/\\|'|\r|\n|\u2028|\u2029/g,Q=function(a){return"\\"+O[a]};u.template=function(a,b,c){!b&&c&&(b=c),b=u.defaults({},b,u.templateSettings);var d=RegExp([(b.escape||N).source,(b.interpolate||N).source,(b.evaluate||N).source].join("|")+"|$","g"),e=0,f="__p+='";a.replace(d,function(b,c,d,g,h){return f+=a.slice(e,h).replace(P,Q),e=h+b.length,c?f+="'+\n((__t=("+c+"))==null?'':_.escape(__t))+\n'":d?f+="'+\n((__t=("+d+"))==null?'':__t)+\n'":g&&(f+="';\n"+g+"\n__p+='"),b}),f+="';\n",b.variable||(f="with(obj||{}){\n"+f+"}\n"),f="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+f+"return __p;\n";try{var g=new Function(b.variable||"obj","_",f)}catch(h){throw h.source=f,h}var i=function(a){return g.call(this,a,u)},j=b.variable||"obj";return i.source="function("+j+"){\n"+f+"}",i},u.chain=function(a){var b=u(a);return b._chain=!0,b};var R=function(a,b){return a._chain?u(b).chain():b};u.mixin=function(a){u.each(u.functions(a),function(b){var c=u[b]=a[b];u.prototype[b]=function(){var a=[this._wrapped];return l.apply(a,arguments),R(this,c.apply(u,a))}})},u.mixin(u),u.each(["pop","push","reverse","shift","sort","splice","unshift"],function(a){var b=i[a];u.prototype[a]=function(){var c=this._wrapped;return b.apply(c,arguments),"shift"!==a&&"splice"!==a||0!==c.length||delete c[0],R(this,c)}}),u.each(["concat","join","slice"],function(a){var b=i[a];u.prototype[a]=function(){return R(this,b.apply(this._wrapped,arguments))}}),u.prototype.value=function(){return this._wrapped},u.prototype.valueOf=u.prototype.toJSON=u.prototype.value,u.prototype.toString=function(){return""+this._wrapped},"function"==typeof define&&define.amd&&define("underscore",[],function(){return u})}).call(this)}),"undefined"==typeof global&&"undefined"!=typeof window&&(global=window),global.Buffer=require("buffer").Buffer,global.process=require("process"),global.setInterval=global.setInterval||function(){},global.clearInterval=global.clearInterval||function(){},global.setTimeout=global.setTimeout||function(){},global.clearTimeout=global.clearTimeout||function(){},global.aqlQuery=function(){var a,b,c,d=arguments[0],e={},f=d[0];for(c=1;cc;++c)b+="\n";a.print(b)},global.console=global.console||require("console"),global.db=require("@arangodb").db,global.arango=require("@arangodb").arango,global.fm=require("@arangodb/foxx/manager"),global.ArangoStatement=require("@arangodb/arango-statement").ArangoStatement,global.tutorial=require("@arangodb/tutorial");var initHelp=function(){var a=require("internal");if(a.db)try{a.db._collections()}catch(b){}a.quiet!==!0&&(require("@arangodb").checkAvailableVersions(),a.arango&&a.arango.isConnected&&a.arango.isConnected()&&a.print("Type 'tutorial' for a tutorial or 'help' to see common examples"))};if("undefined"==typeof window){if(initHelp(),!(global.IS_EXECUTE_SCRIPT||global.IS_EXECUTE_STRING||global.IS_CHECK_SCRIPT||global.IS_UNIT_TESTS||global.IS_JS_LINT))try{var __fs__=require("fs"),__rcf__=__fs__.join(__fs__.home(),".arangosh.rc");if(__fs__.exists(__rcf__)){var __content__=__fs__.read(__rcf__);eval(__content__)}}catch(e){require("console").warn("arangosh.rc: %s",String(e))}try{delete global.IS_EXECUTE_SCRIPT,delete global.IS_EXECUTE_STRING,delete global.IS_CHECK_SCRIPT,delete global.IS_UNIT_TESTS,delete global.IS_JS_LINT}catch(e){}}!function(){"use strict";window.arangoCollectionModel=Backbone.Model.extend({initialize:function(){},idAttribute:"name",urlRoot:"/_api/collection",defaults:{id:"",name:"",status:"",type:"",isSystem:!1,picture:"",locked:!1},getProperties:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/collection/"+encodeURIComponent(this.get("id"))+"/properties",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},getFigures:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/collection/"+this.get("id")+"/figures",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},getRevision:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/collection/"+this.get("id")+"/revision",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},getIndex:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/index/?collection="+this.get("id"),contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},createIndex:function(a,b){var c=this;$.ajax({cache:!1,type:"POST",url:"/_api/index?collection="+c.get("id"),headers:{"x-arango-async":"store"},data:JSON.stringify(a),contentType:"application/json",processData:!1,async:!0,success:function(a,d,e){e.getResponseHeader("x-arango-async-id")?(window.arangoHelper.addAardvarkJob({id:e.getResponseHeader("x-arango-async-id"),type:"index",collection:c.get("id")}),b(!1,a)):b(!0,a)},error:function(a){b(!0,a)}}),b()},deleteIndex:function(a,b){$.ajax({cache:!1,type:"DELETE",url:"/_api/index/"+this.get("name")+"/"+encodeURIComponent(a),async:!0,success:function(){b(!1)},error:function(a){b(!0,a)}}),b()},truncateCollection:function(){$.ajax({async:!1,cache:!1,type:"PUT",url:"/_api/collection/"+this.get("id")+"/truncate",success:function(){arangoHelper.arangoNotification("Collection truncated")},error:function(){arangoHelper.arangoError("Collection error")}})},loadCollection:function(a){$.ajax({async:!0,cache:!1,type:"PUT",url:"/_api/collection/"+this.get("id")+"/load",success:function(){a(!1)},error:function(){a(!0)}}),a()},unloadCollection:function(a){$.ajax({async:!0,cache:!1,type:"PUT",url:"/_api/collection/"+this.get("id")+"/unload?flush=true",success:function(){a(!1)},error:function(){a(!0)}}),a()},renameCollection:function(a){var b=this,c=!1;return $.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/collection/"+this.get("id")+"/rename",data:JSON.stringify({name:a}),contentType:"application/json",processData:!1,success:function(){b.set("name",a),c=!0},error:function(){try{console.log("error")}catch(a){c=!1}}}),c},changeCollection:function(a,b,c){var d=!1;"true"===a?a=!0:"false"===a&&(a=!1);var e={waitForSync:a,journalSize:parseInt(b),indexBuckets:parseInt(c)};return $.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/collection/"+this.get("id")+"/properties",data:JSON.stringify(e),contentType:"application/json",processData:!1,success:function(){d=!0},error:function(a){try{var b=JSON.parse(a.responseText);d=b.errorMessage}catch(c){d=!1}}}),d}})}(),window.DatabaseModel=Backbone.Model.extend({idAttribute:"name",initialize:function(){"use strict"},isNew:function(){"use strict";return!1},sync:function(a,b,c){"use strict";return"update"===a&&(a="create"),Backbone.sync(a,b,c)},url:"/_api/database",defaults:{}}),window.arangoDocumentModel=Backbone.Model.extend({initialize:function(){"use strict"},urlRoot:"/_api/document",defaults:{_id:"",_rev:"",_key:""},getSorted:function(){"use strict";var a=this,b=Object.keys(a.attributes).sort(function(a,b){var c=arangoHelper.isSystemAttribute(a),d=arangoHelper.isSystemAttribute(b);return c!==d?c?-1:1:b>a?-1:1}),c={};return _.each(b,function(b){c[b]=a.attributes[b]}),c}}),function(){"use strict";window.ArangoQuery=Backbone.Model.extend({urlRoot:"/_api/user",defaults:{name:"",type:"custom",value:""}})}(),window.Replication=Backbone.Model.extend({defaults:{state:{},server:{}},initialize:function(){}}),window.Statistics=Backbone.Model.extend({defaults:{},url:function(){"use strict";return"/_admin/statistics"}}),window.StatisticsDescription=Backbone.Model.extend({defaults:{figures:"",groups:""},url:function(){"use strict";return"/_admin/statistics-description"}}),window.Users=Backbone.Model.extend({defaults:{user:"",active:!1,extra:{}},idAttribute:"user",parse:function(a){return this.isNotNew=!0,a},isNew:function(){return!this.isNotNew},url:function(){return this.isNew()?"/_api/user":""!==this.get("user")?"/_api/user/"+this.get("user"):"/_api/user"},checkPassword:function(a){var b=!1;return $.ajax({cache:!1,type:"POST",async:!1,url:"/_api/user/"+this.get("user"),data:JSON.stringify({passwd:a}),contentType:"application/json",processData:!1,success:function(a){b=a.result}}),b},setPassword:function(a){$.ajax({cache:!1,type:"PATCH",async:!1,url:"/_api/user/"+this.get("user"),data:JSON.stringify({passwd:a}),contentType:"application/json",processData:!1})},setExtras:function(a,b){$.ajax({cache:!1,type:"PATCH",async:!1,url:"/_api/user/"+this.get("user"),data:JSON.stringify({extra:{name:a,img:b}}),contentType:"application/json",processData:!1})}}),function(){"use strict";window.CurrentDatabase=Backbone.Model.extend({url:"/_api/database/current",parse:function(a){return a.result}})}(),function(){"use strict";var a=function(a,b,c,d,e,f){var g={contentType:"application/json",processData:!1,type:c};b=b||function(){},f=_.extend({mount:a.encodedMount()},f);var h=_.reduce(f,function(a,b,c){return a+encodeURIComponent(c)+"="+encodeURIComponent(b)+"&"},"?");g.url="/_admin/aardvark/foxxes"+(d?"/"+d:"")+h.slice(0,h.length-1),void 0!==e&&(g.data=JSON.stringify(e)),$.ajax(g).then(function(a){b(null,a)},function(a){window.xhr=a,b(_.extend(a.status?new Error(a.responseJSON?a.responseJSON.errorMessage:a.responseText):new Error("Network Error"),{statusCode:a.status}))})};window.Foxx=Backbone.Model.extend({idAttribute:"mount",defaults:{author:"Unknown Author",name:"",version:"Unknown Version",description:"No description",license:"Unknown License",contributors:[],scripts:{},config:{},deps:{},git:"",system:!1,development:!1},isNew:function(){return!1},encodedMount:function(){return encodeURIComponent(this.get("mount"))},destroy:function(b,c){a(this,c,"DELETE",void 0,void 0,b)},isBroken:function(){return!1},needsAttention:function(){return this.isBroken()||this.needsConfiguration()||this.hasUnconfiguredDependencies()},needsConfiguration:function(){return _.any(this.get("config"),function(a){return void 0===a.current&&a.required!==!1})},hasUnconfiguredDependencies:function(){return _.any(this.get("deps"),function(a){return void 0===a.current&&a.definition.required!==!1})},getConfiguration:function(b){a(this,function(a,c){a||this.set("config",c),"function"==typeof b&&b(a,c)}.bind(this),"GET","config")},setConfiguration:function(b,c){a(this,c,"PATCH","config",b)},getDependencies:function(b){a(this,function(a,c){a||this.set("deps",c),"function"==typeof b&&b(a,c)}.bind(this),"GET","deps")},setDependencies:function(b,c){a(this,c,"PATCH","deps",b)},toggleDevelopment:function(b,c){a(this,function(a,d){a||this.set("development",b),"function"==typeof c&&c(a,d)}.bind(this),"PATCH","devel",b)},runScript:function(b,c,d){a(this,d,"POST","scripts/"+b,c)},runTests:function(b,c){a(this,function(a,b){"function"==typeof c&&c(a?a.responseJSON:a,b)}.bind(this),"POST","tests",b)},isSystem:function(){return this.get("system")},isDevelopment:function(){return this.get("development")},download:function(){window.open("/_db/"+arango.getDatabaseName()+"/_admin/aardvark/foxxes/download/zip?mount="+this.encodedMount())}})}(),function(){"use strict";window.Graph=Backbone.Model.extend({idAttribute:"_key",urlRoot:"/_api/gharial",isNew:function(){return!this.get("_id")},parse:function(a){return a.graph||a},addEdgeDefinition:function(a){$.ajax({async:!1,type:"POST",url:this.urlRoot+"/"+this.get("_key")+"/edge",data:JSON.stringify(a)})},deleteEdgeDefinition:function(a){$.ajax({async:!1,type:"DELETE",url:this.urlRoot+"/"+this.get("_key")+"/edge/"+a})},modifyEdgeDefinition:function(a){$.ajax({async:!1,type:"PUT",url:this.urlRoot+"/"+this.get("_key")+"/edge/"+a.collection,data:JSON.stringify(a)})},addVertexCollection:function(a){$.ajax({async:!1,type:"POST",url:this.urlRoot+"/"+this.get("_key")+"/vertex",data:JSON.stringify({collection:a})})},deleteVertexCollection:function(a){$.ajax({async:!1,type:"DELETE",url:this.urlRoot+"/"+this.get("_key")+"/vertex/"+a})},defaults:{name:"",edgeDefinitions:[],orphanCollections:[]}})}(),function(){"use strict";window.newArangoLog=Backbone.Model.extend({defaults:{lid:"",level:"",timestamp:"",text:"",totalAmount:""},getLogStatus:function(){switch(this.get("level")){case 1:return"Error";case 2:return"Warning";case 3:return"Info";case 4:return"Debug";default:return"Unknown"}}})}(),function(){"use strict";window.Notification=Backbone.Model.extend({defaults:{title:"",date:0,content:"",priority:"",tags:"",seen:!1}})}(),function(){"use strict";window.queryManagementModel=Backbone.Model.extend({defaults:{id:"",query:"",started:"",runTime:""}})}(),function(){"use strict";window.workMonitorModel=Backbone.Model.extend({defaults:{name:"",number:"",status:"",type:""}})}(),function(){"use strict";window.PaginatedCollection=Backbone.Collection.extend({page:0,pagesize:10,totalAmount:0,getPage:function(){return this.page+1},setPage:function(a){return a>=this.getLastPageNumber()?void(this.page=this.getLastPageNumber()-1):1>a?void(this.page=0):void(this.page=a-1)},getLastPageNumber:function(){return Math.max(Math.ceil(this.totalAmount/this.pagesize),1)},getOffset:function(){return this.page*this.pagesize},getPageSize:function(){return this.pagesize},setPageSize:function(a){if("all"===a)this.pagesize="all";else try{a=parseInt(a,10),this.pagesize=a}catch(b){}},setToFirst:function(){this.page=0},setToLast:function(){this.setPage(this.getLastPageNumber())},setToPrev:function(){this.setPage(this.getPage()-1)},setToNext:function(){this.setPage(this.getPage()+1)},setTotal:function(a){this.totalAmount=a},getTotal:function(){return this.totalAmount},setTotalMinusOne:function(){this.totalAmount--}})}(),function(){"use strict";window.arangoCollections=Backbone.Collection.extend({url:"/_api/collection",model:arangoCollectionModel,searchOptions:{searchPhrase:null,includeSystem:!1,includeDocument:!0,includeEdge:!0,includeLoaded:!0,includeUnloaded:!0,sortBy:"name",sortOrder:1},translateStatus:function(a){switch(a){case 0:return"corrupted";case 1:return"new born collection";case 2:return"unloaded";case 3:return"loaded";case 4:return"will be unloaded";case 5:return"deleted";case 6:return"loading";default:return}},translateTypePicture:function(a){var b="";switch(a){case"document":b+="fa-file-text-o";break;case"edge":b+="fa-share-alt";break;case"unknown":b+="fa-question";break;default:b+="fa-cogs"}return b},parse:function(a){var b=this;return _.each(a.collections,function(a){a.isSystem=arangoHelper.isSystemCollection(a),a.type=arangoHelper.collectionType(a),a.status=b.translateStatus(a.status),a.picture=b.translateTypePicture(a.type)}),a.collections},getPosition:function(a){var b,c=this.getFiltered(this.searchOptions),d=null,e=null;for(b=0;b0&&(d=c[b-1]),b0){var e,f=d.get("name").toLowerCase();for(e=0;ed?-1:1):0}),b},newCollection:function(a,b,c,d,e,f,g){var h={},i={};return i.name=a,i.waitForSync=b,d>0&&(i.journalSize=d),i.isSystem=c,i.type=parseInt(e,10),f&&(i.numberOfShards=f,i.shardKeys=g),h.status=!1,$.ajax({cache:!1,type:"POST",url:"/_api/collection",data:JSON.stringify(i),contentType:"application/json",processData:!1,async:!1,success:function(a){h.status=!0,h.data=a},error:function(a){h.status=!1,h.errorMessage=JSON.parse(a.responseText).errorMessage}}),h}})}(),function(){"use strict";window.ArangoDatabase=Backbone.Collection.extend({model:window.DatabaseModel,sortOptions:{desc:!1},url:"/_api/database",comparator:function(a,b){var c=a.get("name").toLowerCase(),d=b.get("name").toLowerCase();return this.sortOptions.desc===!0?d>c?1:c>d?-1:0:c>d?1:d>c?-1:0},parse:function(a){return a?_.map(a.result,function(a){return{name:a}}):void 0},initialize:function(){var a=this;this.fetch().done(function(){a.sort()})},setSortingDesc:function(a){this.sortOptions.desc=a},getDatabases:function(){var a=this;return this.fetch().done(function(){a.sort()}),this.models},getDatabasesForUser:function(){var a;return $.ajax({type:"GET",cache:!1,url:this.url+"/user",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b.result},error:function(){a=[]}}),a.sort()},createDatabaseURL:function(a,b,c){var d=window.location,e=window.location.hash;b=b?"SSL"===b||"https:"===b?"https:":"http:":d.protocol,c=c||d.port;var f=b+"//"+window.location.hostname+":"+c+"/_db/"+encodeURIComponent(a)+"/_admin/aardvark/standalone.html";if(e){var g=e.split("/")[0];0===g.indexOf("#collection")&&(g="#collections"),0===g.indexOf("#application")&&(g="#applications"),f+=g}return f},getCurrentDatabase:function(){var a;return $.ajax({type:"GET",cache:!1,url:this.url+"/current",contentType:"application/json",processData:!1,async:!1,success:function(b){return 200===b.code?void(a=b.result.name):void(a=b)},error:function(b){a=b}}),a},hasSystemAccess:function(){var a=this.getDatabasesForUser();return _.contains(a,"_system")}})}(),window.arangoDocument=Backbone.Collection.extend({url:"/_api/document/",model:arangoDocumentModel,collectionInfo:{},deleteEdge:function(a,b){var c=!1;try{$.ajax({cache:!1,type:"DELETE",async:!1,contentType:"application/json",url:"/_api/edge/"+a+"/"+b,success:function(){c=!0},error:function(){c=!1}})}catch(d){c=!1}return c},deleteDocument:function(a,b){var c=!1;try{$.ajax({cache:!1,type:"DELETE",async:!1,contentType:"application/json",url:"/_api/document/"+a+"/"+b,success:function(){c=!0},error:function(){c=!1}})}catch(d){c=!1}return c},addDocument:function(a,b){var c=this;c.createTypeDocument(a,b)},createTypeEdge:function(a,b,c,d){var e,f=!1;return e=d?JSON.stringify({_key:d}):JSON.stringify({}),$.ajax({cache:!1,type:"POST",async:!1,url:"/_api/edge?collection="+a+"&from="+b+"&to="+c,data:e,contentType:"application/json",processData:!1,success:function(a){f=a._id},error:function(a){f=!1}}),f},createTypeDocument:function(a,b){var c,d=!1;return c=b?JSON.stringify({_key:b}):JSON.stringify({}),$.ajax({cache:!1,type:"POST",async:!1,url:"/_api/document?collection="+encodeURIComponent(a),data:c,contentType:"application/json",processData:!1,success:function(a){d=a._id},error:function(a){d=!1}}),d},getCollectionInfo:function(a){var b=this;return $.ajax({cache:!1,type:"GET",url:"/_api/collection/"+a+"?"+arangoHelper.getRandomToken(),contentType:"application/json",processData:!1,async:!1,success:function(a){b.collectionInfo=a},error:function(a){}}),b.collectionInfo},getEdge:function(a,b){var c=!1,d=this;return this.clearDocument(),$.ajax({cache:!1,type:"GET",async:!1,url:"/_api/edge/"+a+"/"+b,contentType:"application/json",processData:!1,success:function(a){d.add(a),c=!0},error:function(a){c=!1}}),c},getDocument:function(a,b){var c=!1,d=this;return this.clearDocument(),$.ajax({cache:!1,type:"GET",async:!1,url:"/_api/document/"+a+"/"+b,contentType:"application/json",processData:!1,success:function(a){d.add(a),c=!0},error:function(a){c=!1}}),c},saveEdge:function(a,b,c){var d=!1;return $.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/edge/"+a+"/"+b,data:c,contentType:"application/json",processData:!1,success:function(a){d=!0},error:function(a){d=!1}}),d},saveDocument:function(a,b,c){var d=!1;return $.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/document/"+a+"/"+b,data:c,contentType:"application/json",processData:!1,success:function(a){d=!0},error:function(a){d=!1}}),d},updateLocalDocument:function(a){this.clearDocument(),this.add(a)},clearDocument:function(){this.reset()}}),function(){"use strict";window.arangoDocuments=window.PaginatedCollection.extend({collectionID:1,filters:[],MAX_SORT:12e3,lastQuery:{},sortAttribute:"_key",url:"/_api/documents",model:window.arangoDocumentModel,loadTotal:function(){var a=this;$.ajax({cache:!1,type:"GET",url:"/_api/collection/"+this.collectionID+"/count",contentType:"application/json",processData:!1,async:!1,success:function(b){a.setTotal(b.count)}})},setCollection:function(a){this.resetFilter(),this.collectionID=a,this.setPage(1),this.loadTotal()},setSort:function(a){this.sortAttribute=a},getSort:function(){return this.sortAttribute},addFilter:function(a,b,c){this.filters.push({attr:a,op:b,val:c})},setFiltersForQuery:function(a){if(0===this.filters.length)return"";var b=" FILTER",c="",d=_.map(this.filters,function(b,d){return"LIKE"===b.op?(c=" "+b.op+"(x.`"+b.attr+"`, @param",c+=d,c+=")"):(c="IN"===b.op||"NOT IN"===b.op?" ":" x.`",c+=b.attr,c+="IN"===b.op||"NOT IN"===b.op?" ":"` ",c+=b.op,c+="IN"===b.op||"NOT IN"===b.op?" x.@param":" @param",c+=d),a["param"+d]=b.val,c});return b+d.join(" &&")},setPagesize:function(a){this.setPageSize(a)},resetFilter:function(){this.filters=[]},moveDocument:function(a,b,c,d){var e,f,g,h,i={"@collection":b,filterid:a};e="FOR x IN @@collection",e+=" FILTER x._key == @filterid",e+=" INSERT x IN ",e+=c,f="FOR x in @@collection",f+=" FILTER x._key == @filterid",f+=" REMOVE x IN @@collection",g={query:e,bindVars:i},h={query:f,bindVars:i},window.progressView.show(),$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(g),contentType:"application/json",success:function(a){$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(h),contentType:"application/json",success:function(a){d&&d(),window.progressView.hide()},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Documents inserted, but could not be removed.")}})},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not move selected documents.")}})},getDocuments:function(a){window.progressView.showWithDelay(300,"Fetching documents...");var b,c,d,e,f=this;c={"@collection":this.collectionID,offset:this.getOffset(),count:this.getPageSize()},b="FOR x IN @@collection LET att = SLICE(ATTRIBUTES(x), 0, 25)",b+=this.setFiltersForQuery(c),this.getTotal()0)&&(e.options={fullCount:!0}),$.ajax({cache:!1,type:"POST",async:!0,url:"/_api/cursor",data:JSON.stringify(e),contentType:"application/json",success:function(b){window.progressView.toShow=!1,f.clearDocuments(),b.extra&&void 0!==b.extra.stats.fullCount&&f.setTotal(b.extra.stats.fullCount),0!==f.getTotal()&&_.each(b.result,function(a){f.add({id:a._id,rev:a._rev,key:a._key,content:a})}),f.lastQuery=e,a(),window.progressView.hide()},error:function(a){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not fetch requested documents.")}})},clearDocuments:function(){this.reset()},buildDownloadDocumentQuery:function(){var a,b,c;return c={"@collection":this.collectionID},a="FOR x in @@collection",a+=this.setFiltersForQuery(c),this.getTotal()0&&(b="At least one error occurred during upload")}catch(d){}}}),b}})}(),function(){"use strict";window.ArangoLogs=window.PaginatedCollection.extend({upto:!1,loglevel:0,totalPages:0,parse:function(a){var b=[];return _.each(a.lid,function(c,d){b.push({level:a.level[d],lid:c,text:a.text[d],timestamp:a.timestamp[d],totalAmount:a.totalAmount})}),this.totalAmount=a.totalAmount,this.totalPages=Math.ceil(this.totalAmount/this.pagesize),b},initialize:function(a){a.upto===!0&&(this.upto=!0),this.loglevel=a.loglevel},model:window.newArangoLog,url:function(){var a,b,c,d;c=this.page*this.pagesize;var e=this.totalAmount-(this.page+1)*this.pagesize;return 0>e&&this.page===this.totalPages-1?(e=0,d=this.totalAmount%this.pagesize):d=this.pagesize,0===this.totalAmount&&(d=1),a=this.upto?"upto":"level",b="/_admin/log?"+a+"="+this.loglevel+"&size="+d+"&offset="+e}})}(),function(){"use strict";window.ArangoQueries=Backbone.Collection.extend({initialize:function(a,b){var c;$.ajax("whoAmI?_="+Date.now(),{async:!1}).done(function(a){c=a.user}),this.activeUser=c,this.activeUser===!1&&(this.activeUser="root")},url:"/_api/user/",model:ArangoQuery,activeUser:null,parse:function(a){var b,c=this;return _.each(a.result,function(a){if(a.user===c.activeUser)try{a.extra.queries&&(b=a.extra.queries)}catch(d){}}),b},saveCollectionQueries:function(){if(0===this.activeUser)return!1;var a=!1,b=[];return this.each(function(a){b.push({value:a.attributes.value,parameter:a.attributes.parameter,name:a.attributes.name})}),$.ajax({cache:!1,type:"PATCH",async:!1,url:"/_api/user/"+encodeURIComponent(this.activeUser),data:JSON.stringify({extra:{queries:b}}),contentType:"application/json",processData:!1,success:function(){a=!0},error:function(){a=!1}}),a},saveImportQueries:function(a,b){return 0===this.activeUser?!1:(window.progressView.show("Fetching documents..."),void $.ajax({cache:!1,type:"POST",async:!1,url:"query/upload/"+encodeURIComponent(this.activeUser),data:a,contentType:"application/json",processData:!1,success:function(){window.progressView.hide(),arangoHelper.arangoNotification("Queries successfully imported."),b()},error:function(){window.progressView.hide(),arangoHelper.arangoError("Query error","queries could not be imported")}}))}})}(),window.ArangoReplication=Backbone.Collection.extend({model:window.Replication,url:"../api/user",getLogState:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/replication/logger-state",contentType:"application/json", +processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a},getApplyState:function(){var a;return $.ajax({type:"GET",cache:!1,url:"/_api/replication/applier-state",contentType:"application/json",processData:!1,async:!1,success:function(b){a=b},error:function(b){a=b}}),a}}),window.StatisticsCollection=Backbone.Collection.extend({model:window.Statistics,url:"/_admin/statistics"}),window.StatisticsDescriptionCollection=Backbone.Collection.extend({model:window.StatisticsDescription,url:"/_admin/statistics-description",parse:function(a){return a}}),window.ArangoUsers=Backbone.Collection.extend({model:window.Users,activeUser:null,activeUserSettings:{query:{},shell:{},testing:!0},sortOptions:{desc:!1},url:"/_api/user",comparator:function(a,b){var c=a.get("user").toLowerCase(),d=b.get("user").toLowerCase();return this.sortOptions.desc===!0?d>c?1:c>d?-1:0:c>d?1:d>c?-1:0},login:function(a,b){var c=null;return $.ajax("login",{async:!1,method:"POST",data:JSON.stringify({username:a,password:b}),dataType:"json"}).done(function(a){c=a.user}),this.activeUser=c,this.activeUser},setSortingDesc:function(a){this.sortOptions.desc=a},logout:function(){$.ajax("logout",{async:!1,method:"POST"}),this.activeUser=null,this.reset(),window.App.navigate(""),window.location.reload()},setUserSettings:function(a,b){this.activeUserSettings.identifier=b},loadUserSettings:function(){var a=this;$.ajax({type:"GET",cache:!1,url:"/_api/user/"+encodeURIComponent(a.activeUser),contentType:"application/json",processData:!1,async:!1,success:function(b){a.activeUserSettings=b.extra},error:function(a){}})},saveUserSettings:function(){var a=this;$.ajax({cache:!1,type:"PUT",async:!1,url:"/_api/user/"+encodeURIComponent(a.activeUser),data:JSON.stringify({extra:a.activeUserSettings}),contentType:"application/json",processData:!1,success:function(a){},error:function(a){}})},parse:function(a){var b=[];return _.each(a.result,function(a){b.push(a)}),b},whoAmI:function(){if(this.activeUser)return this.activeUser;var a;return $.ajax("whoAmI?_="+Date.now(),{async:!1}).done(function(b){a=b.user}),this.activeUser=a,this.activeUser}}),function(){"use strict";window.FoxxCollection=Backbone.Collection.extend({model:window.Foxx,sortOptions:{desc:!1},url:"/_admin/aardvark/foxxes",comparator:function(a,b){var c,d;return this.sortOptions.desc===!0?(c=a.get("mount"),d=b.get("mount"),d>c?1:c>d?-1:0):(c=a.get("mount"),d=b.get("mount"),c>d?1:d>c?-1:0)},setSortingDesc:function(a){this.sortOptions.desc=a},installFromGithub:function(a,b,c,d){var e="/_admin/aardvark/foxxes/git?mount="+encodeURIComponent(b);void 0!==d&&(e+=d?"&replace=true":"&upgrade=true"),$.ajax({cache:!1,type:"PUT",url:e,data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a){c(a)},error:function(a){c(a)}})},installFromStore:function(a,b,c,d){var e="/_admin/aardvark/foxxes/store?mount="+encodeURIComponent(b);void 0!==d&&(e+=d?"&replace=true":"&upgrade=true"),$.ajax({cache:!1,type:"PUT",url:e,data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a){c(a)},error:function(a){c(a)}})},installFromZip:function(a,b,c,d){var e="/_admin/aardvark/foxxes/zip?mount="+encodeURIComponent(b);void 0!==d&&(e+=d?"&replace=true":"&upgrade=true"),$.ajax({cache:!1,type:"PUT",url:e,data:JSON.stringify({zipFile:a}),contentType:"application/json",processData:!1,success:function(a){c(a)},error:function(a){c(a)}})},generate:function(a,b,c,d){var e="/_admin/aardvark/foxxes/generate?mount="+encodeURIComponent(b);void 0!==d&&(e+=d?"&replace=true":"&upgrade=true"),$.ajax({cache:!1,type:"PUT",url:e,data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a){c(a)},error:function(a){c(a)}})}})}(),function(){"use strict";window.GraphCollection=Backbone.Collection.extend({model:window.Graph,sortOptions:{desc:!1},url:"/_api/gharial",dropAndDeleteGraph:function(a,b){$.ajax({type:"DELETE",url:"/_api/gharial/"+encodeURIComponent(a)+"?dropCollections=true",contentType:"application/json",processData:!0,async:!1,success:function(){return arangoHelper.arangoNotification("Graph deleted."),b(!0),!0},error:function(a){try{var c=JSON.parse(a.responseText).errorMessage;arangoHelper.arangoError("Graph",c)}catch(d){arangoHelper.arangoError("Graph","Could not delete Graph.")}return b(!1),!1}})},comparator:function(a,b){var c=a.get("_key")||"",d=b.get("_key")||"";return c=c.toLowerCase(),d=d.toLowerCase(),this.sortOptions.desc===!0?d>c?1:c>d?-1:0:c>d?1:d>c?-1:0},setSortingDesc:function(a){this.sortOptions.desc=a},parse:function(a){return a.error?void 0:a.graphs}})}(),function(){"use strict";window.NotificationCollection=Backbone.Collection.extend({model:window.Notification,url:""})}(),function(){"use strict";window.QueryManagementActive=Backbone.Collection.extend({model:window.queryManagementModel,url:function(){return"/_api/query/current"},killRunningQuery:function(a,b){$.ajax({url:"/_api/query/"+encodeURIComponent(a),type:"DELETE",success:function(a){b()}})}})}(),function(){"use strict";window.QueryManagementSlow=Backbone.Collection.extend({model:window.queryManagementModel,url:"/_api/query/slow",deleteSlowQueryHistory:function(a){var b=this;$.ajax({url:b.url,type:"DELETE",success:function(b){a()}})}})}(),function(){"use strict";window.WorkMonitorCollection=Backbone.Collection.extend({model:window.workMonitorModel,url:"/_admin/work-monitor",parse:function(a){return a.work}})}(),function(){"use strict";window.PaginationView=Backbone.View.extend({collection:null,paginationDiv:"",idPrefix:"",rerender:function(){},jumpTo:function(a){this.collection.setPage(a),this.rerender()},firstPage:function(){this.jumpTo(1)},lastPage:function(){this.jumpTo(this.collection.getLastPageNumber())},firstDocuments:function(){this.jumpTo(1)},lastDocuments:function(){this.jumpTo(this.collection.getLastPageNumber())},prevDocuments:function(){this.jumpTo(this.collection.getPage()-1)},nextDocuments:function(){this.jumpTo(this.collection.getPage()+1)},renderPagination:function(){$(this.paginationDiv).html("");var a=this,b=this.collection.getPage(),c=this.collection.getLastPageNumber(),d=$(this.paginationDiv),e={page:b,lastPage:c,click:function(b){var c=window.location.hash.split("/");"documents"===c[2]?(e.page=b,window.location.hash=c[0]+"/"+c[1]+"/"+c[2]+"/"+b):(a.jumpTo(b),e.page=b)}};d.html(""),d.pagination(e),$(this.paginationDiv).prepend('
    '),$(this.paginationDiv).append('
    ')}})}(),function(){"use strict";window.ApplicationDetailView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("applicationDetailView.ejs"),events:{"click .open":"openApp","click .delete":"deleteApp","click #app-config":"showConfigDialog","click #app-deps":"showDepsDialog","click #app-switch-mode":"toggleDevelopment","click #app-scripts [data-script]":"runScript","click #app-tests":"runTests","click #app-replace":"replaceApp","click #download-app":"downloadApp","click #app-show-swagger":"showSwagger","click #app-show-readme":"showReadme","mouseenter #app-scripts":"showDropdown","mouseleave #app-scripts":"hideDropdown"},downloadApp:function(){this.model.isSystem()||this.model.download()},replaceApp:function(){var a=this.model.get("mount");window.foxxInstallView.upgrade(a,function(){window.App.applicationDetail(encodeURIComponent(a))}),$(".createModalDialog .arangoHeader").html("Replace Service"),$("#infoTab").click()},updateConfig:function(){this.model.getConfiguration(function(){$("#app-warning")[this.model.needsAttention()?"show":"hide"](),$("#app-warning-config")[this.model.needsConfiguration()?"show":"hide"](),this.model.needsConfiguration()?$("#app-config").addClass("error"):$("#app-config").removeClass("error")}.bind(this))},updateDeps:function(){this.model.getDependencies(function(){$("#app-warning")[this.model.needsAttention()?"show":"hide"](),$("#app-warning-deps")[this.model.hasUnconfiguredDependencies()?"show":"hide"](),this.model.hasUnconfiguredDependencies()?$("#app-deps").addClass("error"):$("#app-deps").removeClass("error")}.bind(this))},toggleDevelopment:function(){this.model.toggleDevelopment(!this.model.isDevelopment(),function(){this.model.isDevelopment()?($("#app-switch-mode").val("Set Production"),$("#app-development-indicator").css("display","inline"),$("#app-development-path").css("display","inline")):($("#app-switch-mode").val("Set Development"),$("#app-development-indicator").css("display","none"),$("#app-development-path").css("display","none"))}.bind(this))},runScript:function(a){a.preventDefault();var b=$(a.currentTarget).attr("data-script"),c=[window.modalView.createBlobEntry("app_script_arguments","Script arguments","",null,"optional",!1,[{rule:function(a){return a&&JSON.parse(a)},msg:"Must be well-formed JSON or empty"}])],d=[window.modalView.createSuccessButton("Run script",function(){var a=$("#app_script_arguments").val();a=a&&JSON.parse(a),window.modalView.hide(),this.model.runScript(b,a,function(a,c){var d;d=a?"

    The script failed with an error"+(a.statusCode?" (HTTP "+a.statusCode+")":"")+":

    "+a.message+"
    ":c?"

    Script results:

    "+JSON.stringify(c,null,2)+"
    ":"

    The script ran successfully.

    ",window.modalView.show("modalTable.ejs",'Result of script "'+b+'"',void 0,void 0,void 0,d)})}.bind(this))];window.modalView.show("modalTable.ejs",'Run script "'+b+'" on "'+this.model.get("mount")+'"',d,c)},showSwagger:function(a){a.preventDefault(),this.render("swagger")},showReadme:function(a){a.preventDefault(),this.render("readme")},runTests:function(a){a.preventDefault();var b="

    WARNING: Running tests may result in destructive side-effects including data loss. Please make sure not to run tests on a production database.

    ";this.model.isDevelopment()&&(b+="

    WARNING: This app is running in development mode. If any of the tests access the app's HTTP API they may become non-deterministic.

    ");var c=[window.modalView.createSuccessButton("Run tests",function(){window.modalView.hide(),this.model.runTests({reporter:"suite"},function(a,b){window.modalView.show("modalTestResults.ejs","Test results",void 0,void 0,void 0,a||b)})}.bind(this))];window.modalView.show("modalTable.ejs",'Run tests for app "'+this.model.get("mount")+'"',c,void 0,void 0,b)},render:function(a){var b=this;return $(this.el).html(this.template.render({app:this.model,db:arangoHelper.currentDatabase(),mode:a})),$.get(this.appUrl()).success(function(){$(".open",this.el).prop("disabled",!1)}.bind(this)),this.updateConfig(),this.updateDeps(),"swagger"===a&&$.get("./foxxes/docs/swagger.json?mount="+encodeURIComponent(this.model.get("mount")),function(a){Object.keys(a.paths).length<1&&(b.render("readme"),$("#app-show-swagger").attr("disabled","true"))}),$(this.el)},openApp:function(){window.open(this.appUrl(),this.model.get("title")).focus()},deleteApp:function(){var a=[window.modalView.createDeleteButton("Delete",function(){var a={teardown:$("#app_delete_run_teardown").is(":checked")};this.model.destroy(a,function(a,b){a||b.error!==!1||(window.modalView.hide(),window.App.navigate("applications",{trigger:!0}))})}.bind(this))],b=[window.modalView.createCheckboxEntry("app_delete_run_teardown","Run teardown?",!0,"Should this app's teardown script be executed before removing the app?",!0)];window.modalView.show("modalTable.ejs",'Delete Foxx App mounted at "'+this.model.get("mount")+'"',a,b,void 0,"

    Are you sure? There is no way back...

    ",!0)},appUrl:function(){return window.location.origin+"/_db/"+encodeURIComponent(arangoHelper.currentDatabase())+this.model.get("mount")},applyConfig:function(){var a={};_.each(this.model.get("config"),function(b,c){var d=$("#app_config_"+c),e=d.val();if("boolean"===b.type||"bool"===b.type)return void(a[c]=d.is(":checked"));if(""===e&&b.hasOwnProperty("default"))return a[c]=b["default"],void("json"===b.type&&(a[c]=JSON.stringify(b["default"])));if("number"===b.type)a[c]=parseFloat(e);else if("integer"===b.type||"int"===b.type)a[c]=parseInt(e,10);else{if("json"!==b.type)return void(a[c]=window.arangoHelper.escapeHtml(e));a[c]=e&&JSON.stringify(JSON.parse(e))}}),this.model.setConfiguration(a,function(){window.modalView.hide(),this.updateConfig()}.bind(this))},showConfigDialog:function(){if(!_.isEmpty(this.model.get("config"))){var a=_.map(this.model.get("config"),function(a,b){var c=void 0===a["default"]?"":String(a["default"]),d=void 0===a.current?"":String(a.current),e="createTextEntry",f=!1,g=[];return"boolean"===a.type||"bool"===a.type?(e="createCheckboxEntry",a["default"]=a["default"]||!1,c=a["default"]||!1,d=a.current||!1):"json"===a.type?(e="createBlobEntry",c=void 0===a["default"]?"":JSON.stringify(a["default"]),d=void 0===a.current?"":a.current,g.push({rule:function(a){return a&&JSON.parse(a)},msg:"Must be well-formed JSON or empty."})):"integer"===a.type||"int"===a.type?g.push({rule:Joi.number().integer().optional().allow(""),msg:"Has to be an integer."}):"number"===a.type?g.push({rule:Joi.number().optional().allow(""),msg:"Has to be a number."}):("password"===a.type&&(e="createPasswordEntry"),g.push({rule:Joi.string().optional().allow(""),msg:"Has to be a string."})),void 0===a["default"]&&a.required!==!1&&(f=!0,g.unshift({rule:Joi.any().required(),msg:"This field is required."})),window.modalView[e]("app_config_"+b,b,d,a.description,c,f,g)}),b=[window.modalView.createSuccessButton("Apply",this.applyConfig.bind(this))];window.modalView.show("modalTable.ejs","Configuration",b,a)}},applyDeps:function(){var a={};_.each(this.model.get("deps"),function(b,c){var d=$("#app_deps_"+c);a[c]=window.arangoHelper.escapeHtml(d.val())}),this.model.setDependencies(a,function(){window.modalView.hide(),this.updateDeps()}.bind(this))},showDepsDialog:function(){if(!_.isEmpty(this.model.get("deps"))){var a=_.map(this.model.get("deps"),function(a,b){var c=void 0===a.current?"":String(a.current),d="",e=a.definition.name;"*"!==a.definition.version&&(e+="@"+a.definition.version);var f=[{rule:Joi.string().optional().allow(""),msg:"Has to be a string."}];return a.definition.required&&f.push({rule:Joi.string().required(),msg:"This value is required."}),window.modalView.createTextEntry("app_deps_"+b,a.title,c,e,d,a.definition.required,f)}),b=[window.modalView.createSuccessButton("Apply",this.applyDeps.bind(this))];window.modalView.show("modalTable.ejs","Dependencies",b,a)}},showDropdown:function(){_.isEmpty(this.model.get("scripts"))||$("#scripts_dropdown").show(200)},hideDropdown:function(){$("#scripts_dropdown").hide()}})}(),function(){"use strict";window.ApplicationsView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("applicationsView.ejs"),events:{"click #addApp":"createInstallModal","click #foxxToggle":"slideToggle","click #checkDevel":"toggleDevel","click #checkProduction":"toggleProduction","click #checkSystem":"toggleSystem"},fixCheckboxes:function(){this._showDevel?$("#checkDevel").attr("checked","checked"):$("#checkDevel").removeAttr("checked"),this._showSystem?$("#checkSystem").attr("checked","checked"):$("#checkSystem").removeAttr("checked"),this._showProd?$("#checkProduction").attr("checked","checked"):$("#checkProduction").removeAttr("checked"),$("#checkDevel").next().removeClass("fa fa-check-square-o fa-square-o").addClass("fa"),$("#checkSystem").next().removeClass("fa fa-check-square-o fa-square-o").addClass("fa"),$("#checkProduction").next().removeClass("fa fa-check-square-o fa-square-o").addClass("fa"),arangoHelper.setCheckboxStatus("#foxxDropdown")},toggleDevel:function(){var a=this;this._showDevel=!this._showDevel,_.each(this._installedSubViews,function(b){b.toggle("devel",a._showDevel)}),this.fixCheckboxes()},toggleProduction:function(){var a=this;this._showProd=!this._showProd,_.each(this._installedSubViews,function(b){b.toggle("production",a._showProd)}),this.fixCheckboxes()},toggleSystem:function(){this._showSystem=!this._showSystem;var a=this;_.each(this._installedSubViews,function(b){b.toggle("system",a._showSystem)}),this.fixCheckboxes()},reload:function(){var a=this;_.each(this._installedSubViews,function(a){a.undelegateEvents()}),this.collection.fetch({success:function(){a.createSubViews(),a.render()}})},createSubViews:function(){var a=this;this._installedSubViews={},a.collection.each(function(b){var c=new window.FoxxActiveView({model:b,appsView:a});a._installedSubViews[b.get("mount")]=c})},initialize:function(){this._installedSubViews={},this._showDevel=!0,this._showProd=!0,this._showSystem=!1,this.reload()},slideToggle:function(){$("#foxxToggle").toggleClass("activated"),$("#foxxDropdownOut").slideToggle(200)},createInstallModal:function(a){a.preventDefault(),window.foxxInstallView.install(this.reload.bind(this))},render:function(){this.collection.sort(),$(this.el).html(this.template.render({})),_.each(this._installedSubViews,function(a){$("#installedList").append(a.render())}),this.delegateEvents(),$("#checkDevel").attr("checked",this._showDevel),$("#checkProduction").attr("checked",this._showProd),$("#checkSystem").attr("checked",this._showSystem),arangoHelper.setCheckboxStatus("#foxxDropdown");var a=this;return _.each(this._installedSubViews,function(b){b.toggle("devel",a._showDevel),b.toggle("system",a._showSystem)}),arangoHelper.fixTooltips("icon_arangodb","left"),this}})}(),function(){"use strict";window.CollectionListItemView=Backbone.View.extend({tagName:"div",className:"tile",template:templateEngine.createTemplate("collectionsItemView.ejs"),initialize:function(){this.collectionsView=this.options.collectionsView},events:{"click .iconSet.icon_arangodb_settings2":"createEditPropertiesModal","click .pull-left":"noop","click .icon_arangodb_settings2":"editProperties","click .spanInfo":"showProperties",click:"selectCollection"},render:function(){return this.model.get("locked")&&$(this.el).addClass("locked"),$(this.el).html(this.template.render({model:this.model})),$(this.el).attr("id","collection_"+this.model.get("name")),this},editProperties:function(a){return this.model.get("locked")?0:(a.stopPropagation(),void this.createEditPropertiesModal())},showProperties:function(a){return this.model.get("locked")?0:(a.stopPropagation(),void this.createInfoModal())},selectCollection:function(a){return $(a.target).hasClass("disabled")?0:this.model.get("locked")?0:void window.App.navigate("collection/"+encodeURIComponent(this.model.get("name"))+"/documents/1",{trigger:!0})},noop:function(a){a.stopPropagation()},unloadCollection:function(){var a=function(a){a?arangoHelper.arangoError("Collection error",this.model.get("name")+" could not be unloaded."):void 0===a?(this.model.set("status","unloading"),this.render()):"#collections"===window.location.hash?(this.model.set("status","unloaded"),this.render()):arangoHelper.arangoNotification("Collection "+this.model.get("name")+" unloaded.")}.bind(this);this.model.unloadCollection(a),window.modalView.hide()},loadCollection:function(){var a=function(a){a?arangoHelper.arangoError("Collection error",this.model.get("name")+" could not be loaded."):void 0===a?(this.model.set("status","loading"),this.render()):"#collections"===window.location.hash?(this.model.set("status","loaded"),this.render()):arangoHelper.arangoNotification("Collection "+this.model.get("name")+" loaded.")}.bind(this);this.model.loadCollection(a),window.modalView.hide()},truncateCollection:function(){this.model.truncateCollection(),this.render(),window.modalView.hide()},deleteCollection:function(){this.model.destroy({error:function(){arangoHelper.arangoError("Could not delete collection.")},success:function(){window.modalView.hide()}}),this.collectionsView.render()},saveModifiedCollection:function(){var a;a=window.isCoordinator()?this.model.get("name"):$("#change-collection-name").val();var b=this.model.get("status");if("loaded"===b){var c;try{c=JSON.parse(1024*$("#change-collection-size").val()*1024)}catch(d){return arangoHelper.arangoError("Please enter a valid number"),0}var e;try{if(e=JSON.parse($("#change-index-buckets").val()),1>e||parseInt(e)!==Math.pow(2,Math.log2(e)))throw"invalid indexBuckets value"}catch(d){return arangoHelper.arangoError("Please enter a valid number of index buckets"),0}var f;if(this.model.get("name")!==a&&(f=this.model.renameCollection(a)),f!==!0&&void 0!==f)return arangoHelper.arangoError("Collection error: "+f),0;var g=$("#change-collection-sync").val(),h=this.model.changeCollection(g,c,e);if(h!==!0)return arangoHelper.arangoNotification("Collection error",h),0;this.collectionsView.render(),window.modalView.hide()}else if("unloaded"===b)if(this.model.get("name")!==a){var i=this.model.renameCollection(a);i===!0?(this.collectionsView.render(),window.modalView.hide()):arangoHelper.arangoError("Collection error: "+i)}else window.modalView.hide()},createEditPropertiesModal:function(){var a=!1;"loaded"===this.model.get("status")&&(a=!0);var b=[],c=[];if(window.isCoordinator()||c.push(window.modalView.createTextEntry("change-collection-name","Name",this.model.get("name"),!1,"",!0,[{rule:Joi.string().regex(/^[a-zA-Z]/),msg:"Collection name must always start with a letter."},{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only Symbols "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No collection name given."}])),a){var d=this.model.getProperties().journalSize;d/=1048576,c.push(window.modalView.createTextEntry("change-collection-size","Journal size",d,"The maximal size of a journal or datafile (in MB). Must be at least 1.","",!0,[{rule:Joi.string().allow("").optional().regex(/^[0-9]*$/),msg:"Must be a number."}]));var e=this.model.getProperties().indexBuckets;c.push(window.modalView.createTextEntry("change-index-buckets","Index buckets",e,"The number of index buckets for this collection. Must be at least 1 and a power of 2.","",!0,[{rule:Joi.string().allow("").optional().regex(/^[1-9][0-9]*$/),msg:"Must be a number greater than 1 and a power of 2."}]));var f=this.model.getProperties().waitForSync;c.push(window.modalView.createSelectEntry("change-collection-sync","Wait for sync",f,"Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}]))}c.push(window.modalView.createReadOnlyEntry("change-collection-id","ID",this.model.get("id"),"")),c.push(window.modalView.createReadOnlyEntry("change-collection-type","Type",this.model.get("type"),"")),c.push(window.modalView.createReadOnlyEntry("change-collection-status","Status",this.model.get("status"),"")),b.push(window.modalView.createDeleteButton("Delete",this.deleteCollection.bind(this))),b.push(window.modalView.createDeleteButton("Truncate",this.truncateCollection.bind(this))),a?b.push(window.modalView.createNotificationButton("Unload",this.unloadCollection.bind(this))):b.push(window.modalView.createNotificationButton("Load",this.loadCollection.bind(this))),b.push(window.modalView.createSuccessButton("Save",this.saveModifiedCollection.bind(this)));var g=["General","Indices"],h=["modalTable.ejs","indicesView.ejs"];window.modalView.show(h,"Modify Collection",b,c,null,null,this.events,null,g),"loaded"===this.model.get("status")?this.getIndex():$($("#infoTab").children()[1]).remove(),this.bindIndexEvents()},bindIndexEvents:function(){this.unbindIndexEvents();var a=this;$("#indexEditView #addIndex").bind("click",function(){a.toggleNewIndexView(),$("#cancelIndex").unbind("click"),$("#cancelIndex").bind("click",function(){a.toggleNewIndexView()}),$("#createIndex").unbind("click"),$("#createIndex").bind("click",function(){a.createIndex()})}),$("#newIndexType").bind("change",function(){a.selectIndexType()}),$(".deleteIndex").bind("click",function(b){a.prepDeleteIndex(b)}),$("#infoTab a").bind("click",function(a){if($("#indexDeleteModal").remove(),"Indices"!==$(a.currentTarget).html()||$(a.currentTarget).parent().hasClass("active")||($("#newIndexView").hide(),$("#indexEditView").show(),$("#modal-dialog .modal-footer .button-danger").hide(),$("#modal-dialog .modal-footer .button-success").hide(),$("#modal-dialog .modal-footer .button-notification").hide(),$("#addIndex").detach().appendTo("#modal-dialog .modal-footer")),"General"===$(a.currentTarget).html()&&!$(a.currentTarget).parent().hasClass("active")){$("#modal-dialog .modal-footer .button-danger").show(),$("#modal-dialog .modal-footer .button-success").show(),$("#modal-dialog .modal-footer .button-notification").show();var b=$(".index-button-bar")[0],c=$(".index-button-bar2")[0];$("#addIndex").detach().appendTo(b),$("#cancelIndex").is(":visible")&&($("#cancelIndex").detach().appendTo(c),$("#createIndex").detach().appendTo(c))}})},unbindIndexEvents:function(){$("#indexEditView #addIndex").unbind("click"),$("#newIndexType").unbind("change"),$("#infoTab a").unbind("click"),$(".deleteIndex").unbind("click")},createInfoModal:function(){var a=[],b=this.model;window.modalView.show("modalCollectionInfo.ejs","Collection: "+this.model.get("name"),a,b)},resetIndexForms:function(){$("#indexHeader input").val("").prop("checked",!1),$("#newIndexType").val("Cap").prop("selected",!0),this.selectIndexType()},createIndex:function(){var a,b,c,d=this,e=$("#newIndexType").val(),f={};switch(e){case"Cap":var g=parseInt($("#newCapSize").val(),10)||0,h=parseInt($("#newCapByteSize").val(),10)||0;f={type:"cap",size:g,byteSize:h};break;case"Geo":a=$("#newGeoFields").val();var i=d.checkboxToValue("#newGeoJson"),j=d.checkboxToValue("#newGeoConstraint"),k=d.checkboxToValue("#newGeoIgnoreNull");f={type:"geo",fields:d.stringToArray(a),geoJson:i,constraint:j,ignoreNull:k};break;case"Hash":a=$("#newHashFields").val(),b=d.checkboxToValue("#newHashUnique"),c=d.checkboxToValue("#newHashSparse"),f={type:"hash",fields:d.stringToArray(a),unique:b,sparse:c};break;case"Fulltext":a=$("#newFulltextFields").val();var l=parseInt($("#newFulltextMinLength").val(),10)||0;f={type:"fulltext",fields:d.stringToArray(a),minLength:l};break;case"Skiplist":a=$("#newSkiplistFields").val(),b=d.checkboxToValue("#newSkiplistUnique"),c=d.checkboxToValue("#newSkiplistSparse"),f={type:"skiplist",fields:d.stringToArray(a),unique:b,sparse:c}}var m=function(a,b){if(a)if(b){var c=JSON.parse(b.responseText);arangoHelper.arangoError("Document error",c.errorMessage)}else arangoHelper.arangoError("Document error","Could not create index.")};window.modalView.hide(),d.model.createIndex(f,m),window.App.arangoCollectionsStore.fetch({success:function(){d.collectionsView.render()}})},lastTarget:null,prepDeleteIndex:function(a){var b=this;this.lastTarget=a,this.lastId=$(this.lastTarget.currentTarget).parent().parent().first().children().first().text(),$("#modal-dialog .modal-footer").after(''),$("#indexConfirmDelete").unbind("click"),$("#indexConfirmDelete").bind("click",function(){$("#indexDeleteModal").remove(),b.deleteIndex()}),$("#indexAbortDelete").unbind("click"),$("#indexAbortDelete").bind("click",function(){$("#indexDeleteModal").remove()})},deleteIndex:function(){var a=function(a){a?(arangoHelper.arangoError("Could not delete index"),$("tr th:contains('"+this.lastId+"')").parent().children().last().html('')):$("tr th:contains('"+this.lastId+"')").parent().remove()}.bind(this);this.model.deleteIndex(this.lastId,a),$("tr th:contains('"+this.lastId+"')").parent().children().last().html('')},selectIndexType:function(){$(".newIndexClass").hide();var a=$("#newIndexType").val();$("#newIndexType"+a).show()},getIndex:function(){this.index=this.model.getIndex();var a="collectionInfoTh modal-text";if(this.index){var b="",c="";_.each(this.index.indexes,function(d){c="primary"===d.type||"edge"===d.type?'':'',void 0!==d.fields&&(b=d.fields.join(", "));var e=d.id.indexOf("/"),f=d.id.substr(e+1,d.id.length),g=d.hasOwnProperty("selectivityEstimate")?(100*d.selectivityEstimate).toFixed(2)+"%":"n/a",h=d.hasOwnProperty("sparse")?d.sparse:"n/a";$("#collectionEditIndexTable").append(""+f+""+d.type+""+d.unique+""+h+""+g+""+b+""+c+"")})}},toggleNewIndexView:function(){var a=$(".index-button-bar2")[0],b=$(".index-button-bar")[0];$("#indexEditView").is(":visible")?($("#indexEditView").hide(),$("#newIndexView").show(),$("#addIndex").detach().appendTo(b),$("#cancelIndex").detach().appendTo("#modal-dialog .modal-footer"),$("#createIndex").detach().appendTo("#modal-dialog .modal-footer")):($("#indexEditView").show(),$("#newIndexView").hide(),$("#addIndex").detach().appendTo("#modal-dialog .modal-footer"),$("#cancelIndex").detach().appendTo(a),$("#createIndex").detach().appendTo(a)),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","right"),this.resetIndexForms()},stringToArray:function(a){var b=[];return a.split(",").forEach(function(a){a=a.replace(/(^\s+|\s+$)/g,""),""!==a&&b.push(a)}),b},checkboxToValue:function(a){return $(a).prop("checked")}})}(),function(){"use strict";window.CollectionsView=Backbone.View.extend({el:"#content",el2:"#collectionsThumbnailsIn",searchTimeout:null,refreshRate:2e3,template:templateEngine.createTemplate("collectionsView.ejs"),checkLockedCollections:function(){var a=this,b=window.arangoHelper.syncAndReturnUninishedAardvarkJobs("index");this.collection.each(function(a){a.set("locked",!1)}),_.each(b,function(b){var c=a.collection.findWhere({id:b.collection});c.set("locked",!0),c.set("lockType",b.type)}),this.collection.each(function(a){a.get("locked")?$("#collection_"+a.get("name")).addClass("locked"):$("#collection_"+a.get("name")).removeClass("locked")})},initialize:function(){var a=this;window.setInterval(function(){a.checkLockedCollections()},a.refreshRate)},render:function(){this.checkLockedCollections();var a=!1;$("#collectionsDropdown").is(":visible")&&(a=!0),$(this.el).html(this.template.render({})),this.setFilterValues(),a===!0&&$("#collectionsDropdown2").show();var b=this.collection.searchOptions;this.collection.getFiltered(b).forEach(function(a){$("#collectionsThumbnailsIn",this.el).append(new window.CollectionListItemView({model:a,collectionsView:this}).render().el)},this),"none"===$("#collectionsDropdown2").css("display")?$("#collectionsToggle").removeClass("activated"):$("#collectionsToggle").addClass("activated");var c;arangoHelper.setCheckboxStatus("#collectionsDropdown");try{c=b.searchPhrase.length}catch(d){}return $("#searchInput").val(b.searchPhrase),$("#searchInput").focus(),$("#searchInput")[0].setSelectionRange(c,c),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","left"),this},events:{"click #createCollection":"createCollection","keydown #searchInput":"restrictToSearchPhraseKey","change #searchInput":"restrictToSearchPhrase","click #searchSubmit":"restrictToSearchPhrase","click .checkSystemCollections":"checkSystem","click #checkLoaded":"checkLoaded","click #checkUnloaded":"checkUnloaded","click #checkDocument":"checkDocument","click #checkEdge":"checkEdge","click #sortName":"sortName","click #sortType":"sortType","click #sortOrder":"sortOrder","click #collectionsToggle":"toggleView", +"click .css-label":"checkBoxes"},updateCollectionsView:function(){var a=this;this.collection.fetch({success:function(){a.render()}})},toggleView:function(){$("#collectionsToggle").toggleClass("activated"),$("#collectionsDropdown2").slideToggle(200)},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},checkSystem:function(){var a=this.collection.searchOptions,b=a.includeSystem;a.includeSystem=$(".checkSystemCollections").is(":checked")===!0,b!==a.includeSystem&&this.render()},checkEdge:function(){var a=this.collection.searchOptions,b=a.includeEdge;a.includeEdge=$("#checkEdge").is(":checked")===!0,b!==a.includeEdge&&this.render()},checkDocument:function(){var a=this.collection.searchOptions,b=a.includeDocument;a.includeDocument=$("#checkDocument").is(":checked")===!0,b!==a.includeDocument&&this.render()},checkLoaded:function(){var a=this.collection.searchOptions,b=a.includeLoaded;a.includeLoaded=$("#checkLoaded").is(":checked")===!0,b!==a.includeLoaded&&this.render()},checkUnloaded:function(){var a=this.collection.searchOptions,b=a.includeUnloaded;a.includeUnloaded=$("#checkUnloaded").is(":checked")===!0,b!==a.includeUnloaded&&this.render()},sortName:function(){var a=this.collection.searchOptions,b=a.sortBy;a.sortBy=$("#sortName").is(":checked")===!0?"name":"type",b!==a.sortBy&&this.render()},sortType:function(){var a=this.collection.searchOptions,b=a.sortBy;a.sortBy=$("#sortType").is(":checked")===!0?"type":"name",b!==a.sortBy&&this.render()},sortOrder:function(){var a=this.collection.searchOptions,b=a.sortOrder;a.sortOrder=$("#sortOrder").is(":checked")===!0?-1:1,b!==a.sortOrder&&this.render()},setFilterValues:function(){var a=this.collection.searchOptions;$("#checkLoaded").attr("checked",a.includeLoaded),$("#checkUnloaded").attr("checked",a.includeUnloaded),$(".checkSystemCollections").attr("checked",a.includeSystem),$("#checkEdge").attr("checked",a.includeEdge),$("#checkDocument").attr("checked",a.includeDocument),$("#sortName").attr("checked","type"!==a.sortBy),$("#sortType").attr("checked","type"===a.sortBy),$("#sortOrder").attr("checked",1!==a.sortOrder)},search:function(){var a=this.collection.searchOptions,b=$("#searchInput").val();b!==a.searchPhrase&&(a.searchPhrase=b,this.render())},resetSearch:function(){this.searchTimeout&&(clearTimeout(this.searchTimeout),this.searchTimeout=null);var a=this.collection.searchOptions;a.searchPhrase=null},restrictToSearchPhraseKey:function(){var a=this;this.resetSearch(),a.searchTimeout=setTimeout(function(){a.search()},200)},restrictToSearchPhrase:function(){this.resetSearch(),this.search()},createCollection:function(a){a.preventDefault(),this.createNewCollectionModal()},submitCreateCollection:function(){var a=$("#new-collection-name").val(),b=$("#new-collection-size").val(),c=$("#new-collection-type").val(),d=$("#new-collection-sync").val(),e=1,f=[];if(window.isCoordinator()){if(e=$("#new-collection-shards").val(),""===e&&(e=1),e=parseInt(e,10),1>e)return arangoHelper.arangoError("Number of shards has to be an integer value greater or equal 1"),0;f=_.pluck($("#new-collection-shardBy").select2("data"),"text"),0===f.length&&f.push("_key")}if("_"===a.substr(0,1))return arangoHelper.arangoError('No "_" allowed as first character!'),0;var g=!1,h="true"===d;if(b>0)try{b=1024*JSON.parse(b)*1024}catch(i){return arangoHelper.arangoError("Please enter a valid number"),0}if(""===a)return arangoHelper.arangoError("No collection name entered!"),0;var j=this.collection.newCollection(a,h,g,b,c,e,f);j.status!==!0&&arangoHelper.arangoError("Collection error",j.errorMessage),this.updateCollectionsView(),window.modalView.hide()},createNewCollectionModal:function(){var a=[],b=[],c={},d=[];b.push(window.modalView.createTextEntry("new-collection-name","Name","",!1,"",!0,[{rule:Joi.string().regex(/^[a-zA-Z]/),msg:"Collection name must always start with a letter."},{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only symbols, "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No collection name given."}])),b.push(window.modalView.createSelectEntry("new-collection-type","Type","","The type of the collection to create.",[{value:2,label:"Document"},{value:3,label:"Edge"}])),window.isCoordinator()&&(b.push(window.modalView.createTextEntry("new-collection-shards","Shards","","The number of shards to create. You cannot change this afterwards. Recommended: DBServers squared","",!0)),b.push(window.modalView.createSelect2Entry("new-collection-shardBy","shardBy","","The keys used to distribute documents on shards. Type the key and press return to add it.","_key",!1))),a.push(window.modalView.createSuccessButton("Save",this.submitCreateCollection.bind(this))),d.push(window.modalView.createTextEntry("new-collection-size","Journal size","","The maximal size of a journal or datafile (in MB). Must be at least 1.","",!1,[{rule:Joi.string().allow("").optional().regex(/^[0-9]*$/),msg:"Must be a number."}])),d.push(window.modalView.createSelectEntry("new-collection-sync","Sync","","Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}])),c.header="Advanced",c.content=d,window.modalView.show("modalTable.ejs","New Collection",a,b,c)}})}(),function(){"use strict";function a(a,b){return(void 0===a||null===a)&&(a=0),a.toFixed(b)}window.DashboardView=Backbone.View.extend({el:"#content",interval:1e4,defaultTimeFrame:12e5,defaultDetailFrame:1728e5,history:{},graphs:{},events:{},tendencies:{asyncPerSecondCurrent:["asyncPerSecondCurrent","asyncPerSecondPercentChange"],syncPerSecondCurrent:["syncPerSecondCurrent","syncPerSecondPercentChange"],clientConnectionsCurrent:["clientConnectionsCurrent","clientConnectionsPercentChange"],clientConnectionsAverage:["clientConnections15M","clientConnections15MPercentChange"],numberOfThreadsCurrent:["numberOfThreadsCurrent","numberOfThreadsPercentChange"],numberOfThreadsAverage:["numberOfThreads15M","numberOfThreads15MPercentChange"],virtualSizeCurrent:["virtualSizeCurrent","virtualSizePercentChange"],virtualSizeAverage:["virtualSize15M","virtualSize15MPercentChange"]},barCharts:{totalTimeDistribution:["queueTimeDistributionPercent","requestTimeDistributionPercent"],dataTransferDistribution:["bytesSentDistributionPercent","bytesReceivedDistributionPercent"]},barChartsElementNames:{queueTimeDistributionPercent:"Queue",requestTimeDistributionPercent:"Computation",bytesSentDistributionPercent:"Bytes sent",bytesReceivedDistributionPercent:"Bytes received"},getDetailFigure:function(a){var b=$(a.currentTarget).attr("id").replace(/ChartButton/g,"");return b},showDetail:function(a){var b,c=this,d=this.getDetailFigure(a);b=this.dygraphConfig.getDetailChartConfig(d),this.getHistoryStatistics(d),this.detailGraphFigure=d,window.modalView.hideFooter=!0,window.modalView.hide(),window.modalView.show("modalGraph.ejs",b.header,void 0,void 0,void 0,void 0,this.events),window.modalView.hideFooter=!1,$("#modal-dialog").on("hidden",function(){c.hidden()}),$("#modal-dialog").toggleClass("modal-chart-detail",!0),b.height=.7*$(window).height(),b.width=$(".modal-inner-detail").width(),b.labelsDiv=$(b.labelsDiv)[0],this.detailGraph=new Dygraph(document.getElementById("lineChartDetail"),this.history[this.server][d],b)},hidden:function(){this.detailGraph.destroy(),delete this.detailGraph,delete this.detailGraphFigure},getCurrentSize:function(a){"#"!==a.substr(0,1)&&(a="#"+a);var b,c;return $(a).attr("style",""),b=$(a).height(),c=$(a).width(),{height:b,width:c}},prepareDygraphs:function(){var a,b=this;this.dygraphConfig.getDashBoardFigures().forEach(function(c){a=b.dygraphConfig.getDefaultConfig(c);var d=b.getCurrentSize(a.div);a.height=d.height,a.width=d.width,b.graphs[c]=new Dygraph(document.getElementById(a.div),b.history[b.server][c]||[],a)})},initialize:function(){this.dygraphConfig=this.options.dygraphConfig,this.d3NotInitialized=!0,this.events["click .dashboard-sub-bar-menu-sign"]=this.showDetail.bind(this),this.events["mousedown .dygraph-rangesel-zoomhandle"]=this.stopUpdating.bind(this),this.events["mouseup .dygraph-rangesel-zoomhandle"]=this.startUpdating.bind(this),this.serverInfo=this.options.serverToShow,this.serverInfo?this.server=this.serverInfo.target:this.server="-local-",this.history[this.server]={}},updateCharts:function(){var a=this;return this.detailGraph?void this.updateLineChart(this.detailGraphFigure,!0):(this.prepareD3Charts(this.isUpdating),this.prepareResidentSize(this.isUpdating),this.updateTendencies(),void Object.keys(this.graphs).forEach(function(b){a.updateLineChart(b,!1)}))},updateTendencies:function(){var a=this,b=this.tendencies,c="";Object.keys(b).forEach(function(b){var d="",e=0;a.history.hasOwnProperty(a.server)&&a.history[a.server].hasOwnProperty(b)&&(e=a.history[a.server][b][1]),0>e?c="#d05448":(c="#7da817",d="+"),a.history.hasOwnProperty(a.server)&&a.history[a.server].hasOwnProperty(b)?$("#"+b).html(a.history[a.server][b][0]+'
    '+d+e+"%"):$("#"+b).html('
    data not ready yet')})},updateDateWindow:function(a,b){var c,d,e=(new Date).getTime();return b&&a.dateWindow_?(c=a.dateWindow_[0],d=e-a.dateWindow_[1]-5*this.interval>0?a.dateWindow_[1]:e,[c,d]):[e-this.defaultTimeFrame,e]},updateLineChart:function(a,b){var c=b?this.detailGraph:this.graphs[a],d={file:this.history[this.server][a],dateWindow:this.updateDateWindow(c,b)},e=0,f=[];_.each(d.file,function(a){var b=a[0].getSeconds()-a[0].getSeconds()%10;d.file[e][0].setSeconds(b),f.push(d.file[e][0]),e++});for(var g=new Date(Math.max.apply(null,f)),h=new Date(Math.min.apply(null,f)),i=new Date(h.getTime()),j=[],k=[];g>i;)i=new Date(i.setSeconds(i.getSeconds()+10)),k.push(i);_.each(k,function(a){var b=!1;_.each(d.file,function(c){Math.floor(a.getTime()/1e3)===Math.floor(c[0].getTime()/1e3)&&(b=!0)}),b===!1&&a1&&d.history[d.server][e].push(c))})},cutOffHistory:function(a,b){for(var c=this;0!==c.history[c.server][a].length;){var d=c.history[c.server][a][0][0];if(d>=b)break;c.history[c.server][a].shift()}},cutOffDygraphHistory:function(a){var b=this,c=new Date(a);this.dygraphConfig.getDashBoardFigures(!0).forEach(function(a){b.dygraphConfig.mapStatToFigure[a]&&b.history[b.server][a]&&b.cutOffHistory(a,c)})},mergeHistory:function(b){var c,d=this;for(c=0;c=0;--c)d.values.push({label:this.getLabel(b[a[0]].cuts,c),value:b[a[0]].values[c]}),e.values.push({label:this.getLabel(b[a[1]].cuts,c),value:b[a[1]].values[c]});return[d,e]},getLabel:function(a,b){return a[b]?0===b?"0 - "+a[b]:a[b-1]+" - "+a[b]:">"+a[b-1]},renderReplicationStatistics:function(a){$("#repl-numbers table tr:nth-child(1) > td:nth-child(2)").html(a.state.totalEvents),$("#repl-numbers table tr:nth-child(2) > td:nth-child(2)").html(a.state.totalRequests),$("#repl-numbers table tr:nth-child(3) > td:nth-child(2)").html(a.state.totalFailedConnects),a.state.lastAppliedContinuousTick?$("#repl-ticks table tr:nth-child(1) > td:nth-child(2)").html(a.state.lastAppliedContinuousTick):$("#repl-ticks table tr:nth-child(1) > td:nth-child(2)").html("no data available").addClass("no-data"),a.state.lastProcessedContinuousTick?$("#repl-ticks table tr:nth-child(2) > td:nth-child(2)").html(a.state.lastProcessedContinuousTick):$("#repl-ticks table tr:nth-child(2) > td:nth-child(2)").html("no data available").addClass("no-data"),a.state.lastAvailableContinuousTick?$("#repl-ticks table tr:nth-child(3) > td:nth-child(2)").html(a.state.lastAvailableContinuousTick):$("#repl-ticks table tr:nth-child(3) > td:nth-child(2)").html("no data available").addClass("no-data"),$("#repl-progress table tr:nth-child(1) > td:nth-child(2)").html(a.state.progress.message),$("#repl-progress table tr:nth-child(2) > td:nth-child(2)").html(a.state.progress.time),$("#repl-progress table tr:nth-child(3) > td:nth-child(2)").html(a.state.progress.failedConnects)},getReplicationStatistics:function(){var a=this;$.ajax("/_api/replication/applier-state",{async:!0}).done(function(b){if(b.hasOwnProperty("state")){var c;c=b.state.running?"active":"inactive",c=''+c+"",$("#replication-chart .dashboard-sub-bar").html("Replication "+c),a.renderReplicationStatistics(b)}})},getStatistics:function(a){var b=this,c="/_db/_system/_admin/aardvark/statistics/short",d="?start=";d+=b.nextStart?b.nextStart:((new Date).getTime()-b.defaultTimeFrame)/1e3,"-local-"!==b.server&&(c=b.serverInfo.endpoint+"/_admin/aardvark/statistics/cluster",d+="&type=short&DBserver="+b.serverInfo.target,b.history.hasOwnProperty(b.server)||(b.history[b.server]={})),$.ajax(c+d,{async:!0}).done(function(c){c.times.length>0&&(b.isUpdating=!0,b.mergeHistory(c)),b.isUpdating!==!1&&(a&&a(),b.updateCharts())}),this.getReplicationStatistics()},getHistoryStatistics:function(a){var b=this,c="statistics/long",d="?filter="+this.dygraphConfig.mapStatToFigure[a].join();"-local-"!==b.server&&(c=b.server.endpoint+"/_admin/aardvark/statistics/cluster",d+="&type=long&DBserver="+b.server.target,b.history.hasOwnProperty(b.server)||(b.history[b.server]={}));var e=window.location.href.split("/"),f=e[0]+"//"+e[2]+"/"+e[3]+"/_system/"+e[5]+"/"+e[6]+"/";$.ajax(f+c+d,{async:!0}).done(function(c){var d;for(b.history[b.server][a]=[],d=0;d data not ready yet

    '),$("#totalTimeDistribution").prepend('

    data not ready yet

    '),$(".dashboard-bar-chart-title").prepend('

    data not ready yet

    '))},removeEmptyDataLabels:function(){$(".dataNotReadyYet").remove()},prepareResidentSize:function(b){var c=this,d=this.getCurrentSize("#residentSizeChartContainer"),e=c.history[c.server].residentSizeCurrent/1024/1024,f="";f=1025>e?a(e,2)+" MB":a(e/1024,2)+" GB";var g=a(100*c.history[c.server].residentSizePercent,2),h=[a(c.history[c.server].physicalMemory/1024/1024/1024,0)+" GB"];return void 0===c.history[c.server].residentSizeChart?void this.addEmptyDataLabels():(this.removeEmptyDataLabels(),void nv.addGraph(function(){var a=nv.models.multiBarHorizontalChart().x(function(a){return a.label}).y(function(a){return a.value}).width(d.width).height(d.height).margin({top:($("residentSizeChartContainer").outerHeight()-$("residentSizeChartContainer").height())/2,right:1,bottom:($("residentSizeChartContainer").outerHeight()-$("residentSizeChartContainer").height())/2,left:1}).showValues(!1).showYAxis(!1).showXAxis(!1).transitionDuration(100).tooltips(!1).showLegend(!1).showControls(!1).stacked(!0);return a.yAxis.tickFormat(function(a){return a+"%"}).showMaxMin(!1),a.xAxis.showMaxMin(!1),d3.select("#residentSizeChart svg").datum(c.history[c.server].residentSizeChart).call(a),d3.select("#residentSizeChart svg").select(".nv-zeroLine").remove(),b&&(d3.select("#residentSizeChart svg").select("#total").remove(),d3.select("#residentSizeChart svg").select("#percentage").remove()),d3.select(".dashboard-bar-chart-title .percentage").html(f+" ("+g+" %)"),d3.select(".dashboard-bar-chart-title .absolut").html(h[0]),nv.utils.windowResize(a.update),a},function(){d3.selectAll("#residentSizeChart .nv-bar").on("click",function(){})}))},prepareD3Charts:function(b){var c=this,d={totalTimeDistribution:["queueTimeDistributionPercent","requestTimeDistributionPercent"],dataTransferDistribution:["bytesSentDistributionPercent","bytesReceivedDistributionPercent"]};this.d3NotInitialized&&(b=!1,this.d3NotInitialized=!1),_.each(Object.keys(d),function(b){var d=c.getCurrentSize("#"+b+"Container .dashboard-interior-chart"),e="#"+b+"Container svg";return void 0===c.history[c.server].residentSizeChart?void c.addEmptyDataLabels():(c.removeEmptyDataLabels(),void nv.addGraph(function(){var f=[0,.25,.5,.75,1],g=75,h=23,i=6;d.width<219?(f=[0,.5,1],g=72,h=21,i=5):d.width<299?(f=[0,.3334,.6667,1],g=77):d.width<379?g=87:d.width<459?g=95:d.width<539?g=100:d.width<619&&(g=105);var j=nv.models.multiBarHorizontalChart().x(function(a){return a.label}).y(function(a){return a.value}).width(d.width).height(d.height).margin({top:5,right:20,bottom:h,left:g}).showValues(!1).showYAxis(!0).showXAxis(!0).transitionDuration(100).tooltips(!1).showLegend(!1).showControls(!1).forceY([0,1]);j.yAxis.showMaxMin(!1);d3.select(".nv-y.nv-axis").selectAll("text").attr("transform","translate (0, "+i+")");return j.yAxis.tickValues(f).tickFormat(function(b){return a(100*b*100/100,0)+"%"}),d3.select(e).datum(c.history[c.server][b]).call(j),nv.utils.windowResize(j.update),j},function(){d3.selectAll(e+" .nv-bar").on("click",function(){})}))})},stopUpdating:function(){this.isUpdating=!1},startUpdating:function(){var a=this;a.timer||(a.timer=window.setInterval(function(){a.getStatistics()},a.interval))},resize:function(){if(this.isUpdating){var a,b=this;_.each(this.graphs,function(c){a=b.getCurrentSize(c.maindiv_.id),c.resize(a.width,a.height)}),this.detailGraph&&(a=this.getCurrentSize(this.detailGraph.maindiv_.id),this.detailGraph.resize(a.width,a.height)),this.prepareD3Charts(!0),this.prepareResidentSize(!0)}},template:templateEngine.createTemplate("dashboardView.ejs"),render:function(a){a||$(this.el).html(this.template.render());var b=function(){this.prepareDygraphs(),this.isUpdating&&(this.prepareD3Charts(),this.prepareResidentSize(),this.updateTendencies()),this.startUpdating()}.bind(this),c=this.options.database.hasSystemAccess();c?this.getStatistics(b):($(".contentDiv").remove(),$(".headerBar").remove(),$(".dashboard-headerbar").remove(),$(".dashboard-row").remove(),$("#content").append('
    You do not have permission to view this page.
    '),$("#content").append("
    You can switch to '_system' to see the dashboard.
    "))}})}(),function(){"use strict";window.databaseView=Backbone.View.extend({users:null,el:"#content",template:templateEngine.createTemplate("databaseView.ejs"),dropdownVisible:!1,currentDB:"",events:{"click #createDatabase":"createDatabase","click #submitCreateDatabase":"submitCreateDatabase","click .editDatabase":"editDatabase","click .icon":"editDatabase","click #selectDatabase":"updateDatabase","click #submitDeleteDatabase":"submitDeleteDatabase","click .contentRowInactive a":"changeDatabase","keyup #databaseSearchInput":"search","click #databaseSearchSubmit":"search","click #databaseToggle":"toggleSettingsDropdown","click .css-label":"checkBoxes","click #dbSortDesc":"sorting","click .tile":"switchDatabase"},sorting:function(){$("#dbSortDesc").is(":checked")?this.collection.setSortingDesc(!0):this.collection.setSortingDesc(!1),$("#databaseDropdown").is(":visible")?this.dropdownVisible=!0:this.dropdownVisible=!1,this.render()},initialize:function(){this.collection.fetch({async:!1})},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},render:function(){return this.currentDatabase(),this.collection.sort(),$(this.el).html(this.template.render({collection:this.collection,searchString:"",currentDB:this.currentDB})),this.dropdownVisible===!0&&($("#dbSortDesc").attr("checked",this.collection.sortOptions.desc),$("#databaseToggle").toggleClass("activated"),$("#databaseDropdown2").show()),arangoHelper.setCheckboxStatus("#databaseDropdown"),this.replaceSVGs(),this},toggleSettingsDropdown:function(){$("#dbSortDesc").attr("checked",this.collection.sortOptions.desc),$("#databaseToggle").toggleClass("activated"),$("#databaseDropdown2").slideToggle(200)},selectedDatabase:function(){return $("#selectDatabases").val()},handleError:function(a,b,c){return 409===a?void arangoHelper.arangoError("DB","Database "+c+" already exists."):400===a?void arangoHelper.arangoError("DB","Invalid Parameters"):403===a?void arangoHelper.arangoError("DB","Insufficent rights. Execute this from _system database"):void 0},validateDatabaseInfo:function(a,b,c){return""===b?(arangoHelper.arangoError("DB","You have to define an owner for the new database"),!1):""===a?(arangoHelper.arangoError("DB","You have to define a name for the new database"),!1):0===a.indexOf("_")?(arangoHelper.arangoError("DB ","Databasename should not start with _"),!1):a.match(/^[a-zA-Z][a-zA-Z0-9_\-]*$/)?!0:(arangoHelper.arangoError("DB","Databasename may only contain numbers, letters, _ and -"),!1)},createDatabase:function(a){a.preventDefault(),this.createAddDatabaseModal()},switchDatabase:function(a){if(!$(a.target).parent().hasClass("iconSet")){var b=$(a.currentTarget).find("h5").text();if(""!==b){var c=this.collection.createDatabaseURL(b);window.location.replace(c)}}},submitCreateDatabase:function(){var a,b=this,c=$("#newDatabaseName").val(),d=$("#newUser").val();if(a="true"===$("#useDefaultPassword").val()?"ARANGODB_DEFAULT_ROOT_PASSWORD":$("#newPassword").val(),this.validateDatabaseInfo(c,d,a)){var e={name:c,users:[{username:d,passwd:a,active:!0}]};this.collection.create(e,{wait:!0,error:function(a,d){b.handleError(d.status,d.statusText,c)},success:function(a){b.updateDatabases(),window.modalView.hide(),window.App.naviView.dbSelectionView.render($("#dbSelect"))}})}},submitDeleteDatabase:function(a){var b=this.collection.where({name:a});b[0].destroy({wait:!0,url:"/_api/database/"+a}),this.updateDatabases(),window.App.naviView.dbSelectionView.render($("#dbSelect")),window.modalView.hide()},currentDatabase:function(){this.currentDB=this.collection.getCurrentDatabase()},changeDatabase:function(a){var b=$(a.currentTarget).attr("id"),c=this.collection.createDatabaseURL(b);window.location.replace(c)},updateDatabases:function(){var a=this;this.collection.fetch({success:function(){a.render(),window.App.handleSelectDatabase()}})},editDatabase:function(a){var b=this.evaluateDatabaseName($(a.currentTarget).attr("id"),"_edit-database"),c=!0;b===this.currentDB&&(c=!1),this.createEditDatabaseModal(b,c)},search:function(){var a,b,c,d;a=$("#databaseSearchInput"),b=$("#databaseSearchInput").val(),d=this.collection.filter(function(a){return-1!==a.get("name").indexOf(b)}),$(this.el).html(this.template.render({collection:d,searchString:b,currentDB:this.currentDB})),this.replaceSVGs(),a=$("#databaseSearchInput"),c=a.val().length,a.focus(),a[0].setSelectionRange(c,c)},replaceSVGs:function(){$(".svgToReplace").each(function(){var a=$(this),b=a.attr("id"),c=a.attr("src");$.get(c,function(c){var d=$(c).find("svg");d.attr("id",b).attr("class","tile-icon-svg").removeAttr("xmlns:a"),a.replaceWith(d)},"xml")})},evaluateDatabaseName:function(a,b){var c=a.lastIndexOf(b);return a.substring(0,c)},createEditDatabaseModal:function(a,b){var c=[],d=[];d.push(window.modalView.createReadOnlyEntry("id_name","Name",a,"")),b?c.push(window.modalView.createDeleteButton("Delete",this.submitDeleteDatabase.bind(this,a))):c.push(window.modalView.createDisabledButton("Delete")),window.modalView.show("modalTable.ejs","Delete database",c,d)},createAddDatabaseModal:function(){var a=[],b=[];b.push(window.modalView.createTextEntry("newDatabaseName","Name","",!1,"Database Name",!0,[{rule:Joi.string().regex(/^[a-zA-Z]/),msg:"Database name must start with a letter."},{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only Symbols "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No database name given."}])),b.push(window.modalView.createTextEntry("newUser","Username",null!==this.users?this.users.whoAmI():"root","Please define the owner of this database. This will be the only user having initial access to this database if authentication is turned on. Please note that if you specify a username different to your account you will not be able to access the database with your account after having creating it. Specifying a username is mandatory even with authentication turned off. If there is a failure you will be informed.","Database Owner",!0,[{rule:Joi.string().required(),msg:"No username given."}])),b.push(window.modalView.createSelectEntry("useDefaultPassword","Use default password",!0,"Read the password from the environment variable ARANGODB_DEFAULT_ROOT_PASSWORD.",[{value:!1,label:"No"},{value:!0,label:"Yes"}])),b.push(window.modalView.createPasswordEntry("newPassword","Password","",!1,"",!1)),a.push(window.modalView.createSuccessButton("Create",this.submitCreateDatabase.bind(this))),window.modalView.show("modalTable.ejs","Create Database",a,b),$("#useDefaultPassword").change(function(){"true"===$("#useDefaultPassword").val()?$("#row_newPassword").hide():$("#row_newPassword").show()}),$("#row_newPassword").hide()}})}(),function(){"use strict";window.DBSelectionView=Backbone.View.extend({template:templateEngine.createTemplate("dbSelectionView.ejs"),events:{"click .dbSelectionLink":"changeDatabase"},initialize:function(a){this.current=a.current},changeDatabase:function(a){var b=$(a.currentTarget).closest(".dbSelectionLink.tab").attr("id"),c=this.collection.createDatabaseURL(b);window.location.replace(c)},render:function(a){return this.$el=a,this.$el.html(this.template.render({list:this.collection.getDatabasesForUser(),current:this.current.get("name")})),this.delegateEvents(),this.el}})}(),function(){"use strict";var a=function(a){var b=a.split("/");return"collection/"+encodeURIComponent(b[0])+"/"+encodeURIComponent(b[1])};window.DocumentView=Backbone.View.extend({el:"#content",colid:0,docid:0,customView:!1,template:templateEngine.createTemplate("documentView.ejs"),events:{"click #saveDocumentButton":"saveDocument","click #deleteDocumentButton":"deleteDocumentModal","click #confirmDeleteDocument":"deleteDocument","click #document-from":"navigateToDocument","click #document-to":"navigateToDocument","keydown #documentEditor .ace_editor":"keyPress","keyup .jsoneditor .search input":"checkSearchBox"},checkSearchBox:function(a){""===$(a.currentTarget).val()&&this.editor.expandAll()},keyPress:function(a){a.ctrlKey&&13===a.keyCode?(a.preventDefault(),this.saveDocument()):a.metaKey&&13===a.keyCode&&(a.preventDefault(),this.saveDocument())},editor:0,setType:function(a){var b,c;return"edge"===a?(b=this.collection.getEdge(this.colid,this.docid),c="Edge: "):"document"===a&&(b=this.collection.getDocument(this.colid,this.docid),c="Document: "),b===!0?(this.type=a,this.fillInfo(c),this.fillEditor(),!0):void 0},deleteDocumentModal:function(){var a=[],b=[];b.push(window.modalView.createReadOnlyEntry("doc-delete-button","Delete","Delete this "+this.type+"?",void 0,void 0,!1,/[<>&'"]/)),a.push(window.modalView.createDeleteButton("Delete",this.deleteDocument.bind(this))),window.modalView.show("modalTable.ejs","Delete Document",a,b)},deleteDocument:function(){var a;if("document"===this.type){if(a=this.collection.deleteDocument(this.colid,this.docid),a===!1)return void arangoHelper.arangoError("Document error:","Could not delete")}else if("edge"===this.type&&(a=this.collection.deleteEdge(this.colid,this.docid),a===!1))return void arangoHelper.arangoError("Edge error:","Could not delete");if(a===!0)if(this.customView)this.customDeleteFunction();else{var b="collection/"+encodeURIComponent(this.colid)+"/documents/1";window.modalView.hide(),window.App.navigate(b,{trigger:!0})}},navigateToDocument:function(a){var b=$(a.target).attr("documentLink");b&&window.App.navigate(b,{trigger:!0})},fillInfo:function(b){var c=this.collection.first(),d=c.get("_id"),e=c.get("_key"),f=c.get("_rev"),g=c.get("_from"),h=c.get("_to");if($("#document-type").text(b),$("#document-id").text(d),$("#document-key").text(e),$("#document-rev").text(f),g&&h){var i=a(g),j=a(h);$("#document-from").text(g),$("#document-from").attr("documentLink",i),$("#document-to").text(h),$("#document-to").attr("documentLink",j)}else $(".edge-info-container").hide()},fillEditor:function(){var a=this.removeReadonlyKeys(this.collection.first().attributes);this.editor.set(a),$(".ace_content").attr("font-size","11pt")},jsonContentChanged:function(){this.enableSaveButton()},render:function(){$(this.el).html(this.template.render({})),this.disableSaveButton(),this.breadcrumb();var a=this,b=document.getElementById("documentEditor"),c={change:function(){a.jsonContentChanged()},search:!0,mode:"tree",modes:["tree","code"],iconlib:"fontawesome4"};return this.editor=new JSONEditor(b,c),this},removeReadonlyKeys:function(a){return _.omit(a,["_key","_id","_from","_to","_rev"])},saveDocument:function(){var a,b;if(void 0===$("#saveDocumentButton").attr("disabled")){try{a=this.editor.get()}catch(c){return this.errorConfirmation(c),void this.disableSaveButton()}if(a=JSON.stringify(a),"document"===this.type){if(b=this.collection.saveDocument(this.colid,this.docid,a),b===!1)return void arangoHelper.arangoError("Document error:","Could not save")}else if("edge"===this.type&&(b=this.collection.saveEdge(this.colid,this.docid,a),b===!1))return void arangoHelper.arangoError("Edge error:","Could not save");b===!0&&(this.successConfirmation(),this.disableSaveButton())}},successConfirmation:function(){arangoHelper.arangoNotification("Document saved."),$("#documentEditor .tree").animate({backgroundColor:"#C6FFB0"},500),$("#documentEditor .tree").animate({backgroundColor:"#FFFFF"},500),$("#documentEditor .ace_content").animate({backgroundColor:"#C6FFB0"},500),$("#documentEditor .ace_content").animate({backgroundColor:"#FFFFF"},500)},errorConfirmation:function(a){arangoHelper.arangoError("Document editor: ",a),$("#documentEditor .tree").animate({backgroundColor:"#FFB0B0"},500),$("#documentEditor .tree").animate({backgroundColor:"#FFFFF"},500),$("#documentEditor .ace_content").animate({backgroundColor:"#FFB0B0"},500),$("#documentEditor .ace_content").animate({backgroundColor:"#FFFFF"},500)},enableSaveButton:function(){$("#saveDocumentButton").prop("disabled",!1),$("#saveDocumentButton").addClass("button-success"),$("#saveDocumentButton").removeClass("button-close")},disableSaveButton:function(){$("#saveDocumentButton").prop("disabled",!0),$("#saveDocumentButton").addClass("button-close"),$("#saveDocumentButton").removeClass("button-success")},breadcrumb:function(){var a=window.location.hash.split("/");$("#transparentHeader").append('"); +},escaped:function(a){return a.replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}})}(),function(){"use strict";window.DocumentsView=window.PaginationView.extend({filters:{0:!0},filterId:0,paginationDiv:"#documentsToolbarF",idPrefix:"documents",addDocumentSwitch:!0,activeFilter:!1,lastCollectionName:void 0,restoredFilters:[],editMode:!1,allowUpload:!1,el:"#content",table:"#documentsTableID",template:templateEngine.createTemplate("documentsView.ejs"),collectionContext:{prev:null,next:null},editButtons:["#deleteSelected","#moveSelected"],initialize:function(){this.documentStore=this.options.documentStore,this.collectionsStore=this.options.collectionsStore,this.tableView=new window.TableView({el:this.table,collection:this.collection}),this.tableView.setRowClick(this.clicked.bind(this)),this.tableView.setRemoveClick(this.remove.bind(this))},setCollectionId:function(a,b){this.collection.setCollection(a),this.collection.setPage(b);var c=arangoHelper.collectionApiType(a);this.page=b,this.type=c,this.checkCollectionState(),this.collection.getDocuments(this.getDocsCallback.bind(this)),this.collectionModel=this.collectionsStore.get(a)},getDocsCallback:function(){$("#documents_last").css("visibility","hidden"),$("#documents_first").css("visibility","hidden"),this.drawTable(),this.renderPaginationElements()},events:{"click #collectionPrev":"prevCollection","click #collectionNext":"nextCollection","click #filterCollection":"filterCollection","click #markDocuments":"editDocuments","click #importCollection":"importCollection","click #exportCollection":"exportCollection","click #filterSend":"sendFilter","click #addFilterItem":"addFilterItem","click .removeFilterItem":"removeFilterItem","click #deleteSelected":"deleteSelectedDocs","click #moveSelected":"moveSelectedDocs","click #addDocumentButton":"addDocumentModal","click #documents_first":"firstDocuments","click #documents_last":"lastDocuments","click #documents_prev":"prevDocuments","click #documents_next":"nextDocuments","click #confirmDeleteBtn":"confirmDelete","click .key":"nop",keyup:"returnPressedHandler","keydown .queryline input":"filterValueKeydown","click #importModal":"showImportModal","click #resetView":"resetView","click #confirmDocImport":"startUpload","click #exportDocuments":"startDownload","change #documentSize":"setPagesize","change #docsSort":"setSorting"},showSpinner:function(){$("#uploadIndicator").show()},hideSpinner:function(){$("#uploadIndicator").hide()},showImportModal:function(){$("#docImportModal").modal("show")},hideImportModal:function(){$("#docImportModal").modal("hide")},setPagesize:function(){var a=$("#documentSize").find(":selected").val();this.collection.setPagesize(a),this.collection.getDocuments(this.getDocsCallback.bind(this))},setSorting:function(){var a=$("#docsSort").val();(""===a||void 0===a||null===a)&&(a="_key"),this.collection.setSort(a)},returnPressedHandler:function(a){13===a.keyCode&&$(a.target).is($("#docsSort"))&&this.collection.getDocuments(this.getDocsCallback.bind(this)),13===a.keyCode&&$("#confirmDeleteBtn").attr("disabled")===!1&&this.confirmDelete()},nop:function(a){a.stopPropagation()},resetView:function(){$("input").val(""),$("select").val("=="),this.removeAllFilterItems(),$("#documentSize").val(this.collection.getPageSize()),$("#documents_last").css("visibility","visible"),$("#documents_first").css("visibility","visible"),this.addDocumentSwitch=!0,this.collection.resetFilter(),this.collection.loadTotal(),this.restoredFilters=[],this.allowUpload=!1,this.files=void 0,this.file=void 0,$("#confirmDocImport").attr("disabled",!0),this.markFilterToggle(),this.collection.getDocuments(this.getDocsCallback.bind(this))},startDownload:function(){var a=this.collection.buildDownloadDocumentQuery();""!==a||void 0!==a||null!==a?window.open(encodeURI("query/result/download/"+btoa(JSON.stringify(a)))):arangoHelper.arangoError("Document error","could not download documents")},startUpload:function(){var a;return this.allowUpload===!0?(this.showSpinner(),a=this.collection.uploadDocuments(this.file),a!==!0?(this.hideSpinner(),this.hideImportModal(),this.resetView(),void arangoHelper.arangoError(a)):(this.hideSpinner(),this.hideImportModal(),void this.resetView())):void 0},uploadSetup:function(){var a=this;$("#importDocuments").change(function(b){a.files=b.target.files||b.dataTransfer.files,a.file=a.files[0],$("#confirmDocImport").attr("disabled",!1),a.allowUpload=!0})},buildCollectionLink:function(a){return"collection/"+encodeURIComponent(a.get("name"))+"/documents/1"},markFilterToggle:function(){this.restoredFilters.length>0?$("#filterCollection").addClass("activated"):$("#filterCollection").removeClass("activated")},editDocuments:function(){$("#importCollection").removeClass("activated"),$("#exportCollection").removeClass("activated"),this.markFilterToggle(),$("#markDocuments").toggleClass("activated"),this.changeEditMode(),$("#filterHeader").hide(),$("#importHeader").hide(),$("#editHeader").slideToggle(200),$("#exportHeader").hide()},filterCollection:function(){$("#importCollection").removeClass("activated"),$("#exportCollection").removeClass("activated"),$("#markDocuments").removeClass("activated"),this.changeEditMode(!1),this.markFilterToggle(),this.activeFilter=!0,$("#importHeader").hide(),$("#editHeader").hide(),$("#exportHeader").hide(),$("#filterHeader").slideToggle(200);var a;for(a in this.filters)if(this.filters.hasOwnProperty(a))return void $("#attribute_name"+a).focus()},exportCollection:function(){$("#importCollection").removeClass("activated"),$("#filterHeader").removeClass("activated"),$("#markDocuments").removeClass("activated"),this.changeEditMode(!1),$("#exportCollection").toggleClass("activated"),this.markFilterToggle(),$("#exportHeader").slideToggle(200),$("#importHeader").hide(),$("#filterHeader").hide(),$("#editHeader").hide()},importCollection:function(){this.markFilterToggle(),$("#markDocuments").removeClass("activated"),this.changeEditMode(!1),$("#importCollection").toggleClass("activated"),$("#exportCollection").removeClass("activated"),$("#importHeader").slideToggle(200),$("#filterHeader").hide(),$("#editHeader").hide(),$("#exportHeader").hide()},changeEditMode:function(a){a===!1||this.editMode===!0?($("#documentsTableID tbody tr").css("cursor","default"),$(".deleteButton").fadeIn(),$(".addButton").fadeIn(),$(".selected-row").removeClass("selected-row"),this.editMode=!1,this.tableView.setRowClick(this.clicked.bind(this))):($("#documentsTableID tbody tr").css("cursor","copy"),$(".deleteButton").fadeOut(),$(".addButton").fadeOut(),$(".selectedCount").text(0),this.editMode=!0,this.tableView.setRowClick(this.editModeClick.bind(this)))},getFilterContent:function(){var a,b=[];for(a in this.filters)if(this.filters.hasOwnProperty(a)){var c=$("#attribute_value"+a).val();try{c=JSON.parse(c)}catch(d){c=String(c)}""!==$("#attribute_name"+a).val()&&b.push({attribute:$("#attribute_name"+a).val(),operator:$("#operator"+a).val(),value:c})}return b},sendFilter:function(){this.restoredFilters=this.getFilterContent();var a=this;this.collection.resetFilter(),this.addDocumentSwitch=!1,_.each(this.restoredFilters,function(b){void 0!==b.operator&&a.collection.addFilter(b.attribute,b.operator,b.value)}),this.collection.setToFirst(),this.collection.getDocuments(this.getDocsCallback.bind(this)),this.markFilterToggle()},restoreFilter:function(){var a=this,b=0;this.filterId=0,$("#docsSort").val(this.collection.getSort()),_.each(this.restoredFilters,function(c){0!==b&&a.addFilterItem(),void 0!==c.operator&&($("#attribute_name"+b).val(c.attribute),$("#operator"+b).val(c.operator),$("#attribute_value"+b).val(c.value)),b++,a.collection.addFilter(c.attribute,c.operator,c.value)})},addFilterItem:function(){var a=++this.filterId;$("#filterHeader").append('
    '),this.filters[a]=!0},filterValueKeydown:function(a){13===a.keyCode&&this.sendFilter()},removeFilterItem:function(a){var b=a.currentTarget,c=b.id.replace(/^removeFilter/,"");delete this.filters[c],delete this.restoredFilters[c],$(b.parentElement).remove()},removeAllFilterItems:function(){var a,b=$("#filterHeader").children().length;for(a=1;b>=a;a++)$("#removeFilter"+a).parent().remove();this.filters={0:!0},this.filterId=0},addDocumentModal:function(){var a=window.location.hash.split("/")[1],b=[],c=[],d=arangoHelper.collectionApiType(a,!0);return"edge"===d?(c.push(window.modalView.createTextEntry("new-edge-from-attr","_from","","document _id: document handle of the linked vertex (incoming relation)",void 0,!1,[{rule:Joi.string().required(),msg:"No _from attribute given."}])),c.push(window.modalView.createTextEntry("new-edge-to","_to","","document _id: document handle of the linked vertex (outgoing relation)",void 0,!1,[{rule:Joi.string().required(),msg:"No _to attribute given."}])),c.push(window.modalView.createTextEntry("new-edge-key-attr","_key",void 0,"the edges unique key(optional attribute, leave empty for autogenerated key","is optional: leave empty for autogenerated key",!1,[{rule:Joi.string().allow("").optional(),msg:""}])),b.push(window.modalView.createSuccessButton("Create",this.addEdge.bind(this))),void window.modalView.show("modalTable.ejs","Create edge",b,c)):(c.push(window.modalView.createTextEntry("new-document-key-attr","_key",void 0,"the documents unique key(optional attribute, leave empty for autogenerated key","is optional: leave empty for autogenerated key",!1,[{rule:Joi.string().allow("").optional(),msg:""}])),b.push(window.modalView.createSuccessButton("Create",this.addDocument.bind(this))),window.modalView.show("modalTable.ejs","Create document",b,c),void 0)},addEdge:function(){var a,b=window.location.hash.split("/")[1],c=$(".modal-body #new-edge-from-attr").last().val(),d=$(".modal-body #new-edge-to").last().val(),e=$(".modal-body #new-edge-key-attr").last().val();a=""!==e||void 0!==e?this.documentStore.createTypeEdge(b,c,d,e):this.documentStore.createTypeEdge(b,c,d),a!==!1?(window.modalView.hide(),window.location.hash="collection/"+a):arangoHelper.arangoError("Edge error","Creation failed.")},addDocument:function(){var a,b=window.location.hash.split("/")[1],c=$(".modal-body #new-document-key-attr").last().val();a=""!==c||void 0!==c?this.documentStore.createTypeDocument(b,c):this.documentStore.createTypeDocument(b),a!==!1?(window.modalView.hide(),window.location.hash="collection/"+a):arangoHelper.arangoError("Document error","Creation failed.")},moveSelectedDocs:function(){var a=[],b=[],c=this.getSelectedDocs();0!==c.length&&(b.push(window.modalView.createTextEntry("move-documents-to","Move to","",!1,"collection-name",!0,[{rule:Joi.string().regex(/^[a-zA-Z]/),msg:"Collection name must always start with a letter."},{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only Symbols "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No collection name given."}])),a.push(window.modalView.createSuccessButton("Move",this.confirmMoveSelectedDocs.bind(this))),window.modalView.show("modalTable.ejs","Move documents",a,b))},confirmMoveSelectedDocs:function(){var a=this.getSelectedDocs(),b=this,c=$(".modal-body").last().find("#move-documents-to").val(),d=function(){this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#markDocuments").click(),window.modalView.hide()}.bind(this);_.each(a,function(a){b.collection.moveDocument(a,b.collection.collectionID,c,d)})},deleteSelectedDocs:function(){var a=[],b=[],c=this.getSelectedDocs();0!==c.length&&(b.push(window.modalView.createReadOnlyEntry(void 0,c.length+" documents selected","Do you want to delete all selected documents?",void 0,void 0,!1,void 0)),a.push(window.modalView.createDeleteButton("Delete",this.confirmDeleteSelectedDocs.bind(this))),window.modalView.show("modalTable.ejs","Delete documents",a,b))},confirmDeleteSelectedDocs:function(){var a=this.getSelectedDocs(),b=[],c=this;_.each(a,function(a){var d=!1;"document"===c.type?(d=c.documentStore.deleteDocument(c.collection.collectionID,a),d?(b.push(!0),c.collection.setTotalMinusOne()):(b.push(!1),arangoHelper.arangoError("Document error","Could not delete document."))):"edge"===c.type&&(d=c.documentStore.deleteEdge(c.collection.collectionID,a),d===!0?(c.collection.setTotalMinusOne(),b.push(!0)):(b.push(!1),arangoHelper.arangoError("Edge error","Could not delete edge")))}),this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#markDocuments").click(),window.modalView.hide()},getSelectedDocs:function(){var a=[];return _.each($("#documentsTableID tbody tr"),function(b){$(b).hasClass("selected-row")&&a.push($($(b).children()[1]).find(".key").text())}),a},remove:function(a){this.docid=$(a.currentTarget).closest("tr").attr("id").substr(4),$("#confirmDeleteBtn").attr("disabled",!1),$("#docDeleteModal").modal("show")},confirmDelete:function(){$("#confirmDeleteBtn").attr("disabled",!0);var a=window.location.hash.split("/"),b=a[3];"source"!==b&&this.reallyDelete()},reallyDelete:function(){var a,b=this,c=($(b.target).closest("tr").get(0),!1);"document"===this.type?(a=this.documentStore.deleteDocument(this.collection.collectionID,this.docid),a?(this.collection.setTotalMinusOne(),c=!0):arangoHelper.arangoError("Doc error")):"edge"===this.type&&(a=this.documentStore.deleteEdge(this.collection.collectionID,this.docid),a===!0?(this.collection.setTotalMinusOne(),c=!0):arangoHelper.arangoError("Edge error")),c===!0&&(this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#docDeleteModal").modal("hide"))},editModeClick:function(a){var b=$(a.currentTarget);b.hasClass("selected-row")?b.removeClass("selected-row"):b.addClass("selected-row");var c=this.getSelectedDocs();$(".selectedCount").text(c.length),_.each(this.editButtons,function(a){c.length>0?($(a).prop("disabled",!1),$(a).removeClass("button-neutral"),$(a).removeClass("disabled"),"#moveSelected"===a?$(a).addClass("button-success"):$(a).addClass("button-danger")):($(a).prop("disabled",!0),$(a).addClass("disabled"),$(a).addClass("button-neutral"),"#moveSelected"===a?$(a).removeClass("button-success"):$(a).removeClass("button-danger"))})},clicked:function(a){var b=a.currentTarget;window.App.navigate("collection/"+this.collection.collectionID+"/"+$(b).attr("id").substr(4),!0)},drawTable:function(){this.tableView.setElement($(this.table)).render(),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","top"),$(".prettify").snippet("javascript",{style:"nedit",menu:!1,startText:!1,transparent:!0,showNum:!1})},checkCollectionState:function(){this.lastCollectionName===this.collectionName?this.activeFilter&&(this.filterCollection(),this.restoreFilter()):void 0!==this.lastCollectionName&&(this.collection.resetFilter(),this.collection.setSort("_key"),this.restoredFilters=[],this.activeFilter=!1)},render:function(){return $(this.el).html(this.template.render({})),this.tableView.setElement($(this.table)).drawLoading(),this.collectionContext=this.collectionsStore.getPosition(this.collection.collectionID),this.breadcrumb(),this.checkCollectionState(),this.lastCollectionName=this.collectionName,this.uploadSetup(),$("[data-toggle=tooltip]").tooltip(),$(".upload-info").tooltip(),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","top"),this.renderPaginationElements(),this.selectActivePagesize(),this.markFilterToggle(),this},rerender:function(){this.collection.getDocuments(this.getDocsCallback.bind(this))},selectActivePagesize:function(){$("#documentSize").val(this.collection.getPageSize())},renderPaginationElements:function(){this.renderPagination();var a=$("#totalDocuments");0===a.length&&($("#documentsToolbarFL").append(''),a=$("#totalDocuments")),"document"===this.type&&a.html(this.collection.getTotal()+" document(s)"),"edge"===this.type&&a.html(this.collection.getTotal()+" edge(s)")},breadcrumb:function(){this.collectionName=window.location.hash.split("/")[1],$("#transparentHeader").append('")}})}(),function(){"use strict";window.EditListEntryView=Backbone.View.extend({template:templateEngine.createTemplate("editListEntryView.ejs"),initialize:function(a){this.key=a.key,this.value=a.value,this.render()},events:{"click .deleteAttribute":"removeRow"},render:function(){$(this.el).html(this.template.render({key:this.key,value:JSON.stringify(this.value),isReadOnly:this.isReadOnly()}))},isReadOnly:function(){return 0===this.key.indexOf("_")},getKey:function(){return $(".key").val()},getValue:function(){var val=$(".val").val();try{val=JSON.parse(val)}catch(e){try{return eval("val = "+val),val}catch(e2){return $(".val").val()}}return val},removeRow:function(){this.remove()}})}(),function(){"use strict";window.FooterView=Backbone.View.extend({el:"#footerBar",system:{},isOffline:!0,isOfflineCounter:0,firstLogin:!0,events:{"click .footer-center p":"showShortcutModal"},initialize:function(){var a=this;window.setInterval(function(){a.getVersion()},15e3),a.getVersion()},template:templateEngine.createTemplate("footerView.ejs"),showServerStatus:function(a){a===!0?($(".serverStatusIndicator").addClass("isOnline"),$(".serverStatusIndicator").addClass("fa-check-circle-o"),$(".serverStatusIndicator").removeClass("fa-times-circle-o")):($(".serverStatusIndicator").removeClass("isOnline"),$(".serverStatusIndicator").removeClass("fa-check-circle-o"),$(".serverStatusIndicator").addClass("fa-times-circle-o"))},showShortcutModal:function(){window.arangoHelper.hotkeysFunctions.showHotkeysModal()},getVersion:function(){var a=this;$.ajax({type:"GET",cache:!1,url:"/_api/version",contentType:"application/json",processData:!1,async:!0,success:function(b){a.showServerStatus(!0),a.isOffline===!0&&(a.isOffline=!1,a.isOfflineCounter=0,a.firstLogin?a.firstLogin=!1:window.setTimeout(function(){a.showServerStatus(!0)},1e3),a.system.name=b.server,a.system.version=b.version,a.render())},error:function(b){a.isOffline=!0,a.isOfflineCounter++,a.isOfflineCounter>=1&&a.showServerStatus(!1)}}),a.system.hasOwnProperty("database")||$.ajax({type:"GET",cache:!1,url:"/_api/database/current",contentType:"application/json",processData:!1,async:!0,success:function(b){var c=b.result.name;a.system.database=c;var d=window.setInterval(function(){var b=$("#databaseNavi");b&&(window.clearTimeout(d),d=null,"_system"===c?($(".logs-menu").css("visibility","visible"),$(".logs-menu").css("display","inline"),$("#databaseNavi").css("display","inline")):($(".logs-menu").css("visibility","hidden"),$(".logs-menu").css("display","none")),a.render())},50)}})},renderVersion:function(){this.system.hasOwnProperty("database")&&this.system.hasOwnProperty("name")&&$(this.el).html(this.template.render({name:this.system.name,version:this.system.version,database:this.system.database}))},render:function(){return this.system.version||this.getVersion(),$(this.el).html(this.template.render({name:this.system.name,version:this.system.version})),this}})}(),function(){"use strict";window.FoxxActiveView=Backbone.View.extend({tagName:"div",className:"tile",template:templateEngine.createTemplate("foxxActiveView.ejs"),_show:!0,events:{click:"openAppDetailView"},openAppDetailView:function(){window.App.navigate("applications/"+encodeURIComponent(this.model.get("mount")),{trigger:!0})},toggle:function(a,b){switch(a){case"devel":this.model.isDevelopment()&&(this._show=b);break;case"production":this.model.isDevelopment()||this.model.isSystem()||(this._show=b);break;case"system":this.model.isSystem()&&(this._show=b)}this._show?$(this.el).show():$(this.el).hide()},render:function(){return $(this.el).html(this.template.render({model:this.model})),$(this.el)}})}(),function(){"use strict";var a=require("internal").errors,b=templateEngine.createTemplate("applicationListView.ejs"),c=function(a){this.collection=a.collection},d=function(b){if(b.error===!1)this.collection.fetch({async:!1}),window.modalView.hide(),this.reload();else{var c=b;switch(b.hasOwnProperty("responseJSON")&&(c=b.responseJSON),c.errorNum){case a.ERROR_APPLICATION_DOWNLOAD_FAILED.code:alert("Unable to download application from the given repository.");break;default:alert("Error: "+c.errorNum+". "+c.errorMessage)}}},e=function(){window.modalView.modalBindValidation({id:"new-app-mount",validateInput:function(){return[{rule:Joi.string().regex(/^(\/(APP[^\/]+|(?!APP)[a-zA-Z0-9_\-%]+))+$/i),msg:"May not contain /APP"},{rule:Joi.string().regex(/^(\/[a-zA-Z0-9_\-%]+)+$/),msg:"Can only contain [a-zA-Z0-9_-%]"},{rule:Joi.string().regex(/^\/([^_]|_open\/)/),msg:"Mountpoints with _ are reserved for internal use"},{rule:Joi.string().regex(/[^\/]$/),msg:"May not end with /"},{rule:Joi.string().regex(/^\//),msg:"Has to start with /"},{rule:Joi.string().required().min(2),msg:"Has to be non-empty"}]}})},f=function(){window.modalView.modalBindValidation({id:"repository",validateInput:function(){return[{rule:Joi.string().required().regex(/^[a-zA-Z0-9_\-]+\/[a-zA-Z0-9_\-]+$/),msg:"No valid Github account and repository."}]}})},g=function(){window.modalView.modalBindValidation({id:"new-app-author",validateInput:function(){return[{rule:Joi.string().required().min(1),msg:"Has to be non empty."}]}}),window.modalView.modalBindValidation({id:"new-app-name",validateInput:function(){return[{rule:Joi.string().required().regex(/^[a-zA-Z\-_][a-zA-Z0-9\-_]*$/),msg:"Can only contain a to z, A to Z, 0-9, '-' and '_'."}]}}),window.modalView.modalBindValidation({id:"new-app-description",validateInput:function(){return[{rule:Joi.string().required().min(1),msg:"Has to be non empty."}]}}),window.modalView.modalBindValidation({id:"new-app-license",validateInput:function(){return[{rule:Joi.string().required().regex(/^[a-zA-Z0-9 \.,;\-]+$/),msg:"Has to be non empty."}]}}),window.modalView.modalTestAll()},h=function(a){window.modalView.clearValidators();var b=$("#modalButton1");switch(this._upgrade||e(),a){case"newApp":b.html("Generate"),b.prop("disabled",!1),g();break;case"appstore":b.html("Install"),b.prop("disabled",!0);break;case"github":f(),b.html("Install"),b.prop("disabled",!1);break;case"zip":b.html("Install"),b.prop("disabled",!1)}b.prop("disabled")||window.modalView.modalTestAll()||b.prop("disabled",!0)},i=function(a){var b=$(a.currentTarget).attr("href").substr(1);h.call(this,b)},j=function(a){if(h.call(this,"appstore"),window.modalView.modalTestAll()){var b,c;this._upgrade?(b=this.mount,c=$("#new-app-teardown").prop("checked")):b=window.arangoHelper.escapeHtml($("#new-app-mount").val());var e=$(a.currentTarget).attr("appId"),f=$(a.currentTarget).attr("appVersion");void 0!==c?this.collection.installFromStore({name:e,version:f},b,d.bind(this),c):this.collection.installFromStore({name:e,version:f},b,d.bind(this))}},k=function(a,b){if(void 0===b?b=this._uploadData:this._uploadData=b,b&&window.modalView.modalTestAll()){var c,e;this._upgrade?(c=this.mount,e=$("#new-app-teardown").prop("checked")):c=window.arangoHelper.escapeHtml($("#new-app-mount").val()),void 0!==e?this.collection.installFromZip(b.filename,c,d.bind(this),e):this.collection.installFromZip(b.filename,c,d.bind(this))}},l=function(){if(window.modalView.modalTestAll()){var a,b,c,e;this._upgrade?(c=this.mount,e=$("#new-app-teardown").prop("checked")):c=window.arangoHelper.escapeHtml($("#new-app-mount").val()),a=window.arangoHelper.escapeHtml($("#repository").val()),b=window.arangoHelper.escapeHtml($("#tag").val()),""===b&&(b="master");var f={url:window.arangoHelper.escapeHtml($("#repository").val()),version:window.arangoHelper.escapeHtml($("#tag").val())};try{Joi.assert(a,Joi.string().regex(/^[a-zA-Z0-9_\-]+\/[a-zA-Z0-9_\-]+$/))}catch(g){return}void 0!==e?this.collection.installFromGithub(f,c,d.bind(this),e):this.collection.installFromGithub(f,c,d.bind(this))}},m=function(){if(window.modalView.modalTestAll()){var a,b;this._upgrade?(a=this.mount,b=$("#new-app-teardown").prop("checked")):a=window.arangoHelper.escapeHtml($("#new-app-mount").val());var c={name:window.arangoHelper.escapeHtml($("#new-app-name").val()),collectionNames:_.map($("#new-app-collections").select2("data"),function(a){return window.arangoHelper.escapeHtml(a.text)}),author:window.arangoHelper.escapeHtml($("#new-app-author").val()),license:window.arangoHelper.escapeHtml($("#new-app-license").val()),description:window.arangoHelper.escapeHtml($("#new-app-description").val())};void 0!==b?this.collection.generate(c,a,d.bind(this),b):this.collection.generate(c,a,d.bind(this))}},n=function(){var a=$(".modal-body .tab-pane.active").attr("id");switch(a){case"newApp":m.apply(this);break;case"github":l.apply(this);break;case"zip":k.apply(this)}},o=function(a,c){var d=[],e={"click #infoTab a":i.bind(a),"click .install-app":j.bind(a)};d.push(window.modalView.createSuccessButton("Generate",n.bind(a))),window.modalView.show("modalApplicationMount.ejs","Install Service",d,c,void 0,void 0,e),$("#new-app-collections").select2({tags:[],showSearchBox:!1,minimumResultsForSearch:-1,width:"336px"});var f=function(){var a=$("#modalButton1");a.prop("disabled")||window.modalView.modalTestAll()?a.prop("disabled",!1):a.prop("disabled",!0)};$(".select2-search-field input").focusout(function(){f(),window.setTimeout(function(){$(".select2-drop").is(":visible")&&($("#select2-search-field input").is(":focus")||($("#s2id_new-app-collections").select2("close"),f()))},80)}),$(".select2-search-field input").focusin(function(){if($(".select2-drop").is(":visible")){var a=$("#modalButton1");a.prop("disabled",!0)}}),$("#upload-foxx-zip").uploadFile({url:"/_api/upload?multipart=true",allowedTypes:"zip",multiple:!1,onSuccess:k.bind(a)}),$.get("foxxes/fishbowl",function(a){var c=$("#appstore-content");c.html(""),_.each(_.sortBy(a,"name"),function(a){c.append(b.render(a))})}).fail(function(){var a=$("#appstore-content");a.append("Store is not available. ArangoDB is not able to connect to github.com")})};c.prototype.install=function(a){this.reload=a,this._upgrade=!1,this._uploadData=void 0,delete this.mount,o(this,!1),window.modalView.clearValidators(),e(),g()},c.prototype.upgrade=function(a,b){this.reload=b,this._upgrade=!0,this._uploadData=void 0,this.mount=a,o(this,!0),window.modalView.clearValidators(),g()},window.FoxxInstallView=c}(),function(){"use strict";window.GraphManagementView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("graphManagementView.ejs"),edgeDefintionTemplate:templateEngine.createTemplate("edgeDefinitionTable.ejs"),eCollList:[],removedECollList:[],dropdownVisible:!1,events:{"click #deleteGraph":"deleteGraph","click .icon_arangodb_settings2.editGraph":"editGraph","click #createGraph":"addNewGraph","keyup #graphManagementSearchInput":"search","click #graphManagementSearchSubmit":"search","click .tile-graph":"redirectToGraphViewer","click #graphManagementToggle":"toggleGraphDropdown","click .css-label":"checkBoxes","change #graphSortDesc":"sorting"},toggleTab:function(a){var b=a.currentTarget.id;b=b.replace("tab-",""),$("#tab-content-create-graph .tab-pane").removeClass("active"),$("#tab-content-create-graph #"+b).addClass("active"),"exampleGraphs"===b?$("#modal-dialog .modal-footer button").css("display","none"):$("#modal-dialog .modal-footer button").css("display","block")},redirectToGraphViewer:function(a){var b=$(a.currentTarget).attr("id");b=b.substr(0,b.length-5),window.location=window.location+"/"+encodeURIComponent(b)},loadGraphViewer:function(a){var b=this.collection.get(a).get("edgeDefinitions");if(b&&0!==b.length){var c={type:"gharial",graphName:a,baseUrl:require("internal").arango.databasePrefix("/")},d=$("#content").width()-75;$("#content").html("");var e=arangoHelper.calculateCenterDivHeight();this.ui=new GraphViewerUI($("#content")[0],c,d,e,{nodeShaper:{label:"_key",color:{type:"attribute",key:"_key"}}},!0),$(".contentDiv").height(e)}},handleResize:function(a){this.width&&this.width===a||(this.width=a,this.ui&&this.ui.changeWidth(a))},addNewGraph:function(a){a.preventDefault(),this.createEditGraphModal()},deleteGraph:function(){var a=this,b=$("#editGraphName")[0].value;if($("#dropGraphCollections").is(":checked")){var c=function(c){c?(a.collection.remove(a.collection.get(b)),a.updateGraphManagementView(),window.modalView.hide()):window.modalView.hide()};this.collection.dropAndDeleteGraph(b,c)}else this.collection.get(b).destroy({success:function(){a.updateGraphManagementView(),window.modalView.hide()},error:function(a,b){var c=JSON.parse(b.responseText),d=c.errorMessage;arangoHelper.arangoError(d),window.modalView.hide()}})},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},toggleGraphDropdown:function(){$("#graphSortDesc").attr("checked",this.collection.sortOptions.desc),$("#graphManagementToggle").toggleClass("activated"),$("#graphManagementDropdown2").slideToggle(200)},sorting:function(){$("#graphSortDesc").is(":checked")?this.collection.setSortingDesc(!0):this.collection.setSortingDesc(!1),$("#graphManagementDropdown").is(":visible")?this.dropdownVisible=!0:this.dropdownVisible=!1,this.render()},createExampleGraphs:function(a){var b=$(a.currentTarget).attr("graph-id"),c=this;$.ajax({type:"POST",url:"/_admin/aardvark/graph-examples/create/"+encodeURIComponent(b),success:function(){window.modalView.hide(),c.updateGraphManagementView(),arangoHelper.arangoNotification("Example Graphs","Graph: "+b+" created.")},error:function(a){if(window.modalView.hide(),console.log(a),a.responseText)try{var c=JSON.parse(a.responseText);arangoHelper.arangoError("Example Graphs",c.errorMessage)}catch(d){arangoHelper.arangoError("Example Graphs","Could not create example graph: "+b)}else arangoHelper.arangoError("Example Graphs","Could not create example graph: "+b)}})},render:function(){return this.collection.fetch({async:!1}),this.collection.sort(),$(this.el).html(this.template.render({graphs:this.collection,searchString:""})),this.dropdownVisible===!0&&($("#graphManagementDropdown2").show(),$("#graphSortDesc").attr("checked",this.collection.sortOptions.desc),$("#graphManagementToggle").toggleClass("activated"),$("#graphManagementDropdown").show()),this.events["click .tableRow"]=this.showHideDefinition.bind(this),this.events['change tr[id*="newEdgeDefinitions"]']=this.setFromAndTo.bind(this),this.events["click .graphViewer-icon-button"]=this.addRemoveDefinition.bind(this),this.events["click #graphTab a"]=this.toggleTab.bind(this),this.events["click .createExampleGraphs"]=this.createExampleGraphs.bind(this),arangoHelper.setCheckboxStatus("#graphManagementDropdown"),this},setFromAndTo:function(a){a.stopPropagation();var b,c=this.calculateEdgeDefinitionMap();if(a.added){if(-1===this.eCollList.indexOf(a.added.id)&&-1!==this.removedECollList.indexOf(a.added.id))return b=a.currentTarget.id.split("row_newEdgeDefinitions")[1],$('input[id*="newEdgeDefinitions'+b+'"]').select2("val",null),void $('input[id*="newEdgeDefinitions'+b+'"]').attr("placeholder","The collection "+a.added.id+" is already used.");this.removedECollList.push(a.added.id),this.eCollList.splice(this.eCollList.indexOf(a.added.id),1)}else this.eCollList.push(a.removed.id),this.removedECollList.splice(this.removedECollList.indexOf(a.removed.id),1);c[a.val]?(b=a.currentTarget.id.split("row_newEdgeDefinitions")[1],$("#s2id_fromCollections"+b).select2("val",c[a.val].from),$("#fromCollections"+b).attr("disabled",!0),$("#s2id_toCollections"+b).select2("val",c[a.val].to), +$("#toCollections"+b).attr("disabled",!0)):(b=a.currentTarget.id.split("row_newEdgeDefinitions")[1],$("#s2id_fromCollections"+b).select2("val",null),$("#fromCollections"+b).attr("disabled",!1),$("#s2id_toCollections"+b).select2("val",null),$("#toCollections"+b).attr("disabled",!1))},editGraph:function(a){a.stopPropagation(),this.collection.fetch(),this.graphToEdit=this.evaluateGraphName($(a.currentTarget).attr("id"),"_settings");var b=this.collection.findWhere({_key:this.graphToEdit});this.createEditGraphModal(b)},saveEditedGraph:function(){var a,b,c,d,e,f=$("#editGraphName")[0].value,g=_.pluck($("#newVertexCollections").select2("data"),"text"),h=[],i={};if(e=$("[id^=s2id_newEdgeDefinitions]").toArray(),e.forEach(function(e){if(d=$(e).attr("id"),d=d.replace("s2id_newEdgeDefinitions",""),a=_.pluck($("#s2id_newEdgeDefinitions"+d).select2("data"),"text")[0],a&&""!==a&&(b=_.pluck($("#s2id_fromCollections"+d).select2("data"),"text"),c=_.pluck($("#s2id_toCollections"+d).select2("data"),"text"),0!==b.length&&0!==c.length)){var f={collection:a,from:b,to:c};h.push(f),i[a]=f}}),0===h.length)return void $("#s2id_newEdgeDefinitions0 .select2-choices").css("border-color","red");var j=this.collection.findWhere({_key:f}),k=j.get("edgeDefinitions"),l=j.get("orphanCollections"),m=[];l.forEach(function(a){-1===g.indexOf(a)&&j.deleteVertexCollection(a)}),g.forEach(function(a){-1===l.indexOf(a)&&j.addVertexCollection(a)});var n=[],o=[],p=[];k.forEach(function(a){var b=a.collection;m.push(b);var c=i[b];void 0===c?p.push(b):JSON.stringify(c)!==JSON.stringify(a)&&o.push(b)}),h.forEach(function(a){var b=a.collection;-1===m.indexOf(b)&&n.push(b)}),n.forEach(function(a){j.addEdgeDefinition(i[a])}),o.forEach(function(a){j.modifyEdgeDefinition(i[a])}),p.forEach(function(a){j.deleteEdgeDefinition(a)}),this.updateGraphManagementView(),window.modalView.hide()},evaluateGraphName:function(a,b){var c=a.lastIndexOf(b);return a.substring(0,c)},search:function(){var a,b,c,d;a=$("#graphManagementSearchInput"),b=$("#graphManagementSearchInput").val(),d=this.collection.filter(function(a){return-1!==a.get("_key").indexOf(b)}),$(this.el).html(this.template.render({graphs:d,searchString:b})),a=$("#graphManagementSearchInput"),c=a.val().length,a.focus(),a[0].setSelectionRange(c,c)},updateGraphManagementView:function(){var a=this;this.collection.fetch({success:function(){a.render()}})},createNewGraph:function(){var a,b,c,d,e,f=$("#createNewGraphName").val(),g=_.pluck($("#newVertexCollections").select2("data"),"text"),h=[],i=this;return f?this.collection.findWhere({_key:f})?(arangoHelper.arangoError("The graph '"+f+"' already exists."),0):(e=$("[id^=s2id_newEdgeDefinitions]").toArray(),e.forEach(function(e){d=$(e).attr("id"),d=d.replace("s2id_newEdgeDefinitions",""),a=_.pluck($("#s2id_newEdgeDefinitions"+d).select2("data"),"text")[0],a&&""!==a&&(b=_.pluck($("#s2id_fromCollections"+d).select2("data"),"text"),c=_.pluck($("#s2id_toCollections"+d).select2("data"),"text"),1!==b&&1!==c&&h.push({collection:a,from:b,to:c}))}),void this.collection.create({name:f,edgeDefinitions:h,orphanCollections:g},{success:function(){i.updateGraphManagementView(),window.modalView.hide()},error:function(a,b){var c=JSON.parse(b.responseText),d=c.errorMessage;d=d.replace("<",""),d=d.replace(">",""),arangoHelper.arangoError(d)}})):(arangoHelper.arangoError("A name for the graph has to be provided."),0)},createEditGraphModal:function(a){var b,c=[],d=[],e=[],f=this.options.collectionCollection.models,g=this,h="",i=[{collection:"",from:"",to:""}],j="",k=function(a,b){return a=a.toLowerCase(),b=b.toLowerCase(),b>a?-1:a>b?1:0};if(this.eCollList=[],this.removedECollList=[],f.forEach(function(a){a.get("isSystem")||("edge"===a.get("type")?g.eCollList.push(a.id):d.push(a.id))}),window.modalView.enableHotKeys=!1,this.counter=0,a?(b="Edit Graph",h=a.get("_key"),i=a.get("edgeDefinitions"),i&&0!==i.length||(i=[{collection:"",from:"",to:""}]),j=a.get("orphanCollections"),e.push(window.modalView.createReadOnlyEntry("editGraphName","Name",h,"The name to identify the graph. Has to be unique")),c.push(window.modalView.createDeleteButton("Delete",this.deleteGraph.bind(this))),c.push(window.modalView.createSuccessButton("Save",this.saveEditedGraph.bind(this)))):(b="Create Graph",e.push(window.modalView.createTextEntry("createNewGraphName","Name","","The name to identify the graph. Has to be unique.","graphName",!0)),c.push(window.modalView.createSuccessButton("Create",this.createNewGraph.bind(this)))),i.forEach(function(a){0===g.counter?(a.collection&&(g.removedECollList.push(a.collection),g.eCollList.splice(g.eCollList.indexOf(a.collection),1)),e.push(window.modalView.createSelect2Entry("newEdgeDefinitions"+g.counter,"Edge definitions",a.collection,"An edge definition defines a relation of the graph","Edge definitions",!0,!1,!0,1,g.eCollList.sort(k)))):e.push(window.modalView.createSelect2Entry("newEdgeDefinitions"+g.counter,"Edge definitions",a.collection,"An edge definition defines a relation of the graph","Edge definitions",!1,!0,!1,1,g.eCollList.sort(k))),e.push(window.modalView.createSelect2Entry("fromCollections"+g.counter,"fromCollections",a.from,"The collections that contain the start vertices of the relation.","fromCollections",!0,!1,!1,10,d.sort(k))),e.push(window.modalView.createSelect2Entry("toCollections"+g.counter,"toCollections",a.to,"The collections that contain the end vertices of the relation.","toCollections",!0,!1,!1,10,d.sort(k))),g.counter++}),e.push(window.modalView.createSelect2Entry("newVertexCollections","Vertex collections",j,"Collections that are part of a graph but not used in an edge definition","Vertex Collections",!1,!1,!1,10,d.sort(k))),window.modalView.show("modalGraphTable.ejs",b,c,e,void 0,void 0,this.events),a){$(".modal-body table").css("border-collapse","separate");var l;for($(".modal-body .spacer").remove(),l=0;l<=this.counter;l++)$("#row_fromCollections"+l).show(),$("#row_toCollections"+l).show(),$("#row_newEdgeDefinitions"+l).addClass("first"),$("#row_fromCollections"+l).addClass("middle"),$("#row_toCollections"+l).addClass("last"),$("#row_toCollections"+l).after('');$("#graphTab").hide(),$("#modal-dialog .modal-delete-confirmation").append('
    ')}},showHideDefinition:function(a){},addRemoveDefinition:function(a){var b=[],c=this.options.collectionCollection.models;c.forEach(function(a){a.get("isSystem")||b.push(a.id)}),a.stopPropagation();var d,e=$(a.currentTarget).attr("id");if(-1===e.indexOf("addAfter_newEdgeDefinitions"))-1!==e.indexOf("remove_newEdgeDefinitions")&&(d=e.split("remove_newEdgeDefinitions")[1],$("#row_newEdgeDefinitions"+d).remove(),$("#row_fromCollections"+d).remove(),$("#row_toCollections"+d).remove(),$("#spacer"+d).remove());else{this.counter++,$("#row_newVertexCollections").before(this.edgeDefintionTemplate.render({number:this.counter})),$("#newEdgeDefinitions"+this.counter).select2({tags:this.eCollList,showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:1}),$("#fromCollections"+this.counter).select2({tags:b,showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:10}),$("#toCollections"+this.counter).select2({tags:b,showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:10}),window.modalView.undelegateEvents(),window.modalView.delegateEvents(this.events);var f;for($(".modal-body .spacer").remove(),f=0;f<=this.counter;f++)$("#row_fromCollections"+f).show(),$("#row_toCollections"+f).show(),$("#row_newEdgeDefinitions"+f).addClass("first"),$("#row_fromCollections"+f).addClass("middle"),$("#row_toCollections"+f).addClass("last"),$("#row_toCollections"+f).after('')}},calculateEdgeDefinitionMap:function(){var a={};return this.collection.models.forEach(function(b){b.get("edgeDefinitions").forEach(function(b){a[b.collection]={from:b.from,to:b.to}})}),a}})}(),function(){"use strict";window.loginView=Backbone.View.extend({el:"#content",el2:".header",el3:".footer",events:{"submit #loginForm":"login","keypress #loginForm input":"clear","change #loginForm input":"clear"},template:templateEngine.createTemplate("loginView.ejs"),render:function(){return $(this.el).html(this.template.render({})),$(this.el2).hide(),$(this.el3).hide(),$("#loginUsername").focus(),this},clear:function(){$("#loginForm input").removeClass("form-error"),$(".wrong-credentials").hide()},login:function(a){a.preventDefault();var b=$("#loginUsername").val(),c=$("#loginPassword").val();b&&(b=this.collection.login(b,c),b?($(this.el2).show(),$(this.el3).show(),window.location.reload(),$("#currentUser").text(b),this.collection.loadUserSettings()):($("#loginForm input").addClass("form-error"),$(".wrong-credentials").show()))}})}(),function(){"use strict";window.LogsView=window.PaginationView.extend({el:"#content",id:"#logContent",paginationDiv:"#logPaginationDiv",idPrefix:"logTable",fetchedAmount:!1,initialize:function(){this.convertModelToJSON()},currentLoglevel:"logall",events:{"click #arangoLogTabbar button":"setActiveLoglevel","click #logTable_first":"firstPage","click #logTable_last":"lastPage"},template:templateEngine.createTemplate("logsView.ejs"),tabbar:templateEngine.createTemplate("arangoTabbar.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),tabbarElements:{id:"arangoLogTabbar",titles:[["Debug","logdebug"],["Warning","logwarning"],["Error","logerror"],["Info","loginfo"],["All","logall"]]},tableDescription:{id:"arangoLogTable",titles:["Loglevel","Date","Message"],rows:[]},convertedRows:null,setActiveLoglevel:function(a){$(".arangodb-tabbar").removeClass("arango-active-tab"),this.currentLoglevel!==a.currentTarget.id&&(this.currentLoglevel=a.currentTarget.id,this.convertModelToJSON())},initTotalAmount:function(){var a=this;this.collection=this.options[this.currentLoglevel],this.collection.fetch({data:$.param({test:!0}),success:function(){a.convertModelToJSON()}}),this.fetchedAmount=!0},invertArray:function(a){var b,c=[],d=0;for(b=a.length-1;b>=0;b--)c[d]=a[b],d++;return c},convertModelToJSON:function(){if(!this.fetchedAmount)return void this.initTotalAmount();var a,b=this,c=[];this.collection=this.options[this.currentLoglevel],this.collection.fetch({success:function(){b.collection.each(function(b){a=new Date(1e3*b.get("timestamp")),c.push([b.getLogStatus(),arangoHelper.formatDT(a),b.get("text")])}),b.tableDescription.rows=b.invertArray(c),b.render()}})},render:function(){return $(this.el).html(this.template.render({})),$(this.id).html(this.tabbar.render({content:this.tabbarElements})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#"+this.currentLoglevel).addClass("arango-active-tab"),$("#logContent").append('
    '),this.renderPagination(),this},rerender:function(){this.convertModelToJSON()}})}(),function(){"use strict";var a=function(a,b,c,d){return{type:a,title:b,callback:c,confirm:d}},b=function(a,b,c,d,e,f,g,h,i,j,k){var l={type:a,label:b};return void 0!==c&&(l.value=c),void 0!==d&&(l.info=d),void 0!==e&&(l.placeholder=e),void 0!==f&&(l.mandatory=f),void 0!==h&&(l.addDelete=h),void 0!==i&&(l.addAdd=i),void 0!==j&&(l.maxEntrySize=j),void 0!==k&&(l.tags=k),g&&(l.validateInput=function(){return g}),l};window.ModalView=Backbone.View.extend({_validators:[],_validateWatchers:[],baseTemplate:templateEngine.createTemplate("modalBase.ejs"),tableTemplate:templateEngine.createTemplate("modalTable.ejs"),el:"#modalPlaceholder",contentEl:"#modalContent",hideFooter:!1,confirm:{list:"#modal-delete-confirmation",yes:"#modal-confirm-delete",no:"#modal-abort-delete"},enabledHotkey:!1,enableHotKeys:!0,buttons:{SUCCESS:"success",NOTIFICATION:"notification",DELETE:"danger",NEUTRAL:"neutral",CLOSE:"close"},tables:{READONLY:"readonly",TEXT:"text",BLOB:"blob",PASSWORD:"password",SELECT:"select",SELECT2:"select2",CHECKBOX:"checkbox"},initialize:function(){Object.freeze(this.buttons),Object.freeze(this.tables)},createModalHotkeys:function(){$(this.el).unbind("keydown"),$(this.el).unbind("return"),$(this.el).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()}),$(".modal-body input").unbind("keydown"),$(".modal-body input").unbind("return"),$(".modal-body input",$(this.el)).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()}),$(".modal-body select").unbind("keydown"),$(".modal-body select").unbind("return"),$(".modal-body select",$(this.el)).bind("keydown","return",function(){$(".createModalDialog .modal-footer .button-success").click()})},createInitModalHotkeys:function(){var a=this;$(this.el).bind("keydown","left",function(){a.navigateThroughButtons("left")}),$(this.el).bind("keydown","right",function(){a.navigateThroughButtons("right")})},navigateThroughButtons:function(a){var b=$(".createModalDialog .modal-footer button").is(":focus");b===!1?"left"===a?$(".createModalDialog .modal-footer button").first().focus():"right"===a&&$("..createModalDialog .modal-footer button").last().focus():b===!0&&("left"===a?$(":focus").prev().focus():"right"===a&&$(":focus").next().focus())},createCloseButton:function(b,c){var d=this;return a(this.buttons.CLOSE,b,function(){d.hide(),c&&c()})},createSuccessButton:function(b,c){return a(this.buttons.SUCCESS,b,c)},createNotificationButton:function(b,c){return a(this.buttons.NOTIFICATION,b,c)},createDeleteButton:function(b,c,d){return a(this.buttons.DELETE,b,c,d)},createNeutralButton:function(b,c){return a(this.buttons.NEUTRAL,b,c)},createDisabledButton:function(b){var c=a(this.buttons.NEUTRAL,b);return c.disabled=!0,c},createReadOnlyEntry:function(a,c,d,e,f,g){var h=b(this.tables.READONLY,c,d,e,void 0,void 0,void 0,f,g);return h.id=a,h},createTextEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.TEXT,c,d,e,f,g,h);return i.id=a,i},createBlobEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.BLOB,c,d,e,f,g,h);return i.id=a,i},createSelect2Entry:function(a,c,d,e,f,g,h,i,j,k){var l=b(this.tables.SELECT2,c,d,e,f,g,void 0,h,i,j,k);return l.id=a,l},createPasswordEntry:function(a,c,d,e,f,g,h){var i=b(this.tables.PASSWORD,c,d,e,f,g,h);return i.id=a,i},createCheckboxEntry:function(a,c,d,e,f){var g=b(this.tables.CHECKBOX,c,d,e);return g.id=a,f&&(g.checked=f),g},createSelectEntry:function(a,c,d,e,f){var g=b(this.tables.SELECT,c,null,e);return g.id=a,d&&(g.selected=d),g.options=f,g},createOptionEntry:function(a,b){return{label:a,value:b||a}},show:function(a,b,c,d,e,f,g,h,i){var j,k,l=this,m=!1;c=c||[],h=Boolean(h),this.clearValidators(),c.length>0?(c.forEach(function(a){a.type===l.buttons.CLOSE&&(m=!0),a.type===l.buttons.DELETE&&(k=k||a.confirm)}),m||(j=c.pop(),c.push(l.createCloseButton("Cancel")),c.push(j))):c.push(l.createCloseButton("Close")),$(this.el).html(this.baseTemplate.render({title:b,buttons:c,hideFooter:this.hideFooter,confirm:k,tabBar:i})),_.each(c,function(a,b){return!a.disabled&&a.callback?a.type!==l.buttons.DELETE||h?void $("#modalButton"+b).bind("click",a.callback):void $("#modalButton"+b).bind("click",function(){$(l.confirm.yes).unbind("click"),$(l.confirm.yes).bind("click",a.callback),$(l.confirm.list).css("display","block")}):void 0}),$(this.confirm.no).bind("click",function(){$(l.confirm.list).css("display","none")});var n;if("string"==typeof a)n=templateEngine.createTemplate(a),$(".createModalDialog .modal-body").html(n.render({content:d,advancedContent:e,info:f}));else{var o=0;_.each(a,function(a){n=templateEngine.createTemplate(a),$(".createModalDialog .modal-body .tab-content #"+i[o]).html(n.render({content:d,advancedContent:e,info:f})),o++})}$(".createModalDialog .modalTooltips").tooltip({position:{my:"left top",at:"right+55 top-1"}});var p=d||[];e&&e.content&&(p=p.concat(e.content)),_.each(p,function(a){l.modalBindValidation(a),a.type===l.tables.SELECT2&&$("#"+a.id).select2({tags:a.tags||[],showSearchBox:!1,minimumResultsForSearch:-1,width:"336px",maximumSelectionSize:a.maxEntrySize||8})}),g&&(this.events=g,this.delegateEvents()),$("#accordion2")&&($("#accordion2 .accordion-toggle").bind("click",function(){$("#collapseOne").is(":visible")?($("#collapseOne").hide(),setTimeout(function(){$(".accordion-toggle").addClass("collapsed")},100)):($("#collapseOne").show(),setTimeout(function(){$(".accordion-toggle").removeClass("collapsed")},100))}),$("#collapseOne").hide(),setTimeout(function(){$(".accordion-toggle").addClass("collapsed")},100)),$("#modal-dialog").modal("show"),this.enabledHotkey===!1&&(this.createInitModalHotkeys(),this.enabledHotkey=!0),this.enableHotKeys&&this.createModalHotkeys();var q=$("#modal-dialog").find("input");q&&setTimeout(function(){var a=$("#modal-dialog");a.length>0&&(a=a.find("input"),a.length>0&&$(a[0]).focus())},800)},modalBindValidation:function(a){var b=this;if(a.hasOwnProperty("id")&&a.hasOwnProperty("validateInput")){var c=function(){var b=$("#"+a.id),c=a.validateInput(b),d=!1;return _.each(c,function(a){var c=b.val();if(a.rule||(a={rule:a}),"function"==typeof a.rule)try{a.rule(c)}catch(e){d=a.msg||e.message}else{var f=Joi.validate(c,a.rule);f.error&&(d=a.msg||f.error.message)}return d?!1:void 0}),d?d:void 0},d=$("#"+a.id);d.on("keyup focusout",function(){var a=c(),e=d.next()[0];a?(d.addClass("invalid-input"),e?$(e).text(a):d.after('

    '+a+"

    "),$(".createModalDialog .modal-footer .button-success").prop("disabled",!0).addClass("disabled")):(d.removeClass("invalid-input"),e&&$(e).remove(),b.modalTestAll())}),this._validators.push(c),this._validateWatchers.push(d)}},modalTestAll:function(){var a=_.map(this._validators,function(a){return a()}),b=_.any(a);return b?$(".createModalDialog .modal-footer .button-success").prop("disabled",!0).addClass("disabled"):$(".createModalDialog .modal-footer .button-success").prop("disabled",!1).removeClass("disabled"),!b},clearValidators:function(){this._validators=[],_.each(this._validateWatchers,function(a){a.unbind("keyup focusout")}),this._validateWatchers=[]},hide:function(){this.clearValidators(),$("#modal-dialog").modal("hide")}})}(),function(){"use strict";window.NavigationView=Backbone.View.extend({el:"#navigationBar",events:{"change #arangoCollectionSelect":"navigateBySelect","click .tab":"navigateByTab","mouseenter .dropdown > *":"showDropdown","mouseleave .dropdown":"hideDropdown"},initialize:function(){this.userCollection=this.options.userCollection,this.currentDB=this.options.currentDB,this.dbSelectionView=new window.DBSelectionView({collection:this.options.database,current:this.currentDB}),this.userBarView=new window.UserBarView({userCollection:this.userCollection}),this.notificationView=new window.NotificationView({collection:this.options.notificationCollection}),this.statisticBarView=new window.StatisticBarView({currentDB:this.currentDB}),this.handleKeyboardHotkeys()},handleSelectDatabase:function(){this.dbSelectionView.render($("#dbSelect"))},template:templateEngine.createTemplate("navigationView.ejs"),render:function(){return $(this.el).html(this.template.render({currentDB:this.currentDB})),this.dbSelectionView.render($("#dbSelect")),this.notificationView.render($("#notificationBar")),this.userCollection.whoAmI()&&this.userBarView.render(),this.statisticBarView.render($("#statisticBar")),window.App.arangoCollectionsStore.findWhere({name:"arangodbflightsdemo"})||$(".demo-menu").css("display","none"),this},navigateBySelect:function(){var a=$("#arangoCollectionSelect").find("option:selected").val();window.App.navigate(a,{trigger:!0})},handleKeyboardHotkeys:function(){arangoHelper.enableKeyboardHotkeys(!0)},navigateByTab:function(a){var b=a.target||a.srcElement,c=b.id,d=!1;""===c&&(c=$(b).attr("class")),"links"===c?(d=!0,$("#link_dropdown").slideToggle(1),a.preventDefault()):"tools"===c?(d=!0,$("#tools_dropdown").slideToggle(1),a.preventDefault()):"dbselection"===c&&(d=!0,$("#dbs_dropdown").slideToggle(1),a.preventDefault()),d||(window.App.navigate(c,{trigger:!0}),a.preventDefault())},handleSelectNavigation:function(){var a=this;$("#arangoCollectionSelect").change(function(){a.navigateBySelect()})},selectMenuItem:function(a){$(".navlist li").removeClass("active"),a&&$("."+a).addClass("active")},showDropdown:function(a){var b=a.target||a.srcElement,c=b.id;"links"===c||"link_dropdown"===c||"links"===a.currentTarget.id?$("#link_dropdown").fadeIn(1):"tools"===c||"tools_dropdown"===c||"tools"===a.currentTarget.id?$("#tools_dropdown").fadeIn(1):("dbselection"===c||"dbs_dropdown"===c||"dbselection"===a.currentTarget.id)&&$("#dbs_dropdown").fadeIn(1)},hideDropdown:function(a){var b=a.target||a.srcElement;b=$(b).parent(),$("#link_dropdown").fadeOut(1),$("#tools_dropdown").fadeOut(1),$("#dbs_dropdown").fadeOut(1)}})}(),function(){"use strict";window.NotificationView=Backbone.View.extend({events:{"click .navlogo #stat_hd":"toggleNotification","click .notificationItem .fa":"removeNotification","click #removeAllNotifications":"removeAllNotifications"},initialize:function(){this.collection.bind("add",this.renderNotifications.bind(this)),this.collection.bind("remove",this.renderNotifications.bind(this)),this.collection.bind("reset",this.renderNotifications.bind(this))},notificationItem:templateEngine.createTemplate("notificationItem.ejs"),el:"#notificationBar",template:templateEngine.createTemplate("notificationView.ejs"),toggleNotification:function(){var a=this.collection.length;0!==a&&$("#notification_menu").toggle()},removeAllNotifications:function(){$.noty.clearQueue(),$.noty.closeAll(),this.collection.reset(),$("#notification_menu").hide()},removeNotification:function(a){var b=a.target.id;this.collection.get(b).destroy()},renderNotifications:function(a,b,c){if(c&&c.add){var d=this.collection.at(this.collection.length-1),e=d.get("title"),f=3e3;if(d.get("content")&&(e=e+": "+d.get("content")),"error"===d.get("type")&&(f=!1),$.noty.clearQueue(),$.noty.closeAll(),noty({theme:"relax",text:e,template:'
    ',maxVisible:1,closeWith:["click"],type:d.get("type"),layout:"bottom",timeout:f,animation:{open:{height:"show"},close:{height:"hide"},easing:"swing",speed:200}}),"success"===d.get("type"))return void d.destroy()}$("#stat_hd_counter").text(this.collection.length),0===this.collection.length?($("#stat_hd").removeClass("fullNotification"),$("#notification_menu").hide()):$("#stat_hd").addClass("fullNotification"),$(".innerDropdownInnerUL").html(this.notificationItem.render({notifications:this.collection})),$(".notificationInfoIcon").tooltip({position:{my:"left top",at:"right+55 top-1"}})},render:function(){return $(this.el).html(this.template.render({notifications:this.collection})),this.renderNotifications(),this.delegateEvents(),this.el}})}(),function(){"use strict";window.ProgressView=Backbone.View.extend({template:templateEngine.createTemplate("progressBase.ejs"),el:"#progressPlaceholder",el2:"#progressPlaceholderIcon",toShow:!1,lastDelay:0,action:function(){},events:{"click .progress-action button":"performAction"},performAction:function(){this.action(),window.progressView.hide()},initialize:function(){},showWithDelay:function(a,b,c,d){var e=this;e.toShow=!0,e.lastDelay=a,setTimeout(function(){e.toShow===!0&&e.show(b,c,d)},e.lastDelay)},show:function(a,b,c){$(this.el).html(this.template.render({})),$(".progress-text").text(a),c?$(".progress-action").html('"):$(".progress-action").html(''),b?this.action=b:this.action=this.hide(),$(this.el).show()},hide:function(){var a=this;a.toShow=!1,$(this.el).hide(),this.action=function(){}}})}(),function(){"use strict";window.queryManagementView=Backbone.View.extend({el:"#content",id:"#queryManagementContent",templateActive:templateEngine.createTemplate("queryManagementViewActive.ejs"),templateSlow:templateEngine.createTemplate("queryManagementViewSlow.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),tabbar:templateEngine.createTemplate("arangoTabbar.ejs"),initialize:function(){this.activeCollection=new window.QueryManagementActive,this.slowCollection=new window.QueryManagementSlow,this.convertModelToJSON(!0)},events:{"click #arangoQueryManagementTabbar button":"switchTab","click #deleteSlowQueryHistory":"deleteSlowQueryHistoryModal","click #arangoQueryManagementTable .fa-minus-circle":"deleteRunningQueryModal"},tabbarElements:{id:"arangoQueryManagementTabbar",titles:[["Active","activequeries"],["Slow","slowqueries"]]},tableDescription:{id:"arangoQueryManagementTable",titles:["ID","Query String","Runtime","Started",""],rows:[],unescaped:[!1,!1,!1,!1,!0]},switchTab:function(a){"activequeries"===a.currentTarget.id?this.convertModelToJSON(!0):"slowqueries"===a.currentTarget.id&&this.convertModelToJSON(!1)},deleteRunningQueryModal:function(a){this.killQueryId=$(a.currentTarget).attr("data-id");var b=[],c=[];c.push(window.modalView.createReadOnlyEntry(void 0,"Running Query","Do you want to kill the running query?",void 0,void 0,!1,void 0)),b.push(window.modalView.createDeleteButton("Kill",this.killRunningQuery.bind(this))),window.modalView.show("modalTable.ejs","Kill Running Query",b,c),$(".modal-delete-confirmation strong").html("Really kill?")},killRunningQuery:function(){this.collection.killRunningQuery(this.killQueryId,this.killRunningQueryCallback.bind(this)),window.modalView.hide()},killRunningQueryCallback:function(){this.convertModelToJSON(!0),this.renderActive()},deleteSlowQueryHistoryModal:function(){var a=[],b=[];b.push(window.modalView.createReadOnlyEntry(void 0,"Slow Query Log","Do you want to delete the slow query log entries?",void 0,void 0,!1,void 0)),a.push(window.modalView.createDeleteButton("Delete",this.deleteSlowQueryHistory.bind(this))),window.modalView.show("modalTable.ejs","Delete Slow Query Log",a,b)},deleteSlowQueryHistory:function(){this.collection.deleteSlowQueryHistory(this.slowQueryCallback.bind(this)),window.modalView.hide()},slowQueryCallback:function(){this.convertModelToJSON(!1),this.renderSlow()},render:function(){this.convertModelToJSON(!0)},renderActive:function(){this.$el.html(this.templateActive.render({})),$(this.id).html(this.tabbar.render({content:this.tabbarElements})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#activequeries").addClass("arango-active-tab")},renderSlow:function(){this.$el.html(this.templateSlow.render({})),$(this.id).html(this.tabbar.render({content:this.tabbarElements})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#slowqueries").addClass("arango-active-tab")},convertModelToJSON:function(a){var b=this,c=[];a===!0?this.collection=this.activeCollection:this.collection=this.slowCollection,this.collection.fetch({success:function(){b.collection.each(function(b){var d="";a&&(d=''),c.push([b.get("id"),b.get("query"),b.get("runTime").toFixed(2)+" s",b.get("started"),d])});var d="No running queries.";a||(d="No slow queries."),0===c.length&&c.push([d,"","",""]),b.tableDescription.rows=c,a?b.renderActive():b.renderSlow()}})}})}(),function(){"use strict";window.queryView=Backbone.View.extend({el:"#content",id:"#customsDiv",warningTemplate:templateEngine.createTemplate("warningList.ejs"),tabArray:[],execPending:!1,initialize:function(){this.refreshAQL(),this.tableDescription.rows=this.customQueries},events:{"click #result-switch":"switchTab","click #query-switch":"switchTab","click #customs-switch":"switchTab","click #submitQueryButton":"submitQuery","click #explainQueryButton":"explainQuery","click #commentText":"commentText","click #uncommentText":"uncommentText","click #undoText":"undoText","click #redoText":"redoText","click #smallOutput":"smallOutput","click #bigOutput":"bigOutput","click #clearOutput":"clearOutput","click #clearInput":"clearInput","click #clearQueryButton":"clearInput","click #addAQL":"addAQL","mouseover #querySelect":function(){this.refreshAQL(!0)},"change #querySelect":"importSelected","keypress #aqlEditor":"aqlShortcuts","click #arangoQueryTable .table-cell0":"editCustomQuery","click #arangoQueryTable .table-cell1":"editCustomQuery","click #arangoQueryTable .table-cell2 a":"deleteAQL","click #confirmQueryImport":"importCustomQueries","click #confirmQueryExport":"exportCustomQueries","click #export-query":"exportCustomQueries","click #import-query":"openExportDialog","click #closeQueryModal":"closeExportDialog","click #downloadQueryResult":"downloadQueryResult"},openExportDialog:function(){$("#queryImportDialog").modal("show")},closeExportDialog:function(){$("#queryImportDialog").modal("hide")},createCustomQueryModal:function(){var a=[],b=[];b.push(window.modalView.createTextEntry("new-query-name","Name","",void 0,void 0,!1,[{rule:Joi.string().required(),msg:"No query name given."}])),a.push(window.modalView.createSuccessButton("Save",this.saveAQL.bind(this))),window.modalView.show("modalTable.ejs","Save Query",a,b,void 0,void 0,{"keyup #new-query-name":this.listenKey.bind(this)})},updateTable:function(){this.tableDescription.rows=this.customQueries,_.each(this.tableDescription.rows,function(a){a.thirdRow='',a.hasOwnProperty("parameter")&&delete a.parameter}),this.tableDescription.unescaped=[!1,!1,!0],this.$(this.id).html(this.table.render({content:this.tableDescription}))},editCustomQuery:function(a){var b=$(a.target).parent().children().first().text(),c=ace.edit("aqlEditor"),d=ace.edit("varsEditor");c.setValue(this.getCustomQueryValueByName(b)),d.setValue(JSON.stringify(this.getCustomQueryParameterByName(b))),this.deselect(d),this.deselect(c),$("#querySelect").val(b),this.switchTab("query-switch")},initTabArray:function(){var a=this;$(".arango-tab").children().each(function(){a.tabArray.push($(this).children().first().attr("id"))})},listenKey:function(a){13===a.keyCode&&this.saveAQL(a),this.checkSaveName()},checkSaveName:function(){var a=$("#new-query-name").val();if("Insert Query"===a)return void $("#new-query-name").val("");var b=this.customQueries.some(function(b){return b.name===a});b?($("#modalButton1").removeClass("button-success"),$("#modalButton1").addClass("button-warning"),$("#modalButton1").text("Update")):($("#modalButton1").removeClass("button-warning"),$("#modalButton1").addClass("button-success"),$("#modalButton1").text("Save"))},clearOutput:function(){var a=ace.edit("queryOutput");a.setValue("")},clearInput:function(){var a=ace.edit("aqlEditor"),b=ace.edit("varsEditor");this.setCachedQuery(a.getValue(),b.getValue()),a.setValue(""),b.setValue("")},smallOutput:function(){var a=ace.edit("queryOutput");a.getSession().foldAll()},bigOutput:function(){var a=ace.edit("queryOutput");a.getSession().unfold()},aqlShortcuts:function(a){a.ctrlKey&&13===a.keyCode?this.submitQuery():a.metaKey&&!a.ctrlKey&&13===a.keyCode&&this.submitQuery()},queries:[],customQueries:[],tableDescription:{id:"arangoQueryTable",titles:["Name","Content",""],rows:[]},template:templateEngine.createTemplate("queryView.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),render:function(){var a=this;this.$el.html(this.template.render({})),this.$(this.id).html(this.table.render({content:this.tableDescription}));var b=1e3,c=$("#querySize");c.empty(),[100,250,500,1e3,2500,5e3,1e4,"all"].forEach(function(a){c.append('")});var d=ace.edit("queryOutput");d.setReadOnly(!0),d.setHighlightActiveLine(!1),d.getSession().setMode("ace/mode/json"),d.setFontSize("13px"),d.setValue("");var e=ace.edit("aqlEditor");e.getSession().setMode("ace/mode/aql"),e.setFontSize("13px"),e.commands.addCommand({name:"togglecomment",bindKey:{win:"Ctrl-Shift-C",linux:"Ctrl-Shift-C", +mac:"Command-Shift-C"},exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEach"});var f=ace.edit("varsEditor");f.getSession().setMode("ace/mode/aql"),f.setFontSize("13px"),f.commands.addCommand({name:"togglecomment",bindKey:{win:"Ctrl-Shift-C",linux:"Ctrl-Shift-C",mac:"Command-Shift-C"},exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEach"});var g=this.getCachedQuery();null!==g&&void 0!==g&&""!==g&&(e.setValue(g.query),""===g.parameter||void 0===g?f.setValue("{}"):f.setValue(g.parameter));var h=function(){var b=e.getSession(),c=e.getCursorPosition(),d=b.getTokenAt(c.row,c.column);d&&("comment"===d.type?$("#commentText i").removeClass("fa-comment").addClass("fa-comment-o").attr("data-original-title","Uncomment"):$("#commentText i").removeClass("fa-comment-o").addClass("fa-comment").attr("data-original-title","Comment"));var g=e.getValue(),h=f.getValue();1===g.length&&(g=""),1===h.length&&(h=""),a.setCachedQuery(g,h)};e.getSession().selection.on("changeCursor",function(){h()}),f.getSession().selection.on("changeCursor",function(){h()}),$("#queryOutput").resizable({handles:"s",ghost:!0,stop:function(){setTimeout(function(){var a=ace.edit("queryOutput");a.resize()},200)}}),arangoHelper.fixTooltips(".vars-editor-header i, .queryTooltips, .icon_arangodb","top"),$("#aqlEditor .ace_text-input").focus();var i=$(window).height()-295;return $("#aqlEditor").height(i-100-29),$("#varsEditor").height(100),$("#queryOutput").height(i),e.resize(),d.resize(),this.initTabArray(),this.renderSelectboxes(),this.deselect(f),this.deselect(d),this.deselect(e),$("#queryDiv").show(),$("#customsDiv").show(),this.initQueryImport(),this.switchTab("query-switch"),this},getCachedQuery:function(){if("undefined"!==Storage){var a=localStorage.getItem("cachedQuery");if(void 0!==a){var b=JSON.parse(a);return b}}},setCachedQuery:function(a,b){if("undefined"!==Storage){var c={query:a,parameter:b};localStorage.setItem("cachedQuery",JSON.stringify(c))}},initQueryImport:function(){var a=this;a.allowUpload=!1,$("#importQueries").change(function(b){a.files=b.target.files||b.dataTransfer.files,a.file=a.files[0],a.allowUpload=!0,$("#confirmQueryImport").removeClass("disabled")})},importCustomQueries:function(){var a=this;if(this.allowUpload===!0){var b=function(){this.collection.fetch({async:!1}),this.updateLocalQueries(),this.renderSelectboxes(),this.updateTable(),a.allowUpload=!1,$("#customs-switch").click()};a.collection.saveImportQueries(a.file,b.bind(this)),$("#confirmQueryImport").addClass("disabled"),$("#queryImportDialog").modal("hide")}},downloadQueryResult:function(){var a=ace.edit("aqlEditor"),b=a.getValue();""!==b||void 0!==b||null!==b?window.open("query/result/download/"+encodeURIComponent(btoa(JSON.stringify({query:b})))):arangoHelper.arangoError("Query error","could not query result.")},exportCustomQueries:function(){var a,b={},c=[];_.each(this.customQueries,function(a){c.push({name:a.name,value:a.value,parameter:a.parameter})}),b={extra:{queries:c}},$.ajax("whoAmI?_="+Date.now(),{async:!1}).done(function(b){a=b.user,(null===a||a===!1)&&(a="root")}),window.open("query/download/"+encodeURIComponent(a))},deselect:function(a){var b=a.getSelection(),c=b.lead.row,d=b.lead.column;b.setSelectionRange({start:{row:c,column:d},end:{row:c,column:d}}),a.focus()},addAQL:function(){this.refreshAQL(!0),this.createCustomQueryModal(),$("#new-query-name").val($("#querySelect").val()),setTimeout(function(){$("#new-query-name").focus()},500),this.checkSaveName()},getAQL:function(){var a,b=this;this.collection.fetch({async:!1});var c=localStorage.getItem("customQueries");if(c){var d=JSON.parse(c);_.each(d,function(a){b.collection.add({value:a.value,name:a.name})}),a=b.collection.saveCollectionQueries(),a===!0&&localStorage.removeItem("customQueries")}this.updateLocalQueries()},deleteAQL:function(a){var b=$(a.target).parent().parent().parent().children().first().text(),c=this.collection.findWhere({name:b});this.collection.remove(c),this.collection.saveCollectionQueries(),this.updateLocalQueries(),this.renderSelectboxes(),this.updateTable()},updateLocalQueries:function(){var a=this;this.customQueries=[],this.collection.each(function(b){a.customQueries.push({name:b.get("name"),value:b.get("value"),parameter:b.get("parameter")})})},saveAQL:function(a){a.stopPropagation(),this.refreshAQL();var b=ace.edit("aqlEditor"),c=ace.edit("varsEditor"),d=$("#new-query-name").val(),e=c.getValue();if(!$("#new-query-name").hasClass("invalid-input")&&""!==d.trim()){var f=b.getValue(),g=!1;if($.each(this.customQueries,function(a,b){return b.name===d?(b.value=f,void(g=!0)):void 0}),g===!0)this.collection.findWhere({name:d}).set("value",f);else{if((""===e||void 0===e)&&(e="{}"),"string"==typeof e)try{e=JSON.parse(e)}catch(h){console.log("could not parse bind parameter")}this.collection.add({name:d,parameter:e,value:f})}this.collection.saveCollectionQueries(),window.modalView.hide(),this.updateLocalQueries(),this.renderSelectboxes(),$("#querySelect").val(d)}},getSystemQueries:function(){var a=this;$.ajax({type:"GET",cache:!1,url:"js/arango/aqltemplates.json",contentType:"application/json",processData:!1,async:!1,success:function(b){a.queries=b},error:function(){arangoHelper.arangoNotification("Query","Error while loading system templates")}})},getCustomQueryValueByName:function(a){return this.collection.findWhere({name:a}).get("value")},getCustomQueryParameterByName:function(a){return this.collection.findWhere({name:a}).get("parameter")},refreshAQL:function(a){if(this.getAQL(),this.getSystemQueries(),this.updateLocalQueries(),a){var b=$("#querySelect").val();this.renderSelectboxes(),$("#querySelect").val(b)}},importSelected:function(a){var b=ace.edit("aqlEditor"),c=ace.edit("varsEditor");$.each(this.queries,function(d,e){$("#"+a.currentTarget.id).val()===e.name&&(b.setValue(e.value),e.hasOwnProperty("parameter")?((""===e.parameter||void 0===e.parameter)&&(e.parameter="{}"),"object"==typeof e.parameter?c.setValue(JSON.stringify(e.parameter)):c.setValue(e.parameter)):c.setValue("{}"))}),$.each(this.customQueries,function(d,e){$("#"+a.currentTarget.id).val()===e.name&&(b.setValue(e.value),e.hasOwnProperty("parameter")?((""===e.parameter||void 0===e.parameter)&&(e.parameter="{}"),c.setValue(e.parameter)):c.setValue("{}"))}),this.deselect(ace.edit("varsEditor")),this.deselect(ace.edit("aqlEditor"))},renderSelectboxes:function(){this.sortQueries();var a="";a="#querySelect",$(a).empty(),$(a).append(''),$(a).append(''),jQuery.each(this.queries,function(b,c){$(a).append('")}),$(a).append(""),this.customQueries.length>0&&($(a).append(''),jQuery.each(this.customQueries,function(b,c){$(a).append('")}),$(a).append(""))},undoText:function(){var a=ace.edit("aqlEditor");a.undo()},redoText:function(){var a=ace.edit("aqlEditor");a.redo()},commentText:function(){var a=ace.edit("aqlEditor");a.toggleCommentLines()},sortQueries:function(){this.queries=_.sortBy(this.queries,"name"),this.customQueries=_.sortBy(this.customQueries,"name")},readQueryData:function(){var a=ace.edit("aqlEditor"),b=ace.edit("varsEditor"),c=a.session.getTextRange(a.getSelectionRange()),d=$("#querySize"),e={query:c||a.getValue(),id:"currentFrontendQuery"};"all"!==d.val()&&(e.batchSize=parseInt(d.val(),10));var f=b.getValue();if(f.length>0)try{var g=JSON.parse(f);0!==Object.keys(g).length&&(e.bindVars=g)}catch(h){return arangoHelper.arangoError("Query error","Could not parse bind parameters."),!1}return JSON.stringify(e)},heatmapColors:["#313695","#4575b4","#74add1","#abd9e9","#e0f3f8","#ffffbf","#fee090","#fdae61","#f46d43","#d73027","#a50026"],heatmap:function(a){return this.heatmapColors[Math.floor(10*a)]},followQueryPath:function(a,b){var c={},d=0;c[b[0].id]=a;var e,f,g,h;for(e=1;e0&&(b+="Warnings:\r\n\r\n",a.extra.warnings.forEach(function(a){b+="["+a.code+"], '"+a.message+"'\r\n"})),""!==b&&(b+="\r\nResult:\r\n\r\n"),d.setValue(b+JSON.stringify(a.result,void 0,2))},g=function(a){f(a),c.switchTab("result-switch"),window.progressView.hide();var e="Execution time: "+c.timer.getTimeAndReset()/1e3+" s";$(".queryExecutionTime").text(e),c.deselect(d),$("#downloadQueryResult").show(),"function"==typeof b&&b()},h=function(){$.ajax({type:"PUT",url:"/_api/job/"+encodeURIComponent(a),contentType:"application/json",processData:!1,success:function(a,b,d){201===d.status?g(a):204===d.status&&(c.checkQueryTimer=window.setTimeout(function(){h()},500))},error:function(a){try{var b=JSON.parse(a.responseText);b.errorMessage&&arangoHelper.arangoError("Query",b.errorMessage)}catch(c){arangoHelper.arangoError("Query","Something went wrong.")}window.progressView.hide()}})};h()},fillResult:function(a){var b=this,c=ace.edit("queryOutput");c.setValue("");var d=this.readQueryData();d&&$.ajax({type:"POST",url:"/_api/cursor",headers:{"x-arango-async":"store"},data:d,contentType:"application/json",processData:!1,success:function(c,d,e){e.getResponseHeader("x-arango-async-id")&&b.queryCallbackFunction(e.getResponseHeader("x-arango-async-id"),a),$.noty.clearQueue(),$.noty.closeAll()},error:function(d){b.switchTab("result-switch"),$("#downloadQueryResult").hide();try{var e=JSON.parse(d.responseText);c.setValue("["+e.errorNum+"] "+e.errorMessage)}catch(f){c.setValue("ERROR"),arangoHelper.arangoError("Query error","ERROR")}window.progressView.hide(),"function"==typeof a&&a()}})},submitQuery:function(){var a=ace.edit("queryOutput");this.fillResult(this.switchTab.bind(this,"result-switch")),a.resize();var b=ace.edit("aqlEditor");this.deselect(b),$("#downloadQueryResult").show()},explainQuery:function(){this.fillExplain()},switchTab:function(a){var b;b="string"==typeof a?a:a.target.id;var c=this,d=function(a){var d="#"+a.replace("-switch",""),e="#tabContent"+d.charAt(1).toUpperCase()+d.substr(2);a===b?($("#"+a).parent().addClass("active"),$(d).addClass("active"),$(e).show(),"query-switch"===b?$("#aqlEditor .ace_text-input").focus():"result-switch"===b&&c.execPending&&c.fillResult()):($("#"+a).parent().removeClass("active"),$(d).removeClass("active"),$(e).hide())};this.tabArray.forEach(d),this.updateTable()}})}(),function(){"use strict";window.shellView=Backbone.View.extend({resizing:!1,el:"#content",template:templateEngine.createTemplate("shellView.ejs"),render:function(){$(this.el).html(this.template.render({})),this.replShell(),$("#shell_workspace").trigger("resize",[150]),this.resize();var a=this;return $(window).resize(function(){a.resize()}),this.executeJs("start_pretty_print(); try { db._collections(); } catch (err) { } undefined;"),this},resize:function(){if(!this.resizing){this.resizing=!0;var a=$(window).height()-250;$("#shell_workspace").height(a),this.resizing=!1}},executeJs:function(a){var b=require("internal");try{var c=window.eval(a);void 0!==c&&(b.browserOutputBuffer="",b.printShell(c),jqconsole.Write("==> "+b.browserOutputBuffer+"\n","jssuccess")),b.browserOutputBuffer=""}catch(d){d instanceof b.ArangoError?d.hasOwnProperty("errorMessage")?jqconsole.Write(d.errorMessage+"\n","jserror"):jqconsole.Write(d.message+"\n","jserror"):jqconsole.Write(d.name+": "+d.message+"\n","jserror")}},replShellPromptHelper:function(a){try{new Function(a)}catch(b){return/[\[\{\(]$/.test(a)?1:0}return!1},replShellHandlerHelper:function(a){},replShell:function(){var a=this,b=require("internal"),c=require("@arangodb/arangosh"),d="Welcome to arangosh. Copyright (c) ArangoDB GmbH\n";window.jqconsole=$("#replShell").jqconsole(d,"JSH> ","...>"),this.executeJs(b.print(c.HELP)),jqconsole.RegisterShortcut("Z",function(){jqconsole.AbortPrompt(),e()}),jqconsole.RegisterShortcut("E",function(){jqconsole.MoveToEnd(),e()}),jqconsole.RegisterMatching("{","}","brace"),jqconsole.RegisterMatching("(",")","paren"),jqconsole.RegisterMatching("[","]","bracket");var e=function(b){"help"===b&&(b=help()),"exit"===b&&location.reload(),a.executeJs(b),jqconsole.Prompt(!0,e,a.replShellPromptHelper(b))};e()}})}(),function(){"use strict";window.StatisticBarView=Backbone.View.extend({el:"#statisticBar",events:{"change #arangoCollectionSelect":"navigateBySelect","click .tab":"navigateByTab"},template:templateEngine.createTemplate("statisticBarView.ejs"),initialize:function(){this.currentDB=this.options.currentDB},replaceSVG:function(a){var b=a.attr("id"),c=a.attr("class"),d=a.attr("src");$.get(d,function(d){var e=$(d).find("svg");void 0===b&&(e=e.attr("id",b)),void 0===c&&(e=e.attr("class",c+" replaced-svg")),e=e.removeAttr("xmlns:a"),a.replaceWith(e)},"xml")},render:function(){var a=this;return $(this.el).html(this.template.render({isSystem:this.currentDB.get("isSystem")})),$("img.svg").each(function(){a.replaceSVG($(this))}),this},navigateBySelect:function(){var a=$("#arangoCollectionSelect").find("option:selected").val();window.App.navigate(a,{trigger:!0})},navigateByTab:function(a){var b=a.target||a.srcElement,c=b.id;return"links"===c?($("#link_dropdown").slideToggle(200),void a.preventDefault()):"tools"===c?($("#tools_dropdown").slideToggle(200),void a.preventDefault()):(window.App.navigate(c,{trigger:!0}),void a.preventDefault())},handleSelectNavigation:function(){$("#arangoCollectionSelect").change(function(){var a=$(this).find("option:selected").val();window.App.navigate(a,{trigger:!0})})},selectMenuItem:function(a){$(".navlist li").removeClass("active"),a&&$("."+a).addClass("active")}})}(),function(){"use strict";window.TableView=Backbone.View.extend({template:templateEngine.createTemplate("tableView.ejs"),loading:templateEngine.createTemplate("loadingTableView.ejs"),initialize:function(){this.rowClickCallback=this.options.rowClick},events:{"click tbody tr":"rowClick","click .deleteButton":"removeClick"},rowClick:function(a){this.hasOwnProperty("rowClickCallback")&&this.rowClickCallback(a)},removeClick:function(a){this.hasOwnProperty("removeClickCallback")&&(this.removeClickCallback(a),a.stopPropagation())},setRowClick:function(a){this.rowClickCallback=a},setRemoveClick:function(a){this.removeClickCallback=a},render:function(){$(this.el).html(this.template.render({docs:this.collection}))},drawLoading:function(){$(this.el).html(this.loading.render({}))}})}(),function(){"use strict";window.testView=Backbone.View.extend({el:"#content",graph:{edges:[],nodes:[]},events:{},initialize:function(){console.log(void 0)},template:templateEngine.createTemplate("testView.ejs"),render:function(){return $(this.el).html(this.template.render({})),this.renderGraph(),this},renderGraph:function(){this.convertData(),console.log(this.graph),this.s=new sigma({graph:this.graph,container:"graph-container",verbose:!0,renderers:[{container:document.getElementById("graph-container"),type:"webgl"}]})},convertData:function(){var a=this;return _.each(this.dump,function(b){_.each(b.p,function(c){a.graph.nodes.push({id:c.verticesvalue.v._id,label:b.v._key,x:Math.random(),y:Math.random(),size:Math.random()}),a.graph.edges.push({id:b.e._id,source:b.e._from,target:b.e._to})})}),null},dump:[{v:{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},e:{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"}]}},{v:{label:"8",_id:"circles/H",_rev:"1841664067459",_key:"H"},e:{theFalse:!1,theTruth:!0,label:"right_blob",_id:"edges/1841666295683",_rev:"1841666295683",_key:"1841666295683",_from:"circles/G",_to:"circles/H"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},{label:"8",_id:"circles/H",_rev:"1841664067459",_key:"H"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},{theFalse:!1,theTruth:!0,label:"right_blob",_id:"edges/1841666295683",_rev:"1841666295683",_key:"1841666295683",_from:"circles/G",_to:"circles/H"}]}},{v:{label:"9",_id:"circles/I",_rev:"1841664264067",_key:"I"},e:{theFalse:!1,theTruth:!0,label:"right_blub",_id:"edges/1841666492291",_rev:"1841666492291",_key:"1841666492291",_from:"circles/H",_to:"circles/I"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},{label:"8",_id:"circles/H",_rev:"1841664067459",_key:"H"},{label:"9",_id:"circles/I",_rev:"1841664264067",_key:"I"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},{theFalse:!1,theTruth:!0,label:"right_blob",_id:"edges/1841666295683",_rev:"1841666295683",_key:"1841666295683",_from:"circles/G",_to:"circles/H"},{theFalse:!1,theTruth:!0,label:"right_blub",_id:"edges/1841666492291",_rev:"1841666492291",_key:"1841666492291",_from:"circles/H",_to:"circles/I"}]}},{v:{label:"10",_id:"circles/J",_rev:"1841664460675",_key:"J"},e:{theFalse:!1,theTruth:!0,label:"right_zip",_id:"edges/1841666688899",_rev:"1841666688899",_key:"1841666688899",_from:"circles/G",_to:"circles/J"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},{label:"10",_id:"circles/J",_rev:"1841664460675",_key:"J"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},{theFalse:!1,theTruth:!0,label:"right_zip",_id:"edges/1841666688899",_rev:"1841666688899",_key:"1841666688899",_from:"circles/G",_to:"circles/J"}]}},{v:{label:"11",_id:"circles/K",_rev:"1841664657283",_key:"K"},e:{theFalse:!1,theTruth:!0,label:"right_zup",_id:"edges/1841666885507",_rev:"1841666885507",_key:"1841666885507",_from:"circles/J",_to:"circles/K"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"7",_id:"circles/G",_rev:"1841663870851",_key:"G"},{label:"10",_id:"circles/J",_rev:"1841664460675",_key:"J"},{label:"11",_id:"circles/K",_rev:"1841664657283",_key:"K"}],edges:[{theFalse:!1,theTruth:!0,label:"right_foo",_id:"edges/1841666099075",_rev:"1841666099075",_key:"1841666099075",_from:"circles/A",_to:"circles/G"},{theFalse:!1,theTruth:!0,label:"right_zip",_id:"edges/1841666688899",_rev:"1841666688899",_key:"1841666688899",_from:"circles/G",_to:"circles/J"},{theFalse:!1,theTruth:!0,label:"right_zup",_id:"edges/1841666885507",_rev:"1841666885507",_key:"1841666885507",_from:"circles/J",_to:"circles/K"}]}},{v:{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},e:{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"}]}},{v:{label:"5",_id:"circles/E",_rev:"1841663477635",_key:"E"},e:{theFalse:!1,theTruth:!0,label:"left_blub",_id:"edges/1841665705859",_rev:"1841665705859",_key:"1841665705859",_from:"circles/B",_to:"circles/E"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},{label:"5",_id:"circles/E",_rev:"1841663477635",_key:"E"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},{theFalse:!1,theTruth:!0,label:"left_blub",_id:"edges/1841665705859",_rev:"1841665705859",_key:"1841665705859",_from:"circles/B",_to:"circles/E"}]}},{v:{label:"6",_id:"circles/F",_rev:"1841663674243",_key:"F"},e:{theFalse:!1,theTruth:!0,label:"left_schubi",_id:"edges/1841665902467",_rev:"1841665902467",_key:"1841665902467",_from:"circles/E",_to:"circles/F"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},{label:"5",_id:"circles/E",_rev:"1841663477635",_key:"E"},{label:"6",_id:"circles/F",_rev:"1841663674243",_key:"F"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},{theFalse:!1,theTruth:!0,label:"left_blub",_id:"edges/1841665705859",_rev:"1841665705859",_key:"1841665705859",_from:"circles/B",_to:"circles/E"},{theFalse:!1,theTruth:!0,label:"left_schubi",_id:"edges/1841665902467",_rev:"1841665902467",_key:"1841665902467",_from:"circles/E",_to:"circles/F"}]}},{v:{label:"3",_id:"circles/C",_rev:"1841663084419",_key:"C"},e:{theFalse:!1,theTruth:!0,label:"left_blarg",_id:"edges/1841665312643",_rev:"1841665312643",_key:"1841665312643",_from:"circles/B",_to:"circles/C"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},{label:"3",_id:"circles/C",_rev:"1841663084419",_key:"C"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},{theFalse:!1,theTruth:!0,label:"left_blarg",_id:"edges/1841665312643",_rev:"1841665312643",_key:"1841665312643",_from:"circles/B",_to:"circles/C"}]}},{v:{label:"4",_id:"circles/D",_rev:"1841663281027",_key:"D"},e:{theFalse:!1,theTruth:!0,label:"left_blorg",_id:"edges/1841665509251",_rev:"1841665509251",_key:"1841665509251",_from:"circles/C",_to:"circles/D"},p:{vertices:[{label:"1",_id:"circles/A",_rev:"1841662691203",_key:"A"},{label:"2",_id:"circles/B",_rev:"1841662887811",_key:"B"},{label:"3",_id:"circles/C",_rev:"1841663084419",_key:"C"},{label:"4",_id:"circles/D",_rev:"1841663281027",_key:"D"}],edges:[{theFalse:!1,theTruth:!0,label:"left_bar",_id:"edges/1841665116035",_rev:"1841665116035",_key:"1841665116035",_from:"circles/A",_to:"circles/B"},{theFalse:!1,theTruth:!0,label:"left_blarg",_id:"edges/1841665312643",_rev:"1841665312643",_key:"1841665312643",_from:"circles/B",_to:"circles/C"},{theFalse:!1,theTruth:!0,label:"left_blorg",_id:"edges/1841665509251",_rev:"1841665509251",_key:"1841665509251",_from:"circles/C",_to:"circles/D"}]}}]})}(),function(){"use strict";window.UserBarView=Backbone.View.extend({events:{"change #userBarSelect":"navigateBySelect","click .tab":"navigateByTab","mouseenter .dropdown":"showDropdown","mouseleave .dropdown":"hideDropdown","click #userLogout":"userLogout"},initialize:function(){this.userCollection=this.options.userCollection,this.userCollection.fetch({async:!1}),this.userCollection.bind("change:extra",this.render.bind(this))},template:templateEngine.createTemplate("userBarView.ejs"),navigateBySelect:function(){var a=$("#arangoCollectionSelect").find("option:selected").val();window.App.navigate(a,{trigger:!0})},navigateByTab:function(a){var b=a.target||a.srcElement;b=$(b).closest("a");var c=b.attr("id");return"user"===c?($("#user_dropdown").slideToggle(200),void a.preventDefault()):(window.App.navigate(c,{trigger:!0}),void a.preventDefault())},showDropdown:function(){$("#user_dropdown").fadeIn(1)},hideDropdown:function(){$("#user_dropdown").fadeOut(1)},render:function(){var a=this.userCollection.whoAmI(),b=null,c=null,d=!1,e=null;return a&&(e=this.userCollection.findWhere({user:a}),e.set({loggedIn:!0}),c=e.get("extra").name,b=e.get("extra").img,d=e.get("active")),b=b?"https://s.gravatar.com/avatar/"+b+"?s=24":"img/default_user.png",c||(c=""),this.$el=$("#userBar"),this.$el.html(this.template.render({img:b,name:c,username:a,active:d})),this.delegateEvents(),this.$el},userLogout:function(){this.userCollection.whoAmI(),this.userCollection.logout()}})}(),function(){"use strict";window.userManagementView=Backbone.View.extend({el:"#content",el2:"#userManagementThumbnailsIn",template:templateEngine.createTemplate("userManagementView.ejs"),events:{"click #createUser":"createUser","click #submitCreateUser":"submitCreateUser","click #userManagementThumbnailsIn .tile":"editUser","click #submitEditUser":"submitEditUser","click #userManagementToggle":"toggleView","keyup #userManagementSearchInput":"search","click #userManagementSearchSubmit":"search","click #callEditUserPassword":"editUserPassword","click #submitEditUserPassword":"submitEditUserPassword","click #submitEditCurrentUserProfile":"submitEditCurrentUserProfile","click .css-label":"checkBoxes","change #userSortDesc":"sorting"},dropdownVisible:!1,initialize:function(){this.collection.fetch({async:!1}),this.currentUser=this.collection.findWhere({user:this.collection.whoAmI()})},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},sorting:function(){$("#userSortDesc").is(":checked")?this.collection.setSortingDesc(!0):this.collection.setSortingDesc(!1),$("#userManagementDropdown").is(":visible")?this.dropdownVisible=!0:this.dropdownVisible=!1,this.render()},render:function(a){var b=!1;return $("#userManagementDropdown").is(":visible")&&(b=!0),this.collection.sort(),$(this.el).html(this.template.render({collection:this.collection,searchString:""})),b===!0&&($("#userManagementDropdown2").show(),$("#userSortDesc").attr("checked",this.collection.sortOptions.desc),$("#userManagementToggle").toggleClass("activated"),$("#userManagementDropdown").show()),a&&this.editCurrentUser(),arangoHelper.setCheckboxStatus("#userManagementDropdown"),this},search:function(){var a,b,c,d;a=$("#userManagementSearchInput"),b=$("#userManagementSearchInput").val(),d=this.collection.filter(function(a){return-1!==a.get("user").indexOf(b)}),$(this.el).html(this.template.render({collection:d,searchString:b})),a=$("#userManagementSearchInput"),c=a.val().length,a.focus(),a[0].setSelectionRange(c,c)},createUser:function(a){a.preventDefault(),this.createCreateUserModal()},submitCreateUser:function(){var a=this,b=$("#newUsername").val(),c=$("#newName").val(),d=$("#newPassword").val(),e=$("#newStatus").is(":checked");if(this.validateUserInfo(c,b,d,e)){var f={user:b,passwd:d,active:e,extra:{name:c}};this.collection.create(f,{wait:!0,error:function(a,b){},success:function(b){a.updateUserManagement(),window.modalView.hide()}})}},validateUserInfo:function(a,b,c,d){return""===b?(arangoHelper.arangoError("You have to define an username"),$("#newUsername").closest("th").css("backgroundColor","red"),!1):!0},updateUserManagement:function(){var a=this;this.collection.fetch({success:function(){a.render()}})},submitDeleteUser:function(a){var b=this.collection.findWhere({user:a});b.destroy({wait:!0}),window.modalView.hide(),this.updateUserManagement()},editUser:function(a){$(a.currentTarget).hasClass("tile")&&(a.currentTarget=$(a.currentTarget).find("img")),this.collection.fetch();var b=this.evaluateUserName($(a.currentTarget).attr("id"),"_edit-user");""===b&&(b=$(a.currentTarget).attr("id"));var c=this.collection.findWhere({user:b});c.get("loggedIn")?this.editCurrentUser():this.createEditUserModal(c.get("user"),c.get("extra").name,c.get("active"))},editCurrentUser:function(){this.createEditCurrentUserModal(this.currentUser.get("user"),this.currentUser.get("extra").name,this.currentUser.get("extra").img)},submitEditUser:function(a){var b=$("#editName").val(),c=$("#editStatus").is(":checked");if(!this.validateStatus(c))return void $("#editStatus").closest("th").css("backgroundColor","red");if(!this.validateName(b))return void $("#editName").closest("th").css("backgroundColor","red");var d=this.collection.findWhere({user:a});d.save({extra:{name:b},active:c},{type:"PATCH"}),window.modalView.hide(),this.updateUserManagement()},validateUsername:function(a){return""===a?(arangoHelper.arangoError("You have to define an username"),$("#newUsername").closest("th").css("backgroundColor","red"),!1):a.match(/^[a-zA-Z][a-zA-Z0-9_\-]*$/)?!0:(arangoHelper.arangoError("Wrong Username","Username may only contain numbers, letters, _ and -"),!1)},validatePassword:function(a){return!0},validateName:function(a){return""===a?!0:a.match(/^[a-zA-Z][a-zA-Z0-9_\-\ ]*$/)?!0:(arangoHelper.arangoError("Wrong Username","Username may only contain numbers, letters, _ and -"),!1)},validateStatus:function(a){return""===a?!1:!0},toggleView:function(){$("#userSortDesc").attr("checked",this.collection.sortOptions.desc),$("#userManagementToggle").toggleClass("activated"),$("#userManagementDropdown2").slideToggle(200)},setFilterValues:function(){},evaluateUserName:function(a,b){var c=a.lastIndexOf(b);return a.substring(0,c)},editUserPassword:function(){window.modalView.hide(),this.createEditUserPasswordModal()},submitEditUserPassword:function(){var a=$("#oldCurrentPassword").val(),b=$("#newCurrentPassword").val(),c=$("#confirmCurrentPassword").val();$("#oldCurrentPassword").val(""),$("#newCurrentPassword").val(""),$("#confirmCurrentPassword").val(""),$("#oldCurrentPassword").closest("th").css("backgroundColor","white"),$("#newCurrentPassword").closest("th").css("backgroundColor","white"),$("#confirmCurrentPassword").closest("th").css("backgroundColor","white");var d=!1;this.validateCurrentPassword(a)||($("#oldCurrentPassword").closest("th").css("backgroundColor","red"),d=!0),b!==c&&($("#confirmCurrentPassword").closest("th").css("backgroundColor","red"),d=!0),this.validatePassword(b)||($("#newCurrentPassword").closest("th").css("backgroundColor","red"),d=!0),d||(this.currentUser.setPassword(b),window.modalView.hide())},validateCurrentPassword:function(a){return this.currentUser.checkPassword(a)},submitEditCurrentUserProfile:function(){var a=$("#editCurrentName").val(),b=$("#editCurrentUserProfileImg").val();b=this.parseImgString(b),this.currentUser.setExtras(a,b),this.updateUserProfile(), +window.modalView.hide()},updateUserProfile:function(){var a=this;this.collection.fetch({success:function(){a.render()}})},parseImgString:function(a){return-1===a.indexOf("@")?a:CryptoJS.MD5(a).toString()},createEditUserModal:function(a,b,c){var d,e;e=[{type:window.modalView.tables.READONLY,label:"Username",value:_.escape(a)},{type:window.modalView.tables.TEXT,label:"Name",value:b,id:"editName",placeholder:"Name"},{type:window.modalView.tables.CHECKBOX,label:"Active",value:"active",checked:c,id:"editStatus"}],d=[{title:"Delete",type:window.modalView.buttons.DELETE,callback:this.submitDeleteUser.bind(this,a)},{title:"Save",type:window.modalView.buttons.SUCCESS,callback:this.submitEditUser.bind(this,a)}],window.modalView.show("modalTable.ejs","Edit User",d,e)},createCreateUserModal:function(){var a=[],b=[];b.push(window.modalView.createTextEntry("newUsername","Username","",!1,"Username",!0,[{rule:Joi.string().regex(/^[a-zA-Z0-9\-_]*$/),msg:'Only symbols, "_" and "-" are allowed.'},{rule:Joi.string().required(),msg:"No username given."}])),b.push(window.modalView.createTextEntry("newName","Name","",!1,"Name",!1)),b.push(window.modalView.createPasswordEntry("newPassword","Password","",!1,"",!1)),b.push(window.modalView.createCheckboxEntry("newStatus","Active","active",!1,!0)),a.push(window.modalView.createSuccessButton("Create",this.submitCreateUser.bind(this))),window.modalView.show("modalTable.ejs","Create New User",a,b)},createEditCurrentUserModal:function(a,b,c){var d=[],e=[];e.push(window.modalView.createReadOnlyEntry("id_username","Username",a)),e.push(window.modalView.createTextEntry("editCurrentName","Name",b,!1,"Name",!1)),e.push(window.modalView.createTextEntry("editCurrentUserProfileImg","Gravatar account (Mail)",c,"Mailaddress or its md5 representation of your gravatar account. The address will be converted into a md5 string. Only the md5 string will be stored, not the mailaddress.","myAccount(at)gravatar.com")),d.push(window.modalView.createNotificationButton("Change Password",this.editUserPassword.bind(this))),d.push(window.modalView.createSuccessButton("Save",this.submitEditCurrentUserProfile.bind(this))),window.modalView.show("modalTable.ejs","Edit User Profile",d,e)},createEditUserPasswordModal:function(){var a=[],b=[];b.push(window.modalView.createPasswordEntry("oldCurrentPassword","Old Password","",!1,"old password",!1)),b.push(window.modalView.createPasswordEntry("newCurrentPassword","New Password","",!1,"new password",!1)),b.push(window.modalView.createPasswordEntry("confirmCurrentPassword","Confirm New Password","",!1,"confirm new password",!1)),a.push(window.modalView.createSuccessButton("Save",this.submitEditUserPassword.bind(this))),window.modalView.show("modalTable.ejs","Edit User Password",a,b)}})}(),function(){"use strict";window.workMonitorView=Backbone.View.extend({el:"#content",id:"#workMonitorContent",template:templateEngine.createTemplate("workMonitorView.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),initialize:function(){},events:{},tableDescription:{id:"workMonitorTable",titles:["Type","Database","Task ID","Started","Url","User","Description","Method"],rows:[],unescaped:[!1,!1,!1,!1,!1,!1,!1,!1]},render:function(){var a=this;this.$el.html(this.template.render({})),this.collection.fetch({success:function(){a.parseTableData(),$(a.id).append(a.table.render({content:a.tableDescription}))}})},parseTableData:function(){var a=this;this.collection.each(function(b){if("AQL query"===b.get("type")){var c=b.get("parent");if(c)try{a.tableDescription.rows.push([b.get("type"),"(p) "+c.database,"(p) "+c.taskId,"(p) "+c.startTime,"(p) "+c.url,"(p) "+c.user,b.get("description"),"(p) "+c.method])}catch(d){console.log("some parse error")}}else"thread"!==b.get("type")&&a.tableDescription.rows.push([b.get("type"),b.get("database"),b.get("taskId"),b.get("startTime"),b.get("url"),b.get("user"),b.get("description"),b.get("method")])})}})}(),function(){"use strict";window.Router=Backbone.Router.extend({routes:{"":"dashboard",dashboard:"dashboard",collections:"collections","new":"newCollection",login:"login","collection/:colid/documents/:pageid":"documents","collection/:colid/:docid":"document",shell:"shell",query:"query",queryManagement:"queryManagement",workMonitor:"workMonitor",databases:"databases",applications:"applications","applications/:mount":"applicationDetail",graph:"graphManagement","graph/:name":"showGraph",userManagement:"userManagement",userProfile:"userProfile",logs:"logs",test:"test"},initialize:function(){window.modalView=new window.ModalView,this.foxxList=new window.FoxxCollection,window.foxxInstallView=new window.FoxxInstallView({collection:this.foxxList}),window.progressView=new window.ProgressView;var a=this;this.userCollection=new window.ArangoUsers,this.initOnce=function(){this.initOnce=function(){},this.arangoDatabase=new window.ArangoDatabase,this.currentDB=new window.CurrentDatabase,this.currentDB.fetch({async:!1}),this.arangoCollectionsStore=new window.arangoCollections,this.arangoDocumentStore=new window.arangoDocument,arangoHelper.setDocumentStore(this.arangoDocumentStore),this.arangoCollectionsStore.fetch({async:!1}),this.footerView=new window.FooterView,this.notificationList=new window.NotificationCollection,this.naviView=new window.NavigationView({database:this.arangoDatabase,currentDB:this.currentDB,notificationCollection:a.notificationList,userCollection:this.userCollection}),this.queryCollection=new window.ArangoQueries,this.footerView.render(),this.naviView.render(),window.checkVersion()}.bind(this),$(window).resize(function(){a.handleResize()})},checkUser:function(){return null===this.userCollection.whoAmI()?(this.navigate("login",{trigger:!0}),!1):(this.initOnce(),!0)},logs:function(){if(this.checkUser()){if(!this.logsView){var a=new window.ArangoLogs({upto:!0,loglevel:4}),b=new window.ArangoLogs({loglevel:4}),c=new window.ArangoLogs({loglevel:3}),d=new window.ArangoLogs({loglevel:2}),e=new window.ArangoLogs({loglevel:1});this.logsView=new window.LogsView({logall:a,logdebug:b,loginfo:c,logwarning:d,logerror:e})}this.logsView.render(),this.naviView.selectMenuItem("tools-menu")}},applicationDetail:function(a){this.checkUser()&&(this.naviView.selectMenuItem("applications-menu"),0===this.foxxList.length&&this.foxxList.fetch({async:!1}),this.hasOwnProperty("applicationDetailView")||(this.applicationDetailView=new window.ApplicationDetailView({model:this.foxxList.get(decodeURIComponent(a))})),this.applicationDetailView.model=this.foxxList.get(decodeURIComponent(a)),this.applicationDetailView.render("swagger"))},login:function(){return null!==this.userCollection.whoAmI()?(this.navigate("",{trigger:!0}),!1):(this.loginView||(this.loginView=new window.loginView({collection:this.userCollection})),void this.loginView.render())},collections:function(){if(this.checkUser()){var a=this.naviView,b=this;this.collectionsView||(this.collectionsView=new window.CollectionsView({collection:this.arangoCollectionsStore})),this.arangoCollectionsStore.fetch({success:function(){b.collectionsView.render(),a.selectMenuItem("collections-menu")}})}},documents:function(a,b){this.checkUser()&&(this.documentsView||(this.documentsView=new window.DocumentsView({collection:new window.arangoDocuments,documentStore:this.arangoDocumentStore,collectionsStore:this.arangoCollectionsStore})),this.documentsView.setCollectionId(a,b),this.documentsView.render())},document:function(a,b){if(this.checkUser()){this.documentView||(this.documentView=new window.DocumentView({collection:this.arangoDocumentStore})),this.documentView.colid=a,this.documentView.docid=b,this.documentView.render();var c=arangoHelper.collectionApiType(a);this.documentView.setType(c)}},shell:function(){this.checkUser()&&(this.shellView||(this.shellView=new window.shellView),this.shellView.render(),this.naviView.selectMenuItem("tools-menu"))},query:function(){this.checkUser()&&(this.queryView||(this.queryView=new window.queryView({collection:this.queryCollection})),this.queryView.render(),this.naviView.selectMenuItem("query-menu"))},test:function(){this.checkUser()&&(this.testView||(this.testView=new window.testView({})),this.testView.render())},workMonitor:function(){this.checkUser()&&(this.workMonitorCollection||(this.workMonitorCollection=new window.WorkMonitorCollection),this.workMonitorView||(this.workMonitorView=new window.workMonitorView({collection:this.workMonitorCollection})),this.workMonitorView.render(),this.naviView.selectMenuItem("tools-menu"))},queryManagement:function(){this.checkUser()&&(this.queryManagementView||(this.queryManagementView=new window.queryManagementView({collection:void 0})),this.queryManagementView.render(),this.naviView.selectMenuItem("tools-menu"))},databases:function(){this.checkUser()&&(arangoHelper.databaseAllowed()===!0?(this.databaseView||(this.databaseView=new window.databaseView({users:this.userCollection,collection:this.arangoDatabase})),this.databaseView.render(),this.naviView.selectMenuItem("databases-menu")):(this.navigate("#",{trigger:!0}),this.naviView.selectMenuItem("dashboard-menu"),$("#databaseNavi").css("display","none"),$("#databaseNaviSelect").css("display","none")))},dashboard:function(){this.checkUser()&&(this.naviView.selectMenuItem("dashboard-menu"),void 0===this.dashboardView&&(this.dashboardView=new window.DashboardView({dygraphConfig:window.dygraphConfig,database:this.arangoDatabase})),this.dashboardView.render())},graphManagement:function(){this.checkUser()&&(this.graphManagementView||(this.graphManagementView=new window.GraphManagementView({collection:new window.GraphCollection,collectionCollection:this.arangoCollectionsStore})),this.graphManagementView.render(),this.naviView.selectMenuItem("graphviewer-menu"))},showGraph:function(a){this.checkUser()&&(this.graphManagementView||(this.graphManagementView=new window.GraphManagementView({collection:new window.GraphCollection,collectionCollection:this.arangoCollectionsStore})),this.graphManagementView.render(),this.graphManagementView.loadGraphViewer(a),this.naviView.selectMenuItem("graphviewer-menu"))},applications:function(){this.checkUser()&&(void 0===this.applicationsView&&(this.applicationsView=new window.ApplicationsView({collection:this.foxxList})),this.applicationsView.reload(),this.naviView.selectMenuItem("applications-menu"))},handleSelectDatabase:function(){this.checkUser()&&this.naviView.handleSelectDatabase()},handleResize:function(){this.dashboardView&&this.dashboardView.resize(),this.graphManagementView&&this.graphManagementView.handleResize($("#content").width()),this.queryView&&this.queryView.resize()},userManagement:function(){this.checkUser()&&(this.userManagementView||(this.userManagementView=new window.userManagementView({collection:this.userCollection})),this.userManagementView.render(),this.naviView.selectMenuItem("tools-menu"))},userProfile:function(){this.checkUser()&&(this.userManagementView||(this.userManagementView=new window.userManagementView({collection:this.userCollection})),this.userManagementView.render(!0),this.naviView.selectMenuItem("tools-menu"))}})}(),function(){"use strict";var a=function(){$.ajax({type:"POST",url:"/_admin/aardvark/disableVersionCheck"})},b=function(a){$.ajax({type:"GET",url:"/_admin/aardvark/shouldCheckVersion",success:function(b){b===!0&&a()}})},c=function(b,c){var d=[];d.push(window.modalView.createNotificationButton("Don't ask again",function(){a(),window.modalView.hide()})),d.push(window.modalView.createSuccessButton("Download Page",function(){window.open("https://www.arangodb.com/download","_blank"),window.modalView.hide()}));var e=[],f=window.modalView.createReadOnlyEntry.bind(window.modalView);e.push(f("current","Current",b.toString())),c.major&&e.push(f("major","Major",c.major.version)),c.minor&&e.push(f("minor","Minor",c.minor.version)),c.bugfix&&e.push(f("bugfix","Bugfix",c.bugfix.version)),window.modalView.show("modalTable.ejs","New Version Available",d,e)};window.checkVersion=function(){$.ajax({type:"GET",cache:!1,url:"/_api/version",contentType:"application/json",processData:!1,async:!0,success:function(a){var d=window.versionHelper.fromString(a.version);window.parseVersions=function(e){_.isEmpty(e)||/-devel$/.test(a.version)||b(c.bind(window,d,e))},$.ajax({type:"GET",async:!0,crossDomain:!0,timeout:3e3,dataType:"jsonp",url:"https://www.arangodb.com/repositories/versions.php?jsonp=parseVersions&version="+encodeURIComponent(d.toString())})}})}}(),function(){"use strict";window.hasOwnProperty("TEST_BUILD")||$(document).ready(function(){window.App=new window.Router,Backbone.history.start(),window.App.handleResize()})}(); \ No newline at end of file diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/app.min.js.gz b/js/apps/system/_admin/aardvark/APP/frontend/build/app.min.js.gz index 980086dad8..fdc87bff33 100644 Binary files a/js/apps/system/_admin/aardvark/APP/frontend/build/app.min.js.gz and b/js/apps/system/_admin/aardvark/APP/frontend/build/app.min.js.gz differ diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/arangoes5.js b/js/apps/system/_admin/aardvark/APP/frontend/build/arangoes5.js index 486ac5cf9a..034529048c 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/arangoes5.js +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/arangoes5.js @@ -27,7 +27,7 @@ //////////////////////////////////////////////////////////////////////////////// /// @brief ArangoError //////////////////////////////////////////////////////////////////////////////// -if(global.ArangoError){exports.ArangoError = global.ArangoError;delete global.ArangoError;}else {exports.ArangoError = function(error){if(error !== undefined){this.error = error.error;this.code = error.code;this.errorNum = error.errorNum;this.errorMessage = error.errorMessage;}this.message = this.toString();};exports.ArangoError.prototype = new Error();}exports.ArangoError.prototype._PRINT = function(context){context.output += this.toString();};exports.ArangoError.prototype.toString = function(){var errorNum=this.errorNum;var errorMessage=this.errorMessage || this.message;return '[ArangoError ' + errorNum + ': ' + errorMessage + ']';}; //////////////////////////////////////////////////////////////////////////////// +if(global.ArangoError){exports.ArangoError = global.ArangoError;delete global.ArangoError;}else {exports.ArangoError = function(error){if(error !== undefined){this.error = error.error;this.code = error.code;this.errorNum = error.errorNum;this.errorMessage = error.errorMessage;}};exports.ArangoError.prototype = new Error();}Object.defineProperty(exports.ArangoError.prototype,'message',{configurable:true,enumerable:true,get:function get(){return this.errorMessage;}});exports.ArangoError.prototype.name = 'ArangoError';exports.ArangoError.prototype._PRINT = function(context){context.output += '[' + this.toString() + ']';};exports.ArangoError.prototype.toString = function(){return this.name + ' ' + this.errorNum + ': ' + this.message;}; //////////////////////////////////////////////////////////////////////////////// /// @brief threadNumber //////////////////////////////////////////////////////////////////////////////// exports.threadNumber = 0;if(global.THREAD_NUMBER){exports.threadNumber = global.THREAD_NUMBER;delete global.THREAD_NUMBER;} //////////////////////////////////////////////////////////////////////////////// @@ -369,7 +369,7 @@ global.start_color_print = function start_color_print(color){require('internal') global.stop_color_print = function stop_color_print(){require('internal').stopColorPrint();};if(global.EXPORTS_SLOW_BUFFER){Object.keys(global.EXPORTS_SLOW_BUFFER).forEach(function(key){exports[key] = global.EXPORTS_SLOW_BUFFER[key];});delete global.EXPORTS_SLOW_BUFFER;}if(global.APP_PATH){exports.appPath = global.APP_PATH;delete global.APP_PATH;}return exports;})()); /*jshint maxlen: 240 */ /*global require */ //////////////////////////////////////////////////////////////////////////////// /// @brief auto-generated file generated from errors.dat //////////////////////////////////////////////////////////////////////////////// -(function(){"use strict";var internal=require("internal");internal.errors = {"ERROR_NO_ERROR":{"code":0,"message":"no error"},"ERROR_FAILED":{"code":1,"message":"failed"},"ERROR_SYS_ERROR":{"code":2,"message":"system error"},"ERROR_OUT_OF_MEMORY":{"code":3,"message":"out of memory"},"ERROR_INTERNAL":{"code":4,"message":"internal error"},"ERROR_ILLEGAL_NUMBER":{"code":5,"message":"illegal number"},"ERROR_NUMERIC_OVERFLOW":{"code":6,"message":"numeric overflow"},"ERROR_ILLEGAL_OPTION":{"code":7,"message":"illegal option"},"ERROR_DEAD_PID":{"code":8,"message":"dead process identifier"},"ERROR_NOT_IMPLEMENTED":{"code":9,"message":"not implemented"},"ERROR_BAD_PARAMETER":{"code":10,"message":"bad parameter"},"ERROR_FORBIDDEN":{"code":11,"message":"forbidden"},"ERROR_OUT_OF_MEMORY_MMAP":{"code":12,"message":"out of memory in mmap"},"ERROR_CORRUPTED_CSV":{"code":13,"message":"csv is corrupt"},"ERROR_FILE_NOT_FOUND":{"code":14,"message":"file not found"},"ERROR_CANNOT_WRITE_FILE":{"code":15,"message":"cannot write file"},"ERROR_CANNOT_OVERWRITE_FILE":{"code":16,"message":"cannot overwrite file"},"ERROR_TYPE_ERROR":{"code":17,"message":"type error"},"ERROR_LOCK_TIMEOUT":{"code":18,"message":"lock timeout"},"ERROR_CANNOT_CREATE_DIRECTORY":{"code":19,"message":"cannot create directory"},"ERROR_CANNOT_CREATE_TEMP_FILE":{"code":20,"message":"cannot create temporary file"},"ERROR_REQUEST_CANCELED":{"code":21,"message":"canceled request"},"ERROR_DEBUG":{"code":22,"message":"intentional debug error"},"ERROR_AID_NOT_FOUND":{"code":23,"message":"internal error with attribute ID in shaper"},"ERROR_LEGEND_INCOMPLETE":{"code":24,"message":"internal error if a legend could not be created"},"ERROR_IP_ADDRESS_INVALID":{"code":25,"message":"IP address is invalid"},"ERROR_LEGEND_NOT_IN_WAL_FILE":{"code":26,"message":"internal error if a legend for a marker does not yet exist in the same WAL file"},"ERROR_FILE_EXISTS":{"code":27,"message":"file exists"},"ERROR_LOCKED":{"code":28,"message":"locked"},"ERROR_DEADLOCK":{"code":29,"message":"deadlock detected"},"ERROR_HTTP_BAD_PARAMETER":{"code":400,"message":"bad parameter"},"ERROR_HTTP_UNAUTHORIZED":{"code":401,"message":"unauthorized"},"ERROR_HTTP_FORBIDDEN":{"code":403,"message":"forbidden"},"ERROR_HTTP_NOT_FOUND":{"code":404,"message":"not found"},"ERROR_HTTP_METHOD_NOT_ALLOWED":{"code":405,"message":"method not supported"},"ERROR_HTTP_PRECONDITION_FAILED":{"code":412,"message":"precondition failed"},"ERROR_HTTP_SERVER_ERROR":{"code":500,"message":"internal server error"},"ERROR_HTTP_CORRUPTED_JSON":{"code":600,"message":"invalid JSON object"},"ERROR_HTTP_SUPERFLUOUS_SUFFICES":{"code":601,"message":"superfluous URL suffices"},"ERROR_ARANGO_ILLEGAL_STATE":{"code":1000,"message":"illegal state"},"ERROR_ARANGO_SHAPER_FAILED":{"code":1001,"message":"could not shape document"},"ERROR_ARANGO_DATAFILE_SEALED":{"code":1002,"message":"datafile sealed"},"ERROR_ARANGO_UNKNOWN_COLLECTION_TYPE":{"code":1003,"message":"unknown type"},"ERROR_ARANGO_READ_ONLY":{"code":1004,"message":"read only"},"ERROR_ARANGO_DUPLICATE_IDENTIFIER":{"code":1005,"message":"duplicate identifier"},"ERROR_ARANGO_DATAFILE_UNREADABLE":{"code":1006,"message":"datafile unreadable"},"ERROR_ARANGO_DATAFILE_EMPTY":{"code":1007,"message":"datafile empty"},"ERROR_ARANGO_RECOVERY":{"code":1008,"message":"logfile recovery error"},"ERROR_ARANGO_CORRUPTED_DATAFILE":{"code":1100,"message":"corrupted datafile"},"ERROR_ARANGO_ILLEGAL_PARAMETER_FILE":{"code":1101,"message":"illegal or unreadable parameter file"},"ERROR_ARANGO_CORRUPTED_COLLECTION":{"code":1102,"message":"corrupted collection"},"ERROR_ARANGO_MMAP_FAILED":{"code":1103,"message":"mmap failed"},"ERROR_ARANGO_FILESYSTEM_FULL":{"code":1104,"message":"filesystem full"},"ERROR_ARANGO_NO_JOURNAL":{"code":1105,"message":"no journal"},"ERROR_ARANGO_DATAFILE_ALREADY_EXISTS":{"code":1106,"message":"cannot create/rename datafile because it already exists"},"ERROR_ARANGO_DATADIR_LOCKED":{"code":1107,"message":"database directory is locked"},"ERROR_ARANGO_COLLECTION_DIRECTORY_ALREADY_EXISTS":{"code":1108,"message":"cannot create/rename collection because directory already exists"},"ERROR_ARANGO_MSYNC_FAILED":{"code":1109,"message":"msync failed"},"ERROR_ARANGO_DATADIR_UNLOCKABLE":{"code":1110,"message":"cannot lock database directory"},"ERROR_ARANGO_SYNC_TIMEOUT":{"code":1111,"message":"sync timeout"},"ERROR_ARANGO_CONFLICT":{"code":1200,"message":"conflict"},"ERROR_ARANGO_DATADIR_INVALID":{"code":1201,"message":"invalid database directory"},"ERROR_ARANGO_DOCUMENT_NOT_FOUND":{"code":1202,"message":"document not found"},"ERROR_ARANGO_COLLECTION_NOT_FOUND":{"code":1203,"message":"collection not found"},"ERROR_ARANGO_COLLECTION_PARAMETER_MISSING":{"code":1204,"message":"parameter 'collection' not found"},"ERROR_ARANGO_DOCUMENT_HANDLE_BAD":{"code":1205,"message":"illegal document handle"},"ERROR_ARANGO_MAXIMAL_SIZE_TOO_SMALL":{"code":1206,"message":"maximal size of journal too small"},"ERROR_ARANGO_DUPLICATE_NAME":{"code":1207,"message":"duplicate name"},"ERROR_ARANGO_ILLEGAL_NAME":{"code":1208,"message":"illegal name"},"ERROR_ARANGO_NO_INDEX":{"code":1209,"message":"no suitable index known"},"ERROR_ARANGO_UNIQUE_CONSTRAINT_VIOLATED":{"code":1210,"message":"unique constraint violated"},"ERROR_ARANGO_INDEX_NOT_FOUND":{"code":1212,"message":"index not found"},"ERROR_ARANGO_CROSS_COLLECTION_REQUEST":{"code":1213,"message":"cross collection request not allowed"},"ERROR_ARANGO_INDEX_HANDLE_BAD":{"code":1214,"message":"illegal index handle"},"ERROR_ARANGO_CAP_CONSTRAINT_ALREADY_DEFINED":{"code":1215,"message":"cap constraint already defined"},"ERROR_ARANGO_DOCUMENT_TOO_LARGE":{"code":1216,"message":"document too large"},"ERROR_ARANGO_COLLECTION_NOT_UNLOADED":{"code":1217,"message":"collection must be unloaded"},"ERROR_ARANGO_COLLECTION_TYPE_INVALID":{"code":1218,"message":"collection type invalid"},"ERROR_ARANGO_VALIDATION_FAILED":{"code":1219,"message":"validator failed"},"ERROR_ARANGO_ATTRIBUTE_PARSER_FAILED":{"code":1220,"message":"parsing attribute name definition failed"},"ERROR_ARANGO_DOCUMENT_KEY_BAD":{"code":1221,"message":"illegal document key"},"ERROR_ARANGO_DOCUMENT_KEY_UNEXPECTED":{"code":1222,"message":"unexpected document key"},"ERROR_ARANGO_DATADIR_NOT_WRITABLE":{"code":1224,"message":"server database directory not writable"},"ERROR_ARANGO_OUT_OF_KEYS":{"code":1225,"message":"out of keys"},"ERROR_ARANGO_DOCUMENT_KEY_MISSING":{"code":1226,"message":"missing document key"},"ERROR_ARANGO_DOCUMENT_TYPE_INVALID":{"code":1227,"message":"invalid document type"},"ERROR_ARANGO_DATABASE_NOT_FOUND":{"code":1228,"message":"database not found"},"ERROR_ARANGO_DATABASE_NAME_INVALID":{"code":1229,"message":"database name invalid"},"ERROR_ARANGO_USE_SYSTEM_DATABASE":{"code":1230,"message":"operation only allowed in system database"},"ERROR_ARANGO_ENDPOINT_NOT_FOUND":{"code":1231,"message":"endpoint not found"},"ERROR_ARANGO_INVALID_KEY_GENERATOR":{"code":1232,"message":"invalid key generator"},"ERROR_ARANGO_INVALID_EDGE_ATTRIBUTE":{"code":1233,"message":"edge attribute missing"},"ERROR_ARANGO_INDEX_DOCUMENT_ATTRIBUTE_MISSING":{"code":1234,"message":"index insertion warning - attribute missing in document"},"ERROR_ARANGO_INDEX_CREATION_FAILED":{"code":1235,"message":"index creation failed"},"ERROR_ARANGO_WRITE_THROTTLE_TIMEOUT":{"code":1236,"message":"write-throttling timeout"},"ERROR_ARANGO_COLLECTION_TYPE_MISMATCH":{"code":1237,"message":"collection type mismatch"},"ERROR_ARANGO_COLLECTION_NOT_LOADED":{"code":1238,"message":"collection not loaded"},"ERROR_ARANGO_DATAFILE_FULL":{"code":1300,"message":"datafile full"},"ERROR_ARANGO_EMPTY_DATADIR":{"code":1301,"message":"server database directory is empty"},"ERROR_REPLICATION_NO_RESPONSE":{"code":1400,"message":"no response"},"ERROR_REPLICATION_INVALID_RESPONSE":{"code":1401,"message":"invalid response"},"ERROR_REPLICATION_MASTER_ERROR":{"code":1402,"message":"master error"},"ERROR_REPLICATION_MASTER_INCOMPATIBLE":{"code":1403,"message":"master incompatible"},"ERROR_REPLICATION_MASTER_CHANGE":{"code":1404,"message":"master change"},"ERROR_REPLICATION_LOOP":{"code":1405,"message":"loop detected"},"ERROR_REPLICATION_UNEXPECTED_MARKER":{"code":1406,"message":"unexpected marker"},"ERROR_REPLICATION_INVALID_APPLIER_STATE":{"code":1407,"message":"invalid applier state"},"ERROR_REPLICATION_UNEXPECTED_TRANSACTION":{"code":1408,"message":"invalid transaction"},"ERROR_REPLICATION_INVALID_APPLIER_CONFIGURATION":{"code":1410,"message":"invalid replication applier configuration"},"ERROR_REPLICATION_RUNNING":{"code":1411,"message":"cannot perform operation while applier is running"},"ERROR_REPLICATION_APPLIER_STOPPED":{"code":1412,"message":"replication stopped"},"ERROR_REPLICATION_NO_START_TICK":{"code":1413,"message":"no start tick"},"ERROR_REPLICATION_START_TICK_NOT_PRESENT":{"code":1414,"message":"start tick not present"},"ERROR_CLUSTER_NO_AGENCY":{"code":1450,"message":"could not connect to agency"},"ERROR_CLUSTER_NO_COORDINATOR_HEADER":{"code":1451,"message":"missing coordinator header"},"ERROR_CLUSTER_COULD_NOT_LOCK_PLAN":{"code":1452,"message":"could not lock plan in agency"},"ERROR_CLUSTER_COLLECTION_ID_EXISTS":{"code":1453,"message":"collection ID already exists"},"ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION_IN_PLAN":{"code":1454,"message":"could not create collection in plan"},"ERROR_CLUSTER_COULD_NOT_READ_CURRENT_VERSION":{"code":1455,"message":"could not read version in current in agency"},"ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION":{"code":1456,"message":"could not create collection"},"ERROR_CLUSTER_TIMEOUT":{"code":1457,"message":"timeout in cluster operation"},"ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_PLAN":{"code":1458,"message":"could not remove collection from plan"},"ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_CURRENT":{"code":1459,"message":"could not remove collection from current"},"ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE_IN_PLAN":{"code":1460,"message":"could not create database in plan"},"ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE":{"code":1461,"message":"could not create database"},"ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_PLAN":{"code":1462,"message":"could not remove database from plan"},"ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_CURRENT":{"code":1463,"message":"could not remove database from current"},"ERROR_CLUSTER_SHARD_GONE":{"code":1464,"message":"no responsible shard found"},"ERROR_CLUSTER_CONNECTION_LOST":{"code":1465,"message":"cluster internal HTTP connection broken"},"ERROR_CLUSTER_MUST_NOT_SPECIFY_KEY":{"code":1466,"message":"must not specify _key for this collection"},"ERROR_CLUSTER_GOT_CONTRADICTING_ANSWERS":{"code":1467,"message":"got contradicting answers from different shards"},"ERROR_CLUSTER_NOT_ALL_SHARDING_ATTRIBUTES_GIVEN":{"code":1468,"message":"not all sharding attributes given"},"ERROR_CLUSTER_MUST_NOT_CHANGE_SHARDING_ATTRIBUTES":{"code":1469,"message":"must not change the value of a shard key attribute"},"ERROR_CLUSTER_UNSUPPORTED":{"code":1470,"message":"unsupported operation or parameter"},"ERROR_CLUSTER_ONLY_ON_COORDINATOR":{"code":1471,"message":"this operation is only valid on a coordinator in a cluster"},"ERROR_CLUSTER_READING_PLAN_AGENCY":{"code":1472,"message":"error reading Plan in agency"},"ERROR_CLUSTER_COULD_NOT_TRUNCATE_COLLECTION":{"code":1473,"message":"could not truncate collection"},"ERROR_CLUSTER_AQL_COMMUNICATION":{"code":1474,"message":"error in cluster internal communication for AQL"},"ERROR_ARANGO_DOCUMENT_NOT_FOUND_OR_SHARDING_ATTRIBUTES_CHANGED":{"code":1475,"message":"document not found or sharding attributes changed"},"ERROR_CLUSTER_COULD_NOT_DETERMINE_ID":{"code":1476,"message":"could not determine my ID from my local info"},"ERROR_CLUSTER_ONLY_ON_DBSERVER":{"code":1477,"message":"this operation is only valid on a DBserver in a cluster"},"ERROR_QUERY_KILLED":{"code":1500,"message":"query killed"},"ERROR_QUERY_PARSE":{"code":1501,"message":"%s"},"ERROR_QUERY_EMPTY":{"code":1502,"message":"query is empty"},"ERROR_QUERY_SCRIPT":{"code":1503,"message":"runtime error '%s'"},"ERROR_QUERY_NUMBER_OUT_OF_RANGE":{"code":1504,"message":"number out of range"},"ERROR_QUERY_VARIABLE_NAME_INVALID":{"code":1510,"message":"variable name '%s' has an invalid format"},"ERROR_QUERY_VARIABLE_REDECLARED":{"code":1511,"message":"variable '%s' is assigned multiple times"},"ERROR_QUERY_VARIABLE_NAME_UNKNOWN":{"code":1512,"message":"unknown variable '%s'"},"ERROR_QUERY_COLLECTION_LOCK_FAILED":{"code":1521,"message":"unable to read-lock collection %s"},"ERROR_QUERY_TOO_MANY_COLLECTIONS":{"code":1522,"message":"too many collections"},"ERROR_QUERY_DOCUMENT_ATTRIBUTE_REDECLARED":{"code":1530,"message":"document attribute '%s' is assigned multiple times"},"ERROR_QUERY_FUNCTION_NAME_UNKNOWN":{"code":1540,"message":"usage of unknown function '%s()'"},"ERROR_QUERY_FUNCTION_ARGUMENT_NUMBER_MISMATCH":{"code":1541,"message":"invalid number of arguments for function '%s()', expected number of arguments: minimum: %d, maximum: %d"},"ERROR_QUERY_FUNCTION_ARGUMENT_TYPE_MISMATCH":{"code":1542,"message":"invalid argument type in call to function '%s()'"},"ERROR_QUERY_INVALID_REGEX":{"code":1543,"message":"invalid regex value"},"ERROR_QUERY_BIND_PARAMETERS_INVALID":{"code":1550,"message":"invalid structure of bind parameters"},"ERROR_QUERY_BIND_PARAMETER_MISSING":{"code":1551,"message":"no value specified for declared bind parameter '%s'"},"ERROR_QUERY_BIND_PARAMETER_UNDECLARED":{"code":1552,"message":"bind parameter '%s' was not declared in the query"},"ERROR_QUERY_BIND_PARAMETER_TYPE":{"code":1553,"message":"bind parameter '%s' has an invalid value or type"},"ERROR_QUERY_INVALID_LOGICAL_VALUE":{"code":1560,"message":"invalid logical value"},"ERROR_QUERY_INVALID_ARITHMETIC_VALUE":{"code":1561,"message":"invalid arithmetic value"},"ERROR_QUERY_DIVISION_BY_ZERO":{"code":1562,"message":"division by zero"},"ERROR_QUERY_ARRAY_EXPECTED":{"code":1563,"message":"array expected"},"ERROR_QUERY_FAIL_CALLED":{"code":1569,"message":"FAIL(%s) called"},"ERROR_QUERY_GEO_INDEX_MISSING":{"code":1570,"message":"no suitable geo index found for geo restriction on '%s'"},"ERROR_QUERY_FULLTEXT_INDEX_MISSING":{"code":1571,"message":"no suitable fulltext index found for fulltext query on '%s'"},"ERROR_QUERY_INVALID_DATE_VALUE":{"code":1572,"message":"invalid date value"},"ERROR_QUERY_MULTI_MODIFY":{"code":1573,"message":"multi-modify query"},"ERROR_QUERY_INVALID_AGGREGATE_EXPRESSION":{"code":1574,"message":"invalid aggregate expression"},"ERROR_QUERY_COMPILE_TIME_OPTIONS":{"code":1575,"message":"query options must be readable at query compile time"},"ERROR_QUERY_EXCEPTION_OPTIONS":{"code":1576,"message":"query options expected"},"ERROR_QUERY_COLLECTION_USED_IN_EXPRESSION":{"code":1577,"message":"collection '%s' used as expression operand"},"ERROR_QUERY_DISALLOWED_DYNAMIC_CALL":{"code":1578,"message":"disallowed dynamic call to '%s'"},"ERROR_QUERY_ACCESS_AFTER_MODIFICATION":{"code":1579,"message":"access after data-modification"},"ERROR_QUERY_FUNCTION_INVALID_NAME":{"code":1580,"message":"invalid user function name"},"ERROR_QUERY_FUNCTION_INVALID_CODE":{"code":1581,"message":"invalid user function code"},"ERROR_QUERY_FUNCTION_NOT_FOUND":{"code":1582,"message":"user function '%s()' not found"},"ERROR_QUERY_FUNCTION_RUNTIME_ERROR":{"code":1583,"message":"user function runtime error: %s"},"ERROR_QUERY_BAD_JSON_PLAN":{"code":1590,"message":"bad execution plan JSON"},"ERROR_QUERY_NOT_FOUND":{"code":1591,"message":"query ID not found"},"ERROR_QUERY_IN_USE":{"code":1592,"message":"query with this ID is in use"},"ERROR_CURSOR_NOT_FOUND":{"code":1600,"message":"cursor not found"},"ERROR_CURSOR_BUSY":{"code":1601,"message":"cursor is busy"},"ERROR_TRANSACTION_INTERNAL":{"code":1650,"message":"internal transaction error"},"ERROR_TRANSACTION_NESTED":{"code":1651,"message":"nested transactions detected"},"ERROR_TRANSACTION_UNREGISTERED_COLLECTION":{"code":1652,"message":"unregistered collection used in transaction"},"ERROR_TRANSACTION_DISALLOWED_OPERATION":{"code":1653,"message":"disallowed operation inside transaction"},"ERROR_TRANSACTION_ABORTED":{"code":1654,"message":"transaction aborted"},"ERROR_USER_INVALID_NAME":{"code":1700,"message":"invalid user name"},"ERROR_USER_INVALID_PASSWORD":{"code":1701,"message":"invalid password"},"ERROR_USER_DUPLICATE":{"code":1702,"message":"duplicate user"},"ERROR_USER_NOT_FOUND":{"code":1703,"message":"user not found"},"ERROR_USER_CHANGE_PASSWORD":{"code":1704,"message":"user must change his password"},"ERROR_APPLICATION_INVALID_NAME":{"code":1750,"message":"invalid application name"},"ERROR_APPLICATION_INVALID_MOUNT":{"code":1751,"message":"invalid mount"},"ERROR_APPLICATION_DOWNLOAD_FAILED":{"code":1752,"message":"application download failed"},"ERROR_APPLICATION_UPLOAD_FAILED":{"code":1753,"message":"application upload failed"},"ERROR_KEYVALUE_INVALID_KEY":{"code":1800,"message":"invalid key declaration"},"ERROR_KEYVALUE_KEY_EXISTS":{"code":1801,"message":"key already exists"},"ERROR_KEYVALUE_KEY_NOT_FOUND":{"code":1802,"message":"key not found"},"ERROR_KEYVALUE_KEY_NOT_UNIQUE":{"code":1803,"message":"key is not unique"},"ERROR_KEYVALUE_KEY_NOT_CHANGED":{"code":1804,"message":"key value not changed"},"ERROR_KEYVALUE_KEY_NOT_REMOVED":{"code":1805,"message":"key value not removed"},"ERROR_KEYVALUE_NO_VALUE":{"code":1806,"message":"missing value"},"ERROR_TASK_INVALID_ID":{"code":1850,"message":"invalid task id"},"ERROR_TASK_DUPLICATE_ID":{"code":1851,"message":"duplicate task id"},"ERROR_TASK_NOT_FOUND":{"code":1852,"message":"task not found"},"ERROR_GRAPH_INVALID_GRAPH":{"code":1901,"message":"invalid graph"},"ERROR_GRAPH_COULD_NOT_CREATE_GRAPH":{"code":1902,"message":"could not create graph"},"ERROR_GRAPH_INVALID_VERTEX":{"code":1903,"message":"invalid vertex"},"ERROR_GRAPH_COULD_NOT_CREATE_VERTEX":{"code":1904,"message":"could not create vertex"},"ERROR_GRAPH_COULD_NOT_CHANGE_VERTEX":{"code":1905,"message":"could not change vertex"},"ERROR_GRAPH_INVALID_EDGE":{"code":1906,"message":"invalid edge"},"ERROR_GRAPH_COULD_NOT_CREATE_EDGE":{"code":1907,"message":"could not create edge"},"ERROR_GRAPH_COULD_NOT_CHANGE_EDGE":{"code":1908,"message":"could not change edge"},"ERROR_GRAPH_TOO_MANY_ITERATIONS":{"code":1909,"message":"too many iterations - try increasing the value of 'maxIterations'"},"ERROR_GRAPH_INVALID_FILTER_RESULT":{"code":1910,"message":"invalid filter result"},"ERROR_GRAPH_COLLECTION_MULTI_USE":{"code":1920,"message":"multi use of edge collection in edge def"},"ERROR_GRAPH_COLLECTION_USE_IN_MULTI_GRAPHS":{"code":1921,"message":"edge collection already used in edge def"},"ERROR_GRAPH_CREATE_MISSING_NAME":{"code":1922,"message":"missing graph name"},"ERROR_GRAPH_CREATE_MALFORMED_EDGE_DEFINITION":{"code":1923,"message":"malformed edge definition"},"ERROR_GRAPH_NOT_FOUND":{"code":1924,"message":"graph not found"},"ERROR_GRAPH_DUPLICATE":{"code":1925,"message":"graph already exists"},"ERROR_GRAPH_VERTEX_COL_DOES_NOT_EXIST":{"code":1926,"message":"vertex collection does not exist or is not part of the graph"},"ERROR_GRAPH_WRONG_COLLECTION_TYPE_VERTEX":{"code":1927,"message":"not a vertex collection"},"ERROR_GRAPH_NOT_IN_ORPHAN_COLLECTION":{"code":1928,"message":"not in orphan collection"},"ERROR_GRAPH_COLLECTION_USED_IN_EDGE_DEF":{"code":1929,"message":"collection already used in edge def"},"ERROR_GRAPH_EDGE_COLLECTION_NOT_USED":{"code":1930,"message":"edge collection not used in graph"},"ERROR_GRAPH_NOT_AN_ARANGO_COLLECTION":{"code":1931,"message":" is not an ArangoCollection"},"ERROR_GRAPH_NO_GRAPH_COLLECTION":{"code":1932,"message":"collection _graphs does not exist"},"ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT_STRING":{"code":1933,"message":"Invalid example type. Has to be String, Array or Object"},"ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT":{"code":1934,"message":"Invalid example type. Has to be Array or Object"},"ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS":{"code":1935,"message":"Invalid number of arguments. Expected: "},"ERROR_GRAPH_INVALID_PARAMETER":{"code":1936,"message":"Invalid parameter type."},"ERROR_GRAPH_INVALID_ID":{"code":1937,"message":"Invalid id"},"ERROR_GRAPH_COLLECTION_USED_IN_ORPHANS":{"code":1938,"message":"collection used in orphans"},"ERROR_GRAPH_EDGE_COL_DOES_NOT_EXIST":{"code":1939,"message":"edge collection does not exist or is not part of the graph"},"ERROR_GRAPH_EMPTY":{"code":1940,"message":"empty graph"},"ERROR_SESSION_UNKNOWN":{"code":1950,"message":"unknown session"},"ERROR_SESSION_EXPIRED":{"code":1951,"message":"session expired"},"SIMPLE_CLIENT_UNKNOWN_ERROR":{"code":2000,"message":"unknown client error"},"SIMPLE_CLIENT_COULD_NOT_CONNECT":{"code":2001,"message":"could not connect to server"},"SIMPLE_CLIENT_COULD_NOT_WRITE":{"code":2002,"message":"could not write to server"},"SIMPLE_CLIENT_COULD_NOT_READ":{"code":2003,"message":"could not read from server"},"ERROR_MALFORMED_MANIFEST_FILE":{"code":3000,"message":"malformed manifest file"},"ERROR_INVALID_APPLICATION_MANIFEST":{"code":3001,"message":"manifest file is invalid"},"ERROR_MANIFEST_FILE_ATTRIBUTE_MISSING":{"code":3002,"message":"missing manifest attribute"},"ERROR_CANNOT_EXTRACT_APPLICATION_ROOT":{"code":3003,"message":"unable to extract app root path"},"ERROR_INVALID_FOXX_OPTIONS":{"code":3004,"message":"invalid foxx options"},"ERROR_FAILED_TO_EXECUTE_SCRIPT":{"code":3005,"message":"failed to execute script"},"ERROR_SYNTAX_ERROR_IN_SCRIPT":{"code":3006,"message":"syntax error in script"},"ERROR_INVALID_MOUNTPOINT":{"code":3007,"message":"mountpoint is invalid"},"ERROR_NO_FOXX_FOUND":{"code":3008,"message":"No foxx found at this location"},"ERROR_APP_NOT_FOUND":{"code":3009,"message":"App not found"},"ERROR_APP_NEEDS_CONFIGURATION":{"code":3010,"message":"App not configured"},"ERROR_MODULE_NOT_FOUND":{"code":3100,"message":"cannot locate module"},"ERROR_MODULE_SYNTAX_ERROR":{"code":3101,"message":"syntax error in module"},"ERROR_MODULE_BAD_WRAPPER":{"code":3102,"message":"failed to wrap module"},"ERROR_MODULE_FAILURE":{"code":3103,"message":"failed to invoke module"},"ERROR_MODULE_UNKNOWN_FILE_TYPE":{"code":3110,"message":"unknown file type"},"ERROR_MODULE_PATH_MUST_BE_ABSOLUTE":{"code":3111,"message":"path must be absolute"},"ERROR_MODULE_CAN_NOT_ESCAPE":{"code":3112,"message":"cannot use '..' to escape top-level-directory"},"ERROR_MODULE_DRIVE_LETTER":{"code":3113,"message":"drive local path is not supported"},"ERROR_MODULE_BAD_MODULE_ORIGIN":{"code":3120,"message":"corrupted module origin"},"ERROR_MODULE_BAD_PACKAGE_ORIGIN":{"code":3121,"message":"corrupted package origin"},"ERROR_MODULE_DOCUMENT_IS_EMPTY":{"code":3125,"message":"no content"},"ERROR_MODULE_MAIN_NOT_READABLE":{"code":3130,"message":"cannot read main file"},"ERROR_MODULE_MAIN_NOT_JS":{"code":3131,"message":"main file is not of type 'js'"},"RESULT_ELEMENT_EXISTS":{"code":10000,"message":"element not inserted into structure, because it already exists"},"RESULT_ELEMENT_NOT_FOUND":{"code":10001,"message":"element not found in structure"},"ERROR_APP_ALREADY_EXISTS":{"code":20000,"message":"newest version of app already installed"},"ERROR_QUEUE_ALREADY_EXISTS":{"code":21000,"message":"named queue already exists"},"ERROR_DISPATCHER_IS_STOPPING":{"code":21001,"message":"dispatcher stopped"},"ERROR_QUEUE_UNKNOWN":{"code":21002,"message":"named queue does not exist"},"ERROR_QUEUE_FULL":{"code":21003,"message":"named queue is full"}};})(); /*jshint -W051:true */ /*global jqconsole, Symbol */ /*eslint-disable */global.DEFINE_MODULE('console',(function(){'use strict'; /*eslint-enable */ //////////////////////////////////////////////////////////////////////////////// +(function(){"use strict";var internal=require("internal");internal.errors = {"ERROR_NO_ERROR":{"code":0,"message":"no error"},"ERROR_FAILED":{"code":1,"message":"failed"},"ERROR_SYS_ERROR":{"code":2,"message":"system error"},"ERROR_OUT_OF_MEMORY":{"code":3,"message":"out of memory"},"ERROR_INTERNAL":{"code":4,"message":"internal error"},"ERROR_ILLEGAL_NUMBER":{"code":5,"message":"illegal number"},"ERROR_NUMERIC_OVERFLOW":{"code":6,"message":"numeric overflow"},"ERROR_ILLEGAL_OPTION":{"code":7,"message":"illegal option"},"ERROR_DEAD_PID":{"code":8,"message":"dead process identifier"},"ERROR_NOT_IMPLEMENTED":{"code":9,"message":"not implemented"},"ERROR_BAD_PARAMETER":{"code":10,"message":"bad parameter"},"ERROR_FORBIDDEN":{"code":11,"message":"forbidden"},"ERROR_OUT_OF_MEMORY_MMAP":{"code":12,"message":"out of memory in mmap"},"ERROR_CORRUPTED_CSV":{"code":13,"message":"csv is corrupt"},"ERROR_FILE_NOT_FOUND":{"code":14,"message":"file not found"},"ERROR_CANNOT_WRITE_FILE":{"code":15,"message":"cannot write file"},"ERROR_CANNOT_OVERWRITE_FILE":{"code":16,"message":"cannot overwrite file"},"ERROR_TYPE_ERROR":{"code":17,"message":"type error"},"ERROR_LOCK_TIMEOUT":{"code":18,"message":"lock timeout"},"ERROR_CANNOT_CREATE_DIRECTORY":{"code":19,"message":"cannot create directory"},"ERROR_CANNOT_CREATE_TEMP_FILE":{"code":20,"message":"cannot create temporary file"},"ERROR_REQUEST_CANCELED":{"code":21,"message":"canceled request"},"ERROR_DEBUG":{"code":22,"message":"intentional debug error"},"ERROR_AID_NOT_FOUND":{"code":23,"message":"internal error with attribute ID in shaper"},"ERROR_LEGEND_INCOMPLETE":{"code":24,"message":"internal error if a legend could not be created"},"ERROR_IP_ADDRESS_INVALID":{"code":25,"message":"IP address is invalid"},"ERROR_LEGEND_NOT_IN_WAL_FILE":{"code":26,"message":"internal error if a legend for a marker does not yet exist in the same WAL file"},"ERROR_FILE_EXISTS":{"code":27,"message":"file exists"},"ERROR_LOCKED":{"code":28,"message":"locked"},"ERROR_DEADLOCK":{"code":29,"message":"deadlock detected"},"ERROR_HTTP_BAD_PARAMETER":{"code":400,"message":"bad parameter"},"ERROR_HTTP_UNAUTHORIZED":{"code":401,"message":"unauthorized"},"ERROR_HTTP_FORBIDDEN":{"code":403,"message":"forbidden"},"ERROR_HTTP_NOT_FOUND":{"code":404,"message":"not found"},"ERROR_HTTP_METHOD_NOT_ALLOWED":{"code":405,"message":"method not supported"},"ERROR_HTTP_PRECONDITION_FAILED":{"code":412,"message":"precondition failed"},"ERROR_HTTP_SERVER_ERROR":{"code":500,"message":"internal server error"},"ERROR_HTTP_CORRUPTED_JSON":{"code":600,"message":"invalid JSON object"},"ERROR_HTTP_SUPERFLUOUS_SUFFICES":{"code":601,"message":"superfluous URL suffices"},"ERROR_ARANGO_ILLEGAL_STATE":{"code":1000,"message":"illegal state"},"ERROR_ARANGO_SHAPER_FAILED":{"code":1001,"message":"could not shape document"},"ERROR_ARANGO_DATAFILE_SEALED":{"code":1002,"message":"datafile sealed"},"ERROR_ARANGO_UNKNOWN_COLLECTION_TYPE":{"code":1003,"message":"unknown type"},"ERROR_ARANGO_READ_ONLY":{"code":1004,"message":"read only"},"ERROR_ARANGO_DUPLICATE_IDENTIFIER":{"code":1005,"message":"duplicate identifier"},"ERROR_ARANGO_DATAFILE_UNREADABLE":{"code":1006,"message":"datafile unreadable"},"ERROR_ARANGO_DATAFILE_EMPTY":{"code":1007,"message":"datafile empty"},"ERROR_ARANGO_RECOVERY":{"code":1008,"message":"logfile recovery error"},"ERROR_ARANGO_CORRUPTED_DATAFILE":{"code":1100,"message":"corrupted datafile"},"ERROR_ARANGO_ILLEGAL_PARAMETER_FILE":{"code":1101,"message":"illegal or unreadable parameter file"},"ERROR_ARANGO_CORRUPTED_COLLECTION":{"code":1102,"message":"corrupted collection"},"ERROR_ARANGO_MMAP_FAILED":{"code":1103,"message":"mmap failed"},"ERROR_ARANGO_FILESYSTEM_FULL":{"code":1104,"message":"filesystem full"},"ERROR_ARANGO_NO_JOURNAL":{"code":1105,"message":"no journal"},"ERROR_ARANGO_DATAFILE_ALREADY_EXISTS":{"code":1106,"message":"cannot create/rename datafile because it already exists"},"ERROR_ARANGO_DATADIR_LOCKED":{"code":1107,"message":"database directory is locked"},"ERROR_ARANGO_COLLECTION_DIRECTORY_ALREADY_EXISTS":{"code":1108,"message":"cannot create/rename collection because directory already exists"},"ERROR_ARANGO_MSYNC_FAILED":{"code":1109,"message":"msync failed"},"ERROR_ARANGO_DATADIR_UNLOCKABLE":{"code":1110,"message":"cannot lock database directory"},"ERROR_ARANGO_SYNC_TIMEOUT":{"code":1111,"message":"sync timeout"},"ERROR_ARANGO_CONFLICT":{"code":1200,"message":"conflict"},"ERROR_ARANGO_DATADIR_INVALID":{"code":1201,"message":"invalid database directory"},"ERROR_ARANGO_DOCUMENT_NOT_FOUND":{"code":1202,"message":"document not found"},"ERROR_ARANGO_COLLECTION_NOT_FOUND":{"code":1203,"message":"collection not found"},"ERROR_ARANGO_COLLECTION_PARAMETER_MISSING":{"code":1204,"message":"parameter 'collection' not found"},"ERROR_ARANGO_DOCUMENT_HANDLE_BAD":{"code":1205,"message":"illegal document handle"},"ERROR_ARANGO_MAXIMAL_SIZE_TOO_SMALL":{"code":1206,"message":"maximal size of journal too small"},"ERROR_ARANGO_DUPLICATE_NAME":{"code":1207,"message":"duplicate name"},"ERROR_ARANGO_ILLEGAL_NAME":{"code":1208,"message":"illegal name"},"ERROR_ARANGO_NO_INDEX":{"code":1209,"message":"no suitable index known"},"ERROR_ARANGO_UNIQUE_CONSTRAINT_VIOLATED":{"code":1210,"message":"unique constraint violated"},"ERROR_ARANGO_INDEX_NOT_FOUND":{"code":1212,"message":"index not found"},"ERROR_ARANGO_CROSS_COLLECTION_REQUEST":{"code":1213,"message":"cross collection request not allowed"},"ERROR_ARANGO_INDEX_HANDLE_BAD":{"code":1214,"message":"illegal index handle"},"ERROR_ARANGO_CAP_CONSTRAINT_ALREADY_DEFINED":{"code":1215,"message":"cap constraint already defined"},"ERROR_ARANGO_DOCUMENT_TOO_LARGE":{"code":1216,"message":"document too large"},"ERROR_ARANGO_COLLECTION_NOT_UNLOADED":{"code":1217,"message":"collection must be unloaded"},"ERROR_ARANGO_COLLECTION_TYPE_INVALID":{"code":1218,"message":"collection type invalid"},"ERROR_ARANGO_VALIDATION_FAILED":{"code":1219,"message":"validator failed"},"ERROR_ARANGO_ATTRIBUTE_PARSER_FAILED":{"code":1220,"message":"parsing attribute name definition failed"},"ERROR_ARANGO_DOCUMENT_KEY_BAD":{"code":1221,"message":"illegal document key"},"ERROR_ARANGO_DOCUMENT_KEY_UNEXPECTED":{"code":1222,"message":"unexpected document key"},"ERROR_ARANGO_DATADIR_NOT_WRITABLE":{"code":1224,"message":"server database directory not writable"},"ERROR_ARANGO_OUT_OF_KEYS":{"code":1225,"message":"out of keys"},"ERROR_ARANGO_DOCUMENT_KEY_MISSING":{"code":1226,"message":"missing document key"},"ERROR_ARANGO_DOCUMENT_TYPE_INVALID":{"code":1227,"message":"invalid document type"},"ERROR_ARANGO_DATABASE_NOT_FOUND":{"code":1228,"message":"database not found"},"ERROR_ARANGO_DATABASE_NAME_INVALID":{"code":1229,"message":"database name invalid"},"ERROR_ARANGO_USE_SYSTEM_DATABASE":{"code":1230,"message":"operation only allowed in system database"},"ERROR_ARANGO_ENDPOINT_NOT_FOUND":{"code":1231,"message":"endpoint not found"},"ERROR_ARANGO_INVALID_KEY_GENERATOR":{"code":1232,"message":"invalid key generator"},"ERROR_ARANGO_INVALID_EDGE_ATTRIBUTE":{"code":1233,"message":"edge attribute missing"},"ERROR_ARANGO_INDEX_DOCUMENT_ATTRIBUTE_MISSING":{"code":1234,"message":"index insertion warning - attribute missing in document"},"ERROR_ARANGO_INDEX_CREATION_FAILED":{"code":1235,"message":"index creation failed"},"ERROR_ARANGO_WRITE_THROTTLE_TIMEOUT":{"code":1236,"message":"write-throttling timeout"},"ERROR_ARANGO_COLLECTION_TYPE_MISMATCH":{"code":1237,"message":"collection type mismatch"},"ERROR_ARANGO_COLLECTION_NOT_LOADED":{"code":1238,"message":"collection not loaded"},"ERROR_ARANGO_DATAFILE_FULL":{"code":1300,"message":"datafile full"},"ERROR_ARANGO_EMPTY_DATADIR":{"code":1301,"message":"server database directory is empty"},"ERROR_REPLICATION_NO_RESPONSE":{"code":1400,"message":"no response"},"ERROR_REPLICATION_INVALID_RESPONSE":{"code":1401,"message":"invalid response"},"ERROR_REPLICATION_MASTER_ERROR":{"code":1402,"message":"master error"},"ERROR_REPLICATION_MASTER_INCOMPATIBLE":{"code":1403,"message":"master incompatible"},"ERROR_REPLICATION_MASTER_CHANGE":{"code":1404,"message":"master change"},"ERROR_REPLICATION_LOOP":{"code":1405,"message":"loop detected"},"ERROR_REPLICATION_UNEXPECTED_MARKER":{"code":1406,"message":"unexpected marker"},"ERROR_REPLICATION_INVALID_APPLIER_STATE":{"code":1407,"message":"invalid applier state"},"ERROR_REPLICATION_UNEXPECTED_TRANSACTION":{"code":1408,"message":"invalid transaction"},"ERROR_REPLICATION_INVALID_APPLIER_CONFIGURATION":{"code":1410,"message":"invalid replication applier configuration"},"ERROR_REPLICATION_RUNNING":{"code":1411,"message":"cannot perform operation while applier is running"},"ERROR_REPLICATION_APPLIER_STOPPED":{"code":1412,"message":"replication stopped"},"ERROR_REPLICATION_NO_START_TICK":{"code":1413,"message":"no start tick"},"ERROR_REPLICATION_START_TICK_NOT_PRESENT":{"code":1414,"message":"start tick not present"},"ERROR_CLUSTER_NO_AGENCY":{"code":1450,"message":"could not connect to agency"},"ERROR_CLUSTER_NO_COORDINATOR_HEADER":{"code":1451,"message":"missing coordinator header"},"ERROR_CLUSTER_COULD_NOT_LOCK_PLAN":{"code":1452,"message":"could not lock plan in agency"},"ERROR_CLUSTER_COLLECTION_ID_EXISTS":{"code":1453,"message":"collection ID already exists"},"ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION_IN_PLAN":{"code":1454,"message":"could not create collection in plan"},"ERROR_CLUSTER_COULD_NOT_READ_CURRENT_VERSION":{"code":1455,"message":"could not read version in current in agency"},"ERROR_CLUSTER_COULD_NOT_CREATE_COLLECTION":{"code":1456,"message":"could not create collection"},"ERROR_CLUSTER_TIMEOUT":{"code":1457,"message":"timeout in cluster operation"},"ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_PLAN":{"code":1458,"message":"could not remove collection from plan"},"ERROR_CLUSTER_COULD_NOT_REMOVE_COLLECTION_IN_CURRENT":{"code":1459,"message":"could not remove collection from current"},"ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE_IN_PLAN":{"code":1460,"message":"could not create database in plan"},"ERROR_CLUSTER_COULD_NOT_CREATE_DATABASE":{"code":1461,"message":"could not create database"},"ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_PLAN":{"code":1462,"message":"could not remove database from plan"},"ERROR_CLUSTER_COULD_NOT_REMOVE_DATABASE_IN_CURRENT":{"code":1463,"message":"could not remove database from current"},"ERROR_CLUSTER_SHARD_GONE":{"code":1464,"message":"no responsible shard found"},"ERROR_CLUSTER_CONNECTION_LOST":{"code":1465,"message":"cluster internal HTTP connection broken"},"ERROR_CLUSTER_MUST_NOT_SPECIFY_KEY":{"code":1466,"message":"must not specify _key for this collection"},"ERROR_CLUSTER_GOT_CONTRADICTING_ANSWERS":{"code":1467,"message":"got contradicting answers from different shards"},"ERROR_CLUSTER_NOT_ALL_SHARDING_ATTRIBUTES_GIVEN":{"code":1468,"message":"not all sharding attributes given"},"ERROR_CLUSTER_MUST_NOT_CHANGE_SHARDING_ATTRIBUTES":{"code":1469,"message":"must not change the value of a shard key attribute"},"ERROR_CLUSTER_UNSUPPORTED":{"code":1470,"message":"unsupported operation or parameter"},"ERROR_CLUSTER_ONLY_ON_COORDINATOR":{"code":1471,"message":"this operation is only valid on a coordinator in a cluster"},"ERROR_CLUSTER_READING_PLAN_AGENCY":{"code":1472,"message":"error reading Plan in agency"},"ERROR_CLUSTER_COULD_NOT_TRUNCATE_COLLECTION":{"code":1473,"message":"could not truncate collection"},"ERROR_CLUSTER_AQL_COMMUNICATION":{"code":1474,"message":"error in cluster internal communication for AQL"},"ERROR_ARANGO_DOCUMENT_NOT_FOUND_OR_SHARDING_ATTRIBUTES_CHANGED":{"code":1475,"message":"document not found or sharding attributes changed"},"ERROR_CLUSTER_COULD_NOT_DETERMINE_ID":{"code":1476,"message":"could not determine my ID from my local info"},"ERROR_CLUSTER_ONLY_ON_DBSERVER":{"code":1477,"message":"this operation is only valid on a DBserver in a cluster"},"ERROR_QUERY_KILLED":{"code":1500,"message":"query killed"},"ERROR_QUERY_PARSE":{"code":1501,"message":"%s"},"ERROR_QUERY_EMPTY":{"code":1502,"message":"query is empty"},"ERROR_QUERY_SCRIPT":{"code":1503,"message":"runtime error '%s'"},"ERROR_QUERY_NUMBER_OUT_OF_RANGE":{"code":1504,"message":"number out of range"},"ERROR_QUERY_VARIABLE_NAME_INVALID":{"code":1510,"message":"variable name '%s' has an invalid format"},"ERROR_QUERY_VARIABLE_REDECLARED":{"code":1511,"message":"variable '%s' is assigned multiple times"},"ERROR_QUERY_VARIABLE_NAME_UNKNOWN":{"code":1512,"message":"unknown variable '%s'"},"ERROR_QUERY_COLLECTION_LOCK_FAILED":{"code":1521,"message":"unable to read-lock collection %s"},"ERROR_QUERY_TOO_MANY_COLLECTIONS":{"code":1522,"message":"too many collections"},"ERROR_QUERY_DOCUMENT_ATTRIBUTE_REDECLARED":{"code":1530,"message":"document attribute '%s' is assigned multiple times"},"ERROR_QUERY_FUNCTION_NAME_UNKNOWN":{"code":1540,"message":"usage of unknown function '%s()'"},"ERROR_QUERY_FUNCTION_ARGUMENT_NUMBER_MISMATCH":{"code":1541,"message":"invalid number of arguments for function '%s()', expected number of arguments: minimum: %d, maximum: %d"},"ERROR_QUERY_FUNCTION_ARGUMENT_TYPE_MISMATCH":{"code":1542,"message":"invalid argument type in call to function '%s()'"},"ERROR_QUERY_INVALID_REGEX":{"code":1543,"message":"invalid regex value"},"ERROR_QUERY_BIND_PARAMETERS_INVALID":{"code":1550,"message":"invalid structure of bind parameters"},"ERROR_QUERY_BIND_PARAMETER_MISSING":{"code":1551,"message":"no value specified for declared bind parameter '%s'"},"ERROR_QUERY_BIND_PARAMETER_UNDECLARED":{"code":1552,"message":"bind parameter '%s' was not declared in the query"},"ERROR_QUERY_BIND_PARAMETER_TYPE":{"code":1553,"message":"bind parameter '%s' has an invalid value or type"},"ERROR_QUERY_INVALID_LOGICAL_VALUE":{"code":1560,"message":"invalid logical value"},"ERROR_QUERY_INVALID_ARITHMETIC_VALUE":{"code":1561,"message":"invalid arithmetic value"},"ERROR_QUERY_DIVISION_BY_ZERO":{"code":1562,"message":"division by zero"},"ERROR_QUERY_ARRAY_EXPECTED":{"code":1563,"message":"array expected"},"ERROR_QUERY_FAIL_CALLED":{"code":1569,"message":"FAIL(%s) called"},"ERROR_QUERY_GEO_INDEX_MISSING":{"code":1570,"message":"no suitable geo index found for geo restriction on '%s'"},"ERROR_QUERY_FULLTEXT_INDEX_MISSING":{"code":1571,"message":"no suitable fulltext index found for fulltext query on '%s'"},"ERROR_QUERY_INVALID_DATE_VALUE":{"code":1572,"message":"invalid date value"},"ERROR_QUERY_MULTI_MODIFY":{"code":1573,"message":"multi-modify query"},"ERROR_QUERY_INVALID_AGGREGATE_EXPRESSION":{"code":1574,"message":"invalid aggregate expression"},"ERROR_QUERY_COMPILE_TIME_OPTIONS":{"code":1575,"message":"query options must be readable at query compile time"},"ERROR_QUERY_EXCEPTION_OPTIONS":{"code":1576,"message":"query options expected"},"ERROR_QUERY_COLLECTION_USED_IN_EXPRESSION":{"code":1577,"message":"collection '%s' used as expression operand"},"ERROR_QUERY_DISALLOWED_DYNAMIC_CALL":{"code":1578,"message":"disallowed dynamic call to '%s'"},"ERROR_QUERY_ACCESS_AFTER_MODIFICATION":{"code":1579,"message":"access after data-modification"},"ERROR_QUERY_FUNCTION_INVALID_NAME":{"code":1580,"message":"invalid user function name"},"ERROR_QUERY_FUNCTION_INVALID_CODE":{"code":1581,"message":"invalid user function code"},"ERROR_QUERY_FUNCTION_NOT_FOUND":{"code":1582,"message":"user function '%s()' not found"},"ERROR_QUERY_FUNCTION_RUNTIME_ERROR":{"code":1583,"message":"user function runtime error: %s"},"ERROR_QUERY_BAD_JSON_PLAN":{"code":1590,"message":"bad execution plan JSON"},"ERROR_QUERY_NOT_FOUND":{"code":1591,"message":"query ID not found"},"ERROR_QUERY_IN_USE":{"code":1592,"message":"query with this ID is in use"},"ERROR_CURSOR_NOT_FOUND":{"code":1600,"message":"cursor not found"},"ERROR_CURSOR_BUSY":{"code":1601,"message":"cursor is busy"},"ERROR_TRANSACTION_INTERNAL":{"code":1650,"message":"internal transaction error"},"ERROR_TRANSACTION_NESTED":{"code":1651,"message":"nested transactions detected"},"ERROR_TRANSACTION_UNREGISTERED_COLLECTION":{"code":1652,"message":"unregistered collection used in transaction"},"ERROR_TRANSACTION_DISALLOWED_OPERATION":{"code":1653,"message":"disallowed operation inside transaction"},"ERROR_TRANSACTION_ABORTED":{"code":1654,"message":"transaction aborted"},"ERROR_USER_INVALID_NAME":{"code":1700,"message":"invalid user name"},"ERROR_USER_INVALID_PASSWORD":{"code":1701,"message":"invalid password"},"ERROR_USER_DUPLICATE":{"code":1702,"message":"duplicate user"},"ERROR_USER_NOT_FOUND":{"code":1703,"message":"user not found"},"ERROR_USER_CHANGE_PASSWORD":{"code":1704,"message":"user must change his password"},"ERROR_APPLICATION_INVALID_NAME":{"code":1750,"message":"invalid application name"},"ERROR_APPLICATION_INVALID_MOUNT":{"code":1751,"message":"invalid mount"},"ERROR_APPLICATION_DOWNLOAD_FAILED":{"code":1752,"message":"application download failed"},"ERROR_APPLICATION_UPLOAD_FAILED":{"code":1753,"message":"application upload failed"},"ERROR_KEYVALUE_INVALID_KEY":{"code":1800,"message":"invalid key declaration"},"ERROR_KEYVALUE_KEY_EXISTS":{"code":1801,"message":"key already exists"},"ERROR_KEYVALUE_KEY_NOT_FOUND":{"code":1802,"message":"key not found"},"ERROR_KEYVALUE_KEY_NOT_UNIQUE":{"code":1803,"message":"key is not unique"},"ERROR_KEYVALUE_KEY_NOT_CHANGED":{"code":1804,"message":"key value not changed"},"ERROR_KEYVALUE_KEY_NOT_REMOVED":{"code":1805,"message":"key value not removed"},"ERROR_KEYVALUE_NO_VALUE":{"code":1806,"message":"missing value"},"ERROR_TASK_INVALID_ID":{"code":1850,"message":"invalid task id"},"ERROR_TASK_DUPLICATE_ID":{"code":1851,"message":"duplicate task id"},"ERROR_TASK_NOT_FOUND":{"code":1852,"message":"task not found"},"ERROR_GRAPH_INVALID_GRAPH":{"code":1901,"message":"invalid graph"},"ERROR_GRAPH_COULD_NOT_CREATE_GRAPH":{"code":1902,"message":"could not create graph"},"ERROR_GRAPH_INVALID_VERTEX":{"code":1903,"message":"invalid vertex"},"ERROR_GRAPH_COULD_NOT_CREATE_VERTEX":{"code":1904,"message":"could not create vertex"},"ERROR_GRAPH_COULD_NOT_CHANGE_VERTEX":{"code":1905,"message":"could not change vertex"},"ERROR_GRAPH_INVALID_EDGE":{"code":1906,"message":"invalid edge"},"ERROR_GRAPH_COULD_NOT_CREATE_EDGE":{"code":1907,"message":"could not create edge"},"ERROR_GRAPH_COULD_NOT_CHANGE_EDGE":{"code":1908,"message":"could not change edge"},"ERROR_GRAPH_TOO_MANY_ITERATIONS":{"code":1909,"message":"too many iterations - try increasing the value of 'maxIterations'"},"ERROR_GRAPH_INVALID_FILTER_RESULT":{"code":1910,"message":"invalid filter result"},"ERROR_GRAPH_COLLECTION_MULTI_USE":{"code":1920,"message":"multi use of edge collection in edge def"},"ERROR_GRAPH_COLLECTION_USE_IN_MULTI_GRAPHS":{"code":1921,"message":"edge collection already used in edge def"},"ERROR_GRAPH_CREATE_MISSING_NAME":{"code":1922,"message":"missing graph name"},"ERROR_GRAPH_CREATE_MALFORMED_EDGE_DEFINITION":{"code":1923,"message":"malformed edge definition"},"ERROR_GRAPH_NOT_FOUND":{"code":1924,"message":"graph not found"},"ERROR_GRAPH_DUPLICATE":{"code":1925,"message":"graph already exists"},"ERROR_GRAPH_VERTEX_COL_DOES_NOT_EXIST":{"code":1926,"message":"vertex collection does not exist or is not part of the graph"},"ERROR_GRAPH_WRONG_COLLECTION_TYPE_VERTEX":{"code":1927,"message":"not a vertex collection"},"ERROR_GRAPH_NOT_IN_ORPHAN_COLLECTION":{"code":1928,"message":"not in orphan collection"},"ERROR_GRAPH_COLLECTION_USED_IN_EDGE_DEF":{"code":1929,"message":"collection already used in edge def"},"ERROR_GRAPH_EDGE_COLLECTION_NOT_USED":{"code":1930,"message":"edge collection not used in graph"},"ERROR_GRAPH_NOT_AN_ARANGO_COLLECTION":{"code":1931,"message":" is not an ArangoCollection"},"ERROR_GRAPH_NO_GRAPH_COLLECTION":{"code":1932,"message":"collection _graphs does not exist"},"ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT_STRING":{"code":1933,"message":"Invalid example type. Has to be String, Array or Object"},"ERROR_GRAPH_INVALID_EXAMPLE_ARRAY_OBJECT":{"code":1934,"message":"Invalid example type. Has to be Array or Object"},"ERROR_GRAPH_INVALID_NUMBER_OF_ARGUMENTS":{"code":1935,"message":"Invalid number of arguments. Expected: "},"ERROR_GRAPH_INVALID_PARAMETER":{"code":1936,"message":"Invalid parameter type."},"ERROR_GRAPH_INVALID_ID":{"code":1937,"message":"Invalid id"},"ERROR_GRAPH_COLLECTION_USED_IN_ORPHANS":{"code":1938,"message":"collection used in orphans"},"ERROR_GRAPH_EDGE_COL_DOES_NOT_EXIST":{"code":1939,"message":"edge collection does not exist or is not part of the graph"},"ERROR_GRAPH_EMPTY":{"code":1940,"message":"empty graph"},"ERROR_SESSION_UNKNOWN":{"code":1950,"message":"unknown session"},"ERROR_SESSION_EXPIRED":{"code":1951,"message":"session expired"},"SIMPLE_CLIENT_UNKNOWN_ERROR":{"code":2000,"message":"unknown client error"},"SIMPLE_CLIENT_COULD_NOT_CONNECT":{"code":2001,"message":"could not connect to server"},"SIMPLE_CLIENT_COULD_NOT_WRITE":{"code":2002,"message":"could not write to server"},"SIMPLE_CLIENT_COULD_NOT_READ":{"code":2003,"message":"could not read from server"},"ERROR_MALFORMED_MANIFEST_FILE":{"code":3000,"message":"malformed manifest file"},"ERROR_INVALID_APPLICATION_MANIFEST":{"code":3001,"message":"manifest file is invalid"},"ERROR_INVALID_FOXX_OPTIONS":{"code":3004,"message":"invalid foxx options"},"ERROR_INVALID_MOUNTPOINT":{"code":3007,"message":"mountpoint is invalid"},"ERROR_APP_NOT_FOUND":{"code":3009,"message":"App not found"},"ERROR_APP_NEEDS_CONFIGURATION":{"code":3010,"message":"App not configured"},"ERROR_MODULE_NOT_FOUND":{"code":3100,"message":"cannot locate module"},"ERROR_MODULE_FAILURE":{"code":3103,"message":"failed to invoke module"},"RESULT_ELEMENT_EXISTS":{"code":10000,"message":"element not inserted into structure, because it already exists"},"RESULT_ELEMENT_NOT_FOUND":{"code":10001,"message":"element not found in structure"},"ERROR_QUEUE_ALREADY_EXISTS":{"code":21000,"message":"named queue already exists"},"ERROR_DISPATCHER_IS_STOPPING":{"code":21001,"message":"dispatcher stopped"},"ERROR_QUEUE_UNKNOWN":{"code":21002,"message":"named queue does not exist"},"ERROR_QUEUE_FULL":{"code":21003,"message":"named queue is full"}};})(); /*jshint -W051:true */ /*global jqconsole, Symbol */ /*eslint-disable */global.DEFINE_MODULE('console',(function(){'use strict'; /*eslint-enable */ //////////////////////////////////////////////////////////////////////////////// /// @brief module "console" /// /// @file @@ -1183,7 +1183,7 @@ exports.createHelpHeadline = function(text){var i;var p="";var x=Math.abs(78 - t /// throws an exception in case of an an error //////////////////////////////////////////////////////////////////////////////// // must came after the export of createHelpHeadline -var arangodb=require("@arangodb");var ArangoError=arangodb.ArangoError;exports.checkRequestResult = function(requestResult){if(requestResult === undefined){throw new ArangoError({"error":true,"code":500,"errorNum":arangodb.ERROR_INTERNAL,"errorMessage":"Unknown error. Request result is empty"});}if(requestResult.hasOwnProperty('error')){if(requestResult.error){if(requestResult.errorNum === arangodb.ERROR_TYPE_ERROR){throw new TypeError(requestResult.errorMessage);}throw new ArangoError(requestResult);} // remove the property from the original object +var arangodb=require("@arangodb");var ArangoError=arangodb.ArangoError;exports.checkRequestResult = function(requestResult){if(requestResult === undefined){throw new ArangoError({"error":true,"code":500,"errorNum":arangodb.ERROR_INTERNAL,"errorMessage":"Unknown error. Request result is empty"});}if(requestResult.hasOwnProperty('error')){if(requestResult.error){if(requestResult.errorNum === arangodb.ERROR_TYPE_ERROR){throw new TypeError(requestResult.errorMessage);}var error=new ArangoError(requestResult);error.message = requestResult.message;throw error;} // remove the property from the original object delete requestResult.error;}return requestResult;}; //////////////////////////////////////////////////////////////////////////////// /// @brief general help //////////////////////////////////////////////////////////////////////////////// diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/arangoes6.js b/js/apps/system/_admin/aardvark/APP/frontend/build/arangoes6.js index 52a0edfd23..66e6ece074 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/arangoes6.js +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/arangoes6.js @@ -49,22 +49,27 @@ if (global.ArangoError) { this.errorNum = error.errorNum; this.errorMessage = error.errorMessage; } - - this.message = this.toString(); }; exports.ArangoError.prototype = new Error(); } +Object.defineProperty(exports.ArangoError.prototype, 'message', { + configurable: true, + enumerable: true, + get() { + return this.errorMessage; + } +}); + +exports.ArangoError.prototype.name = 'ArangoError'; + exports.ArangoError.prototype._PRINT = function(context) { - context.output += this.toString(); + context.output += '[' + this.toString() + ']'; }; exports.ArangoError.prototype.toString = function() { - var errorNum = this.errorNum; - var errorMessage = this.errorMessage || this.message; - - return '[ArangoError ' + errorNum + ': ' + errorMessage + ']'; + return `${this.name} ${this.errorNum}: ${this.message}`; }; @@ -2071,31 +2076,14 @@ return exports; "SIMPLE_CLIENT_COULD_NOT_READ" : { "code" : 2003, "message" : "could not read from server" }, "ERROR_MALFORMED_MANIFEST_FILE" : { "code" : 3000, "message" : "malformed manifest file" }, "ERROR_INVALID_APPLICATION_MANIFEST" : { "code" : 3001, "message" : "manifest file is invalid" }, - "ERROR_MANIFEST_FILE_ATTRIBUTE_MISSING" : { "code" : 3002, "message" : "missing manifest attribute" }, - "ERROR_CANNOT_EXTRACT_APPLICATION_ROOT" : { "code" : 3003, "message" : "unable to extract app root path" }, "ERROR_INVALID_FOXX_OPTIONS" : { "code" : 3004, "message" : "invalid foxx options" }, - "ERROR_FAILED_TO_EXECUTE_SCRIPT" : { "code" : 3005, "message" : "failed to execute script" }, - "ERROR_SYNTAX_ERROR_IN_SCRIPT" : { "code" : 3006, "message" : "syntax error in script" }, "ERROR_INVALID_MOUNTPOINT" : { "code" : 3007, "message" : "mountpoint is invalid" }, - "ERROR_NO_FOXX_FOUND" : { "code" : 3008, "message" : "No foxx found at this location" }, "ERROR_APP_NOT_FOUND" : { "code" : 3009, "message" : "App not found" }, "ERROR_APP_NEEDS_CONFIGURATION" : { "code" : 3010, "message" : "App not configured" }, "ERROR_MODULE_NOT_FOUND" : { "code" : 3100, "message" : "cannot locate module" }, - "ERROR_MODULE_SYNTAX_ERROR" : { "code" : 3101, "message" : "syntax error in module" }, - "ERROR_MODULE_BAD_WRAPPER" : { "code" : 3102, "message" : "failed to wrap module" }, "ERROR_MODULE_FAILURE" : { "code" : 3103, "message" : "failed to invoke module" }, - "ERROR_MODULE_UNKNOWN_FILE_TYPE" : { "code" : 3110, "message" : "unknown file type" }, - "ERROR_MODULE_PATH_MUST_BE_ABSOLUTE" : { "code" : 3111, "message" : "path must be absolute" }, - "ERROR_MODULE_CAN_NOT_ESCAPE" : { "code" : 3112, "message" : "cannot use '..' to escape top-level-directory" }, - "ERROR_MODULE_DRIVE_LETTER" : { "code" : 3113, "message" : "drive local path is not supported" }, - "ERROR_MODULE_BAD_MODULE_ORIGIN" : { "code" : 3120, "message" : "corrupted module origin" }, - "ERROR_MODULE_BAD_PACKAGE_ORIGIN" : { "code" : 3121, "message" : "corrupted package origin" }, - "ERROR_MODULE_DOCUMENT_IS_EMPTY" : { "code" : 3125, "message" : "no content" }, - "ERROR_MODULE_MAIN_NOT_READABLE" : { "code" : 3130, "message" : "cannot read main file" }, - "ERROR_MODULE_MAIN_NOT_JS" : { "code" : 3131, "message" : "main file is not of type 'js'" }, "RESULT_ELEMENT_EXISTS" : { "code" : 10000, "message" : "element not inserted into structure, because it already exists" }, "RESULT_ELEMENT_NOT_FOUND" : { "code" : 10001, "message" : "element not found in structure" }, - "ERROR_APP_ALREADY_EXISTS" : { "code" : 20000, "message" : "newest version of app already installed" }, "ERROR_QUEUE_ALREADY_EXISTS" : { "code" : 21000, "message" : "named queue already exists" }, "ERROR_DISPATCHER_IS_STOPPING" : { "code" : 21001, "message" : "dispatcher stopped" }, "ERROR_QUEUE_UNKNOWN" : { "code" : 21002, "message" : "named queue does not exist" }, @@ -6007,7 +5995,9 @@ exports.checkRequestResult = function (requestResult) { throw new TypeError(requestResult.errorMessage); } - throw new ArangoError(requestResult); + const error = new ArangoError(requestResult); + error.message = requestResult.message; + throw error; } // remove the property from the original object diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/scripts.html.part b/js/apps/system/_admin/aardvark/APP/frontend/build/scripts.html.part index 89973ca9b1..9dbe6415d6 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/scripts.html.part +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/scripts.html.part @@ -1,3 +1,3 @@ - - - + + + diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/standalone-min.html b/js/apps/system/_admin/aardvark/APP/frontend/build/standalone-min.html index 6852497622..750457cf23 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/standalone-min.html +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/standalone-min.html @@ -2780,4 +2780,4 @@ var cutByResolution = function (str) {
    -
    \ No newline at end of file +
    \ No newline at end of file diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/standalone-min.html.gz b/js/apps/system/_admin/aardvark/APP/frontend/build/standalone-min.html.gz index 76e804ef0d..cb8a2d4777 100644 Binary files a/js/apps/system/_admin/aardvark/APP/frontend/build/standalone-min.html.gz and b/js/apps/system/_admin/aardvark/APP/frontend/build/standalone-min.html.gz differ diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/standalone.html b/js/apps/system/_admin/aardvark/APP/frontend/build/standalone.html index 0ffd56d6a6..82d1b39cea 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/standalone.html +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/standalone.html @@ -3044,9 +3044,9 @@ var cutByResolution = function (str) { - - - + + + diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/style-minified.css b/js/apps/system/_admin/aardvark/APP/frontend/build/style-minified.css index e998193cb6..e4f635c9b1 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/style-minified.css +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/style-minified.css @@ -1,7 +1,7 @@ @charset "UTF-8";body{background:#f5f8f0!important;color:#333;display:block;font-size:14px;line-height:20px;margin:0}.fa,.fa-stack{display:inline-block}.fa.fa-pull-left,.fa.pull-left{margin-right:.3em}.page-title span,.pingback a.url,body,input,textarea{font-family:'Open Sans',sans-serif!important;font-weight:400}@font-face{font-family:'Open Sans';font-style:normal;font-weight:300;src:local("Open Sans Light"),local("OpenSans-Light"),url(../fonts/opensans/OpenSansLight.woff) format("woff")}@font-face{font-family:'Open Sans';font-style:normal;font-weight:400;src:local("Open Sans"),local("OpenSans"),url(../fonts/opensans/OpenSans.woff) format("woff")}@font-face{font-family:'Open Sans';font-style:normal;font-weight:700;src:local("Open Sans Bold"),local("OpenSans-Bold"),url(../fonts/opensans/OpenSansBold.woff) format("woff")}@font-face{font-family:'Open Sans';font-style:italic;font-weight:300;src:local("Open Sans Light Italic"),local("OpenSansLight-Italic"),url(../fonts/opensans/OpenSansLightItalic.woff) format("woff")}@font-face{font-family:'Open Sans';font-style:italic;font-weight:400;src:local("Open Sans Italic"),local("OpenSans-Italic"),url(../fonts/opensans/OpenSansItalic.woff) format("woff")}@font-face{font-family:'Open Sans';font-style:italic;font-weight:700;src:local("Open Sans Bold Italic"),local("OpenSans-BoldItalic"),url(../fonts/opensans/OpenSansBoldItalic.woff) format("woff")}/*! * Font Awesome 4.4.0 by @davegandy - http://fontawesome.io - @fontawesome * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) - */@font-face{font-family:FontAwesome;src:url(../fonts/fontawesome/fontawesome-webfont.eot?v=4.4.0);src:url(../fonts/fontawesome/fontawesome-webfont.eot?#iefix&v=4.4.0) format("embedded-opentype"),url(../fonts/fontawesome/fontawesome-webfont.woff2?v=4.4.0) format("woff2"),url(../fonts/fontawesome/fontawesome-webfont.woff?v=4.4.0) format("woff"),url(../fonts/fontawesome/fontawesome-webfont.ttf?v=4.4.0) format("truetype"),url(../fonts/fontawesome/fontawesome-webfont.svg?v=4.4.0#fontawesomeregular) format("svg");font-weight:400;font-style:normal}.fa{font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.modal-body,.ui-tooltip,button{font-family:'Open Sans',sans-serif!important}.fa-lg{font-size:1.3333333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.2857142857em;text-align:center}.fa-ul{padding-left:0;margin-left:2.1428571429em;list-style-type:none}.fa.fa-pull-right,.fa.pull-right{margin-left:.3em}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.1428571429em;width:2.1428571429em;top:.1428571429em;text-align:center}.fa-li.fa-lg{left:-1.8571428571em}.fa-border{padding:.2em .25em .15em;border:.08em solid #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right,.pull-right{float:right}.contentDiv li,.dashboard-bar-chart-container,.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart,.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title,.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut,.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage,.dashboard-full-width-chart,.dashboard-full-width-chart .dashboard-full-width-chart-inner,.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart,.dashboard-half-height-legend,.dashboard-large-chart,.dashboard-large-chart .dashboard-large-chart-inner,.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart,.dashboard-legend,.dashboard-medium-chart,.dashboard-medium-chart .dashboard-interior-chart,.dashboard-small-chart,.dashboard-small-chart .dashboard-small-chart-inner,.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart,.dashboard-sub-bar,.dashboard-sub-bar .dashboard-sub-bar-title,.dashboard-tendency-container,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency .dashboard-subtitle-bar,.dashboard-title-bar .dashboard-half-title-bar,.dashboardModal,.dropdown-toolbar,.fixedDropdown .notificationItemContent,.gv-dropdown-menu,.innerDropdownInnerUL,.link-dropdown-menu,.modal-chart-detail,.modal-chart-detail .modal-body,.modal-chart-detail .modal-dashboard-legend,.modal-chart-detail .modal-inner-detail,.navlist li,.navlogo,.pagination-line li a,.pull-left,.script-dropdown-menu,.user-dropdown-menu,a.button-gui,a.headerButton,div .bigtile,div .bigtile a span.add-Icon,div .tile,div .tile a span.add-Icon,div.centralContent,div.dropdownInner ul,div.footer-center,div.footer-left,div.footer-left p{float:left}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=1);-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2);-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=3);-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=0);-webkit-transform:scale(-1,1);-ms-transform:scale(-1,1);transform:scale(-1,1)}.fa-flip-vertical{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2);-webkit-transform:scale(1,-1);-ms-transform:scale(1,-1);transform:scale(1,-1)}:root .fa-flip-horizontal,:root .fa-flip-vertical,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-rotate-90{filter:none}.fa-stack{position:relative;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:""}.fa-music:before{content:""}.fa-search:before{content:""}.fa-envelope-o:before{content:""}.fa-heart:before{content:""}.fa-star:before{content:""}.fa-star-o:before{content:""}.fa-user:before{content:""}.fa-film:before{content:""}.fa-th-large:before{content:""}.fa-th:before{content:""}.fa-th-list:before{content:""}.fa-check:before{content:""}.fa-close:before,.fa-remove:before,.fa-times:before{content:""}.fa-search-plus:before{content:""}.fa-search-minus:before{content:""}.fa-power-off:before{content:""}.fa-signal:before{content:""}.fa-cog:before,.fa-gear:before{content:""}.fa-trash-o:before{content:""}.fa-home:before{content:""}.fa-file-o:before{content:""}.fa-clock-o:before{content:""}.fa-road:before{content:""}.fa-download:before{content:""}.fa-arrow-circle-o-down:before{content:""}.fa-arrow-circle-o-up:before{content:""}.fa-inbox:before{content:""}.fa-play-circle-o:before{content:""}.fa-repeat:before,.fa-rotate-right:before{content:""}.fa-refresh:before{content:""}.fa-list-alt:before{content:""}.fa-lock:before{content:""}.fa-flag:before{content:""}.fa-headphones:before{content:""}.fa-volume-off:before{content:""}.fa-volume-down:before{content:""}.fa-volume-up:before{content:""}.fa-qrcode:before{content:""}.fa-barcode:before{content:""}.fa-tag:before{content:""}.fa-tags:before{content:""}.fa-book:before{content:""}.fa-bookmark:before{content:""}.fa-print:before{content:""}.fa-camera:before{content:""}.fa-font:before{content:""}.fa-bold:before{content:""}.fa-italic:before{content:""}.fa-text-height:before{content:""}.fa-text-width:before{content:""}.fa-align-left:before{content:""}.fa-align-center:before{content:""}.fa-align-right:before{content:""}.fa-align-justify:before{content:""}.fa-list:before{content:""}.fa-dedent:before,.fa-outdent:before{content:""}.fa-indent:before{content:""}.fa-video-camera:before{content:""}.fa-image:before,.fa-photo:before,.fa-picture-o:before{content:""}.fa-pencil:before{content:""}.fa-map-marker:before{content:""}.fa-adjust:before{content:""}.fa-tint:before{content:""}.fa-edit:before,.fa-pencil-square-o:before{content:""}.fa-share-square-o:before{content:""}.fa-check-square-o:before{content:""}.fa-arrows:before{content:""}.fa-step-backward:before{content:""}.fa-fast-backward:before{content:""}.fa-backward:before{content:""}.fa-play:before{content:""}.fa-pause:before{content:""}.fa-stop:before{content:""}.fa-forward:before{content:""}.fa-fast-forward:before{content:""}.fa-step-forward:before{content:""}.fa-eject:before{content:""}.fa-chevron-left:before{content:""}.fa-chevron-right:before{content:""}.fa-plus-circle:before{content:""}.fa-minus-circle:before{content:""}.fa-times-circle:before{content:""}.fa-check-circle:before{content:""}.fa-question-circle:before{content:""}.fa-info-circle:before{content:""}.fa-crosshairs:before{content:""}.fa-times-circle-o:before{content:""}.fa-check-circle-o:before{content:""}.fa-ban:before{content:""}.fa-arrow-left:before{content:""}.fa-arrow-right:before{content:""}.fa-arrow-up:before{content:""}.fa-arrow-down:before{content:""}.fa-mail-forward:before,.fa-share:before{content:""}.fa-expand:before{content:""}.fa-compress:before{content:""}.fa-plus:before{content:""}.fa-minus:before{content:""}.fa-asterisk:before{content:""}.fa-exclamation-circle:before{content:""}.fa-gift:before{content:""}.fa-leaf:before{content:""}.fa-fire:before{content:""}.fa-eye:before{content:""}.fa-eye-slash:before{content:""}.fa-exclamation-triangle:before,.fa-warning:before{content:""}.fa-plane:before{content:""}.fa-calendar:before{content:""}.fa-random:before{content:""}.fa-comment:before{content:""}.fa-magnet:before{content:""}.fa-chevron-up:before{content:""}.fa-chevron-down:before{content:""}.fa-retweet:before{content:""}.fa-shopping-cart:before{content:""}.fa-folder:before{content:""}.fa-folder-open:before{content:""}.fa-arrows-v:before{content:""}.fa-arrows-h:before{content:""}.fa-bar-chart-o:before,.fa-bar-chart:before{content:""}.fa-twitter-square:before{content:""}.fa-facebook-square:before{content:""}.fa-camera-retro:before{content:""}.fa-key:before{content:""}.fa-cogs:before,.fa-gears:before{content:""}.fa-comments:before{content:""}.fa-thumbs-o-up:before{content:""}.fa-thumbs-o-down:before{content:""}.fa-star-half:before{content:""}.fa-heart-o:before{content:""}.fa-sign-out:before{content:""}.fa-linkedin-square:before{content:""}.fa-thumb-tack:before{content:""}.fa-external-link:before{content:""}.fa-sign-in:before{content:""}.fa-trophy:before{content:""}.fa-github-square:before{content:""}.fa-upload:before{content:""}.fa-lemon-o:before{content:""}.fa-phone:before{content:""}.fa-square-o:before{content:""}.fa-bookmark-o:before{content:""}.fa-phone-square:before{content:""}.fa-twitter:before{content:""}.fa-facebook-f:before,.fa-facebook:before{content:""}.fa-github:before{content:""}.fa-unlock:before{content:""}.fa-credit-card:before{content:""}.fa-feed:before,.fa-rss:before{content:""}.fa-hdd-o:before{content:""}.fa-bullhorn:before{content:""}.fa-bell:before{content:""}.fa-certificate:before{content:""}.fa-hand-o-right:before{content:""}.fa-hand-o-left:before{content:""}.fa-hand-o-up:before{content:""}.fa-hand-o-down:before{content:""}.fa-arrow-circle-left:before{content:""}.fa-arrow-circle-right:before{content:""}.fa-arrow-circle-up:before{content:""}.fa-arrow-circle-down:before{content:""}.fa-globe:before{content:""}.fa-wrench:before{content:""}.fa-tasks:before{content:""}.fa-filter:before{content:""}.fa-briefcase:before{content:""}.fa-arrows-alt:before{content:""}.fa-group:before,.fa-users:before{content:""}.fa-chain:before,.fa-link:before{content:""}.fa-cloud:before{content:""}.fa-flask:before{content:""}.fa-cut:before,.fa-scissors:before{content:""}.fa-copy:before,.fa-files-o:before{content:""}.fa-paperclip:before{content:""}.fa-floppy-o:before,.fa-save:before{content:""}.fa-square:before{content:""}.fa-bars:before,.fa-navicon:before,.fa-reorder:before{content:""}.fa-list-ul:before{content:""}.fa-list-ol:before{content:""}.fa-strikethrough:before{content:""}.fa-underline:before{content:""}.fa-table:before{content:""}.fa-magic:before{content:""}.fa-truck:before{content:""}.fa-pinterest:before{content:""}.fa-pinterest-square:before{content:""}.fa-google-plus-square:before{content:""}.fa-google-plus:before{content:""}.fa-money:before{content:""}.fa-caret-down:before{content:""}.fa-caret-up:before{content:""}.fa-caret-left:before{content:""}.fa-caret-right:before{content:""}.fa-columns:before{content:""}.fa-sort:before,.fa-unsorted:before{content:""}.fa-sort-desc:before,.fa-sort-down:before{content:""}.fa-sort-asc:before,.fa-sort-up:before{content:""}.fa-envelope:before{content:""}.fa-linkedin:before{content:""}.fa-rotate-left:before,.fa-undo:before{content:""}.fa-gavel:before,.fa-legal:before{content:""}.fa-dashboard:before,.fa-tachometer:before{content:""}.fa-comment-o:before{content:""}.fa-comments-o:before{content:""}.fa-bolt:before,.fa-flash:before{content:""}.fa-sitemap:before{content:""}.fa-umbrella:before{content:""}.fa-clipboard:before,.fa-paste:before{content:""}.fa-lightbulb-o:before{content:""}.fa-exchange:before{content:""}.fa-cloud-download:before{content:""}.fa-cloud-upload:before{content:""}.fa-user-md:before{content:""}.fa-stethoscope:before{content:""}.fa-suitcase:before{content:""}.fa-bell-o:before{content:""}.fa-coffee:before{content:""}.fa-cutlery:before{content:""}.fa-file-text-o:before{content:""}.fa-building-o:before{content:""}.fa-hospital-o:before{content:""}.fa-ambulance:before{content:""}.fa-medkit:before{content:""}.fa-fighter-jet:before{content:""}.fa-beer:before{content:""}.fa-h-square:before{content:""}.fa-plus-square:before{content:""}.fa-angle-double-left:before{content:""}.fa-angle-double-right:before{content:""}.fa-angle-double-up:before{content:""}.fa-angle-double-down:before{content:""}.fa-angle-left:before{content:""}.fa-angle-right:before{content:""}.fa-angle-up:before{content:""}.fa-angle-down:before{content:""}.fa-desktop:before{content:""}.fa-laptop:before{content:""}.fa-tablet:before{content:""}.fa-mobile-phone:before,.fa-mobile:before{content:""}.fa-circle-o:before{content:""}.fa-quote-left:before{content:""}.fa-quote-right:before{content:""}.fa-spinner:before{content:""}.fa-circle:before{content:""}.fa-mail-reply:before,.fa-reply:before{content:""}.fa-github-alt:before{content:""}.fa-folder-o:before{content:""}.fa-folder-open-o:before{content:""}.fa-smile-o:before{content:""}.fa-frown-o:before{content:""}.fa-meh-o:before{content:""}.fa-gamepad:before{content:""}.fa-keyboard-o:before{content:""}.fa-flag-o:before{content:""}.fa-flag-checkered:before{content:""}.fa-terminal:before{content:""}.fa-code:before{content:""}.fa-mail-reply-all:before,.fa-reply-all:before{content:""}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:""}.fa-location-arrow:before{content:""}.fa-crop:before{content:""}.fa-code-fork:before{content:""}.fa-chain-broken:before,.fa-unlink:before{content:""}.fa-question:before{content:""}.fa-info:before{content:""}.fa-exclamation:before{content:""}.fa-superscript:before{content:""}.fa-subscript:before{content:""}.fa-eraser:before{content:""}.fa-puzzle-piece:before{content:""}.fa-microphone:before{content:""}.fa-microphone-slash:before{content:""}.fa-shield:before{content:""}.fa-calendar-o:before{content:""}.fa-fire-extinguisher:before{content:""}.fa-rocket:before{content:""}.fa-maxcdn:before{content:""}.fa-chevron-circle-left:before{content:""}.fa-chevron-circle-right:before{content:""}.fa-chevron-circle-up:before{content:""}.fa-chevron-circle-down:before{content:""}.fa-html5:before{content:""}.fa-css3:before{content:""}.fa-anchor:before{content:""}.fa-unlock-alt:before{content:""}.fa-bullseye:before{content:""}.fa-ellipsis-h:before{content:""}.fa-ellipsis-v:before{content:""}.fa-rss-square:before{content:""}.fa-play-circle:before{content:""}.fa-ticket:before{content:""}.fa-minus-square:before{content:""}.fa-minus-square-o:before{content:""}.fa-level-up:before{content:""}.fa-level-down:before{content:""}.fa-check-square:before{content:""}.fa-pencil-square:before{content:""}.fa-external-link-square:before{content:""}.fa-share-square:before{content:""}.fa-compass:before{content:""}.fa-caret-square-o-down:before,.fa-toggle-down:before{content:""}.fa-caret-square-o-up:before,.fa-toggle-up:before{content:""}.fa-caret-square-o-right:before,.fa-toggle-right:before{content:""}.fa-eur:before,.fa-euro:before{content:""}.fa-gbp:before{content:""}.fa-dollar:before,.fa-usd:before{content:""}.fa-inr:before,.fa-rupee:before{content:""}.fa-cny:before,.fa-jpy:before,.fa-rmb:before,.fa-yen:before{content:""}.fa-rouble:before,.fa-rub:before,.fa-ruble:before{content:""}.fa-krw:before,.fa-won:before{content:""}.fa-bitcoin:before,.fa-btc:before{content:""}.fa-file:before{content:""}.fa-file-text:before{content:""}.fa-sort-alpha-asc:before{content:""}.fa-sort-alpha-desc:before{content:""}.fa-sort-amount-asc:before{content:""}.fa-sort-amount-desc:before{content:""}.fa-sort-numeric-asc:before{content:""}.fa-sort-numeric-desc:before{content:""}.fa-thumbs-up:before{content:""}.fa-thumbs-down:before{content:""}.fa-youtube-square:before{content:""}.fa-youtube:before{content:""}.fa-xing:before{content:""}.fa-xing-square:before{content:""}.fa-youtube-play:before{content:""}.fa-dropbox:before{content:""}.fa-stack-overflow:before{content:""}.fa-instagram:before{content:""}.fa-flickr:before{content:""}.fa-adn:before{content:""}.fa-bitbucket:before{content:""}.fa-bitbucket-square:before{content:""}.fa-tumblr:before{content:""}.fa-tumblr-square:before{content:""}.fa-long-arrow-down:before{content:""}.fa-long-arrow-up:before{content:""}.fa-long-arrow-left:before{content:""}.fa-long-arrow-right:before{content:""}.fa-apple:before{content:""}.fa-windows:before{content:""}.fa-android:before{content:""}.fa-linux:before{content:""}.fa-dribbble:before{content:""}.fa-skype:before{content:""}.fa-foursquare:before{content:""}.fa-trello:before{content:""}.fa-female:before{content:""}.fa-male:before{content:""}.fa-gittip:before,.fa-gratipay:before{content:""}.fa-sun-o:before{content:""}.fa-moon-o:before{content:""}.fa-archive:before{content:""}.fa-bug:before{content:""}.fa-vk:before{content:""}.fa-weibo:before{content:""}.fa-renren:before{content:""}.fa-pagelines:before{content:""}.fa-stack-exchange:before{content:""}.fa-arrow-circle-o-right:before{content:""}.fa-arrow-circle-o-left:before{content:""}.fa-caret-square-o-left:before,.fa-toggle-left:before{content:""}.fa-dot-circle-o:before{content:""}.fa-wheelchair:before{content:""}.fa-vimeo-square:before{content:""}.fa-try:before,.fa-turkish-lira:before{content:""}.fa-plus-square-o:before{content:""}.fa-space-shuttle:before{content:""}.fa-slack:before{content:""}.fa-envelope-square:before{content:""}.fa-wordpress:before{content:""}.fa-openid:before{content:""}.fa-bank:before,.fa-institution:before,.fa-university:before{content:""}.fa-graduation-cap:before,.fa-mortar-board:before{content:""}.fa-yahoo:before{content:""}.fa-google:before{content:""}.fa-reddit:before{content:""}.fa-reddit-square:before{content:""}.fa-stumbleupon-circle:before{content:""}.fa-stumbleupon:before{content:""}.fa-delicious:before{content:""}.fa-digg:before{content:""}.fa-pied-piper:before{content:""}.fa-pied-piper-alt:before{content:""}.fa-drupal:before{content:""}.fa-joomla:before{content:""}.fa-language:before{content:""}.fa-fax:before{content:""}.fa-building:before{content:""}.fa-child:before{content:""}.fa-paw:before{content:""}.fa-spoon:before{content:""}.fa-cube:before{content:""}.fa-cubes:before{content:""}.fa-behance:before{content:""}.fa-behance-square:before{content:""}.fa-steam:before{content:""}.fa-steam-square:before{content:""}.fa-recycle:before{content:""}.fa-automobile:before,.fa-car:before{content:""}.fa-cab:before,.fa-taxi:before{content:""}.fa-tree:before{content:""}.fa-spotify:before{content:""}.fa-deviantart:before{content:""}.fa-soundcloud:before{content:""}.fa-database:before{content:""}.fa-file-pdf-o:before{content:""}.fa-file-word-o:before{content:""}.fa-file-excel-o:before{content:""}.fa-file-powerpoint-o:before{content:""}.fa-file-image-o:before,.fa-file-photo-o:before,.fa-file-picture-o:before{content:""}.fa-file-archive-o:before,.fa-file-zip-o:before{content:""}.fa-file-audio-o:before,.fa-file-sound-o:before{content:""}.fa-file-movie-o:before,.fa-file-video-o:before{content:""}.fa-file-code-o:before{content:""}.fa-vine:before{content:""}.fa-codepen:before{content:""}.fa-jsfiddle:before{content:""}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-ring:before,.fa-life-saver:before,.fa-support:before{content:""}.fa-circle-o-notch:before{content:""}.fa-ra:before,.fa-rebel:before{content:""}.fa-empire:before,.fa-ge:before{content:""}.fa-git-square:before{content:""}.fa-git:before{content:""}.fa-hacker-news:before,.fa-y-combinator-square:before,.fa-yc-square:before{content:""}.fa-tencent-weibo:before{content:""}.fa-qq:before{content:""}.fa-wechat:before,.fa-weixin:before{content:""}.fa-paper-plane:before,.fa-send:before{content:""}.fa-paper-plane-o:before,.fa-send-o:before{content:""}.fa-history:before{content:""}.fa-circle-thin:before{content:""}.fa-header:before{content:""}.fa-paragraph:before{content:""}.fa-sliders:before{content:""}.fa-share-alt:before{content:""}.fa-share-alt-square:before{content:""}.fa-bomb:before{content:""}.fa-futbol-o:before,.fa-soccer-ball-o:before{content:""}.fa-tty:before{content:""}.fa-binoculars:before{content:""}.fa-plug:before{content:""}.fa-slideshare:before{content:""}.fa-twitch:before{content:""}.fa-yelp:before{content:""}.fa-newspaper-o:before{content:""}.fa-wifi:before{content:""}.fa-calculator:before{content:""}.fa-paypal:before{content:""}.fa-google-wallet:before{content:""}.fa-cc-visa:before{content:""}.fa-cc-mastercard:before{content:""}.fa-cc-discover:before{content:""}.fa-cc-amex:before{content:""}.fa-cc-paypal:before{content:""}.fa-cc-stripe:before{content:""}.fa-bell-slash:before{content:""}.fa-bell-slash-o:before{content:""}.fa-trash:before{content:""}.fa-copyright:before{content:""}.fa-at:before{content:""}.fa-eyedropper:before{content:""}.fa-paint-brush:before{content:""}.fa-birthday-cake:before{content:""}.fa-area-chart:before{content:""}.fa-pie-chart:before{content:""}.fa-line-chart:before{content:""}.fa-lastfm:before{content:""}.fa-lastfm-square:before{content:""}.fa-toggle-off:before{content:""}.fa-toggle-on:before{content:""}.fa-bicycle:before{content:""}.fa-bus:before{content:""}.fa-ioxhost:before{content:""}.fa-angellist:before{content:""}.fa-cc:before{content:""}.fa-ils:before,.fa-shekel:before,.fa-sheqel:before{content:""}.fa-meanpath:before{content:""}.fa-buysellads:before{content:""}.fa-connectdevelop:before{content:""}.fa-dashcube:before{content:""}.fa-forumbee:before{content:""}.fa-leanpub:before{content:""}.fa-sellsy:before{content:""}.fa-shirtsinbulk:before{content:""}.fa-simplybuilt:before{content:""}.fa-skyatlas:before{content:""}.fa-cart-plus:before{content:""}.fa-cart-arrow-down:before{content:""}.fa-diamond:before{content:""}.fa-ship:before{content:""}.fa-user-secret:before{content:""}.fa-motorcycle:before{content:""}.fa-street-view:before{content:""}.fa-heartbeat:before{content:""}.fa-venus:before{content:""}.fa-mars:before{content:""}.fa-mercury:before{content:""}.fa-intersex:before,.fa-transgender:before{content:""}.fa-transgender-alt:before{content:""}.fa-venus-double:before{content:""}.fa-mars-double:before{content:""}.fa-venus-mars:before{content:""}.fa-mars-stroke:before{content:""}.fa-mars-stroke-v:before{content:""}.fa-mars-stroke-h:before{content:""}.fa-neuter:before{content:""}.fa-genderless:before{content:""}.fa-facebook-official:before{content:""}.fa-pinterest-p:before{content:""}.fa-whatsapp:before{content:""}.fa-server:before{content:""}.fa-user-plus:before{content:""}.fa-user-times:before{content:""}.fa-bed:before,.fa-hotel:before{content:""}.fa-viacoin:before{content:""}.fa-train:before{content:""}.fa-subway:before{content:""}.fa-medium:before{content:""}.fa-y-combinator:before,.fa-yc:before{content:""}.fa-optin-monster:before{content:""}.fa-opencart:before{content:""}.fa-expeditedssl:before{content:""}.fa-battery-4:before,.fa-battery-full:before{content:""}.fa-battery-3:before,.fa-battery-three-quarters:before{content:""}.fa-battery-2:before,.fa-battery-half:before{content:""}.fa-battery-1:before,.fa-battery-quarter:before{content:""}.fa-battery-0:before,.fa-battery-empty:before{content:""}.fa-mouse-pointer:before{content:""}.fa-i-cursor:before{content:""}.fa-object-group:before{content:""}.fa-object-ungroup:before{content:""}.fa-sticky-note:before{content:""}.fa-sticky-note-o:before{content:""}.fa-cc-jcb:before{content:""}.fa-cc-diners-club:before{content:""}.fa-clone:before{content:""}.fa-balance-scale:before{content:""}.fa-hourglass-o:before{content:""}.fa-hourglass-1:before,.fa-hourglass-start:before{content:""}.fa-hourglass-2:before,.fa-hourglass-half:before{content:""}.fa-hourglass-3:before,.fa-hourglass-end:before{content:""}.fa-hourglass:before{content:""}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:""}.fa-hand-paper-o:before,.fa-hand-stop-o:before{content:""}.fa-hand-scissors-o:before{content:""}.fa-hand-lizard-o:before{content:""}.fa-hand-spock-o:before{content:""}.fa-hand-pointer-o:before{content:""}.fa-hand-peace-o:before{content:""}.fa-trademark:before{content:""}.fa-registered:before{content:""}.fa-creative-commons:before{content:""}.fa-gg:before{content:""}.fa-gg-circle:before{content:""}.fa-tripadvisor:before{content:""}.fa-odnoklassniki:before{content:""}.fa-odnoklassniki-square:before{content:""}.fa-get-pocket:before{content:""}.fa-wikipedia-w:before{content:""}.fa-safari:before{content:""}.fa-chrome:before{content:""}.fa-firefox:before{content:""}.fa-opera:before{content:""}.fa-internet-explorer:before{content:""}.fa-television:before,.fa-tv:before{content:""}.fa-contao:before{content:""}.fa-500px:before{content:""}.fa-amazon:before{content:""}.fa-calendar-plus-o:before{content:""}.fa-calendar-minus-o:before{content:""}.fa-calendar-times-o:before{content:""}.fa-calendar-check-o:before{content:""}.fa-industry:before{content:""}.fa-map-pin:before{content:""}.fa-map-signs:before{content:""}.fa-map-o:before{content:""}.fa-map:before{content:""}.fa-commenting:before{content:""}.fa-commenting-o:before{content:""}.fa-houzz:before{content:""}.fa-vimeo:before{content:""}.fa-black-tie:before{content:""}.fa-fonticons:before{content:""}.arango-tab li,.dashboard-sub-bar-menu,.docsThirdCol,.fixedDropdown .notificationItem i,.fixedDropdown button,.headerBar>div.headerButtonBar,.navmenu,.query-button,.search-field,div .bigtile .iconSet span,div .tile .iconSet span,div.footer-right,div.footer-right p,div.gv_colour_list,ul.headerButtonList li{float:right}#distributionChartDiv:after,.arango-tab:after,.dashboard-bar-chart-container .dashboard-bar-chart:after,.dashboard-medium-chart .dashboard-medium-chart-inner:after,.dashboard-medium-chart .dashboard-medium-chart-menu:after,.dashboard-row:after,.dashboard-sub-bar:after,.dashboard-tendency-container .dashboard-tendency-chart:after,.detail-chart:after,.document-info .document-info-container .document-inner-info-container .document-attribute:after,.headerBar>div.headerButtonBar:after,.lineChartDiv:after,.pagination-line li:after,.resizecontainer:after,.tileList:after{clear:both;content:'.';display:block;font-size:0;height:0;visibility:hidden}.caret,.contentDiv:after,.contentDiv:before,.form-actions:after,.form-actions:before{content:''}.addButton,.arango-tab a,.arango-tab li,.arangoicon,.clusterDownBtn button,.contentDiv .icon,.contentTables tr.contentRowInactive a,.deleteButton,.edit-index-table .icon_arangodb_roundminus,.fixedDropdown .notificationItem i,.fullNotification:hover,.gv-search-submit-icon,.icon-info-sign,.link>line,.node,.pagination-line li a,.script-dropdown-menu .dropdown-item,.search-submit-icon,a.button-gui,a.headerButton,div .bigtile,div .bigtile .iconSet span,div .bigtile a span.icon,div .bigtile a svg,div .tile .iconSet span,div .tile a span.icon,div .tile a svg,div.headerDropdown.headerDropdown input[type=checkbox].css-checkbox label.css-label,div.toolbox div.gv_action_button{cursor:pointer}.navbar,footer.footer{background-color:rgba(245,248,240,.95);color:#fff;left:0;position:fixed;right:0;width:100%;z-index:1000}.ajax-file-upload-red,.button-danger{background-color:#da4f49}.ajax-file-upload-red:focus,.ajax-file-upload-red:hover,.button-danger:focus,.button-danger:hover{background-color:#be342e}.contentTables td span,.deleteButton,.edit-index-table .icon_arangodb_roundminus{color:#da4f49}.contentTables td span:focus,.contentTables td span:hover,.deleteButton:focus,.deleteButton:hover,.edit-index-table .icon_arangodb_roundminus:focus,.edit-index-table .icon_arangodb_roundminus:hover{color:#be342e}.ajax-file-upload,.button-success{background-color:#8aa051}.ajax-file-upload:focus,.ajax-file-upload:hover,.button-success:focus,.button-success:hover{background-color:#788f3d}.addButton,.contentTables td.dbThSecond span{color:#8aa051}.addButton:focus,.addButton:hover,.contentTables td.dbThSecond span:focus,.contentTables td.dbThSecond span:hover{color:#788f3d}.button-warning{background-color:#faa732}.button-warning:focus,.button-warning:hover{background-color:#f89406}.button-close,.button-neutral{background-color:#8f8d8c}.button-close:focus,.button-close:hover,.button-neutral:focus,.button-neutral:hover{background-color:#736b68}.dashboard-sub-bar-menu{color:#8f8d8c}.dashboard-sub-bar-menu:focus,.dashboard-sub-bar-menu:hover{color:#736b68}.button-primary{background-color:#564e4a}.button-primary:focus,.button-primary:hover{background-color:#3a322e}.button-header,a.button-gui,a.headerButton{background-color:#fff;border:1px solid #fff;color:#555}.button-header:focus,.button-header:hover,a.button-gui:focus,a.button-gui:hover,a.headerButton:focus,a.headerButton:hover{background-color:#8aa051;border:1px solid #8aa051;color:#fff}.button-notification{background-color:#faa020}.button-notification:focus,.button-notification:hover{background-color:#f87c0f}.button-inactive,.button-inactive:focus,.button-inactive:hover,[class*=' button-']:disabled,[class*=' button-']:focus:disabled,[class*=' button-']:hover:disabled,[class^=button-]:disabled,[class^=button-]:focus:disabled,[class^=button-]:hover:disabled,button.disabled,button.disabled:focus,button.disabled:hover{background-color:#d3d3d3}a.headerButton.disabled,a.headerButton.disabled:focus,a.headerButton.disabled:hover{color:#d3d3d3}div.queryline .fa.fa-search{color:#c2c2c2;font-size:12pt;opacity:.5;position:relative;right:21px;top:-1px}div.queryline .fa.fa-search:hover{cursor:pointer;opacity:1}.login-window .login-input,.modal-body .select2-choices input,.modal-body input,.modal-body select,.modal-body textarea,.navbar .arango-collection-select,div.queryline input,div.queryline select,input.search-input{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#fff!important;border:1px solid rgba(140,138,137,.25);box-shadow:none;outline:transparent 0}.login-window .login-input:focus,.modal-body input:focus,.modal-body select:focus,.modal-body textarea:focus,.navbar .arango-collection-select:focus,div.queryline input:focus,div.queryline select:focus,input.search-input:focus{border-color:#999;box-shadow:none;outline:transparent 0}.dropdown-toolbar,.gv-dropdown-menu,.link-dropdown-menu,.script-dropdown-menu,.user-dropdown-menu{background-color:#f5f8f0;border-color:#666;border-radius:3px;border-style:solid;border-width:1px;box-shadow:none;display:none;list-style:none;margin:5px 0 0;padding:5px 0;position:absolute;right:0;top:80%;z-index:1000}.script-dropdown-menu .dropdown-item a,.tab{display:block}.dropdown-toolbar li,.gv-dropdown-menu li,.link-dropdown-menu li,.script-dropdown-menu li,.user-dropdown-menu li{line-height:23px;white-space:nowrap;width:100%}.dropdown-toolbar .dropdown-header,.gv-dropdown-menu .dropdown-header,.link-dropdown-menu .dropdown-header,.script-dropdown-menu .dropdown-header,.user-dropdown-menu .dropdown-header{color:#999;font-size:15px;font-weight:600;font-variant:small-caps;padding:0}.dropdown-toolbar .dropdown-header:hover,.gv-dropdown-menu .dropdown-header:hover,.link-dropdown-menu .dropdown-header:hover,.script-dropdown-menu .dropdown-header:hover,.user-dropdown-menu .dropdown-header:hover{cursor:default}div .bigtile:hover,div .tile:hover,div.footer-center p:hover{cursor:pointer}.dropdown-toolbar .divider,.gv-dropdown-menu .divider,.link-dropdown-menu .divider,.script-dropdown-menu .divider,.user-dropdown-menu .divider{background-color:#666;height:1px;margin:10px 0 5px}.dropdown-toolbar a,.gv-dropdown-menu a,.link-dropdown-menu a,.script-dropdown-menu a,.user-dropdown-menu a{color:#fff;padding:0 20px}.navbar{-webkit-font-smoothing:subpixel-antialiased;height:44px;margin-bottom:3px;padding-top:6px;top:0}.navbar .no-left-margin{border:0;margin-left:0}.navbar .no-left-margin.hover{background-color:transparent}.navbar .arangodbLogo{height:auto;margin-left:-5px;margin-top:-1px;width:40%}.navbar .arango-collection-select{position:relative;right:-22px;top:4px}.navbar .nav .dropdown .active>.dropdown-toggle,.navbar .nav .dropdown .open.active>.dropdown-toggle,.navbar .nav .dropdown .open>.dropdown-toggle{background:#788f3d}.navbar .nav>.active>a{-webkit-box-shadow:0 0 0 transparent inset;-moz-box-shadow:0 0 0 transparent inset;box-shadow:0 0 0 transparent inset;background-color:#fff;color:#000}.navbar .nav>li>a:focus{background-color:#fff}.navbar .nav>li>a:hover{background-color:#000;color:#686766}.navlist .dropdown-item:hover a,.navlist>.active a,.navlist>.active:hover a,.navlist>li:hover a{color:#000}.navlogo{margin-left:5px;margin-right:-3px;padding-top:3px}.navlist{list-style:none}.navlist>li{height:39px}.navlist li{border-left:1px solid transparent;border-right:1px solid transparent;border-top:1px solid transparent;margin-left:7px}.navlist li.dropdown:hover{background-color:#fff;border-bottom-left-radius:0;border-bottom-right-radius:0;border-left:1px solid rgba(0,0,0,.2);border-right:1px solid rgba(0,0,0,.2);border-top:1px solid rgba(0,0,0,.2)}.navlist li.dropdown:hover a{border-bottom:2px solid #fff}.navlist li.divider,.navlist li.navbar-spacer{border:0}.navlist li.divider{background-color:rgba(0,0,0,.2)}.navlist li.navbar-spacer{background-color:#a0a0a0;height:21px;margin-top:9px;width:1px}.navlist li.navbar-spacer.big{margin-left:15px;margin-right:15px}.navlist li.navbar-spacer.med{margin-left:5px;margin-right:5px}.navlist .dropdown-item,.script-dropdown-menu .dropdown-item{margin-left:0}.navlist li.navbar-spacer:hover{background-color:#a0a0a0}.navlist .active .tab{border-bottom:2px solid #8aa051;padding-bottom:4px}.navlist>.active{background-color:transparent}.navlist>.active:hover{background-color:#fff}.navlist .dropdown-item:hover,.navlist>li:hover{background-color:#fff;border-radius:3px}.navlist .dropdown-item a{border-bottom:0;display:block;font-size:11pt}.navlist .dropdown-item a:hover{background-color:#dee9cf;color:#686766}.tab{color:#686766;font-size:12pt;font-weight:100;padding:9px 5px 10px}.tab.userImg{padding-bottom:5px}.dropdown-item a{border-bottom:0!important;font-weight:300}.dropdown-toolbar li a,footer.footer p{font-weight:100}.dropdown-toolbar{background-color:#fff!important;border:1px solid rgba(140,138,137,.25)}.dropdown-toolbar li a:hover{background:0 0;background-color:#dee9cf!important;color:#000!important}.link-dropdown-menu,.user-dropdown-menu{background-color:#fff;border:1px solid rgba(0,0,0,.2);border-top-right-radius:0;margin-right:-1px;margin-top:7px;z-index:-10}.link-dropdown-menu .dropdown-item,.user-dropdown-menu .dropdown-item{border-left:0;border-right:0}.script-dropdown-menu .dropdown-item a:hover{color:#fff}.script-dropdown-menu .dropdown-item:hover{background-color:#8aa051}.gv-dropdown-menu{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;background-color:rgba(0,0,0,.7);border:1px solid #c2c2c2;margin-right:-20px;margin-top:6px}.gv-dropdown-menu:after{border-bottom-color:#fff}.gv-dropdown-menu li:hover{background-color:#fff;background-image:none}.gv-dropdown-menu li a{padding:0}.gv-dropdown-menu li a label{color:#fff;padding-left:5px}.gv-dropdown-menu li a:focus{background-color:#8aa051!important;background-image:none}#arangoCollectionSelect{display:none;float:right;margin-bottom:0;margin-right:15px;padding-bottom:0}.caret{border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid #686766;display:inline-block;height:0;vertical-align:top;width:0}.applications-menu{display:block}.arango-logo{height:34px;padding:0!important}.arango-logo img{margin-left:22px}.footer{bottom:0;font-size:14px;left:0;position:fixed;right:0;text-align:center;z-index:1000}footer.footer{bottom:0;height:40px}footer.footer p{font-size:10pt;margin-bottom:0;padding-bottom:10px;padding-top:10px}div.footer-left{background:none;color:#686766;width:45%}div.footer-left .social-icons{margin-top:5px}div.footer-left .social-icons a{display:block;float:left;height:25px;width:25px}div.footer-left .social-icons p{background:#fff;border:1px solid rgba(104,103,102,.1);border-radius:20px;height:25px;margin-right:10px;padding:0;width:25px}div.footer-left .social-icons p:hover{background:#8aa051;cursor:pointer}div.footer-left .social-icons p:hover i{color:#fff}div.footer-left .social-icons i{color:#000;margin-top:6px;position:absolute}.addButton,.deleteButton{position:relative;font-size:22px}div.footer-left .social-icons i.fa-twitter{margin-left:-5px}div.footer-left .social-icons i.fa-envelope{margin-left:-19px}div.footer-left .social-icons i.fa-google{margin-left:-17px;margin-top:7px}div.footer-left .social-icons i.fa-stack-overflow{margin-left:-17px}div.footer-center{background:none;color:#686766;width:10%}div.footer-center i{background-color:#fff;border:1px solid rgba(104,103,102,.1);border-radius:20px;margin-left:1px;padding:6px 2px;width:20px}div.footer-center i:hover{background-color:#8aa051;color:#fff}div.footer-center p{padding-top:5px}[class*=' button-']:disabled,[class^=button-]:disabled,a.headerButton.disabled,button.disabled{cursor:not-allowed}div.footer-right{background:none;color:#686766;width:45%}div.footer-right p{color:#fff}div.footer-right i{color:#da4f49;font-size:18px}div.footer-right a{color:#686766;margin-left:5px;position:relative;top:-1px}div.footer-right .isOnline{color:#8aa051!important}.ajax-file-upload,.ajax-file-upload-red,.button-close,.button-danger,.button-header,.button-inactive,.button-neutral,.button-notification,.button-primary,.button-success,.button-warning{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;-webkit-box-shadow:0;-moz-box-shadow:0;box-shadow:0;font-size:14px;font-weight:300!important}.ajax-file-upload,.ajax-file-upload-red,.button-close,.button-danger,.button-inactive,.button-neutral,.button-notification,.button-primary,.button-success,.button-warning{border:0;color:#fff;margin-left:10px;padding:5px 16px}.button-header{margin-top:5px}.addButton{margin-right:7px;margin-top:2px}.deleteButton{padding-right:3px;top:3px}#closeBtnInfoView{margin-left:0!important}button.btn-server{width:120px}button.gv-zoom-btn{background-size:14px 14px;height:14px;vertical-align:baseline;width:14px}button.gv-zoom-btn.btn-zoom-right{border:0;box-shadow:none;right:0;top:13px}button.gv-zoom-btn.pan-right{background-image:url(../img/gv_arrow_right.png)}button.gv-zoom-btn.pan-right:hover{background:inherit;background-image:url(../img/gv_arrow_right.png)}button.gv-zoom-btn.pan-left{background-image:url(../img/gv_arrow_left.png)}button.gv-zoom-btn.pan-left:hover{background:inherit;background-image:url(../img/gv_arrow_left.png)}button.gv-zoom-btn.pan-top{background-image:url(../img/gv_arrow_top.png)}button.gv-zoom-btn.pan-top:hover{background:inherit;background-image:url(../img/gv_arrow_top.png)}button.gv-zoom-btn.pan-bottom{background-image:url(../img/gv_arrow_bottom.png)}button.gv-zoom-btn.pan-bottom:hover{background:inherit;background-image:url(../img/gv_arrow_bottom.png)}button.gv-zoom-btn.btn-zoom{height:14px;margin:0;padding:0;position:absolute;width:16px}button.gv-zoom-btn.btn-zoom-top{border:0;box-shadow:none;left:13px;top:1}button.gv-zoom-btn.btn-zoom-left{border:0;box-shadow:none;left:0;top:13px}button.gv-zoom-btn.btn-zoom-bottom{border:0;box-shadow:none;left:13px;top:25px}button.gv-icon-btn{-moz-border-radius:0!important;-webkit-border-radius:0!important;border-radius:0!important;background-size:36px 36px;height:36px;width:36px}button.gv-icon-btn.active{background-color:#8aa051}button.gv_dropdown_entry{height:30px;margin:4px 4px 4px 30px;width:160px}button.gv_context_button{width:65px}button.large-distance{margin-left:12px}button.short-distance{margin-left:6px}button.shutdown{margin-top:6px;padding:3px 14px}button.graphViewer-icon-button{background-color:transparent;border:0;height:20px;margin-left:5px;margin-top:-2px;padding:0;width:20px}button.graphViewer-icon-button img{height:20px;padding-bottom:10px;width:20px}ul.headerButtonList{display:inline-block;margin-bottom:0;margin-left:0;padding-left:0!important}ul.headerButtonList li{display:inline}a.button-gui,a.headerButton{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;margin-left:5px;margin-right:5px}a.headerButton{margin-top:2px;position:relative}a.headerButton .fa,a.headerButton [class*=" icon_"],a.headerButton [class^=icon_]{display:block;height:23px;line-height:23px;position:static;right:0;text-align:center;top:0;width:27px}a.headerButton .icon_arangodb_arrowleft,a.headerButton .icon_arangodb_arrowright{font-weight:700}a.headerButton.activated{background-color:#788f3d;border:1px solid #788f3d;color:#fff}div.toolbox,div.toolbox div.gv_action_button{-moz-border-radius:3px;-webkit-border-radius:3px;background-color:#fff}a.headerButton.activated:hover{background-color:#fff;color:#788f3d}div.toolbox{border-radius:3px;border:1px solid rgba(140,138,137,.25);margin-right:5px;margin-top:-3px;padding-bottom:5px;padding-top:5px;position:absolute}div.toolbox div.gv_action_button{border-radius:3px;color:#555;height:30px;margin:5px;position:relative;text-align:center;width:30px}div.toolbox div.gv_action_button.active{background-color:#8aa051;color:#fff}div.toolbox div.gv_action_button:first-child{margin-top:0}div.toolbox div.gv_action_button:last-child{margin-bottom:0}h6.gv_button_title,h6.gv_icon_icon{left:0;margin:0;position:absolute;right:0}h6.gv_icon_icon{font-size:22px;left:1px;top:4px}h6.gv_button_title{bottom:1px;display:none}.btn-icon{background-color:#383434;padding:4px}.gv-icon-small{background-size:16px 16px;height:16px!important;width:16px!important}.gv-icon-small.delete{background-image:url(../img/icon_delete.png)}.gv-icon-small.add{background-image:url(../img/plus_icon.png)}a.pagination-button,ul.arango-pagination a{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px}.badge,.btn,.label{text-shadow:none!important}.navbar-inner,.thumbnail{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;-webkit-box-shadow:0;-moz-box-shadow:0;box-shadow:0}.modal-body th.actionCell>button{margin-top:-12px}.btn-old-padding{padding-bottom:4px!important;padding-top:4px!important}button.btn-overview,button.btn-server{margin:5px}a.button-gui{height:auto;margin-bottom:0;margin-top:0;padding-bottom:1px;padding-top:1px;position:absolute;right:2px;text-decoration:none!important;top:2px;width:auto}a.button-gui.button-gui-disabled{display:none}.clusterDownBtn{padding-bottom:10px;padding-top:10px;text-align:center}.clusterDownBtn button{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#f1f1f1;border:1px solid rgba(0,0,0,.1875);color:#333;font-size:20px;font-weight:300;margin:0;padding:12px 18px;text-align:center;text-decoration:none!important;width:250px}.clusterDownBtn button:hover{background-color:#e8e8e8;color:#4a6c30;-webkit-transition-delay:0;-webkit-transition-duration:.2s;-webkit-transition-property:all;-webkit-transition-timing-function:ease-in}.clusterDownBtn button.green{background-color:#617e2b;color:#fff}.clusterDownBtn button.green:hover{background-color:#8ba142}.bottomButtonBar{background-color:#fff;border-top:1px solid rgba(104,103,102,.1);height:30px;padding:10px}.tileList{margin-left:-6px;margin-right:-6px}.tileList legend{padding-left:5px}.tileList .tile:first-child a{opacity:.8}.tileList .tile:first-child a:hover{opacity:1}div .bigtile,div .tile{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:#fff;border:1px solid #f5f8f0;border-radius:3px;font-size:14px;list-style:none;margin-bottom:13px;margin-left:6px;margin-right:6px;position:relative;text-align:center;z-index:1}div .bigtile progress[value],div .tile progress[value]{color:#5bc0de}div .bigtile progress::-webkit-progress-bar-value,div .tile progress::-webkit-progress-bar-value{background:#5bc0de}div .bigtile progress::-webkit-progress-value,div .tile progress::-webkit-progress-value{background:#5bc0de}div .bigtile progress::-moz-progress-bar,div .tile progress::-moz-progress-bar{background:#5bc0de}div .bigtile progress,div .tile progress{-webkit-appearance:none;border-radius:0;height:2px;margin-top:16px;position:relative;width:100%;z-index:10}div .locked.bigtile,div .locked.tile{cursor:not-allowed;opacity:.5}div .locked.bigtile .iconSet span:hover,div .locked.tile .iconSet span:hover{background-color:#fff!important;color:#000;cursor:not-allowed!important}div .locked.bigtile .iconSet:hover,div .locked.tile .iconSet:hover{cursor:not-allowed!important}div .bigtile .collection-type-icon:hover,div .bigtile img:hover,div .tile .collection-type-icon:hover,div .tile img:hover{cursor:pointer}div .bigtile .warning-icons,div .tile .warning-icons{background-color:#da4f49;border-radius:3px;color:#fff;font-size:11px;height:17px;left:0;line-height:13px;margin-left:5px;margin-top:5px;padding-left:9px;padding-right:9px;position:absolute;top:0}div .bigtile a svg.icon,div .bigtile img.icon,div .tile a svg.icon,div .tile img.icon{height:50px;width:50px}div .bigtile .warning-icons .fa,div .tile .warning-icons .fa{font-size:11pt;margin-left:1px}div .bigtile .collection-type-icon,div .tile .collection-type-icon{color:#666;font-size:30pt;margin-top:12pt}div .bigtile img,div .tile img{position:relative}div .bigtile a span.add-Icon,div .tile a span.add-Icon{font-size:22px;margin-left:22px;margin-right:10px;margin-top:-5px;position:relative;right:4px;top:2px}div .bigtile a span.icon,div .tile a span.icon{font-size:50px}div .bigtile .tile-icon-svg,div .tile .tile-icon-svg{cursor:pointer;fill:#686766;height:50px;margin-left:90px;margin-top:10px;position:absolute;width:50px}div .bigtile .tile-icon,div .tile .tile-icon{color:#686766;font-size:50px;line-height:1.2}div .bigtile .icon_arangodb_edge5-2,div .tile .icon_arangodb_edge5-2{display:inline-block;position:relative;top:15px;-moz-transform:rotate(80deg);-o-transform:rotate(80deg);-webkit-transform:rotate(80deg)}div .bigtile h5,div .tile h5{background:#8c8a89;color:#fff;font-size:12px;margin:0;overflow:hidden!important;padding:4px 8px;text-overflow:ellipsis!important;white-space:nowrap!important}div .bigtile h5.inProgress,div .tile h5.inProgress{color:#5bc0de}div .bigtile .tileSelects,div .tile .tileSelects{margin-left:40px;position:relative;z-index:9999}div .bigtile .tileSelects select,div .tile .tileSelects select{float:right;height:20px;margin-right:5px;margin-top:16px;width:70px}div .bigtile .fullBorderBox,div .tile .fullBorderBox{border:1px solid rgba(140,138,137,.25);border-radius:3px;height:100%;position:absolute;width:100%}div.headerBar,div.headerDropdown{border:1px solid rgba(140,138,137,.25)}div .bigtile .borderBox,div .tile .borderBox{border:1px solid rgba(140,138,137,.25);border-radius:3px;height:75px;position:absolute;width:224px}div .bigtile .iconSet,div .tile .iconSet{position:absolute;right:5px;top:5px}div .bigtile .iconSet span,div .tile .iconSet span{border-radius:3px;color:#666;font-size:18px;z-index:2;padding:2px 3px}.modal,.select2-drop-active{z-index:9999999}div .bigtile .iconSet span:hover,div .tile .iconSet span:hover{background-color:#8aa051;color:#fff}div .bigtile .iconSet span.disabled,div .tile .iconSet span.disabled{cursor:default;opacity:.2}div .bigtile .iconSet span.disabled:hover,div .tile .iconSet span.disabled:hover{background-color:#fff;color:#000;cursor:default;opacity:.2}div .bigtile .badge-success,div .tile .badge-success{font-weight:300}div .bigtile .unloaded div,div .tile .unloaded div{border-bottom:16px solid #ff8f35}div .bigtile .deleted div,div .tile .deleted div{border-bottom:16px solid #700}div .bigtile .tileBadge,div .tile .tileBadge{bottom:29px;font-size:11px;font-weight:300;position:absolute;right:0}div .bigtile .tileBadge button,div .tile .tileBadge button{margin-left:0;margin-right:5px}div .bigtile .tileBadge span,div .tile .tileBadge span{display:inline-block;line-height:15px}div .bigtile .tileBadge span .corneredBadge,div .tile .tileBadge span .corneredBadge{border-bottom-style:solid;border-bottom-width:17px;border-left:5px solid transparent;border-radius:3px;color:#fff;height:0;margin-bottom:4px;margin-right:5px;padding-left:1px;padding-right:6px}div .bigtile .tileBadge span .corneredBadge.loading,div .tile .tileBadge span .corneredBadge.loading{border-bottom-color:#ff8f35}div .bigtile .tileBadge span .corneredBadge.loaded,div .tile .tileBadge span .corneredBadge.loaded{border-bottom-color:#8aa051}div .bigtile .tileBadge span .corneredBadge.development,div .bigtile .tileBadge span .corneredBadge.unloaded,div .tile .tileBadge span .corneredBadge.development,div .tile .tileBadge span .corneredBadge.unloaded{border-bottom-color:#ff8f35}div .tile{height:100px;width:226px}div .tile-graph .tile-icon:hover{cursor:pointer}div .bigtile{height:309px;width:452px}div .bigtile .shardContainer{font-size:30px}div .bigtile .shardContainer span{padding:2px}.collectionName{border-bottom-left-radius:3px;border-bottom-right-radius:3px;bottom:0;font-weight:300;left:0;position:absolute;right:0;text-align:left}.resizecontainer{margin:0 auto}@media (max-width:738px){#arangoCollectionUl{display:none}#collectionsDropdown ul{width:auto!important}#arangoCollectionSelect{display:inline-block;height:29px;margin-top:1px}}@media (min-width:739px) and (max-width:1041px){#arangoCollectionUl a{font-size:12px;height:12px;padding:8px 5px}}@media (min-width:1042px) and (max-width:1284px){#arangoCollectionUl a{font-size:14px}}@media (min-width:250px) and (max-width:489px){.resizecontainer{width:228px}.dashboard-full-width-chart{width:225px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:215px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:69.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:214px}.dashboard-large-chart{width:146px}.dashboard-large-chart .dashboard-sub-bar{width:134px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:185px;width:136px}.dashboard-sub-bar-menu{font-size:12px}.dashboard-medium-chart-outer{float:left;width:106px}.dashboard-medium-chart{width:96px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:95px}.dashboard-medium-chart #clusterGraphs svg,.dashboard-medium-chart .dashboard-interior-chart{height:185px;width:96px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:12px;left:79px;top:0}.dashboard-medium-chart #clusterGraphs svg text{font-size:10px}.dashboard-small-chart{width:66px}.dashboard-small-chart .dashboard-sub-bar{width:54px}.dashboard-small-chart .dashboard-small-chart-inner{width:56px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:197px;width:56px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:10px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:78.25px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:8px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:25.08px;line-height:25.08px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:40.17px;line-height:19.08px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:54px}.dashboard-bar-chart-container{height:79.75px}.dashboard-bar-chart-container .dashboard-bar-chart{height:77.75px;width:56px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:25.25px;line-height:25.25px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:28px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:10.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:33.5px;line-height:33.5px;padding:5px 8px 10px;width:40px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:38.5px}.dashboard-bar-chart-container .dashboard-sub-bar{width:54px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-114px;width:248px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{display:none;font-size:12px;min-height:190px;width:10px}.absolut,.percentage{font-size:14px}.modal-chart-detail .modal-inner-detail{width:208px}.modal-body .dashboard-large-chart{width:143px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:131px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:133px}.modal-body .dashboard-medium-chart-outer{float:left;width:91px}.modal-body .dashboard-medium-chart{width:91px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:89px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:91px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:74px}.modal-body .dashboard-small-chart{width:61px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:49px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:51px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:6.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:51px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:56px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:28px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:10.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:40px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:54px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:10px;font-weight:400}.dashboard-subtitle-bar{font-size:14px;font-weight:300}.dashboard-figure{font-size:16px;font-weight:400}.dashboard-figurePer{font-size:14px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:10px}.dashboard-legend{display:none;height:190px;margin-top:-3px;width:0}.dashboard-half-height-legend{display:none;font-size:10px;height:100px;width:0}.application-detail-view section.info{width:228px}.application-detail-view aside.meta{display:none}}@media (min-width:490px) and (max-width:729px){.resizecontainer{width:468px}.dashboard-full-width-chart{width:465px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:455px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:149.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:454px}.dashboard-large-chart{width:306px}.dashboard-large-chart .dashboard-sub-bar{width:294px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:185px;width:296px}.dashboard-sub-bar-menu{font-size:12px}.dashboard-medium-chart-outer{float:left;width:226px}.dashboard-medium-chart{width:216px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:215px}.dashboard-medium-chart #clusterGraphs svg,.dashboard-medium-chart .dashboard-interior-chart{height:185px;width:216px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:12px;left:199px;top:0}.dashboard-medium-chart #clusterGraphs svg text{font-size:10px}.dashboard-small-chart{width:146px}.dashboard-small-chart .dashboard-sub-bar{width:134px}.dashboard-small-chart .dashboard-small-chart-inner{width:136px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:197px;width:136px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:10px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:78.25px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:48px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:25.08px;line-height:25.08px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:40.17px;line-height:19.08px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:134px}.dashboard-bar-chart-container{height:79.75px}.dashboard-bar-chart-container .dashboard-bar-chart{height:77.75px;width:136px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:25.25px;line-height:25.25px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:84px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:34.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:33.5px;line-height:33.5px;padding:5px 8px 10px;width:120px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:38.5px}.dashboard-bar-chart-container .dashboard-sub-bar{width:134px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-234px;width:488px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{display:none;font-size:12px;min-height:190px;width:10px}.absolut,.percentage{font-size:14px}.modal-chart-detail .modal-inner-detail{width:448px}.modal-body .dashboard-large-chart{width:303px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:291px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:293px}.modal-body .dashboard-medium-chart-outer{float:left;width:211px}.modal-body .dashboard-medium-chart{width:211px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:209px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:211px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:194px}.modal-body .dashboard-small-chart{width:141px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:129px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:131px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:46.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:131px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:136px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:84px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:34.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:120px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:134px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:10px;font-weight:400}.dashboard-subtitle-bar{font-size:14px;font-weight:300}.dashboard-figure{font-size:16px;font-weight:400}.dashboard-figurePer{font-size:14px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:10px}.dashboard-legend{display:none;height:190px;margin-top:-3px;width:0}.dashboard-half-height-legend{display:none;font-size:10px;height:100px;width:0}.application-detail-view section.info{width:468px}.application-detail-view aside.meta{display:none}}@media (min-width:730px) and (max-width:969px){.resizecontainer{width:708px}.dashboard-full-width-chart{width:705px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:695px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:229.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:694px}.dashboard-large-chart{width:466px}.dashboard-large-chart .dashboard-sub-bar{width:454px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:185px;width:456px}.dashboard-sub-bar-menu{font-size:12px}.dashboard-medium-chart-outer{float:left;width:346px}.dashboard-medium-chart{width:336px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:335px}.dashboard-medium-chart #clusterGraphs svg,.dashboard-medium-chart .dashboard-interior-chart{height:185px;width:336px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:12px;left:319px;top:0}.dashboard-medium-chart #clusterGraphs svg text{font-size:10px}.dashboard-small-chart{width:226px}.dashboard-small-chart .dashboard-sub-bar{width:214px}.dashboard-small-chart .dashboard-small-chart-inner{width:216px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:197px;width:216px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:10px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:78.25px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:88px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:25.08px;line-height:25.08px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:40.17px;line-height:19.08px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:214px}.dashboard-bar-chart-container{height:79.75px}.dashboard-bar-chart-container .dashboard-bar-chart{height:77.75px;width:216px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:25.25px;line-height:25.25px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:140px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:58.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:33.5px;line-height:33.5px;padding:5px 8px 10px;width:200px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:38.5px}.dashboard-bar-chart-container .dashboard-sub-bar{width:214px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-354px;width:728px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{display:none;font-size:12px;min-height:190px;width:10px}.absolut,.percentage{font-size:14px}.modal-chart-detail .modal-inner-detail{width:688px}.modal-body .dashboard-large-chart{width:463px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:451px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:453px}.modal-body .dashboard-medium-chart-outer{float:left;width:331px}.modal-body .dashboard-medium-chart{width:331px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:329px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:331px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:314px}.modal-body .dashboard-small-chart{width:221px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:209px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:211px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:86.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:211px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:216px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:140px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:58.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:200px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:214px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:10px;font-weight:400}.dashboard-subtitle-bar{font-size:14px;font-weight:300}.dashboard-figure{font-size:16px;font-weight:400}.dashboard-figurePer{font-size:14px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:10px}.dashboard-legend{display:none;height:190px;margin-top:-3px;width:0}.dashboard-half-height-legend{display:none;font-size:10px;height:100px;width:0}.application-detail-view section.info{width:508px}}@media (min-width:970px) and (max-width:1209px){.resizecontainer{width:948px}.dashboard-full-width-chart{width:945px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:935px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:309.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:934px}.dashboard-large-chart{width:626px}.dashboard-large-chart .dashboard-sub-bar{width:614px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:220px;width:496px}.dashboard-sub-bar-menu{font-size:13px}.dashboard-medium-chart-outer{float:left;width:466px}.dashboard-medium-chart{width:456px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:455px}.dashboard-medium-chart .dashboard-interior-chart{height:220px;width:336px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:13px;left:438px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:220px;width:456px}.dashboard-medium-chart #clusterGraphs svg text{font-size:11px}.dashboard-small-chart{width:306px}.dashboard-small-chart .dashboard-sub-bar{width:294px}.dashboard-small-chart .dashboard-small-chart-inner{width:296px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:229px;width:296px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:11px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:96.5px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:128px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:31.17px;line-height:31.17px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:52.33px;line-height:25.17px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:294px}.dashboard-bar-chart-container{height:98px}.dashboard-bar-chart-container .dashboard-bar-chart{height:96px;width:296px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:31.33px;line-height:31.33px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:196px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:82.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:45.67px;line-height:45.67px;padding:5px 8px 10px;width:280px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:50.67px}.dashboard-bar-chart-container .dashboard-sub-bar{width:294px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-474px;width:968px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:13px;min-height:225px;width:130px}.absolut,.percentage{font-size:15px}.modal-chart-detail .modal-inner-detail{width:808px}.modal-body .dashboard-large-chart{width:623px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:611px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:493px}.modal-body .dashboard-medium-chart-outer{float:left;width:451px}.modal-body .dashboard-medium-chart{width:451px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:449px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:331px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:433px}.modal-body .dashboard-small-chart{width:301px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:289px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:291px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:126.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:291px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:296px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:196px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:82.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:280px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:294px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:11px;font-weight:400}.dashboard-subtitle-bar{font-size:15px;font-weight:300}.dashboard-figure{font-size:18px;font-weight:400}.dashboard-figurePer{font-size:16px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:11px}.dashboard-legend{height:225px;margin-top:-3px;width:120px}.dashboard-half-height-legend{font-size:11px;height:117.5px;width:60px}.application-detail-view section.info{width:748px}}@media (min-width:1210px) and (max-width:1449px){.resizecontainer{width:1188px}.dashboard-full-width-chart{width:1185px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:1175px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:389.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:1174px}.dashboard-large-chart{width:786px}.dashboard-large-chart .dashboard-sub-bar{width:774px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:255px;width:646px}.dashboard-sub-bar-menu{font-size:15px}.dashboard-medium-chart-outer{float:left;width:586px}.dashboard-medium-chart{width:576px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:575px}.dashboard-medium-chart .dashboard-interior-chart{height:255px;width:446px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:16px;left:555px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:255px;width:576px}.dashboard-medium-chart #clusterGraphs svg text{font-size:12px}.dashboard-small-chart{width:386px}.dashboard-small-chart .dashboard-sub-bar{width:374px}.dashboard-small-chart .dashboard-small-chart-inner{width:376px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:264px;width:376px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:13px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:114px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:168px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:37px;line-height:37px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:64px;line-height:31px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:374px}.dashboard-bar-chart-container{height:115.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:113.5px;width:376px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:37.17px;line-height:37.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:252px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:106.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:57.33px;line-height:57.33px;padding:5px 8px 10px;width:360px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:62.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:374px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-594px;width:1208px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:14px;min-height:260px;width:140px}.absolut,.percentage{font-size:18px}.modal-chart-detail .modal-inner-detail{width:1038px}.modal-body .dashboard-large-chart{width:783px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:771px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:643px}.modal-body .dashboard-medium-chart-outer{float:left;width:571px}.modal-body .dashboard-medium-chart{width:571px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:569px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:441px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:550px}.modal-body .dashboard-small-chart{width:381px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:369px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:371px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:166.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:371px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:376px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:252px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:106.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:360px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:374px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:13px;font-weight:400}.dashboard-subtitle-bar{font-size:18px;font-weight:300}.dashboard-figure{font-size:22px;font-weight:400}.dashboard-figurePer{font-size:20px;font-weight:300}.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-size:13px;font-weight:400}.dashboard-legend{font-size:12px;font-weight:400;height:260px;margin-top:-3px;width:130px}.dashboard-half-height-legend{font-size:12px;height:135px;width:65px}.application-detail-view section.info{width:988px}}@media (min-width:1450px) and (max-width:1689px){.resizecontainer{width:1428px}.dashboard-full-width-chart{width:1425px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:1415px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:469.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:1414px}.dashboard-large-chart{width:946px}.dashboard-large-chart .dashboard-sub-bar{width:934px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:285px;width:796px}.dashboard-sub-bar-menu{font-size:15px}.dashboard-medium-chart-outer{float:left;width:706px}.dashboard-medium-chart{width:696px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:695px}.dashboard-medium-chart .dashboard-interior-chart{height:285px;width:556px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:18px;left:673px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:285px;width:696px}.dashboard-medium-chart #clusterGraphs svg text{font-size:13px}.dashboard-small-chart{width:466px}.dashboard-small-chart .dashboard-sub-bar{width:454px}.dashboard-small-chart .dashboard-small-chart-inner{width:456px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:294px;width:456px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:13px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:129px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:208px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:42px;line-height:42px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:74px;line-height:36px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:454px}.dashboard-bar-chart-container{height:130.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:128.5px;width:456px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:42.17px;line-height:42.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:308px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:130.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:67.33px;line-height:67.33px;padding:5px 8px 10px;width:440px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:72.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:454px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-714px;width:1448px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:15px;min-height:290px;width:150px}.absolut,.percentage{font-size:20px}.modal-chart-detail .modal-inner-detail{width:1268px}.modal-body .dashboard-large-chart{width:943px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:931px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:793px}.modal-body .dashboard-medium-chart-outer{float:left;width:691px}.modal-body .dashboard-medium-chart{width:691px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:689px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:551px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:668px}.modal-body .dashboard-small-chart{width:461px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:449px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:451px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:206.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:451px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:456px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:308px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:130.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:440px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:454px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:13px;font-weight:400}.dashboard-subtitle-bar{font-size:20px;font-weight:300}.dashboard-figure{font-size:26px;font-weight:400}.dashboard-figurePer{font-size:24px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:13px}.dashboard-legend{height:290px;margin-top:-3px;width:140px}.dashboard-half-height-legend{font-size:13px;height:150px;width:70px}.application-detail-view section.info{width:1228px}}@media (min-width:1690px) and (max-width:1929px){.resizecontainer{width:1668px}.dashboard-full-width-chart{width:1665px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:1655px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:549.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:1654px}.dashboard-large-chart{width:1106px}.dashboard-large-chart .dashboard-sub-bar{width:1094px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:325px;width:936px}.dashboard-sub-bar-menu{font-size:16px}.dashboard-medium-chart-outer{float:left;width:826px}.dashboard-medium-chart{width:816px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:815px}.dashboard-medium-chart .dashboard-interior-chart{height:325px;width:656px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:22px;left:789px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:325px;width:816px}.dashboard-medium-chart #clusterGraphs svg text{font-size:14px}.dashboard-small-chart{width:546px}.dashboard-small-chart .dashboard-sub-bar{width:534px}.dashboard-small-chart .dashboard-small-chart-inner{width:536px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:334px;width:536px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:14px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:149px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:248px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:48.67px;line-height:48.67px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:87.33px;line-height:42.67px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:534px}.dashboard-bar-chart-container{height:150.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:148.5px;width:536px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:48.83px;line-height:48.83px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:364px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:154.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:80.67px;line-height:80.67px;padding:5px 8px 10px;width:520px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:85.67px}.dashboard-bar-chart-container .dashboard-sub-bar{width:534px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-834px;width:1688px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:16px;min-height:330px;width:170px}.absolut,.percentage{font-size:24px}.modal-chart-detail .modal-inner-detail{width:1488px}.modal-body .dashboard-large-chart{width:1103px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1091px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:933px}.modal-body .dashboard-medium-chart-outer{float:left;width:811px}.modal-body .dashboard-medium-chart{width:811px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:809px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:651px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:784px}.modal-body .dashboard-small-chart{width:541px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:529px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:531px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:246.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:531px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:536px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:364px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:154.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:520px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:534px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:14px;font-weight:400}.dashboard-subtitle-bar{font-size:24px;font-weight:300}.dashboard-figure{font-size:30px;font-weight:400}.dashboard-figurePer{font-size:28px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:14px}.dashboard-legend{height:330px;margin-top:-3px;width:160px}.dashboard-half-height-legend{font-size:14px;height:170px;width:80px}.application-detail-view section.info{width:1468px}}@media (min-width:1930px) and (max-width:2169px){.resizecontainer{width:1908px}.dashboard-full-width-chart{width:1905px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:1895px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:629.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:1894px}.dashboard-large-chart{width:1266px}.dashboard-large-chart .dashboard-sub-bar{width:1254px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:385px;width:1086px}.dashboard-sub-bar-menu{font-size:17px}.dashboard-medium-chart-outer{float:left;width:946px}.dashboard-medium-chart{width:936px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:935px}.dashboard-medium-chart .dashboard-interior-chart{height:385px;width:766px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:26px;left:905px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:385px;width:936px}.dashboard-medium-chart #clusterGraphs svg text{font-size:15px}.dashboard-small-chart{width:626px}.dashboard-small-chart .dashboard-sub-bar{width:614px}.dashboard-small-chart .dashboard-small-chart-inner{width:616px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:394px;width:616px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:14px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:179px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:288px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:58.67px;line-height:58.67px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:107.33px;line-height:52.67px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:614px}.dashboard-bar-chart-container{height:180.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:178.5px;width:616px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:58.83px;line-height:58.83px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:420px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:178.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:100.67px;line-height:100.67px;padding:5px 8px 10px;width:600px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:105.67px}.dashboard-bar-chart-container .dashboard-sub-bar{width:614px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-954px;width:1928px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:17px;min-height:390px;width:180px}.absolut,.percentage{font-size:28px}.modal-chart-detail .modal-inner-detail{width:1718px}.modal-body .dashboard-large-chart{width:1263px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1251px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:1083px}.modal-body .dashboard-medium-chart-outer{float:left;width:931px}.modal-body .dashboard-medium-chart{width:931px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:929px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:761px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:900px}.modal-body .dashboard-small-chart{width:621px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:609px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:611px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:286.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:611px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:616px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:420px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:178.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:600px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:614px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:15px;font-weight:400}.dashboard-subtitle-bar{font-size:28px;font-weight:300}.dashboard-figure{font-size:34px;font-weight:400}.dashboard-figurePer{font-size:32px;font-weight:300}.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-size:14px;font-weight:400}.dashboard-legend{font-size:15px;font-weight:400;height:390px;margin-top:-3px;width:170px}.dashboard-half-height-legend{font-size:15px;height:200px;width:85px}.application-detail-view section.info{width:1708px}}@media (min-width:2170px) and (max-width:2409px){.resizecontainer{width:2148px}.dashboard-full-width-chart{width:2145px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:2135px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:709.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:2134px}.dashboard-large-chart{width:1426px}.dashboard-large-chart .dashboard-sub-bar{width:1414px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:285px;width:1276px}.dashboard-sub-bar-menu{font-size:17px}.dashboard-medium-chart-outer{float:left;width:1066px}.dashboard-medium-chart{width:1056px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:1055px}.dashboard-medium-chart .dashboard-interior-chart{height:285px;width:916px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:20px;left:1031px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:285px;width:1056px}.dashboard-medium-chart #clusterGraphs svg text{font-size:15px}.dashboard-small-chart{width:706px}.dashboard-small-chart .dashboard-sub-bar{width:694px}.dashboard-small-chart .dashboard-small-chart-inner{width:696px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:294px;width:696px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:15px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:129px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:328px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:42px;line-height:42px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:74px;line-height:36px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:694px}.dashboard-bar-chart-container{height:130.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:128.5px;width:696px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:42.17px;line-height:42.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:476px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:202.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:67.33px;line-height:67.33px;padding:5px 8px 10px;width:680px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:72.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:694px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-1074px;width:2168px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:17px;min-height:290px;width:150px}.absolut,.percentage{font-size:22px}.modal-chart-detail .modal-inner-detail{width:1988px}.modal-body .dashboard-large-chart{width:1423px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1411px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:1273px}.modal-body .dashboard-medium-chart-outer{float:left;width:1051px}.modal-body .dashboard-medium-chart{width:1051px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:1049px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:911px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:1026px}.modal-body .dashboard-small-chart{width:701px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:689px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:691px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:326.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:691px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:696px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:476px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:202.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:680px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:694px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:15px;font-weight:400}.dashboard-subtitle-bar{font-size:22px;font-weight:300}.dashboard-figure{font-size:36px;font-weight:400}.dashboard-figurePer{font-size:34px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:15px}.dashboard-legend{height:290px;margin-top:-3px;width:140px}.dashboard-half-height-legend{font-size:15px;height:150px;width:70px}.application-detail-view section.info{width:1948px}}@media (min-width:2410px) and (max-width:2649px){.resizecontainer{width:2388px}.dashboard-full-width-chart{width:2385px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:2375px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:789.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:2374px}.dashboard-large-chart{width:1586px}.dashboard-large-chart .dashboard-sub-bar{width:1574px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:285px;width:1436px}.dashboard-sub-bar-menu{font-size:17px}.dashboard-medium-chart-outer{float:left;width:1186px}.dashboard-medium-chart{width:1176px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:1175px}.dashboard-medium-chart .dashboard-interior-chart{height:285px;width:1036px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:20px;left:1151px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:285px;width:1176px}.dashboard-medium-chart #clusterGraphs svg text{font-size:15px}.dashboard-small-chart{width:786px}.dashboard-small-chart .dashboard-sub-bar{width:774px}.dashboard-small-chart .dashboard-small-chart-inner{width:776px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:294px;width:776px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:15px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:129px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:368px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:42px;line-height:42px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:74px;line-height:36px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:774px}.dashboard-bar-chart-container{height:130.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:128.5px;width:776px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:42.17px;line-height:42.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:532px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:226.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:67.33px;line-height:67.33px;padding:5px 8px 10px;width:760px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:72.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:774px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-1194px;width:2408px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:17px;min-height:290px;width:150px}.absolut,.percentage{font-size:22px}.modal-chart-detail .modal-inner-detail{width:2228px}.modal-body .dashboard-large-chart{width:1583px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1571px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:1433px}.modal-body .dashboard-medium-chart-outer{float:left;width:1171px}.modal-body .dashboard-medium-chart{width:1171px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:1169px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:1031px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:1146px}.modal-body .dashboard-small-chart{width:781px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:769px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:771px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:366.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:771px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:776px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:532px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:226.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:760px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:774px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:15px;font-weight:400}.dashboard-subtitle-bar{font-size:22px;font-weight:300}.dashboard-figure{font-size:36px;font-weight:400}.dashboard-figurePer{font-size:34px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:15px}.dashboard-legend{height:290px;margin-top:-3px;width:140px}.dashboard-half-height-legend{font-size:15px;height:150px;width:70px}.application-detail-view section.info{width:2188px}}@media (min-width:2650px) and (max-width:2889px){.resizecontainer{width:2628px}.dashboard-full-width-chart{width:2625px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:2615px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:869.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:2614px}.dashboard-large-chart{width:1746px}.dashboard-large-chart .dashboard-sub-bar{width:1734px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:285px;width:1596px}.dashboard-sub-bar-menu{font-size:17px}.dashboard-medium-chart-outer{float:left;width:1306px}.dashboard-medium-chart{width:1296px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:1295px}.dashboard-medium-chart .dashboard-interior-chart{height:285px;width:1156px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:20px;left:1271px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:285px;width:1296px}.dashboard-medium-chart #clusterGraphs svg text{font-size:15px}.dashboard-small-chart{width:866px}.dashboard-small-chart .dashboard-sub-bar{width:854px}.dashboard-small-chart .dashboard-small-chart-inner{width:856px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:294px;width:856px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:15px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:129px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:408px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:42px;line-height:42px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:74px;line-height:36px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:854px}.dashboard-bar-chart-container{height:130.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:128.5px;width:856px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:42.17px;line-height:42.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:588px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:250.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:67.33px;line-height:67.33px;padding:5px 8px 10px;width:840px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:72.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:854px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-1314px;width:2648px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:17px;min-height:290px;width:150px}.absolut,.percentage{font-size:22px}.modal-chart-detail .modal-inner-detail{width:2468px}.modal-body .dashboard-large-chart{width:1743px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1731px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:1593px}.modal-body .dashboard-medium-chart-outer{float:left;width:1291px}.modal-body .dashboard-medium-chart{width:1291px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:1289px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:1151px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:1266px}.modal-body .dashboard-small-chart{width:861px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:849px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:851px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:406.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:851px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:856px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:588px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:250.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:840px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:854px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:15px;font-weight:400}.dashboard-subtitle-bar{font-size:22px;font-weight:300}.dashboard-figure{font-size:36px;font-weight:400}.dashboard-figurePer{font-size:34px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:15px}.dashboard-legend{height:290px;margin-top:-3px;width:140px}.dashboard-half-height-legend{font-size:15px;height:150px;width:70px}.application-detail-view section.info{width:2428px}}div.centralRow{margin-bottom:40px;margin-top:40px}div.centralContent{background-color:transparent;height:100%;margin-left:-5px;margin-right:-5px;min-height:80px;padding:5px;width:100%}.contentDiv{list-style:none;padding:13px 0 0}.contentDiv li{background-color:rgba(0,0,0,.05)}.contentDiv a.add{display:block;font-weight:400;padding:40px 0;text-align:left}.modal-body th .valueCell,.modal-body th th.actionCell,.modal-body th th.keyCell,.waitModal{text-align:center}.contentDiv .icon{padding-left:5px;padding-right:5px;padding-top:10px}.contentDiv:after{clear:both}.contentDiv:after,.contentDiv:before{display:table;line-height:0}.clusterInfoIcon{float:left;padding-left:5px;padding-top:2px}.waitModal.icon{font-size:100px;height:120px}.waitModal.message{font-size:20px}.icon_arangodb_info{color:#333;font-size:23px}li a [class*=" icon_arangodb"],li a [class^=icon_arangodb]{font-size:18px;position:absolute;right:4px;top:2px}.fa-minus-circle{color:#da4f49;font-size:14pt}.fa-minus-circle:hover{cursor:pointer}div.headerDropdown{background-color:#fff;border-radius:3px;clear:both;display:none;padding:10px;position:relative;width:auto}div.headerDropdown.smallDropdown .dropdownInner{min-height:20px}div.headerDropdown.headerDropdown input[type=checkbox].css-checkbox{display:none}div.headerDropdown.headerDropdown input[type=checkbox].css-checkbox label.css-label{background-position:0 0;background-repeat:no-repeat;display:inline-block;font-size:15px;height:15px;margin-top:0;padding-left:20px;vertical-align:middle}div.headerDropdown.headerDropdown input[type=checkbox].css-checkbox:checked+label.css-label{background-position:0 -15px}div.dropdown-title{margin-bottom:10px}div.dropdownInner{-webkit-box-shadow:0;-moz-box-shadow:0;box-shadow:0;min-height:125px;position:relative;width:auto}div.dropdownInner .nav-header{font-size:10pt}div.dropdownInner>.nav-header{color:#000;font-size:10pt;font-weight:400}div.dropdownInner>label{color:#000;font-weight:300}div.dropdownInner ul{border-left:1px solid rgba(140,138,137,.25);display:inline;list-style-type:none;margin-top:10px;min-height:105px;width:230px}div.dropdownInner ul:first-of-type,div.queryline input[type=file]{border:0}div.dropdownInner ul label{color:#000;padding-left:20px}div.dropdownInner ul li .fa{color:#999;margin-right:5px}div.dropdownInner ul li .fa.fa-square-o{margin-left:1px;margin-right:6px}div.dropdownInner ul li .fa.fa-check-circle-o,div.dropdownInner ul li .fa.fa-check-square-o,div.dropdownInner ul li .fa.fa-dot-circle-o{color:#8aa051}div.queryline{color:#000;height:35px}div.queryline .textDiv{margin-right:10px;margin-top:4px}div.queryline input,div.queryline select{margin-bottom:5px}div.queryline.querylineAdd span{color:#fff;padding-left:10px;position:relative;top:-21px}div.queryline .removeFilterItem i{margin-left:5px!important;margin-top:0!important}div.queryline div.searchByAttribute{margin-left:6px;margin-right:6px;position:relative}div.queryline div.searchByAttribute>ul.gv-dropdown-menu{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;background-color:#fff;color:#fff;display:none;left:0;position:absolute;top:20px;width:247px}div.dropdownImport{background-color:#fff;border-radius:3px;display:none;position:relative;padding:10px 10px 5px}div.dropdownImport input{line-height:0;margin-bottom:-15px;margin-top:5px}select.filterSelect{color:#00f;margin-left:10px;margin-right:10px;width:100px}#filterHeader button{float:right;margin-left:10px!important;margin-top:1px}div.input-append button.gv_example_toggle{-moz-border-radius:0 4px 4px 0;-webkit-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0;background-color:#8f8d8c;height:30px;margin-left:-1px;padding-left:10px;padding-right:10px;padding-top:12px;vertical-align:top}div.input-append button.gv_example_toggle:hover{background-color:#8aa051}div.headerBar,div.headerBar .infoField{background-color:#fff;padding-left:5px;padding-right:5px}.searchEqualsLabel{margin-left:6px;margin-right:6px}img.gv-throbber{background-image:url(../img/swagger/throbber.gif)}span.gv_caret{border-top:5px solid #fff;margin-top:2px!important}input.search-input{height:14px;line-height:18px;margin-right:-1px;margin-top:6px;width:120px}.search-field{margin-left:10px}.search-field .fa-search{color:#c2c2c2;font-size:12pt;opacity:.5;position:absolute;right:9px;top:9px}.search-field .fa-search:hover{cursor:pointer;opacity:1}.gv-search-submit-icon,.search-submit-icon{background-image:url(../img/enter_icon.png);background-size:14px;height:14px;margin-left:-18px;opacity:.2;position:absolute;width:14px}.gv-search-submit-icon:hover,.search-submit-icon:hover{opacity:.8}.search-submit-icon{margin-top:11px}.gv-search-submit-icon{margin-top:6px}div.headerBar{border-radius:3px;color:#fff;font-size:16px;height:36px;margin-bottom:5px;margin-top:15px;position:relative}div.headerBar .infoField{border:1px solid rgba(140,138,137,.25);border-radius:3px!important;color:#000;float:right;font-size:12px;margin-right:7px;margin-top:7px}div.headerBar .infoField .fa{cursor:pointer;margin-left:5px}div.headerBar input[type=checkbox].css-checkbox{display:none}div.headerBar input[type=checkbox].css-checkbox label.css-label{background-position:0 0;background-repeat:no-repeat;cursor:pointer;display:inline-block;font-size:15px;height:15px;margin-top:0;padding-left:20px;vertical-align:middle}div.headerBar input[type=checkbox].css-checkbox:checked+label.css-label{background-position:0 -15px}div.headerBar input[type=radio]{display:none}div.headerBar input[type=radio] label span{background:url(../img/check_radio_sheet.png) -38px top no-repeat;cursor:pointer;display:inline-block;height:19px;margin:-1px 4px 0 0;vertical-align:middle;width:19px}#transparentHeader input[type=checkbox].css-checkbox,.arangoFrame,.contentTables tr.contentRowActive span,.display-none,.modal-delete-confirmation,.query-div,.query-output .ace_cursor-layer,.query-output .ace_replace_form{display:none}div.headerBar input[type=radio]:checked+label span{background:url(../img/check_radio_sheet.png) -57px top no-repeat}.headerButtonList a.error{color:#da4f49}.headerButtonList a.error:hover{background-color:#da4f49;border-color:#da4f49;color:#fff}.headerBar a.arangoHeader{color:#000;font-size:13pt;font-weight:100;left:0;position:relative;top:7px}.headerBar>div.headerButtonBar{margin:4px 0;margin-bottom:0!important}.breadcrumb{background:0 0;border:0;border-radius:0;padding:7px 0}.breadcrumb .disabledBread{color:#666;float:left;font-size:13pt;font-weight:100;padding-right:5px;position:relative}.breadcrumb .disabledBread i{font-size:10pt;margin-left:10px}.breadcrumb .activeBread{color:#8aa051;float:left;font-size:13pt;font-weight:100}.arangoHeader{font-weight:400}.checkboxLabel{margin-top:4px;padding-left:0}.css-label{background-image:url(../img/dark-check-green.png)}.css-label-round{background-image:url(../img/dark-check-green-round.png)}.modal-dashboard-header,.modal-header{background-color:#fff;border-bottom:0!important;border-radius:3px;margin-top:5px;padding-left:5px;padding-right:10px;padding-top:4px}.modal-dashboard-header .arangoHeader,.modal-header .arangoHeader{color:#000;font-size:13pt;font-weight:100;left:5px;position:relative;top:2px}.modal-dashboard-header a,.modal-header a{top:2px!important}.modal-dashboard-header .close,.modal-header .close{color:#fff;font-weight:300;margin-top:2px;opacity:.5}.modal-dashboard-header .close:hover,.modal-header .close:hover{opacity:1}.modal-tabbar{border-bottom:1px solid #666}.modal-body{color:#736b68;font-size:14px;font-weight:300;max-height:410px}.modal-body .select2-choices{background-image:none!important;border:1px solid #999;border-radius:3px;-webkit-box-shadow:none;box-shadow:none}.modal-body .select2-choices input:active{-webkit-box-shadow:none;box-shadow:none;outline:0!important}.modal-body .select2-choices .select2-search-choice{margin:5px 0 3px 5px!important}.modal-body .select2-choices li{background-color:#fff!important;background-image:none!important;color:#000}.modal-body tr.first,.modal-body tr.last,.modal-body tr.middle{background-color:#f5f8f0}.modal-body .select2-choices li a{margin-left:1px;margin-top:-1px}.modal-body .select2-choices:active{border:1px solid #999;-webkit-box-shadow:none!important;box-shadow:none!important;outline:transparent!important}.modal-body .nav-tabs{margin-top:15px}.modal-body .nav-tabs>li>a:hover{border-color:#8c8a89}.modal-body input,.modal-body select,.modal-body textarea{margin-top:10px}.modal-body input[type=checkbox]{margin-bottom:10px}.modal-body input[type=text].invalid-input{border-color:rgba(234,23,23,.6)}.modal-body input[type=text].invalid-input:focus{-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(234,23,23,.6);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(234,23,23,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(234,23,23,.6)}.modal-body input[type=file]{line-height:17px}.modal-body tr.spacer{height:10px}.modal-body tr.first th:first-child{border-top-left-radius:3px}.modal-body tr.first th:last-child{border-top-right-radius:3px}.modal-body tr.middle{padding-left:10px;padding-right:10px}.modal-body tr.last th:first-child{border-bottom-left-radius:3px}.modal-body tr.last th:last-child{border-bottom-right-radius:3px}.modal-body tr.first th:first-child,.modal-body tr.last th:first-child,.modal-body tr.middle th:first-child{padding-left:10px}.modal-body tr.first th:last-child,.modal-body tr.last th:last-child,.modal-body tr.middle th:last-child{padding-right:10px}.modal-body th.actionCell{width:30px}.modal-body th.keyCell{width:170px}.modal-body th.keyCell input{width:150px}.modal-body th .valueCell{width:300px}.modal-body th .valueCell input{width:290px}.modal-body th .select2-container{margin-bottom:10px;margin-top:10px}.modal-body .icon-info-sign{margin-bottom:10px;margin-left:10px;opacity:.7;padding-bottom:5px}.modal-body .icon-info-sign:hover{opacity:1}.modal-body .icon_arangodb_info{color:#736b68;font-size:18px;margin-top:-10px;position:absolute;right:12px}.modal-body .icon_arangodb_info:hover{color:#000}.modal-body .collapse{margin-right:-14px;position:relative}.modal-body .accordion-inner{border-top:0;margin-left:0;padding-left:0;padding-right:0}.modal-body .accordion-toggle span .caret{border-top-color:#000;float:right;margin-top:5px}.modal-body .accordion-toggle.collapsed span .caret{-ms-transform:rotate(90deg);-webkit-transform:rotate(90deg);transform:rotate(90deg)}.modal-body input{width:384px}.modal-body select{width:398px}.modal-body .collectionTh{height:50px}.modal-body .tab-content{min-height:200px}.modal-body .tab-content .tab-pane{border-top:1px solid #666!important;margin-left:0!important;padding-top:10px}.modal-body .tab-content .tab-pane-modal{border-top:none!important}.modal-body .tab-content #appstore{max-height:290px}.modal-body .errorMessage{background-color:#fff;color:#da4f49;font-size:9pt;font-weight:400;margin-bottom:5px;margin-top:-9px;position:absolute}.modal-body .nav .tab-icon{margin-right:5px;margin-top:-3px;width:20px}.modal-text{font-weight:300;padding-bottom:3px;padding-top:3px}.modal-backdrop,.modal-backdrop.fade.in{opacity:.4}.modal{border:0!important;border-radius:3px!important;box-shadow:0;width:580px}.modal .fade.in{top:12.1%!important}.modal table tr:last-child{border-bottom:0!important}.waitModal{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background:0 0;border:0;color:#fff}.waitModalBackdrop{opacity:.7!important}.modalTooltips span{color:#736b68;font-size:20px}.fixedDropdown .dropdown-header a,.fixedDropdown .notificationItem,.modalTooltips span:hover{color:#000}.gv-object-view{text-align:left;white-space:pre}.capitalize{text-transform:capitalize}.modal-footer{border-top:0!important;padding-right:17px}.modal-header{margin-left:5px;margin-right:5px}.modal-dashboard-header{margin-left:0;margin-right:0;padding-bottom:9px}.modal table tr,.thBorderBottom{border-bottom:1px solid #f7f3f2!important}.modal-delete-confirmation button{margin-right:10px;margin-top:-4px}.modal-delete-confirmation button .modal-confirm-delete{margin-right:-18px}.modal-delete-confirmation fieldset input{float:left}.modal-delete-confirmation fieldset label{float:left;margin-left:10px}.createModalDialog table{width:100%}.createModalDialog .collection-info-figures table{float:left;margin-left:0;margin-right:0;margin-top:0;min-width:200px;padding:3px;text-align:left}.createModalDialog .figures1,.createModalDialog .figures2{margin-bottom:20px;width:255px}.createModalDialog .figures2{margin-left:20px!important}.createModalDialog .figures3{margin-bottom:0;width:100%}.foxx-store-row .foxx-name{font-weight:700}.foxx-store-row .foxx-author{font-size:10pt;font-weight:300;margin-top:-4px}.foxx-store-row .foxx-version{font-weight:400}#new-app-mount{margin-right:24px;width:360px}#control_event_edge_delete_modal,#control_event_edge_edit_modal,#control_event_new_node_modal,#control_event_node_delete_modal,#control_event_node_edit_modal{margin-left:-320px;width:640px}.navlogo .stat_cpu,.navlogo .stat_ram{height:26px;width:26px}.navlogo .stat_cpu{margin-top:1px}.navlogo .stat_cpu path{fill:#aa0}.navlogo .stat_ram path{fill:#070}.navlogo .stat_req{height:22px;width:22px}.navlogo .stat_req path{fill:#aa0}#notification_menu .innerDropdownInnerUL{margin-left:0}#noty_bottom_layout_container li{border:0!important}.noty_bar .arango_message{font-weight:500!important}.noty_bar .arango_message div{float:right;width:20px}.fixedDropdown{background:#fff!important;border-color:rgba(140,138,137,.25)!important;border-radius:3px!important;margin:10px -3px 0!important;right:-1px!important;width:210px}.fixedDropdown .dropdown-header,.fixedDropdown .dropdown-item,.innerDropdownInnerUL{border-bottom:1px solid rgba(0,0,0,.2)}.contentButtons,.contentTables{margin-bottom:10px;width:100%}.fixedDropdown:after{visibility:hidden}.fixedDropdown .dropdown-header{margin-left:-1px;padding:0!important}.fixedDropdown a{padding-left:5px!important}.fixedDropdown .notificationItemContent{font-size:.9em;font-weight:300;margin-left:15px;max-width:180px;min-height:15px;white-space:normal;width:180px;word-wrap:break-word}.contentButtons #createDatabase,.contentButtons #createUser,.dashboard-bar-chart-container:first-child,.dashboard-full-width-chart .dashboard-full-width-chart-inner:first-child,.dashboard-large-chart .dashboard-large-chart-inner:first-child,.dashboard-medium-chart:first-child,.dashboard-small-chart .dashboard-small-chart-inner:first-child,.dashboard-tendency-container:first-child{margin-left:0}.fixedDropdown button{margin-right:5px;margin-top:5px}.fixedDropdown .notificationItem .notificationItemTitle{color:#000;font-weight:400;max-width:165px;overflow-wrap:break-word;white-space:normal;word-wrap:break-word}.fixedDropdown .notificationItem .notificationItemTitle:hover{background-color:transparent;cursor:default}.fixedDropdown .notificationItem i{color:rgba(0,0,0,.2);font-size:20px;padding-left:5px;position:relative;right:2px}.fixedDropdown .notificationItem i:hover{color:#000}.innerDropdownInnerUL{height:220px!important;min-height:220px;overflow-x:hidden;overflow-y:auto;width:100%}.innerDropdownInnerUL .dropdown-item:hover{background-color:#e1e1e1!important}.innerDropdownInnerUL li{width:auto!important}#stat_hd{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#fff;border:1px solid rgba(140,138,137,.25);height:25px;margin-top:3px;position:relative;right:3px;text-align:center;width:25px}#stat_hd #stat_hd_counter{color:#c2c2c2;line-height:25px;text-align:center}.fullNotification{background-color:#da4f49!important;border:1px solid #da4f49!important}.fullNotification p{color:#fff!important}.contentTables tr.contentRowActive a,.contentTables tr.contentRowInactive a{color:#000!important}.contentButtons{clear:both}.contentTables thead{text-align:left}.contentTables thead tr{background-color:#fff;border-bottom:1px solid #c2c2c2}.contentTables tbody tr:nth-child(odd){background-color:#d9d9d9}.contentTables tbody tr:nth-child(even){background-color:#fff}.contentTables tr.contentRowActive{background-color:#bdcc92!important;font-weight:400}.contentTables .dbThFirst{width:90%}.contentTables .dbThSecond{width:10%}.contentTables td{padding:12px 18px}.contentTables td span{float:right;font-size:22px}.contentTables .collectionThSec{margin-right:0;width:80%}.contentTables .collectionTh{margin-right:0;width:5%}.user-menu-img{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#fff;border:1px solid rgba(140,138,137,.25);height:25px;margin-top:-4px}.ui-tooltip{background-color:#8aa051!important;border:0!important;border-radius:3px!important;box-shadow:none!important;color:#fff!important;font-size:10pt!important;font-weight:100!important;z-index:99999999}.dataNotReadyYet,.dygraph-label.dygraph-title{font-family:'Open Sans',sans-serif}.tooltip-inner{max-width:300px!important;white-space:normal!important;word-wrap:break-word!important}.index-tooltip{color:#736b68}.index-tooltip:hover{color:#000}.index-tooltip .arangoicon{font-size:18px!important}.tooltipInfoTh{width:10%}.dbselection{float:left;margin-right:3px;max-width:160px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dashboard-bar-chart-container,.dashboard-full-width-chart .dashboard-full-width-chart-inner,.dashboard-large-chart .dashboard-large-chart-inner,.dashboard-medium-chart,.dashboard-small-chart .dashboard-small-chart-inner,.dashboard-tendency-container{border-top-left-radius:3px;border-top-right-radius:3px}.dashboard-bar-chart-container,.dashboard-full-width-chart,.dashboard-large-chart,.dashboard-medium-chart,.dashboard-small-chart,.dashboard-tendency-container{margin-bottom:10px;position:relative}.dashboard-sub-bar-menu{cursor:pointer;position:absolute;right:9px;top:6px}.dataNotReadyYet{font-size:20px;font-weight:100;text-align:center}.dashboard-sub-bar{background-color:#686766;border-bottom-left-radius:3px;border-bottom-right-radius:3px;color:#fff;height:24px;line-height:24px;margin:0;padding:0 6px}.dashboard-full-width-chart{border:1px solid rgba(104,103,102,.1);border-radius:3px;margin-right:12px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;padding-bottom:10px;padding-top:12px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-subtitle-bar.top{border-bottom:1px solid #e1e1e1;height:48px;line-height:48px;text-align:right}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{border-left:1px solid #e1e1e1}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner{margin-left:10px;margin-right:10px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table{margin-bottom:10px;margin-top:10px;table-layout:fixed;width:100%}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart,.dashboard-medium-chart .dashboard-interior-chart{margin-bottom:0}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table .no-data{font-style:italic;font-weight:100}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table tr{border-bottom:1px solid rgba(0,0,0,.025)}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table td:first-child{width:100px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table td:last-child{text-align:right}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart:first-child{border-left:0}.dashboard-full-width-chart .state{background-color:#fff;border-radius:5px;color:#000;margin-left:5px;padding-left:6px;padding-right:4px}.dashboard-large-chart{border:1px solid rgba(104,103,102,.1);border-radius:3px;margin-right:12px}.dashboard-large-chart .dashboard-large-chart-inner{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;padding-bottom:10px;padding-top:12px}.dashboard-small-chart{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-small-chart .dashboard-small-chart-inner{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;padding-bottom:10px;padding-top:5px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-bar rect{fill-opacity:.15;stroke-opacity:.8;stroke-width:.5px}.dashboard-medium-chart-outer{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-medium-chart-outer:first-child{margin-right:10px}.dashboard-medium-chart{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;margin-bottom:0;padding-top:10px}.dashboard-medium-chart:first-child{margin-right:12px}.dashboard-medium-chart .dashboard-medium-chart-outer{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-medium-chart .dashboard-medium-chart-menu{-moz-border-radius:2px;-webkit-border-radius:2px;border-radius:2px;border:0 solid rgba(0,0,0,.3);color:rgba(0,0,0,.3);cursor:pointer;padding:0 4px;position:absolute;z-index:1000}.dashboard-medium-chart .dashboard-medium-chart-menu:hover{color:rgba(0,0,0,.7)}.dashboard-medium-chart .dashboard-medium-chart-inner{padding-bottom:10px}.dashboard-medium-chart .clusterChart .slice path{fill-opacity:.15;stroke-opacity:1;stroke-width:1.5px}.dashboard-tendency-container{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-tendency-container .dashboard-tendency-chart{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;border-top-left-radius:3px;border-top-right-radius:3px;padding-bottom:5px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{background-color:#fff;margin-top:5px;padding:0 8px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency:first-child{border-right:1px solid #e1e1e1}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency .dashboard-subtitle-bar{border-bottom:1px solid #e1e1e1;text-align:right}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency .dashboard-figure{text-align:center}.dashboard-bar-chart-container{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-bar-chart-container .dashboard-bar-chart{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;border-top-left-radius:3px;border-top-right-radius:3px;padding-bottom:5px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{margin-top:5px;padding:0 8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{font-weight:400}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{text-align:right}#dashboardDetailedChart .dygraph-axis-label-y,.dashboardDetailChart .dygraph-axis-label-y,.innerDashboardChart .dygraph-axis-label-y{text-align:left}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart .nv-bar rect{fill-opacity:.15;stroke-opacity:.8;stroke-width:.5px}.dashboard-legend .dashboard-legend-inner{padding:0 5px 5px 0}.dashboard-spacer{margin:0 12px}.headerBar.dashboard-headerbar{margin:20px 0}.modal-chart-detail .modal-dashboard-legend .dashboard-legend-inner{padding-left:20px}.dashboard-half-height-legend .dashboard-legend-inner{padding-top:20px}.dashboard-title-bar{background-color:#686766;color:#fff;font-size:14.5px;font-weight:400;height:30px;line-height:30px;padding:0 5px 0 10px}.dashboard-title-bar .dashboard-half-title-bar{border-left:1px solid #000;margin-left:-1px;width:50%}.dashboard-title-bar .dashboard-half-title-bar:first-child{border-left:0;margin-left:0}.dashboard-row{margin-bottom:0;margin-left:0;margin-right:0}.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{color:#666}.dashboardModal{-moz-border-radius:8px!important;-webkit-border-radius:8px!important;border-radius:8px!important;height:80%;margin-left:-45%;min-width:780px;overflow:auto;padding:10px;top:10%;width:90%!important}#dashboardHttpGroup{border:6px solid #000;height:100%;width:100%}#dashboardDetailedChart{border:1px solid #000;height:300px;width:100%}.innerDashboardChart{bottom:5px;left:5px;position:absolute;right:5px;top:5px}.dashboardChart{background-color:#fff;border:1px solid rgba(0,0,0,.2);float:left;height:210px;margin:1.05%;position:relative;width:31%}.dygraph-label.dygraph-title{color:#000;font-size:15px;font-weight:400;text-align:left}.collectionInfoTh2,.collectionTh,.figuresHeader th{font-family:'Open Sans',sans-serif!important}#dashboardDetailedLineChart{padding-top:10px}.dashboardDistribution{float:left;width:270px}.dashboardDistribution svg{height:220px;width:250px}.showHotkeyHelp{cursor:pointer}.shortcuts{font-size:14px;font-weight:200}.shortcuts b{border-left:1px solid rgba(0,0,0,.34);margin-left:5px;padding-left:5px}.shortcuts .clearShortcut,.shortcuts b:first-child{border-left:0;margin-left:0;padding-left:0}.loginFixedWindow{background:#f5f8f0;height:100%;left:0;position:fixed;top:0;width:100%;z-index:9999}.loginFixedWindow .resizecontainer{position:relative;top:0}.loginFixedWindow .resizecontainer img{height:33px;margin-left:-6px;margin-top:9px}.login-window{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;height:auto;left:50%;margin-left:-220px!important;margin-top:-150px;padding:10px;position:absolute;top:50%;width:400px}.login-window .fa{color:rgba(0,0,0,.4);float:right;font-size:14pt;margin-right:5px;margin-top:-34px}.login-window .wrong-credentials{color:#da4f49;margin-top:-30px;text-align:center}.login-window .login-space{height:50px}.login-window .login-input{width:387px}.login-window .form-error{border:1px solid #da4f49!important}toolbar{background-color:#f0f0f0;border-bottom:0;border-style:solid;border-width:1px;font-size:20px;height:27px;margin-left:0;margin-right:0}toolbar span:hover{background-color:#da4f49;color:#fff}.queryBottomActions{border-top:1px solid rgba(140,138,137,.25);padding:10px}.queryExecutionTime{margin-left:10px;margin-top:15px}#queryManagementContent{margin-top:18px}.queryManagementBottomActions{background-color:#fff;border-bottom-left-radius:3px;border-bottom-right-radius:3px;border-top:1px solid #c2c2c2;height:40px;margin-top:-2px;padding-top:10px}.queryMethods,.vars-editor-header{border-top:1px solid rgba(140,138,137,.25)}.queryManagementBottomActions button{margin-right:10px}.queryMethods{padding:10px 10px 5px}.queryMethods input{line-height:0;margin-top:5px}.queryMethods button a{color:#fff}.vars-editor-header{margin-top:-5px;padding-left:5px}.vars-editor-header i{border-radius:2px;color:#666;height:15px;margin-left:5px;padding-left:3px;padding-top:1px;width:15px}.vars-editor-header i:hover{background-color:#8aa051;color:#fff;cursor:pointer}.aql-editor,.vars-editor{border-color:#a0a0a0;border-left:0!important;border-top:1px solid rgba(140,138,137,.25)!important;height:200px;margin-bottom:5px;min-height:100px;min-width:99.8%;width:auto}.aql-editor .ace_error,.aql-editor .ace_info,.vars-editor .ace_error,.vars-editor .ace_info{background:0 0}.queryTH{width:20%!important}.queryTH2{width:75%!important}.query-output{background-color:#fff;border:0;border-top-width:0;height:200px;margin-left:0;margin-right:0;min-height:100px;overflow-y:hidden;width:auto}.query-output .ace_error,.query-output .ace_info{background:0 0}.ace_print-margin{visibility:hidden!important}#documentsTableID_filter,#documentsTableID_length,#documentsTableID_paginate,#documentsTableID_wrapper .fg-toolbar,.jsoneditor .outer .tree>table>tbody>tr:first-of-type{visibility:hidden}.styled-select{float:right;height:30px;overflow:hidden;width:220px}.styled-select select{background:#fff;border:1px solid #c2c2c2!important;border-radius:3px!important;font-size:14px;font-weight:300;height:30px;line-height:1;padding:5px;padding-left:5px!important;padding-top:3px!important}.querySizeDiv,.querySizeDiv select{height:30px!important}.query-select,.query-size{line-height:20px!important;z-index:9999!important}.querySizeDiv{margin-right:10px;width:130px!important}.wide-button-div{height:36px;margin-bottom:15px;margin-top:-10px;padding-top:5px;width:100%}.shortcut-div{float:left;margin-top:-5px;padding-left:45px;width:auto}.query-dropdown-left{margin-top:10px;width:100%}.query-dropdown-right{width:100%}.query-dropdown-right textarea{padding:5px 0 0;resize:vertical;width:100%}.query-dropdown-right textarea:focus{border-color:#8aa051;box-shadow:0 0 3px #8aa051;outline:0}.query-modal-select{padding-left:0;width:100%}.output-toolbar{border-color:silver;border-top:0;position:relative;width:auto}.output-toolbar span{float:right;margin-left:5px;margin-right:5px;position:relative;top:2px}.query-select{border:0!important;border-radius:0!important;margin-bottom:0}.query-select option{z-index:9999!important}.query-dropdown{background-color:#d9d9d9;margin-left:0;margin-right:0;padding-left:5px;padding-right:5px}.tooltip-margin{margin-top:1px}.query-dropdown-in{background-color:#fff;padding:10px}.query-dropdown-in a{color:#686766;font-size:16px;font-weight:bolder;margin-bottom:5px;width:100%}.query-dropdown-in #save-edit-query{margin-left:7px!important}.query-dropdown-in #delete-edit-query{margin-left:0!important}.query-size{border-radius:0!important;width:130px!important}.query-div .arango-table,.query-div .arango-table tbody,.query-div .arango-table tr{max-width:100%;width:100%}#queryContent{margin-top:18px}#queryContent .arango-tab a{border-bottom-color:#ddd;font-weight:100}#queryContent .arango-tab .active{border-bottom-color:#fff!important}.query-div{min-height:360px}.query-div .ace-tm .ace_comment{color:#8aa051}.query-div .icon_arangodb{cursor:pointer;margin-bottom:5px}.query-div .arango-table{border-top:1px solid rgba(140,138,137,.25);table-layout:fixed}.query-div .arango-table .table-cell0{cursor:pointer;min-width:250px;overflow:hidden;text-overflow:ellipsis!important;white-space:nowrap!important;width:20%}.query-div .arango-table .table-cell1,.query-div .arango-table .table-cell2{overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}.query-div .arango-table .table-cell1{cursor:pointer;width:73%}.query-div .arango-table .table-cell2{max-width:40px;min-width:40px;width:40px}.arangoDataTable .key,div.gv-colour-list li{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.queryImport{margin-bottom:10px}.explain-tree,.tab-content{width:100%}.explain-tree .node text{font-size:14px}.explain-tree .link{fill:none;stroke:#ccc;stroke-width:1.5px}.editor-toolbar{border-color:#a0a0a0;height:33px;margin-top:5px}.editor-toolbar span{border-radius:3px;float:right;height:18px;margin-left:3px;position:relative;top:0;width:25px;padding:3px 0 6px 5px}.editor-toolbar .vars-editor-header i,.editor-toolbar span:hover{background-color:#8aa051;color:#fff}.editor-toolbar i{margin-right:5px;margin-top:3px}.editor-toolbar i:hover{cursor:pointer}.editor-toolbar .fa{color:#666;margin-left:1px;margin-top:2px}.editor-toolbar .arango-icon-disk,.editor-toolbar .fa.fa-upload{margin-top:1px}.editor-toolbar .icon_arangodb{color:#666;font-size:14pt}.editor-toolbar .icon_arangodb:first-child{margin-right:10px}.editor-toolbar .fa-comment,.editor-toolbar .fa-comment-o{font-size:15px;position:relative;right:-2px;top:-2px}.row{margin:0 0 20px}.innerContent{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;min-height:200px;padding-top:13px}.arangoFrame{background-color:rgba(0,0,0,.5);bottom:0;left:0;position:fixed;right:0;top:0;z-index:77777}.arangoFrame .outerDiv{min-height:100%;padding:40px;z-index:88888}.arangoFrame .innerDiv{z-index:99999}.arangoFrame .fa-times{color:#fff;float:right;font-size:12pt}.arangoFrame .fa-times:hover{color:#c2c2c2;cursor:pointer}.container{margin-left:20px;margin-right:20px;width:auto!important}.arango-tab{border-bottom:1px solid #ddd;list-style:none;margin-left:0;padding-bottom:0;padding-right:10px}.arango-tab a{-moz-border-radius:0;-webkit-border-radius:0;border-radius:3px 3px 0 0;background-color:#8c8a89;border:1px solid transparent;border-bottom-color:#888;color:#fff;display:block;font-size:13px;line-height:20px;margin-right:2px;min-width:50px;padding:2px 15px;text-align:center}.arango-tab li{background-color:transparent;border:0;margin-bottom:-1px;margin-left:2px;position:relative;z-index:900}.arango-tab li.active a{background:#fff;border-bottom-color:#fff!important;border-left-color:#c2c2c2;border-right-color:#c2c2c2;border-top-color:#c2c2c2;color:#000;height:21px;margin-top:-1px}.jsoneditor,.jsoneditor .menu{background-color:#fff!important}.jsoneditor{border:0 solid rgba(0,0,0,.2)!important}.jsoneditor .menu{border-bottom:1px solid #c2c2c2!important;border-left:0!important;border-right:0!important;border-top:0!important}.jsoneditor .menu button{border:0!important}.jsoneditor .menu button:hover{background-color:#8aa051;color:#fff}.jsoneditor .search .frame{border:0!important;margin:3px!important}.jsoneditor .search .frame input{border:1px solid #c2c2c2!important;border-radius:3px;margin-left:5px;margin-right:5px;margin-top:-2px}.jsoneditor .search .results{color:#fff!important;margin-top:3px!important}.document-editor-extra,div.gv-manage-button-container{margin-top:10px}.document-editor{height:500px;margin-bottom:5px;margin-top:-10px;width:100%}.disabledPag,.disabledPag a{cursor:default!important;opacity:.5!important}.pagination-line{background-color:#fff;border-bottom-left-radius:3px;border-bottom-right-radius:3px;border-top:1px solid rgba(104,103,102,.1);margin:0;padding-top:12px;text-align:center}.pagination-line li a:hover,.pagination-line li.active a,.pagination-line li.active span{background-color:#8f8d8c;color:#fff}.pagination-line li a{background-color:#fff;border:1px solid #fff;font-size:11.9px;line-height:20px;padding:2px 10px;text-decoration:none;border-width:0;min-width:12pt}.pagination-line ul{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;display:inline-block;margin-bottom:0;margin-left:0}.pagination-line li{display:inline-block;margin-left:11px}.pagination-line li span{color:#000;font-size:14px;position:relative;top:2px}.pagination-line li:first-child a,.pagination-line li:first-child span,.pagination-line li:last-child a,.pagination-line li:last-child span{-webkit-box-shadow:0;-moz-box-shadow:0;box-shadow:0;background:#8f8d8c;border:0;color:#000;height:21px;position:relative;width:14px}.pagination-line li.disabled:first-child a,.pagination-line li.disabled:first-child span,.pagination-line li.disabled:last-child a,.pagination-line li.disabled:last-child span{background-color:#777;color:#666;cursor:default;pointer-events:none}.collection-pagination{margin-left:23px!important}.arango-pagination i.fa,.las-pagi i.fa,.pre-pagi i.fa{font-size:19px;position:relative;top:-2px}.arango-pagination li:first-child{margin-right:20px}.arango-pagination li:last-child{margin-left:30px}.pre-pagi{margin-right:-5px!important}.accordion-group{border:0}.accordion-body{height:auto!important}.accordion-heading a{border:1px solid #ccc;color:#000;font-weight:400;width:397px!important}.shell_workspace{margin-top:13px}.shell_workspace ::-webkit-scrollbar{display:none}.replShell{background-color:#fff;float:left;height:100%;min-width:100px;overflow-y:hidden;position:relative;width:100%}.replShell>div{border-radius:3px}.replShell pre{border-bottom:0;border-left:0;border-right:1px solid #a0a0a0;border-top:1px solid #a0a0a0}.jqconsole{background-color:#000;border-radius:0;padding:10px}.jqconsole-header{color:#fff}.jserror{color:#f06;margin-left:-10px}.jssuccess{color:#6f0}.jqconsole-cursor{background-color:grey}.jqconsole-blurred .jqconsole-header .jqconsole-cursor{color:#c4cccc}.jqconsole-prompt{color:#b91}.jqconsole-old-prompt{color:#f60;font-weight:400}.jqconsole-input{color:#dd0}.jqconsole-old-input{color:#bb0;font-weight:400}.jqconsole-output{color:#fff}.query-output .ace_gutter-cell{background-color:#f0f0f0}.centralContent .api-actions{margin:0!important;padding:0}.centralContent .api-actions .container{padding-bottom:10px!important;padding-top:13px!important;margin:0 5px!important}.centralContent .api-actions .resource{border-bottom:0!important;padding-left:5px!important}.centralContent .api-actions .resource .heading>.options{margin:11px 10px 0 0!important}.centralContent .api-actions .resource .heading h2 a{color:#000!important;font-weight:300!important}.centralContent .api-actions .active .heading h2 a{color:#000!important}.centralContent .api-actions .endpoint .operations .content{margin:0!important}.centralContent .api-actions .endpoint .operations .content h4{font-weight:700!important}.centralContent .api-actions .endpoints{margin-right:5px!important}.centralContent .api-actions .endpoints .endpoint:last-child{padding-bottom:5px!important}.centralContent .api-actions input[type=button]{background:#8f8d8c!important;border:none!important;box-shadow:none!important;color:#fff!important;float:right!important;font-size:14px!important;font-weight:300!important;margin-top:10px!important;padding:8px 16px!important}.centralContent .api-actions .endpoint .operations .content,.centralContent .api-actions .endpoint .operations .heading{border-radius:0!important;font-weight:300!important}.centralContent .api-actions .required,.centralContent .api-actions em,.centralContent .api-actions strong,.collectionInfoTh2,.collectionTh,.figuresHeader th{font-weight:400!important}.centralContent .api-actions .http_method,.centralContent .api-actions .toggleOperation{border-radius:0!important}.form-actions{background:0 0;border:0}.form-actions:after,.form-actions:before{display:table;line-height:0}.form-actions:after{clear:both}.swagger-section #swagger-ui-container{margin:.3em 1em!important}.alert{padding:15px 35px 15px 14px}.alert,textarea{border-radius:0!important}.log-content{word-break:break-all;word-wrap:break-word}.log-content-id{margin-top:20px;padding-bottom:0!important}.log-content-id .dataTable{border-collapse:separate;border-spacing:0 5px;table-layout:fixed!important}.log-content-id .arango-tab{border-bottom:0!important}.log-content-id .tab-content{margin-top:1px!important}.tab-content{min-height:390px}.crit-table-id,.debug-table-id,.info-table-id,.log-table-id,.warn-table-id{border-spacing:0 0;font-size:15px!important;margin-top:-5px!important}.crit-table-id thead,.debug-table-id thead,.info-table-id thead,.log-table-id thead,.warn-table-id thead{background-color:#f9f9f9;border-top:6px solid #888!important;text-align:center}.crit-table-id thead tr th,.debug-table-id thead tr th,.info-table-id thead tr th,.log-table-id thead tr th,.warn-table-id thead tr th{background-color:#fff!important;border-bottom:1px solid #c2c2c2;border-top:2px solid #888}.crit-table-id .firstcol,.debug-table-id .firstcol,.info-table-id .firstcol,.log-table-id .firstcol,.warn-table-id .firstcol{cursor:default!important;max-width:80px!important;width:80px!important}.crit-table-id tbody .firstcol,.debug-table-id tbody .firstcol,.info-table-id tbody .firstcol,.log-table-id tbody .firstcol,.warn-table-id tbody .firstcol{background-color:transparent!important}.crit-table-id tbody tr td,.debug-table-id tbody tr td,.info-table-id tbody tr td,.log-table-id tbody tr td,.warn-table-id tbody tr td{padding-bottom:8px!important;padding-top:8px!important}.thirdcol{cursor:default!important;max-width:500px!important}.dataTables_empty,.seccol{cursor:default!important;margin-bottom:5px;width:100px!important}.dataTables_info{display:none}#arangoLogTable tbody td:nth-child(1),#arangoLogTable tbody td:nth-child(2){text-align:center;width:80px}#arangoLogTable tbody td:nth-child(3){width:auto}div.gv_zoom_widget{height:300px;left:64px;opacity:.7;position:absolute;top:20px;width:40px;z-index:1}div.gv_zoom_widget div.gv_zoom_buttons_bg{background-image:url(../img/gv_button_bg_reverse.png);background-size:contain;height:40px;margin-bottom:20px}div.gv_zoom_widget div.gv_zoom_slider{background:#f5f8f0;border-radius:3px;height:200px;margin:0 17px;width:4px}div.gv_zoom_widget a.ui-slider-handle{background-color:#555;border:1px solid rgba(140,138,137,.25);height:.5em;left:-.55em;outline:0}div.gv_zoom_widget a.ui-slider-handle.ui-state-hover{outline-color:#fff}div.gv_zoom_widget a.ui-slider-handle:hover{cursor:pointer}div.gv_zoom_widget .ui-state-default{background:#f6f6f6}#menubar{margin:0 0 10px}div.gv_colour_list{max-height:680px;overflow:auto;position:absolute;right:26px;text-align:right;top:20px;z-index:1}div.gv_colour_list li{background-color:transparent;float:none;padding:2px 6px}svg.graph-viewer{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;left:54px;position:absolute;top:10px;z-index:0}div.gv-colour-list ul ul,div.gv-colour-list ul ul:first-child,div.gv-colour-list ul ul:last-child{border-left:1px solid rgba(104,103,102,.1);border-right:1px solid rgba(104,103,102,.1)}svg.graph-viewer text{max-width:90px;pointer-events:none}div.gv-background{position:relative}.link>line{stroke-width:1}div.gv-colour-list:hover{opacity:1}div.gv-colour-list{border-radius:3px;max-height:350px;max-width:300px;min-width:190px;opacity:.1;overflow-x:hidden!important;overflow-y:auto;position:absolute;right:8px;text-align:right;top:20px;z-index:1}div.gv-colour-list li{float:none;padding:2px 6px}div.gv-colour-list ul ul:first-child{border-top:1px solid rgba(104,103,102,.1);border-top-left-radius:3px;border-top-right-radius:3px}div.gv-colour-list ul ul:last-child{border-bottom:1px solid rgba(104,103,102,.1);border-bottom-left-radius:3px;border-bottom-right-radius:3px}legend.gv-inner{font-size:16px}input.gv-radio-button{display:block;margin-top:3px;width:auto}.addCollection .accordion,.collectionTh select,.collectionTh textarea{margin-top:10px}.collectionTh{font-size:14px;text-align:left;width:20%!important}.collectionInfoTh{min-width:60px;text-align:left;width:320px}.addCollection table tr{border-bottom:0!important;height:53px}.addCollection .icon_arangodb_info{margin-left:20px!important;position:relative;top:2px!important}.addCollection .collectionThSec{width:320px!important}.addCollection .collectionTh{width:96px}.addCollection .modalInput{width:320px}.addCollection .modalSelect{width:334px}.addCollection .accordion-toggle{width:457px!important}.change-collection .tab-content{min-height:230px}.change-collection input{width:384px!important}.change-collection select{width:398px!important}.show-collection .tab-content{min-height:200px}.collectionInfoTh2{text-align:left;width:150px}.collection-info-figures table{float:left;margin-left:0;margin-right:0;margin-top:0;min-width:200px;padding:3px;text-align:left}.figuresHeader{border-bottom:1px solid #c2c2c2}.document-info .document-bold-font,.document-info .document-thin-font{font-family:droid sans mono,monospace,courier new,courier,sans-serif;font-size:11pt}#collectionIndexTable{margin-left:0;width:100%}#collectionTab,#graphTab,#infoTab{border-bottom:0;margin-bottom:1px;padding-bottom:0;padding-right:10px}#collectionTab li,#graphTab li,#infoTab li{float:right}#collectionTab li.disabled a,#graphTab li.disabled a,#infoTab li.disabled a{cursor:not-allowed}#collectionTab a,#graphTab a,#infoTab a{background-color:#8c8a89;border-bottom:1px solid #666;border-top-left-radius:3px!important;border-top-right-radius:3px!important;color:#fff;font-size:13px!important;height:21px;margin-bottom:-1px;margin-right:4px;padding:2px 15px!important}#collectionTab .active>a,#graphTab .active>a,#infoTab .active>a{background-color:#fff;border-color:#888 #888 transparent!important;color:#000}#confirmCreateEdge{margin-left:20px}.collection-info-figures .icon_arangodb_info{position:relative!important;right:-4px!important}.snippet-wrap .snippet-num li{list-style:decimal-leading-zero}.snippet-no-num{list-style-type:none;padding-left:0}.snippet-no-num .prettify{font-size:1.2em}.snippet-no-num .sh_number{color:#044;font-weight:100;margin-left:5px}.snippet-no-num .sh_symbol{color:#00f;font-weight:100;margin-left:5px}.snippet-no-num .sh_cbracket{color:#c7a317;font-weight:100;margin-left:5px}.snippet-no-num .sh_keyword{color:#c12dad;font-weight:100;margin-left:5px}.snippet-no-num .sh_string{color:#ce2f30;font-weight:100;margin-left:5px}.snippet-no-num .sh_array,.snippet-no-num .sh_object{color:#00f;font-weight:100;margin-left:5px}@media (max-width:738px){.arango-collection-ul{display:none}.collection-dropdown ul{width:auto!important}.arango-collection-select{display:inline-block}}@media (min-width:739px) and (max-width:1041px){.arango-collection-ul a{font-size:11px;padding:7px 5px 10px}}@media (min-width:1042px) and (max-width:1284px){.arango-collection-ul a{font-size:13px}}#documentsDiv{padding-top:1px}.document-info-div{margin-top:20px;min-height:0}.document-content-div{margin-top:10px}.document-info{background-color:#fff;border-radius:3px;margin-bottom:8px;margin-top:-13px;min-height:65px;padding:5px}.document-info .document-info-container{clear:both;width:100%}.document-info .document-info-container .document-inner-info-container{float:left;margin-left:10px;margin-top:5px}.document-info .document-info-container .document-inner-info-container .document-attribute{margin-right:20px}.document-info .document-info-container .document-inner-info-container .document-attribute div{float:left}.document-info .document-bold-font{min-width:55px}.document-info .document-thin-font{color:#8aa051}.document-info .document-type-container div{float:left}.document-info .document-type-container #document-id{margin-left:10px}.document-link:hover{cursor:pointer;text-decoration:underline}.jsoneditor .tree div{font-size:11pt}#progressPlaceholder{background-color:rgba(0,0,0,.4);bottom:0;left:0;position:fixed;right:0;top:0;z-index:9999}.progress-view{background-color:#363c39;border-radius:2px;color:#fff;height:188px;left:50%;margin:-100px 0 0 -150px;position:absolute;top:50%;width:300px}.progress-view .progress-content{margin-left:90px;margin-top:10px}.progress-view .progress-content .fa-spinner{font-size:100pt}.progress-view .progress-message{background-color:#fff;border-radius:0 0 2px 2px;color:#fff;font-weight:200;height:44px;margin-top:33px;padding-top:3px;text-align:center}.progress-view .progress-text{color:#000;float:left;margin-left:5px;margin-top:10px}.progress-view .progress-action{float:right;margin-right:5px;margin-top:5px}#progressPlaceholderIcon{color:#8aa051;float:left;font-size:22px;margin-left:10px;margin-top:7px}.pong-loader{margin-left:17px;margin-top:35px}@-moz-keyframes pong-loader{0%{left:5px;top:0}25%{left:65px;top:20px}50%{left:5px}62.5%{top:50px}75%{left:65px;top:70%}100%{left:5px;top:0}}@-webkit-keyframes pong-loader{0%{left:5px;top:0}25%{left:65px;top:20px}50%{left:5px}62.5%{top:50px}75%{left:65px;top:70%}100%{left:5px;top:0}}@keyframes pong-loader{0%{left:5px;top:0}25%{left:65px;top:20px}50%{left:5px}62.5%{top:50px}75%{left:65px;top:70%}100%{left:5px;top:0}}@-moz-keyframes pong-loader-paddle-1{0%{-moz-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}25%{-moz-box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-moz-box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-moz-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-moz-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@-webkit-keyframes pong-loader-paddle-1{0%{-webkit-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}25%{-webkit-box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-webkit-box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-webkit-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-webkit-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@keyframes pong-loader-paddle-1{0%{-moz-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}25%{-moz-box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-moz-box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-moz-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-moz-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@-moz-keyframes pong-loader-paddle-2{0%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-moz-box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-moz-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-moz-box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@-webkit-keyframes pong-loader-paddle-2{0%{-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-webkit-box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-webkit-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-webkit-box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@keyframes pong-loader-paddle-2{0%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-moz-box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-moz-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-moz-box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}}.pong-loader:not(:required){-moz-animation:pong-loader-paddle-1 1.5s infinite linear;-webkit-animation:pong-loader-paddle-1 1.5s infinite linear;animation:pong-loader-paddle-1 1.5s infinite linear;background:#353c39;-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;display:inline-block;height:60px;overflow:hidden;position:relative;text-indent:100%;width:80px}.pong-loader:not(:required):after,.pong-loader:not(:required):before{display:block;position:absolute;top:0;width:10px;left:0;content:''}.pong-loader:not(:required):before{-moz-animation:pong-loader-paddle-2 1.5s infinite linear;-webkit-animation:pong-loader-paddle-2 1.5s infinite linear;animation:pong-loader-paddle-2 1.5s infinite linear;-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;height:100%}.pong-loader:not(:required):after{-moz-animation:pong-loader 1.5s infinite linear;-webkit-animation:pong-loader 1.5s infinite linear;animation:pong-loader 1.5s infinite linear;background:#8cdb8b;-moz-border-radius:50%;-webkit-border-radius:50%;border-radius:50%;height:10px}.application-detail-view section.info{float:left;padding:13px 0 0}.application-detail-view section.info .header{height:200px;margin-bottom:0;position:relative}.application-detail-view section.info .header div.header-icon-container{border-radius:3px;height:182px;left:0;margin:0 0 4px;position:absolute;width:182px}.application-detail-view section.info .header div.header-icon-container img.icon{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;height:auto;max-height:160px;max-width:160px;padding:10px;width:auto}.application-detail-view section.info .header .header_right{padding-top:1px;position:absolute;right:-10px;width:150px}.application-detail-view section.info .header .header_right input.delete,.application-detail-view section.info .header .header_right input.switch-docu,.application-detail-view section.info .header .header_right input.switch-mode,.application-detail-view section.info .header .header_right input.upgrade{margin-top:7.83px;padding-left:10px;padding-right:10px}.application-detail-view section.info .header .header_right input{width:130px}.application-detail-view section.info .header .header_left{margin-left:190px;margin-right:145px;padding-left:10px;padding-top:1px}.application-detail-view section.info .header .header_left input{margin-left:0;margin-top:-4px}.application-detail-view section.info .header .header_left .header_line h3{float:left;margin-bottom:0;margin-top:0;padding-right:5px}.application-detail-view section.info .header .header_left .header_line .license,.application-detail-view section.info .header .header_left .header_line .version{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#fff;border:1px solid rgba(140,138,137,.25);color:#a0a0a0;font-size:.6em;font-weight:400;padding:0 8px 2px;position:relative;top:-3px}.application-detail-view section.info .header .header_left .header_line:after{clear:both;content:'';display:table}.application-detail-view section.info .header .app-warning{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background:#da4f49;color:#fff;padding:6px 8px}.application-detail-view section.info .header .app-warning h4,.application-detail-view section.info .header .app-warning p{font-size:1em;margin:0}.application-detail-view aside.meta{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;clear:right;float:left;height:182px;margin-top:12px;max-height:182px;max-width:182px;overflow-x:hidden;position:relative;right:-16px;width:182px}.application-detail-view aside.meta dl{margin-bottom:0;margin-top:0;padding-left:7px;padding-top:5px}main{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;margin-top:220px}main .app-info{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background:#5bc0de;color:#fff;margin:10px;padding:6px 8px}main .app-info h4,main .app-info p{font-size:1em;margin:0}main .swagger iframe{border:0;border-radius:3px;height:600px;width:100%}main .readme{background:#fff;padding:1em 2em}.tests-result .stack{border-color:#da4f49;color:#da4f49;font-size:12px;line-height:1.5;margin:5px 0}.tests-result-stats .fail,.tests-result-stats .pass,.tests-result-stats .pending{padding:0 2px}.tests-result-spec{margin-bottom:0}.tests-result-spec-suites .tests-result-spec-suites{margin-left:20px}.tests-result-spec-suites dd{margin-bottom:20px;margin-left:0}.tests-result-spec-tests{margin-left:20px}.tests-result-spec-test-title{padding-left:20px}.tests-result-spec-test-title .fa{line-height:18px;margin-left:-20px;margin-top:2px;position:absolute}.tests-result-spec-test-title .fa-circle{font-size:50%;margin-left:-16px}.tests-result .pass{color:#8aa051}.tests-result .fail{color:#da4f49}.tests-result .pending{color:#666}.hotkeysList .hotkeysLabel{clear:both;color:#000;font-size:16px;font-weight:400}.hotkeysList .hotkeysContent{padding-left:10px}.hotkeysList li{line-height:25px}.hotkeysList li .hotkeysDiv{float:left}.hotkeysList .hotkeysicons{background-color:#686766;border:1px solid #000;border-radius:2px;color:#fff;display:inline;height:19px;margin-left:10px;text-align:center;width:19px}.arango-table tbody tr:nth-child(even),.arango-table thead{background-color:#fff}.hotkeysContentLabel{float:left;width:30%}.arango-table{border-top:1px solid #c2c2c2;width:100%}.arango-table thead th{border-bottom:1px solid #c2c2c2;height:43px}.arango-table tbody tr:nth-child(odd){background:rgba(104,103,102,.05)}.arango-table tbody td{padding:10px 18px}.arango-tabbar{height:27px;width:100%}.arango-tabbar button{background-color:#8c8a89;border:0;border-top-left-radius:3px;border-top-right-radius:3px;color:#fff;float:right;font-weight:100;height:27px;margin-right:5px;width:82px}.arango-tabbar button:first-child{margin-right:10px}.arango-tabbar .arango-active-tab{background-color:#fff;border-bottom:1px solid #fff;border-left:1px solid #c2c2c2;border-right:1px solid #c2c2c2;border-top:1px solid #c2c2c2;color:#000;height:28px;margin-bottom:-1px}.docsSecCol,.docsThirdCol{height:26px}.arangoDataTable{border-spacing:0 0;position:relative;table-layout:fixed!important;width:100%!important}.arangoDataTable thead{background-color:#fff!important;font-weight:400!important;text-align:left}.arangoDataTable thead th{border-bottom:0;cursor:default!important;font-weight:400!important;padding:10px 14px!important}.arangoDataTable thead tr{border-bottom:1px solid #c2c2c2}.arangoDataTable tr{cursor:pointer}.arangoDataTable td{padding:8px 18px!important}.arangoDataTable .key{font-weight:100;margin-top:4px}.arangoDataTable .dataTable .noPointer tr{cursor:default}.arangoDataTable .selected-row{background-color:#8aa051!important}.arangoDataTable .selected-row div,.arangoDataTable .selected-row li,.arangoDataTable .selected-row span{color:#fff!important}.api-container #resources>li.resource:nth-child(even),table.arangoDataTable tr.even{background-color:#fff}.api-container #resources>li.resource:nth-child(odd),table.arangoDataTable tr.odd{background-color:rgba(104,103,102,.05)}#tableDiv table.dataTable td{padding:12px 18px!important}#documentsTableID_filter,#documentsTableID_length{display:none}#documentsTableID_wrapper{min-height:480px!important;padding-bottom:0!important}.snippet-no-num{font-family:'Open Sans',sans-serif;font-size:1em;font-weight:400;margin-bottom:0}.cuttedContent,.prettify ul li,.writeable a{overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}.totalDocuments{color:#666;float:left;font-weight:100;margin-top:-37px!important;padding-left:10px}.prettify{border:none!important;font-size:1em!important;margin:0!important;padding:0!important}table .sorting{background:0 0!important}#documentsDiv{margin-top:20px}.new-index-view input[type=checkbox]{float:left}.new-index-view table tr{width:600px!important}.new-index-view table tr th:last-child{width:50px!important}.new-index-view table th{font-weight:300!important;width:200px!important}.edit-index-table{margin-top:5px;min-width:auto!important}.edit-index-table th{padding-bottom:5px;padding-left:5px;padding-top:5px}.edit-index-table .icon_arangodb_locked{color:rgba(0,0,0,.5);cursor:default;font-size:20px;margin-left:10px}.edit-index-table .icon_arangodb_roundminus{font-size:20px;margin-left:10px}.contentIn .arangoicon{font-size:25px;position:relative;top:-3px!important}#collectionEditIndexTable thead{border-bottom:1px solid #e5e5e5}.newIndexClass table{border-top:1px solid #f7f3f2;margin-bottom:60px}.newIndexClass table select{margin-right:7px}.newIndexClass table .arangoicon{float:right;margin-right:-12px;margin-top:5px}.index-button-bar{bottom:0;margin-bottom:15px;margin-right:17px;margin-top:15px;position:absolute;right:0}.index-button-bar button{float:right;margin-left:0}.index-button-bar #cancelIndex{margin-right:13px}.docsFirstCol,.docsSecCol,.docsThirdCol{border:0!important}.docsFirstCol{height:26px;width:80%}.docsSecCol{min-width:400px!important;width:10%}.add-filter-item{margin-left:5px}.add-filter-item i{margin-top:0!important}.upload-indicator{display:none;margin-top:-3px;padding-right:10px}.documentsDropdown .dropdownImport,.documentsDropdown .headerDropdown{clear:both;margin-bottom:5px}.documents-size{background-color:#fff!important;border:1px solid #e5e5e5;border-radius:2px;box-shadow:none;float:right;height:28px;line-height:18px;margin-left:10px;margin-right:-2px;margin-top:0;outline:transparent 0;width:115px}.queryline .fa-info-circle:hover{cursor:pointer}.ace_error{background:0 0!important}#exportHeader .fa-exclamation-circle{color:#fff;font-size:13pt;margin-right:10px}.totalDocuments:hover{color:#000}.ajax-file-upload-statusbar{-moz-border-radius:2px;-webkit-border-radius:2px;border-radius:2px;border:1px solid rgba(0,0,0,.7);margin:10px 10px 5px 5px;padding:5px;width:420px}.ajax-file-upload-filename{color:grey;height:auto;margin:0 5px 5px 10px;width:100%}.ajax-file-upload-progress{-moz-border-radius:2px;-webkit-border-radius:2px;border-radius:2px;border:1px solid #d9d9d9;display:inline-block;margin:0 10px 5px;padding:1px;position:relative;width:250px}.ajax-file-upload-bar{-moz-border-radius:2px;-webkit-border-radius:2px;border-radius:2px;background-color:rgba(0,0,0,.7);color:#fff;height:20px;width:0}.ajax-file-upload-percent{display:inline-block;left:48%;position:absolute;top:3px}.ajax-file-upload-red{font-size:13px;font-weight:400;margin-right:5px;padding:4px 15px;vertical-align:top}.ajax-file-upload{display:inline-block;font-size:16px;font-weight:700;height:25px;margin:0 10px 10px 0;padding:6px 10px 4px}.ajax-upload-dragdrop{border:1px dotted #8f8d8c;color:#736b68;padding:10px 10px 0;text-align:left;vertical-align:middle;width:506px}.ajax-upload-dragdrop span{position:relative;top:-22px}/*! + */@font-face{font-family:FontAwesome;src:url(../fonts/fontawesome/fontawesome-webfont.eot?v=4.4.0);src:url(../fonts/fontawesome/fontawesome-webfont.eot?#iefix&v=4.4.0) format("embedded-opentype"),url(../fonts/fontawesome/fontawesome-webfont.woff2?v=4.4.0) format("woff2"),url(../fonts/fontawesome/fontawesome-webfont.woff?v=4.4.0) format("woff"),url(../fonts/fontawesome/fontawesome-webfont.ttf?v=4.4.0) format("truetype"),url(../fonts/fontawesome/fontawesome-webfont.svg?v=4.4.0#fontawesomeregular) format("svg");font-weight:400;font-style:normal}.fa{font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.modal-body,.ui-tooltip,button{font-family:'Open Sans',sans-serif!important}.fa-lg{font-size:1.3333333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.2857142857em;text-align:center}.fa-ul{padding-left:0;margin-left:2.1428571429em;list-style-type:none}.fa.fa-pull-right,.fa.pull-right{margin-left:.3em}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.1428571429em;width:2.1428571429em;top:.1428571429em;text-align:center}.fa-li.fa-lg{left:-1.8571428571em}.fa-border{padding:.2em .25em .15em;border:.08em solid #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right,.pull-right{float:right}.contentDiv li,.dashboard-bar-chart-container,.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart,.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title,.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut,.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage,.dashboard-full-width-chart,.dashboard-full-width-chart .dashboard-full-width-chart-inner,.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart,.dashboard-half-height-legend,.dashboard-large-chart,.dashboard-large-chart .dashboard-large-chart-inner,.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart,.dashboard-legend,.dashboard-medium-chart,.dashboard-medium-chart .dashboard-interior-chart,.dashboard-small-chart,.dashboard-small-chart .dashboard-small-chart-inner,.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart,.dashboard-sub-bar,.dashboard-sub-bar .dashboard-sub-bar-title,.dashboard-tendency-container,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency .dashboard-subtitle-bar,.dashboard-title-bar .dashboard-half-title-bar,.dashboardModal,.dropdown-toolbar,.fixedDropdown .notificationItemContent,.gv-dropdown-menu,.innerDropdownInnerUL,.link-dropdown-menu,.modal-chart-detail,.modal-chart-detail .modal-body,.modal-chart-detail .modal-dashboard-legend,.modal-chart-detail .modal-inner-detail,.navlist li,.navlogo,.pagination-line li a,.pull-left,.script-dropdown-menu,.user-dropdown-menu,a.button-gui,a.headerButton,div .bigtile,div .bigtile a span.add-Icon,div .tile,div .tile a span.add-Icon,div.centralContent,div.dropdownInner ul,div.footer-center,div.footer-left,div.footer-left p{float:left}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=1);-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2);-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=3);-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=0);-webkit-transform:scale(-1,1);-ms-transform:scale(-1,1);transform:scale(-1,1)}.fa-flip-vertical{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2);-webkit-transform:scale(1,-1);-ms-transform:scale(1,-1);transform:scale(1,-1)}:root .fa-flip-horizontal,:root .fa-flip-vertical,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-rotate-90{filter:none}.fa-stack{position:relative;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:""}.fa-music:before{content:""}.fa-search:before{content:""}.fa-envelope-o:before{content:""}.fa-heart:before{content:""}.fa-star:before{content:""}.fa-star-o:before{content:""}.fa-user:before{content:""}.fa-film:before{content:""}.fa-th-large:before{content:""}.fa-th:before{content:""}.fa-th-list:before{content:""}.fa-check:before{content:""}.fa-close:before,.fa-remove:before,.fa-times:before{content:""}.fa-search-plus:before{content:""}.fa-search-minus:before{content:""}.fa-power-off:before{content:""}.fa-signal:before{content:""}.fa-cog:before,.fa-gear:before{content:""}.fa-trash-o:before{content:""}.fa-home:before{content:""}.fa-file-o:before{content:""}.fa-clock-o:before{content:""}.fa-road:before{content:""}.fa-download:before{content:""}.fa-arrow-circle-o-down:before{content:""}.fa-arrow-circle-o-up:before{content:""}.fa-inbox:before{content:""}.fa-play-circle-o:before{content:""}.fa-repeat:before,.fa-rotate-right:before{content:""}.fa-refresh:before{content:""}.fa-list-alt:before{content:""}.fa-lock:before{content:""}.fa-flag:before{content:""}.fa-headphones:before{content:""}.fa-volume-off:before{content:""}.fa-volume-down:before{content:""}.fa-volume-up:before{content:""}.fa-qrcode:before{content:""}.fa-barcode:before{content:""}.fa-tag:before{content:""}.fa-tags:before{content:""}.fa-book:before{content:""}.fa-bookmark:before{content:""}.fa-print:before{content:""}.fa-camera:before{content:""}.fa-font:before{content:""}.fa-bold:before{content:""}.fa-italic:before{content:""}.fa-text-height:before{content:""}.fa-text-width:before{content:""}.fa-align-left:before{content:""}.fa-align-center:before{content:""}.fa-align-right:before{content:""}.fa-align-justify:before{content:""}.fa-list:before{content:""}.fa-dedent:before,.fa-outdent:before{content:""}.fa-indent:before{content:""}.fa-video-camera:before{content:""}.fa-image:before,.fa-photo:before,.fa-picture-o:before{content:""}.fa-pencil:before{content:""}.fa-map-marker:before{content:""}.fa-adjust:before{content:""}.fa-tint:before{content:""}.fa-edit:before,.fa-pencil-square-o:before{content:""}.fa-share-square-o:before{content:""}.fa-check-square-o:before{content:""}.fa-arrows:before{content:""}.fa-step-backward:before{content:""}.fa-fast-backward:before{content:""}.fa-backward:before{content:""}.fa-play:before{content:""}.fa-pause:before{content:""}.fa-stop:before{content:""}.fa-forward:before{content:""}.fa-fast-forward:before{content:""}.fa-step-forward:before{content:""}.fa-eject:before{content:""}.fa-chevron-left:before{content:""}.fa-chevron-right:before{content:""}.fa-plus-circle:before{content:""}.fa-minus-circle:before{content:""}.fa-times-circle:before{content:""}.fa-check-circle:before{content:""}.fa-question-circle:before{content:""}.fa-info-circle:before{content:""}.fa-crosshairs:before{content:""}.fa-times-circle-o:before{content:""}.fa-check-circle-o:before{content:""}.fa-ban:before{content:""}.fa-arrow-left:before{content:""}.fa-arrow-right:before{content:""}.fa-arrow-up:before{content:""}.fa-arrow-down:before{content:""}.fa-mail-forward:before,.fa-share:before{content:""}.fa-expand:before{content:""}.fa-compress:before{content:""}.fa-plus:before{content:""}.fa-minus:before{content:""}.fa-asterisk:before{content:""}.fa-exclamation-circle:before{content:""}.fa-gift:before{content:""}.fa-leaf:before{content:""}.fa-fire:before{content:""}.fa-eye:before{content:""}.fa-eye-slash:before{content:""}.fa-exclamation-triangle:before,.fa-warning:before{content:""}.fa-plane:before{content:""}.fa-calendar:before{content:""}.fa-random:before{content:""}.fa-comment:before{content:""}.fa-magnet:before{content:""}.fa-chevron-up:before{content:""}.fa-chevron-down:before{content:""}.fa-retweet:before{content:""}.fa-shopping-cart:before{content:""}.fa-folder:before{content:""}.fa-folder-open:before{content:""}.fa-arrows-v:before{content:""}.fa-arrows-h:before{content:""}.fa-bar-chart-o:before,.fa-bar-chart:before{content:""}.fa-twitter-square:before{content:""}.fa-facebook-square:before{content:""}.fa-camera-retro:before{content:""}.fa-key:before{content:""}.fa-cogs:before,.fa-gears:before{content:""}.fa-comments:before{content:""}.fa-thumbs-o-up:before{content:""}.fa-thumbs-o-down:before{content:""}.fa-star-half:before{content:""}.fa-heart-o:before{content:""}.fa-sign-out:before{content:""}.fa-linkedin-square:before{content:""}.fa-thumb-tack:before{content:""}.fa-external-link:before{content:""}.fa-sign-in:before{content:""}.fa-trophy:before{content:""}.fa-github-square:before{content:""}.fa-upload:before{content:""}.fa-lemon-o:before{content:""}.fa-phone:before{content:""}.fa-square-o:before{content:""}.fa-bookmark-o:before{content:""}.fa-phone-square:before{content:""}.fa-twitter:before{content:""}.fa-facebook-f:before,.fa-facebook:before{content:""}.fa-github:before{content:""}.fa-unlock:before{content:""}.fa-credit-card:before{content:""}.fa-feed:before,.fa-rss:before{content:""}.fa-hdd-o:before{content:""}.fa-bullhorn:before{content:""}.fa-bell:before{content:""}.fa-certificate:before{content:""}.fa-hand-o-right:before{content:""}.fa-hand-o-left:before{content:""}.fa-hand-o-up:before{content:""}.fa-hand-o-down:before{content:""}.fa-arrow-circle-left:before{content:""}.fa-arrow-circle-right:before{content:""}.fa-arrow-circle-up:before{content:""}.fa-arrow-circle-down:before{content:""}.fa-globe:before{content:""}.fa-wrench:before{content:""}.fa-tasks:before{content:""}.fa-filter:before{content:""}.fa-briefcase:before{content:""}.fa-arrows-alt:before{content:""}.fa-group:before,.fa-users:before{content:""}.fa-chain:before,.fa-link:before{content:""}.fa-cloud:before{content:""}.fa-flask:before{content:""}.fa-cut:before,.fa-scissors:before{content:""}.fa-copy:before,.fa-files-o:before{content:""}.fa-paperclip:before{content:""}.fa-floppy-o:before,.fa-save:before{content:""}.fa-square:before{content:""}.fa-bars:before,.fa-navicon:before,.fa-reorder:before{content:""}.fa-list-ul:before{content:""}.fa-list-ol:before{content:""}.fa-strikethrough:before{content:""}.fa-underline:before{content:""}.fa-table:before{content:""}.fa-magic:before{content:""}.fa-truck:before{content:""}.fa-pinterest:before{content:""}.fa-pinterest-square:before{content:""}.fa-google-plus-square:before{content:""}.fa-google-plus:before{content:""}.fa-money:before{content:""}.fa-caret-down:before{content:""}.fa-caret-up:before{content:""}.fa-caret-left:before{content:""}.fa-caret-right:before{content:""}.fa-columns:before{content:""}.fa-sort:before,.fa-unsorted:before{content:""}.fa-sort-desc:before,.fa-sort-down:before{content:""}.fa-sort-asc:before,.fa-sort-up:before{content:""}.fa-envelope:before{content:""}.fa-linkedin:before{content:""}.fa-rotate-left:before,.fa-undo:before{content:""}.fa-gavel:before,.fa-legal:before{content:""}.fa-dashboard:before,.fa-tachometer:before{content:""}.fa-comment-o:before{content:""}.fa-comments-o:before{content:""}.fa-bolt:before,.fa-flash:before{content:""}.fa-sitemap:before{content:""}.fa-umbrella:before{content:""}.fa-clipboard:before,.fa-paste:before{content:""}.fa-lightbulb-o:before{content:""}.fa-exchange:before{content:""}.fa-cloud-download:before{content:""}.fa-cloud-upload:before{content:""}.fa-user-md:before{content:""}.fa-stethoscope:before{content:""}.fa-suitcase:before{content:""}.fa-bell-o:before{content:""}.fa-coffee:before{content:""}.fa-cutlery:before{content:""}.fa-file-text-o:before{content:""}.fa-building-o:before{content:""}.fa-hospital-o:before{content:""}.fa-ambulance:before{content:""}.fa-medkit:before{content:""}.fa-fighter-jet:before{content:""}.fa-beer:before{content:""}.fa-h-square:before{content:""}.fa-plus-square:before{content:""}.fa-angle-double-left:before{content:""}.fa-angle-double-right:before{content:""}.fa-angle-double-up:before{content:""}.fa-angle-double-down:before{content:""}.fa-angle-left:before{content:""}.fa-angle-right:before{content:""}.fa-angle-up:before{content:""}.fa-angle-down:before{content:""}.fa-desktop:before{content:""}.fa-laptop:before{content:""}.fa-tablet:before{content:""}.fa-mobile-phone:before,.fa-mobile:before{content:""}.fa-circle-o:before{content:""}.fa-quote-left:before{content:""}.fa-quote-right:before{content:""}.fa-spinner:before{content:""}.fa-circle:before{content:""}.fa-mail-reply:before,.fa-reply:before{content:""}.fa-github-alt:before{content:""}.fa-folder-o:before{content:""}.fa-folder-open-o:before{content:""}.fa-smile-o:before{content:""}.fa-frown-o:before{content:""}.fa-meh-o:before{content:""}.fa-gamepad:before{content:""}.fa-keyboard-o:before{content:""}.fa-flag-o:before{content:""}.fa-flag-checkered:before{content:""}.fa-terminal:before{content:""}.fa-code:before{content:""}.fa-mail-reply-all:before,.fa-reply-all:before{content:""}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:""}.fa-location-arrow:before{content:""}.fa-crop:before{content:""}.fa-code-fork:before{content:""}.fa-chain-broken:before,.fa-unlink:before{content:""}.fa-question:before{content:""}.fa-info:before{content:""}.fa-exclamation:before{content:""}.fa-superscript:before{content:""}.fa-subscript:before{content:""}.fa-eraser:before{content:""}.fa-puzzle-piece:before{content:""}.fa-microphone:before{content:""}.fa-microphone-slash:before{content:""}.fa-shield:before{content:""}.fa-calendar-o:before{content:""}.fa-fire-extinguisher:before{content:""}.fa-rocket:before{content:""}.fa-maxcdn:before{content:""}.fa-chevron-circle-left:before{content:""}.fa-chevron-circle-right:before{content:""}.fa-chevron-circle-up:before{content:""}.fa-chevron-circle-down:before{content:""}.fa-html5:before{content:""}.fa-css3:before{content:""}.fa-anchor:before{content:""}.fa-unlock-alt:before{content:""}.fa-bullseye:before{content:""}.fa-ellipsis-h:before{content:""}.fa-ellipsis-v:before{content:""}.fa-rss-square:before{content:""}.fa-play-circle:before{content:""}.fa-ticket:before{content:""}.fa-minus-square:before{content:""}.fa-minus-square-o:before{content:""}.fa-level-up:before{content:""}.fa-level-down:before{content:""}.fa-check-square:before{content:""}.fa-pencil-square:before{content:""}.fa-external-link-square:before{content:""}.fa-share-square:before{content:""}.fa-compass:before{content:""}.fa-caret-square-o-down:before,.fa-toggle-down:before{content:""}.fa-caret-square-o-up:before,.fa-toggle-up:before{content:""}.fa-caret-square-o-right:before,.fa-toggle-right:before{content:""}.fa-eur:before,.fa-euro:before{content:""}.fa-gbp:before{content:""}.fa-dollar:before,.fa-usd:before{content:""}.fa-inr:before,.fa-rupee:before{content:""}.fa-cny:before,.fa-jpy:before,.fa-rmb:before,.fa-yen:before{content:""}.fa-rouble:before,.fa-rub:before,.fa-ruble:before{content:""}.fa-krw:before,.fa-won:before{content:""}.fa-bitcoin:before,.fa-btc:before{content:""}.fa-file:before{content:""}.fa-file-text:before{content:""}.fa-sort-alpha-asc:before{content:""}.fa-sort-alpha-desc:before{content:""}.fa-sort-amount-asc:before{content:""}.fa-sort-amount-desc:before{content:""}.fa-sort-numeric-asc:before{content:""}.fa-sort-numeric-desc:before{content:""}.fa-thumbs-up:before{content:""}.fa-thumbs-down:before{content:""}.fa-youtube-square:before{content:""}.fa-youtube:before{content:""}.fa-xing:before{content:""}.fa-xing-square:before{content:""}.fa-youtube-play:before{content:""}.fa-dropbox:before{content:""}.fa-stack-overflow:before{content:""}.fa-instagram:before{content:""}.fa-flickr:before{content:""}.fa-adn:before{content:""}.fa-bitbucket:before{content:""}.fa-bitbucket-square:before{content:""}.fa-tumblr:before{content:""}.fa-tumblr-square:before{content:""}.fa-long-arrow-down:before{content:""}.fa-long-arrow-up:before{content:""}.fa-long-arrow-left:before{content:""}.fa-long-arrow-right:before{content:""}.fa-apple:before{content:""}.fa-windows:before{content:""}.fa-android:before{content:""}.fa-linux:before{content:""}.fa-dribbble:before{content:""}.fa-skype:before{content:""}.fa-foursquare:before{content:""}.fa-trello:before{content:""}.fa-female:before{content:""}.fa-male:before{content:""}.fa-gittip:before,.fa-gratipay:before{content:""}.fa-sun-o:before{content:""}.fa-moon-o:before{content:""}.fa-archive:before{content:""}.fa-bug:before{content:""}.fa-vk:before{content:""}.fa-weibo:before{content:""}.fa-renren:before{content:""}.fa-pagelines:before{content:""}.fa-stack-exchange:before{content:""}.fa-arrow-circle-o-right:before{content:""}.fa-arrow-circle-o-left:before{content:""}.fa-caret-square-o-left:before,.fa-toggle-left:before{content:""}.fa-dot-circle-o:before{content:""}.fa-wheelchair:before{content:""}.fa-vimeo-square:before{content:""}.fa-try:before,.fa-turkish-lira:before{content:""}.fa-plus-square-o:before{content:""}.fa-space-shuttle:before{content:""}.fa-slack:before{content:""}.fa-envelope-square:before{content:""}.fa-wordpress:before{content:""}.fa-openid:before{content:""}.fa-bank:before,.fa-institution:before,.fa-university:before{content:""}.fa-graduation-cap:before,.fa-mortar-board:before{content:""}.fa-yahoo:before{content:""}.fa-google:before{content:""}.fa-reddit:before{content:""}.fa-reddit-square:before{content:""}.fa-stumbleupon-circle:before{content:""}.fa-stumbleupon:before{content:""}.fa-delicious:before{content:""}.fa-digg:before{content:""}.fa-pied-piper:before{content:""}.fa-pied-piper-alt:before{content:""}.fa-drupal:before{content:""}.fa-joomla:before{content:""}.fa-language:before{content:""}.fa-fax:before{content:""}.fa-building:before{content:""}.fa-child:before{content:""}.fa-paw:before{content:""}.fa-spoon:before{content:""}.fa-cube:before{content:""}.fa-cubes:before{content:""}.fa-behance:before{content:""}.fa-behance-square:before{content:""}.fa-steam:before{content:""}.fa-steam-square:before{content:""}.fa-recycle:before{content:""}.fa-automobile:before,.fa-car:before{content:""}.fa-cab:before,.fa-taxi:before{content:""}.fa-tree:before{content:""}.fa-spotify:before{content:""}.fa-deviantart:before{content:""}.fa-soundcloud:before{content:""}.fa-database:before{content:""}.fa-file-pdf-o:before{content:""}.fa-file-word-o:before{content:""}.fa-file-excel-o:before{content:""}.fa-file-powerpoint-o:before{content:""}.fa-file-image-o:before,.fa-file-photo-o:before,.fa-file-picture-o:before{content:""}.fa-file-archive-o:before,.fa-file-zip-o:before{content:""}.fa-file-audio-o:before,.fa-file-sound-o:before{content:""}.fa-file-movie-o:before,.fa-file-video-o:before{content:""}.fa-file-code-o:before{content:""}.fa-vine:before{content:""}.fa-codepen:before{content:""}.fa-jsfiddle:before{content:""}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-ring:before,.fa-life-saver:before,.fa-support:before{content:""}.fa-circle-o-notch:before{content:""}.fa-ra:before,.fa-rebel:before{content:""}.fa-empire:before,.fa-ge:before{content:""}.fa-git-square:before{content:""}.fa-git:before{content:""}.fa-hacker-news:before,.fa-y-combinator-square:before,.fa-yc-square:before{content:""}.fa-tencent-weibo:before{content:""}.fa-qq:before{content:""}.fa-wechat:before,.fa-weixin:before{content:""}.fa-paper-plane:before,.fa-send:before{content:""}.fa-paper-plane-o:before,.fa-send-o:before{content:""}.fa-history:before{content:""}.fa-circle-thin:before{content:""}.fa-header:before{content:""}.fa-paragraph:before{content:""}.fa-sliders:before{content:""}.fa-share-alt:before{content:""}.fa-share-alt-square:before{content:""}.fa-bomb:before{content:""}.fa-futbol-o:before,.fa-soccer-ball-o:before{content:""}.fa-tty:before{content:""}.fa-binoculars:before{content:""}.fa-plug:before{content:""}.fa-slideshare:before{content:""}.fa-twitch:before{content:""}.fa-yelp:before{content:""}.fa-newspaper-o:before{content:""}.fa-wifi:before{content:""}.fa-calculator:before{content:""}.fa-paypal:before{content:""}.fa-google-wallet:before{content:""}.fa-cc-visa:before{content:""}.fa-cc-mastercard:before{content:""}.fa-cc-discover:before{content:""}.fa-cc-amex:before{content:""}.fa-cc-paypal:before{content:""}.fa-cc-stripe:before{content:""}.fa-bell-slash:before{content:""}.fa-bell-slash-o:before{content:""}.fa-trash:before{content:""}.fa-copyright:before{content:""}.fa-at:before{content:""}.fa-eyedropper:before{content:""}.fa-paint-brush:before{content:""}.fa-birthday-cake:before{content:""}.fa-area-chart:before{content:""}.fa-pie-chart:before{content:""}.fa-line-chart:before{content:""}.fa-lastfm:before{content:""}.fa-lastfm-square:before{content:""}.fa-toggle-off:before{content:""}.fa-toggle-on:before{content:""}.fa-bicycle:before{content:""}.fa-bus:before{content:""}.fa-ioxhost:before{content:""}.fa-angellist:before{content:""}.fa-cc:before{content:""}.fa-ils:before,.fa-shekel:before,.fa-sheqel:before{content:""}.fa-meanpath:before{content:""}.fa-buysellads:before{content:""}.fa-connectdevelop:before{content:""}.fa-dashcube:before{content:""}.fa-forumbee:before{content:""}.fa-leanpub:before{content:""}.fa-sellsy:before{content:""}.fa-shirtsinbulk:before{content:""}.fa-simplybuilt:before{content:""}.fa-skyatlas:before{content:""}.fa-cart-plus:before{content:""}.fa-cart-arrow-down:before{content:""}.fa-diamond:before{content:""}.fa-ship:before{content:""}.fa-user-secret:before{content:""}.fa-motorcycle:before{content:""}.fa-street-view:before{content:""}.fa-heartbeat:before{content:""}.fa-venus:before{content:""}.fa-mars:before{content:""}.fa-mercury:before{content:""}.fa-intersex:before,.fa-transgender:before{content:""}.fa-transgender-alt:before{content:""}.fa-venus-double:before{content:""}.fa-mars-double:before{content:""}.fa-venus-mars:before{content:""}.fa-mars-stroke:before{content:""}.fa-mars-stroke-v:before{content:""}.fa-mars-stroke-h:before{content:""}.fa-neuter:before{content:""}.fa-genderless:before{content:""}.fa-facebook-official:before{content:""}.fa-pinterest-p:before{content:""}.fa-whatsapp:before{content:""}.fa-server:before{content:""}.fa-user-plus:before{content:""}.fa-user-times:before{content:""}.fa-bed:before,.fa-hotel:before{content:""}.fa-viacoin:before{content:""}.fa-train:before{content:""}.fa-subway:before{content:""}.fa-medium:before{content:""}.fa-y-combinator:before,.fa-yc:before{content:""}.fa-optin-monster:before{content:""}.fa-opencart:before{content:""}.fa-expeditedssl:before{content:""}.fa-battery-4:before,.fa-battery-full:before{content:""}.fa-battery-3:before,.fa-battery-three-quarters:before{content:""}.fa-battery-2:before,.fa-battery-half:before{content:""}.fa-battery-1:before,.fa-battery-quarter:before{content:""}.fa-battery-0:before,.fa-battery-empty:before{content:""}.fa-mouse-pointer:before{content:""}.fa-i-cursor:before{content:""}.fa-object-group:before{content:""}.fa-object-ungroup:before{content:""}.fa-sticky-note:before{content:""}.fa-sticky-note-o:before{content:""}.fa-cc-jcb:before{content:""}.fa-cc-diners-club:before{content:""}.fa-clone:before{content:""}.fa-balance-scale:before{content:""}.fa-hourglass-o:before{content:""}.fa-hourglass-1:before,.fa-hourglass-start:before{content:""}.fa-hourglass-2:before,.fa-hourglass-half:before{content:""}.fa-hourglass-3:before,.fa-hourglass-end:before{content:""}.fa-hourglass:before{content:""}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:""}.fa-hand-paper-o:before,.fa-hand-stop-o:before{content:""}.fa-hand-scissors-o:before{content:""}.fa-hand-lizard-o:before{content:""}.fa-hand-spock-o:before{content:""}.fa-hand-pointer-o:before{content:""}.fa-hand-peace-o:before{content:""}.fa-trademark:before{content:""}.fa-registered:before{content:""}.fa-creative-commons:before{content:""}.fa-gg:before{content:""}.fa-gg-circle:before{content:""}.fa-tripadvisor:before{content:""}.fa-odnoklassniki:before{content:""}.fa-odnoklassniki-square:before{content:""}.fa-get-pocket:before{content:""}.fa-wikipedia-w:before{content:""}.fa-safari:before{content:""}.fa-chrome:before{content:""}.fa-firefox:before{content:""}.fa-opera:before{content:""}.fa-internet-explorer:before{content:""}.fa-television:before,.fa-tv:before{content:""}.fa-contao:before{content:""}.fa-500px:before{content:""}.fa-amazon:before{content:""}.fa-calendar-plus-o:before{content:""}.fa-calendar-minus-o:before{content:""}.fa-calendar-times-o:before{content:""}.fa-calendar-check-o:before{content:""}.fa-industry:before{content:""}.fa-map-pin:before{content:""}.fa-map-signs:before{content:""}.fa-map-o:before{content:""}.fa-map:before{content:""}.fa-commenting:before{content:""}.fa-commenting-o:before{content:""}.fa-houzz:before{content:""}.fa-vimeo:before{content:""}.fa-black-tie:before{content:""}.fa-fonticons:before{content:""}.arango-tab li,.dashboard-sub-bar-menu,.docsThirdCol,.fixedDropdown .notificationItem i,.fixedDropdown button,.headerBar>div.headerButtonBar,.navmenu,.query-button,.search-field,div .bigtile .iconSet span,div .tile .iconSet span,div.footer-right,div.footer-right p,div.gv_colour_list,ul.headerButtonList li{float:right}#distributionChartDiv:after,.arango-tab:after,.dashboard-bar-chart-container .dashboard-bar-chart:after,.dashboard-medium-chart .dashboard-medium-chart-inner:after,.dashboard-medium-chart .dashboard-medium-chart-menu:after,.dashboard-row:after,.dashboard-sub-bar:after,.dashboard-tendency-container .dashboard-tendency-chart:after,.detail-chart:after,.document-info .document-info-container .document-inner-info-container .document-attribute:after,.headerBar>div.headerButtonBar:after,.lineChartDiv:after,.pagination-line li:after,.resizecontainer:after,.tileList:after{clear:both;content:'.';display:block;font-size:0;height:0;visibility:hidden}.caret,.contentDiv:after,.contentDiv:before,.form-actions:after,.form-actions:before{content:''}.addButton,.arango-tab a,.arango-tab li,.arangoicon,.clusterDownBtn button,.contentDiv .icon,.contentTables tr.contentRowInactive a,.deleteButton,.edit-index-table .icon_arangodb_roundminus,.fixedDropdown .notificationItem i,.fullNotification:hover,.gv-search-submit-icon,.icon-info-sign,.link>line,.node,.pagination-line li a,.script-dropdown-menu .dropdown-item,.search-submit-icon,a.button-gui,a.headerButton,div .bigtile,div .bigtile .iconSet span,div .bigtile a span.icon,div .bigtile a svg,div .tile .iconSet span,div .tile a span.icon,div .tile a svg,div.headerDropdown.headerDropdown input[type=checkbox].css-checkbox label.css-label,div.toolbox div.gv_action_button{cursor:pointer}.navbar,footer.footer{background-color:rgba(245,248,240,.95);color:#fff;left:0;position:fixed;right:0;width:100%;z-index:1000}.ajax-file-upload-red,.button-danger{background-color:#da4f49}.ajax-file-upload-red:focus,.ajax-file-upload-red:hover,.button-danger:focus,.button-danger:hover{background-color:#be342e}.contentTables td span,.deleteButton,.edit-index-table .icon_arangodb_roundminus{color:#da4f49}.contentTables td span:focus,.contentTables td span:hover,.deleteButton:focus,.deleteButton:hover,.edit-index-table .icon_arangodb_roundminus:focus,.edit-index-table .icon_arangodb_roundminus:hover{color:#be342e}.ajax-file-upload,.button-success{background-color:#8aa051}.ajax-file-upload:focus,.ajax-file-upload:hover,.button-success:focus,.button-success:hover{background-color:#788f3d}.addButton,.contentTables td.dbThSecond span{color:#8aa051}.addButton:focus,.addButton:hover,.contentTables td.dbThSecond span:focus,.contentTables td.dbThSecond span:hover{color:#788f3d}.button-warning{background-color:#faa732}.button-warning:focus,.button-warning:hover{background-color:#f89406}.button-close,.button-neutral{background-color:#8f8d8c}.button-close:focus,.button-close:hover,.button-neutral:focus,.button-neutral:hover{background-color:#736b68}.dashboard-sub-bar-menu{color:#8f8d8c}.dashboard-sub-bar-menu:focus,.dashboard-sub-bar-menu:hover{color:#736b68}.button-primary{background-color:#564e4a}.button-primary:focus,.button-primary:hover{background-color:#3a322e}.button-header,a.button-gui,a.headerButton{background-color:#fff;border:1px solid #fff;color:#555}.button-header:focus,.button-header:hover,a.button-gui:focus,a.button-gui:hover,a.headerButton:focus,a.headerButton:hover{background-color:#8aa051;border:1px solid #8aa051;color:#fff}.button-notification{background-color:#faa020}.button-notification:focus,.button-notification:hover{background-color:#f87c0f}.button-inactive,.button-inactive:focus,.button-inactive:hover,[class*=' button-']:disabled,[class*=' button-']:focus:disabled,[class*=' button-']:hover:disabled,[class^=button-]:disabled,[class^=button-]:focus:disabled,[class^=button-]:hover:disabled,button.disabled,button.disabled:focus,button.disabled:hover{background-color:#d3d3d3}a.headerButton.disabled,a.headerButton.disabled:focus,a.headerButton.disabled:hover{color:#d3d3d3}div.queryline .fa.fa-search{color:#c2c2c2;font-size:12pt;opacity:.5;position:relative;right:21px;top:-1px}div.queryline .fa.fa-search:hover{cursor:pointer;opacity:1}.login-window .login-input,.modal-body .select2-choices input,.modal-body input,.modal-body select,.modal-body textarea,.navbar .arango-collection-select,div.queryline input,div.queryline select,input.search-input{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#fff!important;border:1px solid rgba(140,138,137,.25);box-shadow:none;outline:transparent 0}.login-window .login-input:focus,.modal-body input:focus,.modal-body select:focus,.modal-body textarea:focus,.navbar .arango-collection-select:focus,div.queryline input:focus,div.queryline select:focus,input.search-input:focus{border-color:#999;box-shadow:none;outline:transparent 0}.dropdown-toolbar,.gv-dropdown-menu,.link-dropdown-menu,.script-dropdown-menu,.user-dropdown-menu{background-color:#f5f8f0;border-color:#666;border-radius:3px;border-style:solid;border-width:1px;box-shadow:none;display:none;list-style:none;margin:5px 0 0;padding:5px 0;position:absolute;right:0;top:80%;z-index:1000}.script-dropdown-menu .dropdown-item a,.tab{display:block}.dropdown-toolbar li,.gv-dropdown-menu li,.link-dropdown-menu li,.script-dropdown-menu li,.user-dropdown-menu li{line-height:23px;white-space:nowrap;width:100%}.dropdown-toolbar .dropdown-header,.gv-dropdown-menu .dropdown-header,.link-dropdown-menu .dropdown-header,.script-dropdown-menu .dropdown-header,.user-dropdown-menu .dropdown-header{color:#999;font-size:15px;font-weight:600;font-variant:small-caps;padding:0}.dropdown-toolbar .dropdown-header:hover,.gv-dropdown-menu .dropdown-header:hover,.link-dropdown-menu .dropdown-header:hover,.script-dropdown-menu .dropdown-header:hover,.user-dropdown-menu .dropdown-header:hover{cursor:default}div .bigtile:hover,div .tile:hover,div.footer-center p:hover{cursor:pointer}.dropdown-toolbar .divider,.gv-dropdown-menu .divider,.link-dropdown-menu .divider,.script-dropdown-menu .divider,.user-dropdown-menu .divider{background-color:#666;height:1px;margin:10px 0 5px}.dropdown-toolbar a,.gv-dropdown-menu a,.link-dropdown-menu a,.script-dropdown-menu a,.user-dropdown-menu a{color:#fff;padding:0 20px}.navbar{-webkit-font-smoothing:subpixel-antialiased;height:44px;margin-bottom:3px;padding-top:6px;top:0}.navbar .no-left-margin{border:0;margin-left:0}.navbar .no-left-margin.hover{background-color:transparent}.navbar .arangodbLogo{height:auto;margin-left:-5px;margin-top:-1px;width:40%}.navbar .arango-collection-select{position:relative;right:-22px;top:4px}.navbar .nav .dropdown .active>.dropdown-toggle,.navbar .nav .dropdown .open.active>.dropdown-toggle,.navbar .nav .dropdown .open>.dropdown-toggle{background:#788f3d}.navbar .nav>.active>a{-webkit-box-shadow:0 0 0 transparent inset;-moz-box-shadow:0 0 0 transparent inset;box-shadow:0 0 0 transparent inset;background-color:#fff;color:#000}.navbar .nav>li>a:focus{background-color:#fff}.navbar .nav>li>a:hover{background-color:#000;color:#686766}.navlist .dropdown-item:hover a,.navlist>.active a,.navlist>.active:hover a,.navlist>li:hover a{color:#000}.navlogo{margin-left:5px;margin-right:-3px;padding-top:3px}.navlist{list-style:none}.navlist>li{height:39px}.navlist li{border-left:1px solid transparent;border-right:1px solid transparent;border-top:1px solid transparent;margin-left:7px}.navlist li.dropdown:hover{background-color:#fff;border-bottom-left-radius:0;border-bottom-right-radius:0;border-left:1px solid rgba(0,0,0,.2);border-right:1px solid rgba(0,0,0,.2);border-top:1px solid rgba(0,0,0,.2)}.navlist li.dropdown:hover a{border-bottom:2px solid #fff}.navlist li.divider,.navlist li.navbar-spacer{border:0}.navlist li.divider{background-color:rgba(0,0,0,.2)}.navlist li.navbar-spacer{background-color:#a0a0a0;height:21px;margin-top:9px;width:1px}.navlist li.navbar-spacer.big{margin-left:15px;margin-right:15px}.navlist li.navbar-spacer.med{margin-left:5px;margin-right:5px}.navlist .dropdown-item,.script-dropdown-menu .dropdown-item{margin-left:0}.navlist li.navbar-spacer:hover{background-color:#a0a0a0}.navlist .active .tab{border-bottom:2px solid #8aa051;padding-bottom:4px}.navlist>.active{background-color:transparent}.navlist>.active:hover{background-color:#fff}.navlist .dropdown-item:hover,.navlist>li:hover{background-color:#fff;border-radius:3px}.navlist .dropdown-item a{border-bottom:0;display:block;font-size:11pt}.navlist .dropdown-item a:hover{background-color:#dee9cf;color:#686766}.tab{color:#686766;font-size:12pt;font-weight:100;padding:9px 5px 10px}.tab.userImg{padding-bottom:5px}.dropdown-item a{border-bottom:0!important;font-weight:300}.dropdown-toolbar li a,footer.footer p{font-weight:100}.dropdown-toolbar{background-color:#fff!important;border:1px solid rgba(140,138,137,.25)}.dropdown-toolbar li a:hover{background:0 0;background-color:#dee9cf!important;color:#000!important}.link-dropdown-menu,.user-dropdown-menu{background-color:#fff;border:1px solid rgba(0,0,0,.2);border-top-right-radius:0;margin-right:-1px;margin-top:7px;z-index:-10}.link-dropdown-menu .dropdown-item,.user-dropdown-menu .dropdown-item{border-left:0;border-right:0}.script-dropdown-menu .dropdown-item a:hover{color:#fff}.script-dropdown-menu .dropdown-item:hover{background-color:#8aa051}.gv-dropdown-menu{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;background-color:rgba(0,0,0,.7);border:1px solid #c2c2c2;margin-right:-20px;margin-top:6px}.gv-dropdown-menu:after{border-bottom-color:#fff}.gv-dropdown-menu li:hover{background-color:#fff;background-image:none}.gv-dropdown-menu li a{padding:0}.gv-dropdown-menu li a label{color:#fff;padding-left:5px}.gv-dropdown-menu li a:focus{background-color:#8aa051!important;background-image:none}#arangoCollectionSelect{display:none;float:right;margin-bottom:0;margin-right:15px;padding-bottom:0}.caret{border-left:5px solid transparent;border-right:5px solid transparent;border-top:5px solid #686766;display:inline-block;height:0;vertical-align:top;width:0}.applications-menu{display:block}.arango-logo{height:34px;padding:0!important}.arango-logo img{margin-left:22px}.footer{bottom:0;font-size:14px;left:0;position:fixed;right:0;text-align:center;z-index:1000}footer.footer{bottom:0;height:40px}footer.footer p{font-size:10pt;margin-bottom:0;padding-bottom:10px;padding-top:10px}div.footer-left{background:none;color:#686766;width:45%}div.footer-left .social-icons{margin-top:5px}div.footer-left .social-icons a{display:block;float:left;height:25px;width:25px}div.footer-left .social-icons p{background:#fff;border:1px solid rgba(104,103,102,.1);border-radius:20px;height:25px;margin-right:10px;padding:0;width:25px}div.footer-left .social-icons p:hover{background:#8aa051;cursor:pointer}div.footer-left .social-icons p:hover i{color:#fff}div.footer-left .social-icons i{color:#000;margin-top:6px;position:absolute}.addButton,.deleteButton{position:relative;font-size:22px}div.footer-left .social-icons i.fa-twitter{margin-left:-5px}div.footer-left .social-icons i.fa-envelope{margin-left:-19px}div.footer-left .social-icons i.fa-google{margin-left:-17px;margin-top:7px}div.footer-left .social-icons i.fa-stack-overflow{margin-left:-17px}div.footer-center{background:none;color:#686766;width:10%}div.footer-center i{background-color:#fff;border:1px solid rgba(104,103,102,.1);border-radius:20px;margin-left:1px;padding:6px 2px;width:20px}div.footer-center i:hover{background-color:#8aa051;color:#fff}div.footer-center p{padding-top:5px}[class*=' button-']:disabled,[class^=button-]:disabled,a.headerButton.disabled,button.disabled{cursor:not-allowed}div.footer-right{background:none;color:#686766;width:45%}div.footer-right p{color:#fff}div.footer-right i{color:#da4f49;font-size:18px}div.footer-right a{color:#686766;margin-left:5px;position:relative;top:-1px}div.footer-right .isOnline{color:#8aa051!important}.ajax-file-upload,.ajax-file-upload-red,.button-close,.button-danger,.button-header,.button-inactive,.button-neutral,.button-notification,.button-primary,.button-success,.button-warning{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;-webkit-box-shadow:0;-moz-box-shadow:0;box-shadow:0;font-size:14px;font-weight:300!important}.ajax-file-upload,.ajax-file-upload-red,.button-close,.button-danger,.button-inactive,.button-neutral,.button-notification,.button-primary,.button-success,.button-warning{border:0;color:#fff;margin-left:10px;padding:5px 16px}.button-header{margin-top:5px}.addButton{margin-right:7px;margin-top:2px}.deleteButton{padding-right:3px;top:3px}#closeBtnInfoView{margin-left:0!important}button.btn-server{width:120px}button.gv-zoom-btn{background-size:14px 14px;height:14px;vertical-align:baseline;width:14px}button.gv-zoom-btn.btn-zoom-right{border:0;box-shadow:none;right:0;top:13px}button.gv-zoom-btn.pan-right{background-image:url(../img/gv_arrow_right.png)}button.gv-zoom-btn.pan-right:hover{background:inherit;background-image:url(../img/gv_arrow_right.png)}button.gv-zoom-btn.pan-left{background-image:url(../img/gv_arrow_left.png)}button.gv-zoom-btn.pan-left:hover{background:inherit;background-image:url(../img/gv_arrow_left.png)}button.gv-zoom-btn.pan-top{background-image:url(../img/gv_arrow_top.png)}button.gv-zoom-btn.pan-top:hover{background:inherit;background-image:url(../img/gv_arrow_top.png)}button.gv-zoom-btn.pan-bottom{background-image:url(../img/gv_arrow_bottom.png)}button.gv-zoom-btn.pan-bottom:hover{background:inherit;background-image:url(../img/gv_arrow_bottom.png)}button.gv-zoom-btn.btn-zoom{height:14px;margin:0;padding:0;position:absolute;width:16px}button.gv-zoom-btn.btn-zoom-top{border:0;box-shadow:none;left:13px;top:1}button.gv-zoom-btn.btn-zoom-left{border:0;box-shadow:none;left:0;top:13px}button.gv-zoom-btn.btn-zoom-bottom{border:0;box-shadow:none;left:13px;top:25px}button.gv-icon-btn{-moz-border-radius:0!important;-webkit-border-radius:0!important;border-radius:0!important;background-size:36px 36px;height:36px;width:36px}button.gv-icon-btn.active{background-color:#8aa051}button.gv_dropdown_entry{height:30px;margin:4px 4px 4px 30px;width:160px}button.gv_context_button{width:65px}button.large-distance{margin-left:12px}button.short-distance{margin-left:6px}button.shutdown{margin-top:6px;padding:3px 14px}button.graphViewer-icon-button{background-color:transparent;border:0;height:20px;margin-left:5px;margin-top:-2px;padding:0;width:20px}button.graphViewer-icon-button img{height:20px;padding-bottom:10px;width:20px}ul.headerButtonList{display:inline-block;margin-bottom:0;margin-left:0;padding-left:0!important}ul.headerButtonList li{display:inline}a.button-gui,a.headerButton{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;margin-left:5px;margin-right:5px}a.headerButton{margin-top:2px;position:relative}a.headerButton .fa,a.headerButton [class*=" icon_"],a.headerButton [class^=icon_]{display:block;height:23px;line-height:23px;position:static;right:0;text-align:center;top:0;width:27px}a.headerButton .icon_arangodb_arrowleft,a.headerButton .icon_arangodb_arrowright{font-weight:700}a.headerButton.activated{background-color:#788f3d;border:1px solid #788f3d;color:#fff}div.toolbox,div.toolbox div.gv_action_button{-moz-border-radius:3px;-webkit-border-radius:3px;background-color:#fff}a.headerButton.activated:hover{background-color:#fff;color:#788f3d}div.toolbox{border-radius:3px;border:1px solid rgba(140,138,137,.25);margin-right:5px;margin-top:-3px;padding-bottom:5px;padding-top:5px;position:absolute}div.toolbox div.gv_action_button{border-radius:3px;color:#555;height:30px;margin:5px;position:relative;text-align:center;width:30px}div.toolbox div.gv_action_button.active{background-color:#8aa051;color:#fff}div.toolbox div.gv_action_button:first-child{margin-top:0}div.toolbox div.gv_action_button:last-child{margin-bottom:0}h6.gv_button_title,h6.gv_icon_icon{left:0;margin:0;position:absolute;right:0}h6.gv_icon_icon{font-size:22px;left:1px;top:4px}h6.gv_button_title{bottom:1px;display:none}.btn-icon{background-color:#383434;padding:4px}.gv-icon-small{background-size:16px 16px;height:16px!important;width:16px!important}.gv-icon-small.delete{background-image:url(../img/icon_delete.png)}.gv-icon-small.add{background-image:url(../img/plus_icon.png)}a.pagination-button,ul.arango-pagination a{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px}.badge,.btn,.label{text-shadow:none!important}.navbar-inner,.thumbnail{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;-webkit-box-shadow:0;-moz-box-shadow:0;box-shadow:0}.modal-body th.actionCell>button{margin-top:-12px}.btn-old-padding{padding-bottom:4px!important;padding-top:4px!important}button.btn-overview,button.btn-server{margin:5px}a.button-gui{height:auto;margin-bottom:0;margin-top:0;padding-bottom:1px;padding-top:1px;position:absolute;right:2px;text-decoration:none!important;top:2px;width:auto}a.button-gui.button-gui-disabled{display:none}.clusterDownBtn{padding-bottom:10px;padding-top:10px;text-align:center}.clusterDownBtn button{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#f1f1f1;border:1px solid rgba(0,0,0,.1875);color:#333;font-size:20px;font-weight:300;margin:0;padding:12px 18px;text-align:center;text-decoration:none!important;width:250px}.clusterDownBtn button:hover{background-color:#e8e8e8;color:#4a6c30;-webkit-transition-delay:0;-webkit-transition-duration:.2s;-webkit-transition-property:all;-webkit-transition-timing-function:ease-in}.clusterDownBtn button.green{background-color:#617e2b;color:#fff}.clusterDownBtn button.green:hover{background-color:#8ba142}.bottomButtonBar{background-color:#fff;border-top:1px solid rgba(104,103,102,.1);height:30px;padding:10px}.tileList{margin-left:-6px;margin-right:-6px}.tileList legend{padding-left:5px}.tileList .tile:first-child a{opacity:.8}.tileList .tile:first-child a:hover{opacity:1}div .bigtile,div .tile{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:#fff;border:1px solid #f5f8f0;border-radius:3px;font-size:14px;list-style:none;margin-bottom:13px;margin-left:6px;margin-right:6px;position:relative;text-align:center;z-index:1}div .bigtile progress[value],div .tile progress[value]{color:#5bc0de}div .bigtile progress::-webkit-progress-bar-value,div .tile progress::-webkit-progress-bar-value{background:#5bc0de}div .bigtile progress::-webkit-progress-value,div .tile progress::-webkit-progress-value{background:#5bc0de}div .bigtile progress::-moz-progress-bar,div .tile progress::-moz-progress-bar{background:#5bc0de}div .bigtile progress,div .tile progress{-webkit-appearance:none;border-radius:0;height:2px;margin-top:16px;position:relative;width:100%;z-index:10}div .locked.bigtile,div .locked.tile{cursor:not-allowed;opacity:.5}div .locked.bigtile .iconSet span:hover,div .locked.tile .iconSet span:hover{background-color:#fff!important;color:#000;cursor:not-allowed!important}div .locked.bigtile .iconSet:hover,div .locked.tile .iconSet:hover{cursor:not-allowed!important}div .bigtile .collection-type-icon:hover,div .bigtile img:hover,div .tile .collection-type-icon:hover,div .tile img:hover{cursor:pointer}div .bigtile .warning-icons,div .tile .warning-icons{background-color:#da4f49;border-radius:3px;color:#fff;font-size:11px;height:17px;left:0;line-height:13px;margin-left:5px;margin-top:5px;padding-left:9px;padding-right:9px;position:absolute;top:0}div .bigtile a svg.icon,div .bigtile img.icon,div .tile a svg.icon,div .tile img.icon{height:50px;width:50px}div .bigtile .warning-icons .fa,div .tile .warning-icons .fa{font-size:11pt;margin-left:1px}div .bigtile .collection-type-icon,div .tile .collection-type-icon{color:#666;font-size:30pt;margin-top:12pt}div .bigtile img,div .tile img{position:relative}div .bigtile a span.add-Icon,div .tile a span.add-Icon{font-size:22px;margin-left:22px;margin-right:10px;margin-top:-5px;position:relative;right:4px;top:2px}div .bigtile a span.icon,div .tile a span.icon{font-size:50px}div .bigtile .tile-icon-svg,div .tile .tile-icon-svg{cursor:pointer;fill:#686766;height:50px;margin-left:90px;margin-top:10px;position:absolute;width:50px}div .bigtile .tile-icon,div .tile .tile-icon{color:#686766;font-size:50px;line-height:1.2}div .bigtile .icon_arangodb_edge5-2,div .tile .icon_arangodb_edge5-2{display:inline-block;position:relative;top:15px;-moz-transform:rotate(80deg);-o-transform:rotate(80deg);-webkit-transform:rotate(80deg)}div .bigtile h5,div .tile h5{background:#8c8a89;color:#fff;font-size:12px;margin:0;overflow:hidden!important;padding:4px 8px;text-overflow:ellipsis!important;white-space:nowrap!important}div .bigtile h5.inProgress,div .tile h5.inProgress{color:#5bc0de}div .bigtile .tileSelects,div .tile .tileSelects{margin-left:40px;position:relative;z-index:9999}div .bigtile .tileSelects select,div .tile .tileSelects select{float:right;height:20px;margin-right:5px;margin-top:16px;width:70px}div .bigtile .fullBorderBox,div .tile .fullBorderBox{border:1px solid rgba(140,138,137,.25);border-radius:3px;height:100%;position:absolute;width:100%}div.headerBar,div.headerDropdown{border:1px solid rgba(140,138,137,.25)}div .bigtile .borderBox,div .tile .borderBox{border:1px solid rgba(140,138,137,.25);border-radius:3px;height:75px;position:absolute;width:224px}div .bigtile .iconSet,div .tile .iconSet{position:absolute;right:5px;top:5px}div .bigtile .iconSet span,div .tile .iconSet span{border-radius:3px;color:#666;font-size:18px;z-index:2;padding:2px 3px}.modal,.select2-drop-active{z-index:9999999}div .bigtile .iconSet span:hover,div .tile .iconSet span:hover{background-color:#8aa051;color:#fff}div .bigtile .iconSet span.disabled,div .tile .iconSet span.disabled{cursor:default;opacity:.2}div .bigtile .iconSet span.disabled:hover,div .tile .iconSet span.disabled:hover{background-color:#fff;color:#000;cursor:default;opacity:.2}div .bigtile .badge-success,div .tile .badge-success{font-weight:300}div .bigtile .unloaded div,div .tile .unloaded div{border-bottom:16px solid #ff8f35}div .bigtile .deleted div,div .tile .deleted div{border-bottom:16px solid #700}div .bigtile .tileBadge,div .tile .tileBadge{bottom:29px;font-size:11px;font-weight:300;position:absolute;right:0}div .bigtile .tileBadge button,div .tile .tileBadge button{margin-left:0;margin-right:5px}div .bigtile .tileBadge span,div .tile .tileBadge span{display:inline-block;line-height:15px}div .bigtile .tileBadge span .corneredBadge,div .tile .tileBadge span .corneredBadge{border-bottom-style:solid;border-bottom-width:17px;border-left:5px solid transparent;border-radius:3px;color:#fff;height:0;margin-bottom:4px;margin-right:5px;padding-left:1px;padding-right:6px}div .bigtile .tileBadge span .corneredBadge.loading,div .tile .tileBadge span .corneredBadge.loading{border-bottom-color:#ff8f35}div .bigtile .tileBadge span .corneredBadge.loaded,div .tile .tileBadge span .corneredBadge.loaded{border-bottom-color:#8aa051}div .bigtile .tileBadge span .corneredBadge.development,div .bigtile .tileBadge span .corneredBadge.unloaded,div .tile .tileBadge span .corneredBadge.development,div .tile .tileBadge span .corneredBadge.unloaded{border-bottom-color:#ff8f35}div .tile{height:100px;width:226px}div .tile-graph .tile-icon:hover{cursor:pointer}div .bigtile{height:309px;width:452px}div .bigtile .shardContainer{font-size:30px}div .bigtile .shardContainer span{padding:2px}.collectionName{border-bottom-left-radius:3px;border-bottom-right-radius:3px;bottom:0;font-weight:300;left:0;position:absolute;right:0;text-align:left}.resizecontainer{margin:0 auto}@media (max-width:738px){#arangoCollectionUl{display:none}#collectionsDropdown ul{width:auto!important}#arangoCollectionSelect{display:inline-block;height:29px;margin-top:1px}}@media (min-width:739px) and (max-width:1041px){#arangoCollectionUl a{font-size:12px;height:12px;padding:8px 5px}}@media (min-width:1042px) and (max-width:1284px){#arangoCollectionUl a{font-size:14px}}@media (min-width:250px) and (max-width:489px){.resizecontainer{width:228px}.dashboard-full-width-chart{width:225px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:215px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:69.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:214px}.dashboard-large-chart{width:146px}.dashboard-large-chart .dashboard-sub-bar{width:134px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:185px;width:136px}.dashboard-sub-bar-menu{font-size:12px}.dashboard-medium-chart-outer{float:left;width:106px}.dashboard-medium-chart{width:96px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:95px}.dashboard-medium-chart #clusterGraphs svg,.dashboard-medium-chart .dashboard-interior-chart{height:185px;width:96px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:12px;left:79px;top:0}.dashboard-medium-chart #clusterGraphs svg text{font-size:10px}.dashboard-small-chart{width:66px}.dashboard-small-chart .dashboard-sub-bar{width:54px}.dashboard-small-chart .dashboard-small-chart-inner{width:56px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:197px;width:56px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:10px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:78.25px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:8px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:25.08px;line-height:25.08px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:40.17px;line-height:19.08px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:54px}.dashboard-bar-chart-container{height:79.75px}.dashboard-bar-chart-container .dashboard-bar-chart{height:77.75px;width:56px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:25.25px;line-height:25.25px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:28px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:10.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:33.5px;line-height:33.5px;padding:5px 8px 10px;width:40px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:38.5px}.dashboard-bar-chart-container .dashboard-sub-bar{width:54px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-114px;width:248px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{display:none;font-size:12px;min-height:190px;width:10px}.absolut,.percentage{font-size:14px}.modal-chart-detail .modal-inner-detail{width:208px}.modal-body .dashboard-large-chart{width:143px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:131px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:133px}.modal-body .dashboard-medium-chart-outer{float:left;width:91px}.modal-body .dashboard-medium-chart{width:91px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:89px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:91px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:74px}.modal-body .dashboard-small-chart{width:61px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:49px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:51px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:6.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:51px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:56px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:28px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:10.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:40px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:54px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:10px;font-weight:400}.dashboard-subtitle-bar{font-size:14px;font-weight:300}.dashboard-figure{font-size:16px;font-weight:400}.dashboard-figurePer{font-size:14px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:10px}.dashboard-legend{display:none;height:190px;margin-top:-3px;width:0}.dashboard-half-height-legend{display:none;font-size:10px;height:100px;width:0}.application-detail-view section.info{width:228px}.application-detail-view aside.meta{display:none}}@media (min-width:490px) and (max-width:729px){.resizecontainer{width:468px}.dashboard-full-width-chart{width:465px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:455px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:149.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:454px}.dashboard-large-chart{width:306px}.dashboard-large-chart .dashboard-sub-bar{width:294px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:185px;width:296px}.dashboard-sub-bar-menu{font-size:12px}.dashboard-medium-chart-outer{float:left;width:226px}.dashboard-medium-chart{width:216px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:215px}.dashboard-medium-chart #clusterGraphs svg,.dashboard-medium-chart .dashboard-interior-chart{height:185px;width:216px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:12px;left:199px;top:0}.dashboard-medium-chart #clusterGraphs svg text{font-size:10px}.dashboard-small-chart{width:146px}.dashboard-small-chart .dashboard-sub-bar{width:134px}.dashboard-small-chart .dashboard-small-chart-inner{width:136px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:197px;width:136px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:10px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:78.25px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:48px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:25.08px;line-height:25.08px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:40.17px;line-height:19.08px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:134px}.dashboard-bar-chart-container{height:79.75px}.dashboard-bar-chart-container .dashboard-bar-chart{height:77.75px;width:136px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:25.25px;line-height:25.25px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:84px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:34.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:33.5px;line-height:33.5px;padding:5px 8px 10px;width:120px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:38.5px}.dashboard-bar-chart-container .dashboard-sub-bar{width:134px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-234px;width:488px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{display:none;font-size:12px;min-height:190px;width:10px}.absolut,.percentage{font-size:14px}.modal-chart-detail .modal-inner-detail{width:448px}.modal-body .dashboard-large-chart{width:303px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:291px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:293px}.modal-body .dashboard-medium-chart-outer{float:left;width:211px}.modal-body .dashboard-medium-chart{width:211px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:209px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:211px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:194px}.modal-body .dashboard-small-chart{width:141px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:129px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:131px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:46.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:131px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:136px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:84px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:34.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:120px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:134px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:10px;font-weight:400}.dashboard-subtitle-bar{font-size:14px;font-weight:300}.dashboard-figure{font-size:16px;font-weight:400}.dashboard-figurePer{font-size:14px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:10px}.dashboard-legend{display:none;height:190px;margin-top:-3px;width:0}.dashboard-half-height-legend{display:none;font-size:10px;height:100px;width:0}.application-detail-view section.info{width:468px}.application-detail-view aside.meta{display:none}}@media (min-width:730px) and (max-width:969px){.resizecontainer{width:708px}.dashboard-full-width-chart{width:705px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:695px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:229.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:694px}.dashboard-large-chart{width:466px}.dashboard-large-chart .dashboard-sub-bar{width:454px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:185px;width:456px}.dashboard-sub-bar-menu{font-size:12px}.dashboard-medium-chart-outer{float:left;width:346px}.dashboard-medium-chart{width:336px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:335px}.dashboard-medium-chart #clusterGraphs svg,.dashboard-medium-chart .dashboard-interior-chart{height:185px;width:336px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:12px;left:319px;top:0}.dashboard-medium-chart #clusterGraphs svg text{font-size:10px}.dashboard-small-chart{width:226px}.dashboard-small-chart .dashboard-sub-bar{width:214px}.dashboard-small-chart .dashboard-small-chart-inner{width:216px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:197px;width:216px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:10px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:78.25px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:88px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:25.08px;line-height:25.08px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:40.17px;line-height:19.08px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:214px}.dashboard-bar-chart-container{height:79.75px}.dashboard-bar-chart-container .dashboard-bar-chart{height:77.75px;width:216px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:25.25px;line-height:25.25px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:140px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:58.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:33.5px;line-height:33.5px;padding:5px 8px 10px;width:200px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:38.5px}.dashboard-bar-chart-container .dashboard-sub-bar{width:214px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-354px;width:728px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{display:none;font-size:12px;min-height:190px;width:10px}.absolut,.percentage{font-size:14px}.modal-chart-detail .modal-inner-detail{width:688px}.modal-body .dashboard-large-chart{width:463px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:451px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:453px}.modal-body .dashboard-medium-chart-outer{float:left;width:331px}.modal-body .dashboard-medium-chart{width:331px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:329px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:331px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:314px}.modal-body .dashboard-small-chart{width:221px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:209px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:211px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:86.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:211px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:216px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:140px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:58.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:200px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:214px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:10px;font-weight:400}.dashboard-subtitle-bar{font-size:14px;font-weight:300}.dashboard-figure{font-size:16px;font-weight:400}.dashboard-figurePer{font-size:14px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:10px}.dashboard-legend{display:none;height:190px;margin-top:-3px;width:0}.dashboard-half-height-legend{display:none;font-size:10px;height:100px;width:0}.application-detail-view section.info{width:508px}}@media (min-width:970px) and (max-width:1209px){.resizecontainer{width:948px}.dashboard-full-width-chart{width:945px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:935px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:309.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:934px}.dashboard-large-chart{width:626px}.dashboard-large-chart .dashboard-sub-bar{width:614px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:220px;width:496px}.dashboard-sub-bar-menu{font-size:13px}.dashboard-medium-chart-outer{float:left;width:466px}.dashboard-medium-chart{width:456px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:455px}.dashboard-medium-chart .dashboard-interior-chart{height:220px;width:336px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:13px;left:438px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:220px;width:456px}.dashboard-medium-chart #clusterGraphs svg text{font-size:11px}.dashboard-small-chart{width:306px}.dashboard-small-chart .dashboard-sub-bar{width:294px}.dashboard-small-chart .dashboard-small-chart-inner{width:296px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:229px;width:296px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:11px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:96.5px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:128px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:31.17px;line-height:31.17px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:52.33px;line-height:25.17px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:294px}.dashboard-bar-chart-container{height:98px}.dashboard-bar-chart-container .dashboard-bar-chart{height:96px;width:296px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:31.33px;line-height:31.33px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:196px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:82.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:45.67px;line-height:45.67px;padding:5px 8px 10px;width:280px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:50.67px}.dashboard-bar-chart-container .dashboard-sub-bar{width:294px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-474px;width:968px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:13px;min-height:225px;width:130px}.absolut,.percentage{font-size:15px}.modal-chart-detail .modal-inner-detail{width:808px}.modal-body .dashboard-large-chart{width:623px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:611px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:493px}.modal-body .dashboard-medium-chart-outer{float:left;width:451px}.modal-body .dashboard-medium-chart{width:451px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:449px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:331px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:433px}.modal-body .dashboard-small-chart{width:301px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:289px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:291px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:126.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:291px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:296px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:196px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:82.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:280px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:294px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:11px;font-weight:400}.dashboard-subtitle-bar{font-size:15px;font-weight:300}.dashboard-figure{font-size:18px;font-weight:400}.dashboard-figurePer{font-size:16px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:11px}.dashboard-legend{height:225px;margin-top:-3px;width:120px}.dashboard-half-height-legend{font-size:11px;height:117.5px;width:60px}.application-detail-view section.info{width:748px}}@media (min-width:1210px) and (max-width:1449px){.resizecontainer{width:1188px}.dashboard-full-width-chart{width:1185px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:1175px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:389.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:1174px}.dashboard-large-chart{width:786px}.dashboard-large-chart .dashboard-sub-bar{width:774px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:255px;width:646px}.dashboard-sub-bar-menu{font-size:15px}.dashboard-medium-chart-outer{float:left;width:586px}.dashboard-medium-chart{width:576px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:575px}.dashboard-medium-chart .dashboard-interior-chart{height:255px;width:446px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:16px;left:555px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:255px;width:576px}.dashboard-medium-chart #clusterGraphs svg text{font-size:12px}.dashboard-small-chart{width:386px}.dashboard-small-chart .dashboard-sub-bar{width:374px}.dashboard-small-chart .dashboard-small-chart-inner{width:376px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:264px;width:376px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:13px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:114px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:168px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:37px;line-height:37px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:64px;line-height:31px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:374px}.dashboard-bar-chart-container{height:115.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:113.5px;width:376px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:37.17px;line-height:37.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:252px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:106.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:57.33px;line-height:57.33px;padding:5px 8px 10px;width:360px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:62.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:374px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-594px;width:1208px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:14px;min-height:260px;width:140px}.absolut,.percentage{font-size:18px}.modal-chart-detail .modal-inner-detail{width:1038px}.modal-body .dashboard-large-chart{width:783px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:771px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:643px}.modal-body .dashboard-medium-chart-outer{float:left;width:571px}.modal-body .dashboard-medium-chart{width:571px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:569px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:441px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:550px}.modal-body .dashboard-small-chart{width:381px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:369px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:371px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:166.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:371px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:376px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:252px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:106.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:360px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:374px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:13px;font-weight:400}.dashboard-subtitle-bar{font-size:18px;font-weight:300}.dashboard-figure{font-size:22px;font-weight:400}.dashboard-figurePer{font-size:20px;font-weight:300}.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-size:13px;font-weight:400}.dashboard-legend{font-size:12px;font-weight:400;height:260px;margin-top:-3px;width:130px}.dashboard-half-height-legend{font-size:12px;height:135px;width:65px}.application-detail-view section.info{width:988px}}@media (min-width:1450px) and (max-width:1689px){.resizecontainer{width:1428px}.dashboard-full-width-chart{width:1425px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:1415px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:469.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:1414px}.dashboard-large-chart{width:946px}.dashboard-large-chart .dashboard-sub-bar{width:934px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:285px;width:796px}.dashboard-sub-bar-menu{font-size:15px}.dashboard-medium-chart-outer{float:left;width:706px}.dashboard-medium-chart{width:696px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:695px}.dashboard-medium-chart .dashboard-interior-chart{height:285px;width:556px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:18px;left:673px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:285px;width:696px}.dashboard-medium-chart #clusterGraphs svg text{font-size:13px}.dashboard-small-chart{width:466px}.dashboard-small-chart .dashboard-sub-bar{width:454px}.dashboard-small-chart .dashboard-small-chart-inner{width:456px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:294px;width:456px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:13px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:129px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:208px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:42px;line-height:42px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:74px;line-height:36px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:454px}.dashboard-bar-chart-container{height:130.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:128.5px;width:456px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:42.17px;line-height:42.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:308px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:130.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:67.33px;line-height:67.33px;padding:5px 8px 10px;width:440px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:72.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:454px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-714px;width:1448px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:15px;min-height:290px;width:150px}.absolut,.percentage{font-size:20px}.modal-chart-detail .modal-inner-detail{width:1268px}.modal-body .dashboard-large-chart{width:943px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:931px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:793px}.modal-body .dashboard-medium-chart-outer{float:left;width:691px}.modal-body .dashboard-medium-chart{width:691px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:689px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:551px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:668px}.modal-body .dashboard-small-chart{width:461px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:449px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:451px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:206.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:451px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:456px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:308px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:130.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:440px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:454px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:13px;font-weight:400}.dashboard-subtitle-bar{font-size:20px;font-weight:300}.dashboard-figure{font-size:26px;font-weight:400}.dashboard-figurePer{font-size:24px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:13px}.dashboard-legend{height:290px;margin-top:-3px;width:140px}.dashboard-half-height-legend{font-size:13px;height:150px;width:70px}.application-detail-view section.info{width:1228px}}@media (min-width:1690px) and (max-width:1929px){.resizecontainer{width:1668px}.dashboard-full-width-chart{width:1665px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:1655px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:549.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:1654px}.dashboard-large-chart{width:1106px}.dashboard-large-chart .dashboard-sub-bar{width:1094px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:325px;width:936px}.dashboard-sub-bar-menu{font-size:16px}.dashboard-medium-chart-outer{float:left;width:826px}.dashboard-medium-chart{width:816px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:815px}.dashboard-medium-chart .dashboard-interior-chart{height:325px;width:656px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:22px;left:789px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:325px;width:816px}.dashboard-medium-chart #clusterGraphs svg text{font-size:14px}.dashboard-small-chart{width:546px}.dashboard-small-chart .dashboard-sub-bar{width:534px}.dashboard-small-chart .dashboard-small-chart-inner{width:536px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:334px;width:536px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:14px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:149px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:248px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:48.67px;line-height:48.67px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:87.33px;line-height:42.67px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:534px}.dashboard-bar-chart-container{height:150.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:148.5px;width:536px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:48.83px;line-height:48.83px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:364px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:154.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:80.67px;line-height:80.67px;padding:5px 8px 10px;width:520px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:85.67px}.dashboard-bar-chart-container .dashboard-sub-bar{width:534px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-834px;width:1688px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:16px;min-height:330px;width:170px}.absolut,.percentage{font-size:24px}.modal-chart-detail .modal-inner-detail{width:1488px}.modal-body .dashboard-large-chart{width:1103px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1091px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:933px}.modal-body .dashboard-medium-chart-outer{float:left;width:811px}.modal-body .dashboard-medium-chart{width:811px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:809px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:651px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:784px}.modal-body .dashboard-small-chart{width:541px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:529px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:531px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:246.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:531px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:536px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:364px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:154.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:520px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:534px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:14px;font-weight:400}.dashboard-subtitle-bar{font-size:24px;font-weight:300}.dashboard-figure{font-size:30px;font-weight:400}.dashboard-figurePer{font-size:28px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:14px}.dashboard-legend{height:330px;margin-top:-3px;width:160px}.dashboard-half-height-legend{font-size:14px;height:170px;width:80px}.application-detail-view section.info{width:1468px}}@media (min-width:1930px) and (max-width:2169px){.resizecontainer{width:1908px}.dashboard-full-width-chart{width:1905px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:1895px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:629.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:1894px}.dashboard-large-chart{width:1266px}.dashboard-large-chart .dashboard-sub-bar{width:1254px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:385px;width:1086px}.dashboard-sub-bar-menu{font-size:17px}.dashboard-medium-chart-outer{float:left;width:946px}.dashboard-medium-chart{width:936px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:935px}.dashboard-medium-chart .dashboard-interior-chart{height:385px;width:766px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:26px;left:905px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:385px;width:936px}.dashboard-medium-chart #clusterGraphs svg text{font-size:15px}.dashboard-small-chart{width:626px}.dashboard-small-chart .dashboard-sub-bar{width:614px}.dashboard-small-chart .dashboard-small-chart-inner{width:616px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:394px;width:616px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:14px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:179px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:288px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:58.67px;line-height:58.67px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:107.33px;line-height:52.67px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:614px}.dashboard-bar-chart-container{height:180.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:178.5px;width:616px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:58.83px;line-height:58.83px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:420px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:178.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:100.67px;line-height:100.67px;padding:5px 8px 10px;width:600px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:105.67px}.dashboard-bar-chart-container .dashboard-sub-bar{width:614px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-954px;width:1928px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:17px;min-height:390px;width:180px}.absolut,.percentage{font-size:28px}.modal-chart-detail .modal-inner-detail{width:1718px}.modal-body .dashboard-large-chart{width:1263px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1251px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:1083px}.modal-body .dashboard-medium-chart-outer{float:left;width:931px}.modal-body .dashboard-medium-chart{width:931px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:929px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:761px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:900px}.modal-body .dashboard-small-chart{width:621px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:609px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:611px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:286.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:611px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:616px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:420px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:178.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:600px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:614px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:15px;font-weight:400}.dashboard-subtitle-bar{font-size:28px;font-weight:300}.dashboard-figure{font-size:34px;font-weight:400}.dashboard-figurePer{font-size:32px;font-weight:300}.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-size:14px;font-weight:400}.dashboard-legend{font-size:15px;font-weight:400;height:390px;margin-top:-3px;width:170px}.dashboard-half-height-legend{font-size:15px;height:200px;width:85px}.application-detail-view section.info{width:1708px}}@media (min-width:2170px) and (max-width:2409px){.resizecontainer{width:2148px}.dashboard-full-width-chart{width:2145px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:2135px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:709.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:2134px}.dashboard-large-chart{width:1426px}.dashboard-large-chart .dashboard-sub-bar{width:1414px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:285px;width:1276px}.dashboard-sub-bar-menu{font-size:17px}.dashboard-medium-chart-outer{float:left;width:1066px}.dashboard-medium-chart{width:1056px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:1055px}.dashboard-medium-chart .dashboard-interior-chart{height:285px;width:916px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:20px;left:1031px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:285px;width:1056px}.dashboard-medium-chart #clusterGraphs svg text{font-size:15px}.dashboard-small-chart{width:706px}.dashboard-small-chart .dashboard-sub-bar{width:694px}.dashboard-small-chart .dashboard-small-chart-inner{width:696px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:294px;width:696px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:15px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:129px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:328px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:42px;line-height:42px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:74px;line-height:36px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:694px}.dashboard-bar-chart-container{height:130.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:128.5px;width:696px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:42.17px;line-height:42.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:476px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:202.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:67.33px;line-height:67.33px;padding:5px 8px 10px;width:680px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:72.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:694px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-1074px;width:2168px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:17px;min-height:290px;width:150px}.absolut,.percentage{font-size:22px}.modal-chart-detail .modal-inner-detail{width:1988px}.modal-body .dashboard-large-chart{width:1423px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1411px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:1273px}.modal-body .dashboard-medium-chart-outer{float:left;width:1051px}.modal-body .dashboard-medium-chart{width:1051px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:1049px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:911px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:1026px}.modal-body .dashboard-small-chart{width:701px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:689px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:691px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:326.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:691px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:696px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:476px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:202.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:680px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:694px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:15px;font-weight:400}.dashboard-subtitle-bar{font-size:22px;font-weight:300}.dashboard-figure{font-size:36px;font-weight:400}.dashboard-figurePer{font-size:34px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:15px}.dashboard-legend{height:290px;margin-top:-3px;width:140px}.dashboard-half-height-legend{font-size:15px;height:150px;width:70px}.application-detail-view section.info{width:1948px}}@media (min-width:2410px) and (max-width:2649px){.resizecontainer{width:2388px}.dashboard-full-width-chart{width:2385px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:2375px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:789.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:2374px}.dashboard-large-chart{width:1586px}.dashboard-large-chart .dashboard-sub-bar{width:1574px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:285px;width:1436px}.dashboard-sub-bar-menu{font-size:17px}.dashboard-medium-chart-outer{float:left;width:1186px}.dashboard-medium-chart{width:1176px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:1175px}.dashboard-medium-chart .dashboard-interior-chart{height:285px;width:1036px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:20px;left:1151px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:285px;width:1176px}.dashboard-medium-chart #clusterGraphs svg text{font-size:15px}.dashboard-small-chart{width:786px}.dashboard-small-chart .dashboard-sub-bar{width:774px}.dashboard-small-chart .dashboard-small-chart-inner{width:776px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:294px;width:776px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:15px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:129px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:368px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:42px;line-height:42px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:74px;line-height:36px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:774px}.dashboard-bar-chart-container{height:130.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:128.5px;width:776px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:42.17px;line-height:42.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:532px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:226.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:67.33px;line-height:67.33px;padding:5px 8px 10px;width:760px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:72.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:774px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-1194px;width:2408px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:17px;min-height:290px;width:150px}.absolut,.percentage{font-size:22px}.modal-chart-detail .modal-inner-detail{width:2228px}.modal-body .dashboard-large-chart{width:1583px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1571px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:1433px}.modal-body .dashboard-medium-chart-outer{float:left;width:1171px}.modal-body .dashboard-medium-chart{width:1171px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:1169px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:1031px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:1146px}.modal-body .dashboard-small-chart{width:781px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:769px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:771px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:366.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:771px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:776px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:532px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:226.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:760px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:774px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:15px;font-weight:400}.dashboard-subtitle-bar{font-size:22px;font-weight:300}.dashboard-figure{font-size:36px;font-weight:400}.dashboard-figurePer{font-size:34px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:15px}.dashboard-legend{height:290px;margin-top:-3px;width:140px}.dashboard-half-height-legend{font-size:15px;height:150px;width:70px}.application-detail-view section.info{width:2188px}}@media (min-width:2650px) and (max-width:2889px){.resizecontainer{width:2628px}.dashboard-full-width-chart{width:2625px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{width:2615px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{float:left;width:869.33px}.dashboard-full-width-chart .dashboard-sub-bar{width:2614px}.dashboard-large-chart{width:1746px}.dashboard-large-chart .dashboard-sub-bar{width:1734px}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{height:285px;width:1596px}.dashboard-sub-bar-menu{font-size:17px}.dashboard-medium-chart-outer{float:left;width:1306px}.dashboard-medium-chart{width:1296px}.dashboard-medium-chart .dashboard-sub-bar{margin-left:-5px;width:1295px}.dashboard-medium-chart .dashboard-interior-chart{height:285px;width:1156px}.dashboard-medium-chart .dashboard-medium-chart-menu{font-size:20px;left:1271px;top:0}.dashboard-medium-chart #clusterGraphs svg{height:285px;width:1296px}.dashboard-medium-chart #clusterGraphs svg text{font-size:15px}.dashboard-small-chart{width:866px}.dashboard-small-chart .dashboard-sub-bar{width:854px}.dashboard-small-chart .dashboard-small-chart-inner{width:856px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{height:294px;width:856px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-axis text{fill:#666;font-size:15px;font-weight:400}.dashboard-tendency-container .dashboard-tendency-chart{height:129px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:408px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar{height:42px;line-height:42px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure{height:74px;line-height:36px;padding-top:5px}.dashboard-tendency-container .dashboard-sub-bar{width:854px}.dashboard-bar-chart-container{height:130.5px}.dashboard-bar-chart-container .dashboard-bar-chart{height:128.5px;width:856px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{height:42.17px;line-height:42.17px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:588px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:250.8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart{height:67.33px;line-height:67.33px;padding:5px 8px 10px;width:840px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart #residentSizeChart{height:72.33px}.dashboard-bar-chart-container .dashboard-sub-bar{width:854px}.modal-chart-detail{bottom:12.1%!important;left:50%;margin-left:-1314px;width:2648px!important}.modal-chart-detail .modal-body{height:95%;max-height:none;padding:5px}.modal-chart-detail .modal-dashboard-legend{font-size:17px;min-height:290px;width:150px}.absolut,.percentage{font-size:22px}.modal-chart-detail .modal-inner-detail{width:2468px}.modal-body .dashboard-large-chart{width:1743px}.modal-body .dashboard-large-chart .dashboard-sub-bar{width:1731px}.modal-body .dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart{width:1593px}.modal-body .dashboard-medium-chart-outer{float:left;width:1291px}.modal-body .dashboard-medium-chart{width:1291px}.modal-body .dashboard-medium-chart .dashboard-sub-bar{width:1289px}.modal-body .dashboard-medium-chart .dashboard-interior-chart{width:1151px}.modal-body .dashboard-medium-chart .dashboard-medium-chart-menu{left:1266px}.modal-body .dashboard-small-chart{width:861px}.modal-body .dashboard-small-chart .dashboard-sub-bar{width:849px}.modal-body .dashboard-small-chart .dashboard-small-chart-inner,.modal-body .dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart{width:851px}.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-figure,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-subtitle-bar,.modal-body .dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{width:406.5px}.modal-body .dashboard-tendency-container .dashboard-sub-bar{width:851px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart{width:856px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{width:588px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{width:250.8px}.modal-body .dashboard-bar-chart-container .dashboard-bar-chart-chart{width:840px}.modal-body .dashboard-bar-chart-container .dashboard-sub-bar{width:854px}.absolut{font-weight:300}.dashboard-sub-bar{font-size:15px;font-weight:400}.dashboard-subtitle-bar{font-size:22px;font-weight:300}.dashboard-figure{font-size:36px;font-weight:400}.dashboard-figurePer{font-size:34px;font-weight:300}.dashboard-legend,.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{font-weight:400;font-size:15px}.dashboard-legend{height:290px;margin-top:-3px;width:140px}.dashboard-half-height-legend{font-size:15px;height:150px;width:70px}.application-detail-view section.info{width:2428px}}div.centralRow{margin-bottom:40px;margin-top:40px}div.centralContent{background-color:transparent;height:100%;margin-left:-5px;margin-right:-5px;min-height:80px;padding:5px;width:100%}.contentDiv{list-style:none;padding:13px 0 0}.contentDiv li{background-color:rgba(0,0,0,.05)}.contentDiv a.add{display:block;font-weight:400;padding:40px 0;text-align:left}.modal-body th .valueCell,.modal-body th th.actionCell,.modal-body th th.keyCell,.waitModal{text-align:center}.contentDiv .icon{padding-left:5px;padding-right:5px;padding-top:10px}.contentDiv:after{clear:both}.contentDiv:after,.contentDiv:before{display:table;line-height:0}.clusterInfoIcon{float:left;padding-left:5px;padding-top:2px}.waitModal.icon{font-size:100px;height:120px}.waitModal.message{font-size:20px}.icon_arangodb_info{color:#333;font-size:23px}li a [class*=" icon_arangodb"],li a [class^=icon_arangodb]{font-size:18px;position:absolute;right:4px;top:2px}.fa-minus-circle{color:#da4f49;font-size:14pt}.fa-minus-circle:hover{cursor:pointer}div.headerDropdown{background-color:#fff;border-radius:3px;clear:both;display:none;padding:10px;position:relative;width:auto}div.headerDropdown.smallDropdown .dropdownInner{min-height:20px}div.headerDropdown.headerDropdown input[type=checkbox].css-checkbox{display:none}div.headerDropdown.headerDropdown input[type=checkbox].css-checkbox label.css-label{background-position:0 0;background-repeat:no-repeat;display:inline-block;font-size:15px;height:15px;margin-top:0;padding-left:20px;vertical-align:middle}div.headerDropdown.headerDropdown input[type=checkbox].css-checkbox:checked+label.css-label{background-position:0 -15px}div.dropdown-title{margin-bottom:10px}div.dropdownInner{-webkit-box-shadow:0;-moz-box-shadow:0;box-shadow:0;min-height:125px;position:relative;width:auto}div.dropdownInner .nav-header{font-size:10pt}div.dropdownInner>.nav-header{color:#000;font-size:10pt;font-weight:400}div.dropdownInner>label{color:#000;font-weight:300}div.dropdownInner ul{border-left:1px solid rgba(140,138,137,.25);display:inline;list-style-type:none;margin-top:10px;min-height:105px;width:230px}div.dropdownInner ul:first-of-type,div.queryline input[type=file]{border:0}div.dropdownInner ul label{color:#000;padding-left:20px}div.dropdownInner ul li .fa{color:#999;margin-right:5px}div.dropdownInner ul li .fa.fa-square-o{margin-left:1px;margin-right:6px}div.dropdownInner ul li .fa.fa-check-circle-o,div.dropdownInner ul li .fa.fa-check-square-o,div.dropdownInner ul li .fa.fa-dot-circle-o{color:#8aa051}div.queryline{color:#000;height:35px}div.queryline .textDiv{margin-right:10px;margin-top:4px}div.queryline input,div.queryline select{margin-bottom:5px}div.queryline.querylineAdd span{color:#fff;padding-left:10px;position:relative;top:-21px}div.queryline .removeFilterItem i{margin-left:5px!important;margin-top:0!important}div.queryline div.searchByAttribute{margin-left:6px;margin-right:6px;position:relative}div.queryline div.searchByAttribute>ul.gv-dropdown-menu{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;background-color:#fff;color:#fff;display:none;left:0;position:absolute;top:20px;width:247px}div.dropdownImport{background-color:#fff;border-radius:3px;display:none;position:relative;padding:10px 10px 5px}div.dropdownImport input{line-height:0;margin-bottom:-15px;margin-top:5px}select.filterSelect{color:#00f;margin-left:10px;margin-right:10px;width:100px}#filterHeader button{float:right;margin-left:10px!important;margin-top:1px}div.input-append button.gv_example_toggle{-moz-border-radius:0 4px 4px 0;-webkit-border-radius:0 4px 4px 0;border-radius:0 4px 4px 0;background-color:#8f8d8c;height:30px;margin-left:-1px;padding-left:10px;padding-right:10px;padding-top:12px;vertical-align:top}div.input-append button.gv_example_toggle:hover{background-color:#8aa051}div.headerBar,div.headerBar .infoField{background-color:#fff;padding-left:5px;padding-right:5px}.searchEqualsLabel{margin-left:6px;margin-right:6px}img.gv-throbber{background-image:url(../img/swagger/throbber.gif)}span.gv_caret{border-top:5px solid #fff;margin-top:2px!important}input.search-input{height:14px;line-height:18px;margin-right:-1px;margin-top:6px;width:120px}.search-field{margin-left:10px}.search-field .fa-search{color:#c2c2c2;font-size:12pt;opacity:.5;position:absolute;right:9px;top:9px}.search-field .fa-search:hover{cursor:pointer;opacity:1}.gv-search-submit-icon,.search-submit-icon{background-image:url(../img/enter_icon.png);background-size:14px;height:14px;margin-left:-18px;opacity:.2;position:absolute;width:14px}.gv-search-submit-icon:hover,.search-submit-icon:hover{opacity:.8}.search-submit-icon{margin-top:11px}.gv-search-submit-icon{margin-top:6px}div.headerBar{border-radius:3px;color:#fff;font-size:16px;height:36px;margin-bottom:5px;margin-top:15px;position:relative}div.headerBar .infoField{border:1px solid rgba(140,138,137,.25);border-radius:3px!important;color:#000;float:right;font-size:12px;margin-right:7px;margin-top:7px}div.headerBar .infoField .fa{cursor:pointer;margin-left:5px}div.headerBar input[type=checkbox].css-checkbox{display:none}div.headerBar input[type=checkbox].css-checkbox label.css-label{background-position:0 0;background-repeat:no-repeat;cursor:pointer;display:inline-block;font-size:15px;height:15px;margin-top:0;padding-left:20px;vertical-align:middle}div.headerBar input[type=checkbox].css-checkbox:checked+label.css-label{background-position:0 -15px}div.headerBar input[type=radio]{display:none}div.headerBar input[type=radio] label span{background:url(../img/check_radio_sheet.png) -38px top no-repeat;cursor:pointer;display:inline-block;height:19px;margin:-1px 4px 0 0;vertical-align:middle;width:19px}#transparentHeader input[type=checkbox].css-checkbox,.arangoFrame,.contentTables tr.contentRowActive span,.display-none,.modal-delete-confirmation,.query-div,.query-output .ace_cursor-layer,.query-output .ace_replace_form{display:none}div.headerBar input[type=radio]:checked+label span{background:url(../img/check_radio_sheet.png) -57px top no-repeat}.headerButtonList a.error{color:#da4f49}.headerButtonList a.error:hover{background-color:#da4f49;border-color:#da4f49;color:#fff}.headerBar a.arangoHeader{color:#000;font-size:13pt;font-weight:100;left:0;position:relative;top:7px}.headerBar>div.headerButtonBar{margin:4px 0;margin-bottom:0!important}.breadcrumb{background:0 0;border:0;border-radius:0;padding:7px 0}.breadcrumb .disabledBread{color:#666;float:left;font-size:13pt;font-weight:100;padding-right:5px;position:relative}.breadcrumb .disabledBread i{font-size:10pt;margin-left:10px}.breadcrumb .activeBread{color:#8aa051;float:left;font-size:13pt;font-weight:100}.arangoHeader{font-weight:400}.checkboxLabel{margin-top:4px;padding-left:0}.css-label{background-image:url(../img/dark-check-green.png)}.css-label-round{background-image:url(../img/dark-check-green-round.png)}.modal-dashboard-header,.modal-header{background-color:#fff;border-bottom:0!important;border-radius:3px;margin-top:5px;padding-left:5px;padding-right:10px;padding-top:4px}.modal-dashboard-header .arangoHeader,.modal-header .arangoHeader{color:#000;font-size:13pt;font-weight:100;left:5px;position:relative;top:2px}.modal-dashboard-header a,.modal-header a{top:2px!important}.modal-dashboard-header .close,.modal-header .close{color:#fff;font-weight:300;margin-top:2px;opacity:.5}.modal-dashboard-header .close:hover,.modal-header .close:hover{opacity:1}.modal-tabbar{border-bottom:1px solid #666}.modal-body{color:#736b68;font-size:14px;font-weight:300;max-height:410px}.modal-body .select2-choices{background-image:none!important;border:1px solid #999;border-radius:3px;-webkit-box-shadow:none;box-shadow:none}.modal-body .select2-choices input:active{-webkit-box-shadow:none;box-shadow:none;outline:0!important}.modal-body .select2-choices .select2-search-choice{margin:5px 0 3px 5px!important}.modal-body .select2-choices li{background-color:#fff!important;background-image:none!important;color:#000}.modal-body tr.first,.modal-body tr.last,.modal-body tr.middle{background-color:#f5f8f0}.modal-body .select2-choices li a{margin-left:1px;margin-top:-1px}.modal-body .select2-choices:active{border:1px solid #999;-webkit-box-shadow:none!important;box-shadow:none!important;outline:transparent!important}.modal-body .nav-tabs{margin-top:15px}.modal-body .nav-tabs>li>a:hover{border-color:#8c8a89}.modal-body input,.modal-body select,.modal-body textarea{margin-top:10px}.modal-body input[type=checkbox]{margin-bottom:10px}.modal-body input[type=text].invalid-input{border-color:rgba(234,23,23,.6)}.modal-body input[type=text].invalid-input:focus{-webkit-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(234,23,23,.6);-moz-box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(234,23,23,.6);box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(234,23,23,.6)}.modal-body input[type=file]{line-height:17px}.modal-body tr.spacer{height:10px}.modal-body tr.first th:first-child{border-top-left-radius:3px}.modal-body tr.first th:last-child{border-top-right-radius:3px}.modal-body tr.middle{padding-left:10px;padding-right:10px}.modal-body tr.last th:first-child{border-bottom-left-radius:3px}.modal-body tr.last th:last-child{border-bottom-right-radius:3px}.modal-body tr.first th:first-child,.modal-body tr.last th:first-child,.modal-body tr.middle th:first-child{padding-left:10px}.modal-body tr.first th:last-child,.modal-body tr.last th:last-child,.modal-body tr.middle th:last-child{padding-right:10px}.modal-body th.actionCell{width:30px}.modal-body th.keyCell{width:170px}.modal-body th.keyCell input{width:150px}.modal-body th .valueCell{width:300px}.modal-body th .valueCell input{width:290px}.modal-body th .select2-container{margin-bottom:10px;margin-top:10px}.modal-body .icon-info-sign{margin-bottom:10px;margin-left:10px;opacity:.7;padding-bottom:5px}.modal-body .icon-info-sign:hover{opacity:1}.modal-body .icon_arangodb_info{color:#736b68;font-size:18px;margin-top:-10px;position:absolute;right:12px}.modal-body .icon_arangodb_info:hover{color:#000}.modal-body .collapse{margin-right:-14px;position:relative}.modal-body .accordion-inner{border-top:0;margin-left:0;padding-left:0;padding-right:0}.modal-body .accordion-toggle span .caret{border-top-color:#000;float:right;margin-top:5px}.modal-body .accordion-toggle.collapsed span .caret{-ms-transform:rotate(90deg);-webkit-transform:rotate(90deg);transform:rotate(90deg)}.modal-body input{width:384px}.modal-body select{width:398px}.modal-body .collectionTh{height:50px}.modal-body .tab-content{min-height:200px}.modal-body .tab-content .tab-pane{border-top:1px solid #666!important;margin-left:0!important;padding-top:10px}.modal-body .tab-content .tab-pane-modal{border-top:none!important}.modal-body .tab-content #appstore{max-height:290px}.modal-body .errorMessage{background-color:#fff;color:#da4f49;font-size:9pt;font-weight:400;margin-bottom:5px;margin-top:-9px;position:absolute}.modal-body .nav .tab-icon{margin-right:5px;margin-top:-3px;width:20px}.modal-text{font-weight:300;padding-bottom:3px;padding-top:3px}.modal-backdrop,.modal-backdrop.fade.in{opacity:.4}.modal{border:0!important;border-radius:3px!important;box-shadow:0;width:580px}.modal .fade.in{top:12.1%!important}.modal table tr:last-child{border-bottom:0!important}.waitModal{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background:0 0;border:0;color:#fff}.waitModalBackdrop{opacity:.7!important}.modalTooltips span{color:#736b68;font-size:20px}.fixedDropdown .dropdown-header a,.fixedDropdown .notificationItem,.modalTooltips span:hover{color:#000}.gv-object-view{text-align:left;white-space:pre}.capitalize{text-transform:capitalize}.modal-footer{border-top:0!important;padding-right:17px}.modal-header{margin-left:5px;margin-right:5px}.modal-dashboard-header{margin-left:0;margin-right:0;padding-bottom:9px}.modal table tr,.thBorderBottom{border-bottom:1px solid #f7f3f2!important}.modal-delete-confirmation button{margin-right:10px;margin-top:-4px}.modal-delete-confirmation button .modal-confirm-delete{margin-right:-18px}.modal-delete-confirmation fieldset input{float:left}.modal-delete-confirmation fieldset label{float:left;margin-left:10px}.createModalDialog table{width:100%}.createModalDialog .collection-info-figures table{float:left;margin-left:0;margin-right:0;margin-top:0;min-width:200px;padding:3px;text-align:left}.createModalDialog .figures1,.createModalDialog .figures2{margin-bottom:20px;width:255px}.createModalDialog .figures2{margin-left:20px!important}.createModalDialog .figures3{margin-bottom:0;width:100%}.foxx-store-row .foxx-name{font-weight:700}.foxx-store-row .foxx-author{font-size:10pt;font-weight:300;margin-top:-4px}.foxx-store-row .foxx-version{font-weight:400}#new-app-mount{margin-right:24px;width:360px}#control_event_edge_delete_modal,#control_event_edge_edit_modal,#control_event_new_node_modal,#control_event_node_delete_modal,#control_event_node_edit_modal{margin-left:-320px;width:640px}.navlogo .stat_cpu,.navlogo .stat_ram{height:26px;width:26px}.navlogo .stat_cpu{margin-top:1px}.navlogo .stat_cpu path{fill:#aa0}.navlogo .stat_ram path{fill:#070}.navlogo .stat_req{height:22px;width:22px}.navlogo .stat_req path{fill:#aa0}#notification_menu .innerDropdownInnerUL{margin-left:0}#noty_bottom_layout_container li{border:0!important}.noty_bar .arango_message{font-weight:500!important}.noty_bar .arango_message div{float:right;width:20px}.fixedDropdown{background:#fff!important;border-color:rgba(140,138,137,.25)!important;border-radius:3px!important;margin:10px -3px 0!important;right:-1px!important;width:210px}.fixedDropdown .dropdown-header,.fixedDropdown .dropdown-item,.innerDropdownInnerUL{border-bottom:1px solid rgba(0,0,0,.2)}.contentButtons,.contentTables{margin-bottom:10px;width:100%}.fixedDropdown:after{visibility:hidden}.fixedDropdown .dropdown-header{margin-left:-1px;padding:0!important}.fixedDropdown a{padding-left:5px!important}.fixedDropdown .notificationItemContent{font-size:.9em;font-weight:300;margin-left:15px;max-width:180px;min-height:15px;white-space:normal;width:180px;word-wrap:break-word}.contentButtons #createDatabase,.contentButtons #createUser,.dashboard-bar-chart-container:first-child,.dashboard-full-width-chart .dashboard-full-width-chart-inner:first-child,.dashboard-large-chart .dashboard-large-chart-inner:first-child,.dashboard-medium-chart:first-child,.dashboard-small-chart .dashboard-small-chart-inner:first-child,.dashboard-tendency-container:first-child{margin-left:0}.fixedDropdown button{margin-right:5px;margin-top:5px}.fixedDropdown .notificationItem .notificationItemTitle{color:#000;font-weight:400;max-width:165px;overflow-wrap:break-word;white-space:normal;word-wrap:break-word}.fixedDropdown .notificationItem .notificationItemTitle:hover{background-color:transparent;cursor:default}.fixedDropdown .notificationItem i{color:rgba(0,0,0,.2);font-size:20px;padding-left:5px;position:relative;right:2px}.fixedDropdown .notificationItem i:hover{color:#000}.innerDropdownInnerUL{height:220px!important;min-height:220px;overflow-x:hidden;overflow-y:auto;width:100%}.innerDropdownInnerUL .dropdown-item:hover{background-color:#e1e1e1!important}.innerDropdownInnerUL li{width:auto!important}#stat_hd{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#fff;border:1px solid rgba(140,138,137,.25);height:25px;margin-top:3px;position:relative;right:3px;text-align:center;width:25px}#stat_hd #stat_hd_counter{color:#c2c2c2;line-height:25px;text-align:center}.fullNotification{background-color:#da4f49!important;border:1px solid #da4f49!important}.fullNotification p{color:#fff!important}.contentTables tr.contentRowActive a,.contentTables tr.contentRowInactive a{color:#000!important}.contentButtons{clear:both}.contentTables thead{text-align:left}.contentTables thead tr{background-color:#fff;border-bottom:1px solid #c2c2c2}.contentTables tbody tr:nth-child(odd){background-color:#d9d9d9}.contentTables tbody tr:nth-child(even){background-color:#fff}.contentTables tr.contentRowActive{background-color:#bdcc92!important;font-weight:400}.contentTables .dbThFirst{width:90%}.contentTables .dbThSecond{width:10%}.contentTables td{padding:12px 18px}.contentTables td span{float:right;font-size:22px}.contentTables .collectionThSec{margin-right:0;width:80%}.contentTables .collectionTh{margin-right:0;width:5%}.user-menu-img{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#fff;border:1px solid rgba(140,138,137,.25);height:25px;margin-top:-4px}.ui-tooltip{background-color:#8aa051!important;border:0!important;border-radius:3px!important;box-shadow:none!important;color:#fff!important;font-size:10pt!important;font-weight:100!important;z-index:99999999}.dataNotReadyYet,.dygraph-label.dygraph-title{font-family:'Open Sans',sans-serif}.tooltip-inner{max-width:300px!important;white-space:normal!important;word-wrap:break-word!important}.index-tooltip{color:#736b68}.index-tooltip:hover{color:#000}.index-tooltip .arangoicon{font-size:18px!important}.tooltipInfoTh{width:10%}.dbselection{float:left;margin-right:3px;max-width:160px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dashboard-bar-chart-container,.dashboard-full-width-chart .dashboard-full-width-chart-inner,.dashboard-large-chart .dashboard-large-chart-inner,.dashboard-medium-chart,.dashboard-small-chart .dashboard-small-chart-inner,.dashboard-tendency-container{border-top-left-radius:3px;border-top-right-radius:3px}.dashboard-bar-chart-container,.dashboard-full-width-chart,.dashboard-large-chart,.dashboard-medium-chart,.dashboard-small-chart,.dashboard-tendency-container{margin-bottom:10px;position:relative}.dashboard-sub-bar-menu{cursor:pointer;position:absolute;right:9px;top:6px}.dataNotReadyYet{font-size:20px;font-weight:100;text-align:center}.dashboard-sub-bar{background-color:#686766;border-bottom-left-radius:3px;border-bottom-right-radius:3px;color:#fff;height:24px;line-height:24px;margin:0;padding:0 6px}.dashboard-full-width-chart{border:1px solid rgba(104,103,102,.1);border-radius:3px;margin-right:12px}.dashboard-full-width-chart .dashboard-full-width-chart-inner{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;padding-bottom:10px;padding-top:12px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-subtitle-bar.top{border-bottom:1px solid #e1e1e1;height:48px;line-height:48px;text-align:right}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart{border-left:1px solid #e1e1e1}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner{margin-left:10px;margin-right:10px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table{margin-bottom:10px;margin-top:10px;table-layout:fixed;width:100%}.dashboard-large-chart .dashboard-large-chart-inner .dashboard-interior-chart,.dashboard-medium-chart .dashboard-interior-chart{margin-bottom:0}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table .no-data{font-style:italic;font-weight:100}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table tr{border-bottom:1px solid rgba(0,0,0,.025)}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table td:first-child{width:100px}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart .inner table td:last-child{text-align:right}.dashboard-full-width-chart .dashboard-full-width-chart-inner .dashboard-interior-chart:first-child{border-left:0}.dashboard-full-width-chart .state{background-color:#fff;border-radius:5px;color:#000;margin-left:5px;padding-left:6px;padding-right:4px}.dashboard-large-chart{border:1px solid rgba(104,103,102,.1);border-radius:3px;margin-right:12px}.dashboard-large-chart .dashboard-large-chart-inner{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;padding-bottom:10px;padding-top:12px}.dashboard-small-chart{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-small-chart .dashboard-small-chart-inner{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;padding-bottom:10px;padding-top:5px}.dashboard-small-chart .dashboard-small-chart-inner .dashboard-interior-chart .nv-bar rect{fill-opacity:.15;stroke-opacity:.8;stroke-width:.5px}.dashboard-medium-chart-outer{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-medium-chart-outer:first-child{margin-right:10px}.dashboard-medium-chart{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;margin-bottom:0;padding-top:10px}.dashboard-medium-chart:first-child{margin-right:12px}.dashboard-medium-chart .dashboard-medium-chart-outer{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-medium-chart .dashboard-medium-chart-menu{-moz-border-radius:2px;-webkit-border-radius:2px;border-radius:2px;border:0 solid rgba(0,0,0,.3);color:rgba(0,0,0,.3);cursor:pointer;padding:0 4px;position:absolute;z-index:1000}.dashboard-medium-chart .dashboard-medium-chart-menu:hover{color:rgba(0,0,0,.7)}.dashboard-medium-chart .dashboard-medium-chart-inner{padding-bottom:10px}.dashboard-medium-chart .clusterChart .slice path{fill-opacity:.15;stroke-opacity:1;stroke-width:1.5px}.dashboard-tendency-container{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-tendency-container .dashboard-tendency-chart{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;border-top-left-radius:3px;border-top-right-radius:3px;padding-bottom:5px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency{background-color:#fff;margin-top:5px;padding:0 8px}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency:first-child{border-right:1px solid #e1e1e1}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency .dashboard-subtitle-bar{border-bottom:1px solid #e1e1e1;text-align:right}.dashboard-tendency-container .dashboard-tendency-chart .dashboard-tendency .dashboard-figure{text-align:center}.dashboard-bar-chart-container{border:1px solid rgba(104,103,102,.1);border-radius:3px}.dashboard-bar-chart-container .dashboard-bar-chart{background-color:#fff;border-left:5px solid #fff;border-right:5px solid #fff;border-top:5px solid #fff;border-top-left-radius:3px;border-top-right-radius:3px;padding-bottom:5px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title{margin-top:5px;padding:0 8px}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .percentage{font-weight:400}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-title .absolut{text-align:right}#dashboardDetailedChart .dygraph-axis-label-y,.dashboardDetailChart .dygraph-axis-label-y,.innerDashboardChart .dygraph-axis-label-y{text-align:left}.dashboard-bar-chart-container .dashboard-bar-chart .dashboard-bar-chart-chart .nv-bar rect{fill-opacity:.15;stroke-opacity:.8;stroke-width:.5px}.dashboard-legend .dashboard-legend-inner{padding:0 5px 5px 0}.dashboard-spacer{margin:0 12px}.headerBar.dashboard-headerbar{margin:20px 0}.modal-chart-detail .modal-dashboard-legend .dashboard-legend-inner{padding-left:20px}.dashboard-half-height-legend .dashboard-legend-inner{padding-top:20px}.dashboard-title-bar{background-color:#686766;color:#fff;font-size:14.5px;font-weight:400;height:30px;line-height:30px;padding:0 5px 0 10px}.dashboard-title-bar .dashboard-half-title-bar{border-left:1px solid #000;margin-left:-1px;width:50%}.dashboard-title-bar .dashboard-half-title-bar:first-child{border-left:0;margin-left:0}.dashboard-row{margin-bottom:0;margin-left:0;margin-right:0}.dygraph-axis-label.dygraph-axis-label-x,.dygraph-axis-label.dygraph-axis-label-y{color:#666}.dashboardModal{-moz-border-radius:8px!important;-webkit-border-radius:8px!important;border-radius:8px!important;height:80%;margin-left:-45%;min-width:780px;overflow:auto;padding:10px;top:10%;width:90%!important}#dashboardHttpGroup{border:6px solid #000;height:100%;width:100%}#dashboardDetailedChart{border:1px solid #000;height:300px;width:100%}.innerDashboardChart{bottom:5px;left:5px;position:absolute;right:5px;top:5px}.dashboardChart{background-color:#fff;border:1px solid rgba(0,0,0,.2);float:left;height:210px;margin:1.05%;position:relative;width:31%}.dygraph-label.dygraph-title{color:#000;font-size:15px;font-weight:400;text-align:left}.collectionInfoTh2,.collectionTh,.figuresHeader th{font-family:'Open Sans',sans-serif!important}#dashboardDetailedLineChart{padding-top:10px}.dashboardDistribution{float:left;width:270px}.dashboardDistribution svg{height:220px;width:250px}.showHotkeyHelp{cursor:pointer}.shortcuts{font-size:14px;font-weight:200}.shortcuts b{border-left:1px solid rgba(0,0,0,.34);margin-left:5px;padding-left:5px}.shortcuts .clearShortcut,.shortcuts b:first-child{border-left:0;margin-left:0;padding-left:0}.loginFixedWindow{background:#f5f8f0;height:100%;left:0;position:fixed;top:0;width:100%;z-index:9999}.loginFixedWindow .resizecontainer{position:relative;top:0}.loginFixedWindow .resizecontainer img{height:33px;margin-left:-6px;margin-top:9px}.login-window{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;height:auto;left:50%;margin-left:-220px!important;margin-top:-150px;padding:10px;position:absolute;top:50%;width:400px}.login-window .fa{color:rgba(0,0,0,.4);float:right;font-size:14pt;margin-right:5px;margin-top:-34px}.login-window .wrong-credentials{color:#da4f49;margin-top:-30px;text-align:center}.login-window .login-space{height:50px}.login-window .login-input{width:387px}.login-window .form-error{border:1px solid #da4f49!important}toolbar{background-color:#f0f0f0;border-bottom:0;border-style:solid;border-width:1px;font-size:20px;height:27px;margin-left:0;margin-right:0}toolbar span:hover{background-color:#da4f49;color:#fff}.queryBottomActions{border-top:1px solid rgba(140,138,137,.25);padding:10px}.queryExecutionTime{margin-left:10px;margin-top:15px}#queryManagementContent{margin-top:18px}.queryManagementBottomActions{background-color:#fff;border-bottom-left-radius:3px;border-bottom-right-radius:3px;border-top:1px solid #c2c2c2;height:40px;margin-top:-2px;padding-top:10px}.queryMethods,.vars-editor-header{border-top:1px solid rgba(140,138,137,.25)}.queryManagementBottomActions button{margin-right:10px}.queryMethods{padding:10px 10px 5px}.queryMethods input{line-height:0;margin-top:5px}.queryMethods button a{color:#fff}.vars-editor-header{margin-top:-5px;padding-left:5px}.vars-editor-header i{border-radius:2px;color:#666;height:15px;margin-left:5px;padding-left:3px;padding-top:1px;width:15px}.vars-editor-header i:hover{background-color:#8aa051;color:#fff;cursor:pointer}.aql-editor,.vars-editor{border-color:#a0a0a0;border-left:0!important;border-top:1px solid rgba(140,138,137,.25)!important;height:200px;margin-bottom:5px;min-height:100px;min-width:99.8%;width:auto}.aql-editor .ace_error,.aql-editor .ace_info,.vars-editor .ace_error,.vars-editor .ace_info{background:0 0}.queryTH{width:20%!important}.queryTH2{width:75%!important}.query-output{background-color:#fff;border:0;border-top-width:0;height:200px;margin-left:0;margin-right:0;min-height:100px;overflow-y:hidden;width:auto}.query-output .ace_error,.query-output .ace_info{background:0 0}.ace_print-margin{visibility:hidden!important}#documentsTableID_filter,#documentsTableID_length,#documentsTableID_paginate,#documentsTableID_wrapper .fg-toolbar,.jsoneditor .outer .tree>table>tbody>tr:first-of-type{visibility:hidden}.styled-select{float:right;height:30px;overflow:hidden;width:220px}.styled-select select{background:#fff;border:1px solid #c2c2c2!important;border-radius:3px!important;font-size:14px;font-weight:300;height:30px;line-height:1;padding:5px;padding-left:5px!important;padding-top:3px!important}.querySizeDiv,.querySizeDiv select{height:30px!important}.query-select,.query-size{line-height:20px!important;z-index:9999!important}.querySizeDiv{margin-right:10px;width:130px!important}.wide-button-div{height:36px;margin-bottom:15px;margin-top:-10px;padding-top:5px;width:100%}.shortcut-div{float:left;margin-top:-5px;padding-left:45px;width:auto}.query-dropdown-left{margin-top:10px;width:100%}.query-dropdown-right{width:100%}.query-dropdown-right textarea{padding:5px 0 0;resize:vertical;width:100%}.query-dropdown-right textarea:focus{border-color:#8aa051;box-shadow:0 0 3px #8aa051;outline:0}.query-modal-select{padding-left:0;width:100%}.output-toolbar{border-color:silver;border-top:0;position:relative;width:auto}.output-toolbar span{float:right;margin-left:5px;margin-right:5px;position:relative;top:2px}.query-select{border:0!important;border-radius:0!important;margin-bottom:0}.query-select option{z-index:9999!important}.query-dropdown{background-color:#d9d9d9;margin-left:0;margin-right:0;padding-left:5px;padding-right:5px}.tooltip-margin{margin-top:1px}.query-dropdown-in{background-color:#fff;padding:10px}.query-dropdown-in a{color:#686766;font-size:16px;font-weight:bolder;margin-bottom:5px;width:100%}.query-dropdown-in #save-edit-query{margin-left:7px!important}.query-dropdown-in #delete-edit-query{margin-left:0!important}.query-size{border-radius:0!important;width:130px!important}.query-div .arango-table,.query-div .arango-table tbody,.query-div .arango-table tr{max-width:100%;width:100%}#queryContent{margin-top:18px}#queryContent .arango-tab a{border-bottom-color:#ddd;font-weight:100}#queryContent .arango-tab .active{border-bottom-color:#fff!important}.query-div{min-height:360px}.query-div .ace-tm .ace_comment{color:#8aa051}.query-div .icon_arangodb{cursor:pointer;margin-bottom:5px}.query-div .arango-table{border-top:1px solid rgba(140,138,137,.25);table-layout:fixed}.query-div .arango-table .table-cell0{cursor:pointer;min-width:250px;overflow:hidden;text-overflow:ellipsis!important;white-space:nowrap!important;width:20%}.query-div .arango-table .table-cell1,.query-div .arango-table .table-cell2{overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}.query-div .arango-table .table-cell1{cursor:pointer;width:73%}.query-div .arango-table .table-cell2{max-width:40px;min-width:40px;width:40px}.arangoDataTable .key,div.gv-colour-list li{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.queryImport{margin-bottom:10px}.explain-tree,.tab-content{width:100%}.explain-tree .node text{font-size:14px}.explain-tree .link{fill:none;stroke:#ccc;stroke-width:1.5px}.editor-toolbar{border-color:#a0a0a0;height:33px;margin-top:5px}.editor-toolbar span{border-radius:3px;float:right;height:18px;margin-left:3px;position:relative;top:0;width:25px;padding:3px 0 6px 5px}.editor-toolbar .vars-editor-header i,.editor-toolbar span:hover{background-color:#8aa051;color:#fff}.editor-toolbar i{margin-right:5px;margin-top:3px}.editor-toolbar i:hover{cursor:pointer}.editor-toolbar .fa{color:#666;margin-left:1px;margin-top:2px}.editor-toolbar .arango-icon-disk,.editor-toolbar .fa.fa-upload{margin-top:1px}.editor-toolbar .icon_arangodb{color:#666;font-size:14pt}.editor-toolbar .icon_arangodb:first-child{margin-right:10px}.editor-toolbar .fa-comment,.editor-toolbar .fa-comment-o{font-size:15px;position:relative;right:-2px;top:-2px}.row{margin:0 0 20px}.innerContent{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;min-height:200px;padding-top:13px}.arangoFrame{background-color:rgba(0,0,0,.5);bottom:0;left:0;position:fixed;right:0;top:0;z-index:77777}.arangoFrame .outerDiv{min-height:100%;padding:40px;z-index:88888}.arangoFrame .innerDiv{z-index:99999}.arangoFrame .fa-times{color:#fff;float:right;font-size:12pt}.arangoFrame .fa-times:hover{color:#c2c2c2;cursor:pointer}.container{margin-left:20px;margin-right:20px;width:auto!important}.arango-tab{border-bottom:1px solid #ddd;list-style:none;margin-left:0;padding-bottom:0;padding-right:10px}.arango-tab a{-moz-border-radius:0;-webkit-border-radius:0;border-radius:3px 3px 0 0;background-color:#8c8a89;border:1px solid transparent;border-bottom-color:#888;color:#fff;display:block;font-size:13px;line-height:20px;margin-right:2px;min-width:50px;padding:2px 15px;text-align:center}.arango-tab li{background-color:transparent;border:0;margin-bottom:-1px;margin-left:2px;position:relative;z-index:900}.arango-tab li.active a{background:#fff;border-bottom-color:#fff!important;border-left-color:#c2c2c2;border-right-color:#c2c2c2;border-top-color:#c2c2c2;color:#000;height:21px;margin-top:-1px}.jsoneditor,.jsoneditor .menu{background-color:#fff!important}.jsoneditor{border:0 solid rgba(0,0,0,.2)!important}.jsoneditor .menu{border-bottom:1px solid #c2c2c2!important;border-left:0!important;border-right:0!important;border-top:0!important}.jsoneditor .menu button{border:0!important}.jsoneditor .menu button:hover{background-color:#8aa051;color:#fff}.jsoneditor .search .frame{border:0!important;margin:3px!important}.jsoneditor .search .frame input{border:1px solid #c2c2c2!important;border-radius:3px;margin-left:5px;margin-right:5px;margin-top:-2px}.jsoneditor .search .results{color:#fff!important;margin-top:3px!important}.document-editor-extra,div.gv-manage-button-container{margin-top:10px}.document-editor{height:500px;margin-bottom:5px;margin-top:-10px;width:100%}.disabledPag,.disabledPag a{cursor:default!important;opacity:.5!important}.pagination-line{background-color:#fff;border-bottom-left-radius:3px;border-bottom-right-radius:3px;border-top:1px solid rgba(104,103,102,.1);margin:0;padding-top:12px;text-align:center}.pagination-line li a:hover,.pagination-line li.active a,.pagination-line li.active span{background-color:#8f8d8c;color:#fff}.pagination-line li a{background-color:#fff;border:1px solid #fff;font-size:11.9px;line-height:20px;padding:2px 10px;text-decoration:none;border-width:0;min-width:12pt}.pagination-line ul{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;display:inline-block;margin-bottom:0;margin-left:0}.pagination-line li{display:inline-block;margin-left:11px}.pagination-line li span{color:#000;font-size:14px;position:relative;top:2px}.pagination-line li:first-child a,.pagination-line li:first-child span,.pagination-line li:last-child a,.pagination-line li:last-child span{-webkit-box-shadow:0;-moz-box-shadow:0;box-shadow:0;background:#8f8d8c;border:0;color:#000;height:21px;position:relative;width:14px}.pagination-line li.disabled:first-child a,.pagination-line li.disabled:first-child span,.pagination-line li.disabled:last-child a,.pagination-line li.disabled:last-child span{background-color:#777;color:#666;cursor:default;pointer-events:none}.collection-pagination{margin-left:23px!important}.arango-pagination i.fa,.las-pagi i.fa,.pre-pagi i.fa{font-size:19px;position:relative;top:-2px}.arango-pagination li:first-child{margin-right:20px}.arango-pagination li:last-child{margin-left:30px}.pre-pagi{margin-right:-5px!important}.accordion-group{border:0}.accordion-body{height:auto!important}.accordion-heading a{border:1px solid #ccc;color:#000;font-weight:400;width:397px!important}.shell_workspace{margin-top:13px}.shell_workspace ::-webkit-scrollbar{display:none}.replShell{background-color:#fff;float:left;height:100%;min-width:100px;overflow-y:hidden;position:relative;width:100%}.replShell>div{border-radius:3px}.replShell pre{border-bottom:0;border-left:0;border-right:1px solid #a0a0a0;border-top:1px solid #a0a0a0}.jqconsole{background-color:#000;border-radius:0;padding:10px}.jqconsole-header{color:#fff}.jserror{color:#f06;margin-left:-10px}.jssuccess{color:#6f0}.jqconsole-cursor{background-color:grey}.jqconsole-blurred .jqconsole-header .jqconsole-cursor{color:#c4cccc}.jqconsole-prompt{color:#b91}.jqconsole-old-prompt{color:#f60;font-weight:400}.jqconsole-input{color:#dd0}.jqconsole-old-input{color:#bb0;font-weight:400}.jqconsole-output{color:#fff}.query-output .ace_gutter-cell{background-color:#f0f0f0}.centralContent .api-actions{margin:0!important;padding:0}.centralContent .api-actions .container{padding-bottom:10px!important;padding-top:13px!important;margin:0 5px!important}.centralContent .api-actions .resource{border-bottom:0!important;padding-left:5px!important}.centralContent .api-actions .resource .heading>.options{margin:11px 10px 0 0!important}.centralContent .api-actions .resource .heading h2 a{color:#000!important;font-weight:300!important}.centralContent .api-actions .active .heading h2 a{color:#000!important}.centralContent .api-actions .endpoint .operations .content{margin:0!important}.centralContent .api-actions .endpoint .operations .content h4{font-weight:700!important}.centralContent .api-actions .endpoints{margin-right:5px!important}.centralContent .api-actions .endpoints .endpoint:last-child{padding-bottom:5px!important}.centralContent .api-actions input[type=button]{background:#8f8d8c!important;border:none!important;box-shadow:none!important;color:#fff!important;float:right!important;font-size:14px!important;font-weight:300!important;margin-top:10px!important;padding:8px 16px!important}.centralContent .api-actions .endpoint .operations .content,.centralContent .api-actions .endpoint .operations .heading{border-radius:0!important;font-weight:300!important}.centralContent .api-actions .required,.centralContent .api-actions em,.centralContent .api-actions strong,.collectionInfoTh2,.collectionTh,.figuresHeader th{font-weight:400!important}.centralContent .api-actions .http_method,.centralContent .api-actions .toggleOperation{border-radius:0!important}.form-actions{background:0 0;border:0}.form-actions:after,.form-actions:before{display:table;line-height:0}.form-actions:after{clear:both}.swagger-section #swagger-ui-container{margin:.3em 1em!important}.alert{padding:15px 35px 15px 14px}.alert,textarea{border-radius:0!important}.log-content{word-break:break-all;word-wrap:break-word}.log-content-id{margin-top:20px;padding-bottom:0!important}.log-content-id .dataTable{border-collapse:separate;border-spacing:0 5px;table-layout:fixed!important}.log-content-id .arango-tab{border-bottom:0!important}.log-content-id .tab-content{margin-top:1px!important}.tab-content{min-height:390px}.crit-table-id,.debug-table-id,.info-table-id,.log-table-id,.warn-table-id{border-spacing:0 0;font-size:15px!important;margin-top:-5px!important}.crit-table-id thead,.debug-table-id thead,.info-table-id thead,.log-table-id thead,.warn-table-id thead{background-color:#f9f9f9;border-top:6px solid #888!important;text-align:center}.crit-table-id thead tr th,.debug-table-id thead tr th,.info-table-id thead tr th,.log-table-id thead tr th,.warn-table-id thead tr th{background-color:#fff!important;border-bottom:1px solid #c2c2c2;border-top:2px solid #888}.crit-table-id .firstcol,.debug-table-id .firstcol,.info-table-id .firstcol,.log-table-id .firstcol,.warn-table-id .firstcol{cursor:default!important;max-width:80px!important;width:80px!important}.crit-table-id tbody .firstcol,.debug-table-id tbody .firstcol,.info-table-id tbody .firstcol,.log-table-id tbody .firstcol,.warn-table-id tbody .firstcol{background-color:transparent!important}.crit-table-id tbody tr td,.debug-table-id tbody tr td,.info-table-id tbody tr td,.log-table-id tbody tr td,.warn-table-id tbody tr td{padding-bottom:8px!important;padding-top:8px!important}.thirdcol{cursor:default!important;max-width:500px!important}.dataTables_empty,.seccol{cursor:default!important;margin-bottom:5px;width:100px!important}.dataTables_info{display:none}#arangoLogTable tbody td:nth-child(1),#arangoLogTable tbody td:nth-child(2){text-align:center;width:80px}#arangoLogTable tbody td:nth-child(3){width:auto}div.gv_zoom_widget{height:300px;left:64px;opacity:.7;position:absolute;top:20px;width:40px;z-index:1}div.gv_zoom_widget div.gv_zoom_buttons_bg{background-image:url(../img/gv_button_bg_reverse.png);background-size:contain;height:40px;margin-bottom:20px}div.gv_zoom_widget div.gv_zoom_slider{background:#f5f8f0;border-radius:3px;height:200px;margin:0 17px;width:4px}div.gv_zoom_widget a.ui-slider-handle{background-color:#555;border:1px solid rgba(140,138,137,.25);height:.5em;left:-.55em;outline:0}div.gv_zoom_widget a.ui-slider-handle.ui-state-hover{outline-color:#fff}div.gv_zoom_widget a.ui-slider-handle:hover{cursor:pointer}div.gv_zoom_widget .ui-state-default{background:#f6f6f6}#menubar{margin:0 0 10px}div.gv_colour_list{max-height:680px;overflow:auto;position:absolute;right:26px;text-align:right;top:20px;z-index:1}div.gv_colour_list li{background-color:transparent;float:none;padding:2px 6px}svg.graph-viewer{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;left:54px;position:absolute;top:10px;z-index:0}div.gv-colour-list ul ul,div.gv-colour-list ul ul:first-child,div.gv-colour-list ul ul:last-child{border-left:1px solid rgba(104,103,102,.1);border-right:1px solid rgba(104,103,102,.1)}svg.graph-viewer text{max-width:90px;pointer-events:none}div.gv-background{position:relative}.link>line{stroke-width:1}div.gv-colour-list:hover{opacity:1}div.gv-colour-list{border-radius:3px;max-height:350px;max-width:300px;min-width:190px;opacity:.1;overflow-x:hidden!important;overflow-y:auto;position:absolute;right:8px;text-align:right;top:20px;z-index:1}div.gv-colour-list li{float:none;padding:2px 6px}div.gv-colour-list ul ul:first-child{border-top:1px solid rgba(104,103,102,.1);border-top-left-radius:3px;border-top-right-radius:3px}div.gv-colour-list ul ul:last-child{border-bottom:1px solid rgba(104,103,102,.1);border-bottom-left-radius:3px;border-bottom-right-radius:3px}legend.gv-inner{font-size:16px}input.gv-radio-button{display:block;margin-top:3px;width:auto}.addCollection .accordion,.collectionTh select,.collectionTh textarea{margin-top:10px}.collectionTh{font-size:14px;text-align:left;width:20%!important}.collectionInfoTh{min-width:60px;text-align:left;width:320px}.addCollection table tr{border-bottom:0!important;height:53px}.addCollection .icon_arangodb_info{margin-left:20px!important;position:relative;top:2px!important}.addCollection .collectionThSec{width:320px!important}.addCollection .collectionTh{width:96px}.addCollection .modalInput{width:320px}.addCollection .modalSelect{width:334px}.addCollection .accordion-toggle{width:457px!important}.change-collection .tab-content{min-height:230px}.change-collection input{width:384px!important}.change-collection select{width:398px!important}.show-collection .tab-content{min-height:200px}.collectionInfoTh2{text-align:left;width:150px}.collection-info-figures table{float:left;margin-left:0;margin-right:0;margin-top:0;min-width:200px;padding:3px;text-align:left}.figuresHeader{border-bottom:1px solid #c2c2c2}.document-info .document-bold-font,.document-info .document-thin-font{font-family:droid sans mono,monospace,courier new,courier,sans-serif;font-size:11pt}#collectionIndexTable{margin-left:0;width:100%}#collectionTab,#graphTab,#infoTab{border-bottom:0;margin-bottom:1px;padding-bottom:0;padding-right:10px}#collectionTab li,#graphTab li,#infoTab li{float:right}#collectionTab li.disabled a,#graphTab li.disabled a,#infoTab li.disabled a{cursor:not-allowed}#collectionTab a,#graphTab a,#infoTab a{background-color:#8c8a89;border-bottom:1px solid #666;border-top-left-radius:3px!important;border-top-right-radius:3px!important;color:#fff;font-size:13px!important;height:21px;margin-bottom:-1px;margin-right:4px;padding:2px 15px!important}#collectionTab .active>a,#graphTab .active>a,#infoTab .active>a{background-color:#fff;border-color:#888 #888 transparent!important;color:#000}#confirmCreateEdge{margin-left:20px}.collection-info-figures .icon_arangodb_info{position:relative!important;right:-4px!important}.snippet-wrap .snippet-num li{list-style:decimal-leading-zero}.snippet-no-num{list-style-type:none;padding-left:0}.snippet-no-num .prettify{font-size:1.2em}.snippet-no-num .sh_number{color:#044;font-weight:100;margin-left:5px}.snippet-no-num .sh_symbol{color:#00f;font-weight:100;margin-left:5px}.snippet-no-num .sh_cbracket{color:#c7a317;font-weight:100;margin-left:5px}.snippet-no-num .sh_keyword{color:#c12dad;font-weight:100;margin-left:5px}.snippet-no-num .sh_string{color:#ce2f30;font-weight:100;margin-left:5px}.snippet-no-num .sh_array,.snippet-no-num .sh_object{color:#00f;font-weight:100;margin-left:5px}@media (max-width:738px){.arango-collection-ul{display:none}.collection-dropdown ul{width:auto!important}.arango-collection-select{display:inline-block}}@media (min-width:739px) and (max-width:1041px){.arango-collection-ul a{font-size:11px;padding:7px 5px 10px}}@media (min-width:1042px) and (max-width:1284px){.arango-collection-ul a{font-size:13px}}#documentsDiv{padding-top:1px}.document-info-div{margin-top:20px;min-height:0}.document-content-div{margin-top:10px}.document-info{background-color:#fff;border-radius:3px;margin-bottom:8px;margin-top:-13px;min-height:65px;padding:5px}.document-info .document-info-container{clear:both;width:100%}.document-info .document-info-container .document-inner-info-container{float:left;margin-left:10px;margin-top:5px}.document-info .document-info-container .document-inner-info-container .document-attribute{margin-right:20px}.document-info .document-info-container .document-inner-info-container .document-attribute div{float:left}.document-info .document-bold-font{min-width:55px}.document-info .document-thin-font{color:#8aa051}.document-info .document-type-container div{float:left}.document-info .document-type-container #document-id{margin-left:10px}.document-link:hover{cursor:pointer;text-decoration:underline}.jsoneditor .tree div{font-size:11pt}#progressPlaceholder{background-color:rgba(0,0,0,.4);bottom:0;left:0;position:fixed;right:0;top:0;z-index:9999}.progress-view{background-color:#363c39;border-radius:2px;color:#fff;height:188px;left:50%;margin:-100px 0 0 -150px;position:absolute;top:50%;width:300px}.progress-view .progress-content{margin-left:90px;margin-top:10px}.progress-view .progress-content .fa-spinner{font-size:100pt}.progress-view .progress-message{background-color:#fff;border-radius:0 0 2px 2px;color:#fff;font-weight:200;height:44px;margin-top:33px;padding-top:3px;text-align:center}.progress-view .progress-text{color:#000;float:left;margin-left:5px;margin-top:10px}.progress-view .progress-action{float:right;margin-right:5px;margin-top:5px}#progressPlaceholderIcon{color:#8aa051;float:left;font-size:22px;margin-left:10px;margin-top:7px}.pong-loader{margin-left:17px;margin-top:35px}@-moz-keyframes pong-loader{0%{left:5px;top:0}25%{left:65px;top:20px}50%{left:5px}62.5%{top:50px}75%{left:65px;top:70%}100%{left:5px;top:0}}@-webkit-keyframes pong-loader{0%{left:5px;top:0}25%{left:65px;top:20px}50%{left:5px}62.5%{top:50px}75%{left:65px;top:70%}100%{left:5px;top:0}}@keyframes pong-loader{0%{left:5px;top:0}25%{left:65px;top:20px}50%{left:5px}62.5%{top:50px}75%{left:65px;top:70%}100%{left:5px;top:0}}@-moz-keyframes pong-loader-paddle-1{0%{-moz-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}25%{-moz-box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-moz-box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-moz-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-moz-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@-webkit-keyframes pong-loader-paddle-1{0%{-webkit-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}25%{-webkit-box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-webkit-box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-webkit-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-webkit-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@keyframes pong-loader-paddle-1{0%{-moz-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}25%{-moz-box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 15px 0 0,inset #353c39 0 -25px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-moz-box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 10px 0 0,inset #353c39 0 -30px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-moz-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-moz-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 5px 0 0,inset #353c39 0 -35px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@-moz-keyframes pong-loader-paddle-2{0%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-moz-box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-moz-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-moz-box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@-webkit-keyframes pong-loader-paddle-2{0%{-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-webkit-box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-webkit-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-webkit-box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}}@keyframes pong-loader-paddle-2{0%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}50%{-moz-box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 30px 0 0,inset #353c39 0 -10px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}62.5%{-moz-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 40px 0 0,inset #353c39 0 0 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}75%{-moz-box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 20px 0 0,inset #353c39 0 -20px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}100%{-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 3px 0 0 0,inset #8cdb8b -10px 0 0 0}}.pong-loader:not(:required){-moz-animation:pong-loader-paddle-1 1.5s infinite linear;-webkit-animation:pong-loader-paddle-1 1.5s infinite linear;animation:pong-loader-paddle-1 1.5s infinite linear;background:#353c39;-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;display:inline-block;height:60px;overflow:hidden;position:relative;text-indent:100%;width:80px}.pong-loader:not(:required):after,.pong-loader:not(:required):before{display:block;position:absolute;top:0;width:10px;left:0;content:''}.pong-loader:not(:required):before{-moz-animation:pong-loader-paddle-2 1.5s infinite linear;-webkit-animation:pong-loader-paddle-2 1.5s infinite linear;animation:pong-loader-paddle-2 1.5s infinite linear;-moz-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;-webkit-box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;box-shadow:inset #353c39 0 0 0 0,inset #353c39 0 -40px 0 0,inset #353c39 -3px 0 0 0,inset #8cdb8b -10px 0 0 0;height:100%}.pong-loader:not(:required):after{-moz-animation:pong-loader 1.5s infinite linear;-webkit-animation:pong-loader 1.5s infinite linear;animation:pong-loader 1.5s infinite linear;background:#8cdb8b;-moz-border-radius:50%;-webkit-border-radius:50%;border-radius:50%;height:10px}.application-detail-view section.info{float:left;padding:13px 0 0}.application-detail-view section.info .header{height:200px;margin-bottom:0;position:relative}.application-detail-view section.info .header div.header-icon-container{border-radius:3px;height:182px;left:0;margin:0 0 4px;position:absolute;width:182px}.application-detail-view section.info .header div.header-icon-container img.icon{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;height:auto;max-height:160px;max-width:160px;padding:10px;width:auto}.application-detail-view section.info .header .header_right{padding-top:1px;position:absolute;right:-10px;width:150px}.application-detail-view section.info .header .header_right input.delete,.application-detail-view section.info .header .header_right input.switch-docu,.application-detail-view section.info .header .header_right input.switch-mode,.application-detail-view section.info .header .header_right input.upgrade{margin-top:7.83px;padding-left:10px;padding-right:10px}.application-detail-view section.info .header .header_right input{width:130px}.application-detail-view section.info .header .header_left{margin-left:190px;margin-right:145px;padding-left:10px;padding-top:1px}.application-detail-view section.info .header .header_left input{margin-left:0;margin-top:-4px}.application-detail-view section.info .header .header_left .header_line h3{float:left;margin-bottom:0;margin-top:0;padding-right:5px}.application-detail-view section.info .header .header_left .header_line .license,.application-detail-view section.info .header .header_left .header_line .version{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-color:#fff;border:1px solid rgba(140,138,137,.25);color:#a0a0a0;font-size:.6em;font-weight:400;padding:0 8px 2px;position:relative;top:-3px}.application-detail-view section.info .header .header_left .header_line:after{clear:both;content:'';display:table}.application-detail-view section.info .header .app-warning{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background:#da4f49;color:#fff;padding:6px 8px}.application-detail-view section.info .header .app-warning h4,.application-detail-view section.info .header .app-warning p{font-size:1em;margin:0}.application-detail-view aside.meta{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;clear:right;float:left;height:182px;margin-top:12px;max-height:182px;max-width:182px;overflow-x:hidden;position:relative;right:-16px;width:182px}.application-detail-view aside.meta dl{margin-bottom:0;margin-top:0;padding-left:7px;padding-top:5px}main{background-color:#fff;border:1px solid rgba(140,138,137,.25);border-radius:3px;margin-top:220px}main .app-info{-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background:#5bc0de;color:#fff;margin:10px;padding:6px 8px}main .app-info h4,main .app-info p{font-size:1em;margin:0}main .swagger iframe{border:0;border-radius:3px;height:600px;width:100%}main .readme{background:#fff;padding:1em 2em}.tests-result .stack{border-color:#da4f49;color:#da4f49;font-size:12px;line-height:1.5;margin:5px 0}.tests-result-stats .fail,.tests-result-stats .pass,.tests-result-stats .pending{padding:0 2px}.tests-result-spec{margin-bottom:0}.tests-result-spec-suites .tests-result-spec-suites{margin-left:20px}.tests-result-spec-suites dd{margin-bottom:20px;margin-left:0}.tests-result-spec-tests{margin-left:20px}.tests-result-spec-test-title{padding-left:20px}.tests-result-spec-test-title .fa{line-height:18px;margin-left:-20px;margin-top:2px;position:absolute}.tests-result-spec-test-title .fa-circle{font-size:50%;margin-left:-16px}.tests-result .pass{color:#8aa051}.tests-result .fail{color:#da4f49}.tests-result .pending{color:#666}.hotkeysList .hotkeysLabel{clear:both;color:#000;font-size:16px;font-weight:400}.hotkeysList .hotkeysContent{padding-left:10px}.hotkeysList li{line-height:25px}.hotkeysList li .hotkeysDiv{float:left}.hotkeysList .hotkeysicons{background-color:#686766;border:1px solid #000;border-radius:2px;color:#fff;display:inline;height:19px;margin-left:10px;text-align:center;width:19px}.arango-table tbody tr:nth-child(even),.arango-table thead{background-color:#fff}.hotkeysContentLabel{float:left;width:30%}.arango-table{border-top:1px solid #c2c2c2;width:100%}.arango-table thead th{border-bottom:1px solid #c2c2c2;height:43px}.arango-table tbody tr:nth-child(odd){background:rgba(104,103,102,.05)}.arango-table tbody td{padding:10px 18px}.arango-tabbar{height:27px;width:100%}.arango-tabbar button{background-color:#8c8a89;border:0;border-top-left-radius:3px;border-top-right-radius:3px;color:#fff;float:right;font-weight:100;height:27px;margin-right:5px;width:82px}.arango-tabbar button:first-child{margin-right:10px}.arango-tabbar .arango-active-tab{background-color:#fff;border-bottom:1px solid #fff;border-left:1px solid #c2c2c2;border-right:1px solid #c2c2c2;border-top:1px solid #c2c2c2;color:#000;height:28px;margin-bottom:-1px}.docsSecCol,.docsThirdCol{height:26px}.arangoDataTable{border-spacing:0 0;position:relative;table-layout:fixed!important;width:100%!important}.arangoDataTable thead{background-color:#fff!important;font-weight:400!important;text-align:left}.arangoDataTable thead th{border-bottom:0;cursor:default!important;font-weight:400!important;padding:10px 14px!important}.arangoDataTable thead tr{border-bottom:1px solid #c2c2c2}.arangoDataTable tr{cursor:pointer}.arangoDataTable td{padding:8px 18px!important}.arangoDataTable .key{font-weight:100;margin-top:4px}.arangoDataTable .dataTable .noPointer tr{cursor:default}.arangoDataTable .selected-row{background-color:#8aa051!important}.arangoDataTable .selected-row div,.arangoDataTable .selected-row li,.arangoDataTable .selected-row span{color:#fff!important}.api-container #resources>li.resource:nth-child(even),table.arangoDataTable tr.even{background-color:#fff}.api-container #resources>li.resource:nth-child(odd),table.arangoDataTable tr.odd{background-color:rgba(104,103,102,.05)}#tableDiv table.dataTable td{padding:12px 18px!important}#documentsTableID_filter,#documentsTableID_length{display:none}#documentsTableID_wrapper{min-height:420px!important;padding-bottom:0!important}.snippet-no-num{font-family:'Open Sans',sans-serif;font-size:1em;font-weight:400;margin-bottom:0}.cuttedContent,.prettify ul li,.writeable a{overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}.totalDocuments{color:#666;float:left;font-weight:100;margin-top:-37px!important;padding-left:10px}.prettify{border:none!important;font-size:1em!important;margin:0!important;padding:0!important}table .sorting{background:0 0!important}#documentsDiv{margin-top:20px}.new-index-view input[type=checkbox]{float:left}.new-index-view table tr{width:600px!important}.new-index-view table tr th:last-child{width:50px!important}.new-index-view table th{font-weight:300!important;width:200px!important}.edit-index-table{margin-top:5px;min-width:auto!important}.edit-index-table th{padding-bottom:5px;padding-left:5px;padding-top:5px}.edit-index-table .icon_arangodb_locked{color:rgba(0,0,0,.5);cursor:default;font-size:20px;margin-left:10px}.edit-index-table .icon_arangodb_roundminus{font-size:20px;margin-left:10px}.edit-index-table .fa{margin-left:13px}.contentIn .arangoicon{font-size:25px;position:relative;top:-3px!important}#collectionEditIndexTable thead{border-bottom:1px solid #e5e5e5}.newIndexClass table{border-top:1px solid #f7f3f2;margin-bottom:60px}.newIndexClass table select{margin-right:7px}.newIndexClass table .arangoicon{float:right;margin-right:-12px;margin-top:5px}.index-button-bar{bottom:0;margin-bottom:15px;margin-right:17px;margin-top:15px;position:absolute;right:0}.index-button-bar button{float:right;margin-left:0}.index-button-bar #cancelIndex{margin-right:13px}.docsFirstCol,.docsSecCol,.docsThirdCol{border:0!important}.docsFirstCol{height:26px;width:80%}.docsSecCol{min-width:400px!important;width:10%}.add-filter-item{margin-left:5px}.add-filter-item i{margin-top:0!important}.upload-indicator{display:none;margin-top:-3px;padding-right:10px}.documentsDropdown .dropdownImport,.documentsDropdown .headerDropdown{clear:both;margin-bottom:5px}.documents-size{background-color:#fff!important;border:1px solid #e5e5e5;border-radius:2px;box-shadow:none;float:right;height:28px;line-height:18px;margin-left:10px;margin-right:-2px;margin-top:0;outline:transparent 0;width:115px}.queryline .fa-info-circle:hover{cursor:pointer}.ace_error{background:0 0!important}#exportHeader .fa-exclamation-circle{color:#fff;font-size:13pt;margin-right:10px}.totalDocuments:hover{color:#000}.ajax-file-upload-statusbar{-moz-border-radius:2px;-webkit-border-radius:2px;border-radius:2px;border:1px solid rgba(0,0,0,.7);margin:10px 10px 5px 5px;padding:5px;width:420px}.ajax-file-upload-filename{color:grey;height:auto;margin:0 5px 5px 10px;width:100%}.ajax-file-upload-progress{-moz-border-radius:2px;-webkit-border-radius:2px;border-radius:2px;border:1px solid #d9d9d9;display:inline-block;margin:0 10px 5px;padding:1px;position:relative;width:250px}.ajax-file-upload-bar{-moz-border-radius:2px;-webkit-border-radius:2px;border-radius:2px;background-color:rgba(0,0,0,.7);color:#fff;height:20px;width:0}.ajax-file-upload-percent{display:inline-block;left:48%;position:absolute;top:3px}.ajax-file-upload-red{font-size:13px;font-weight:400;margin-right:5px;padding:4px 15px;vertical-align:top}.ajax-file-upload{display:inline-block;font-size:16px;font-weight:700;height:25px;margin:0 10px 10px 0;padding:6px 10px 4px}.ajax-upload-dragdrop{border:1px dotted #8f8d8c;color:#736b68;padding:10px 10px 0;text-align:left;vertical-align:middle;width:506px}.ajax-upload-dragdrop span{position:relative;top:-22px}/*! Animate.css - http://daneden.me/animate Licensed under the MIT license - http://opensource.org/licenses/MIT diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/style-minified.css.gz b/js/apps/system/_admin/aardvark/APP/frontend/build/style-minified.css.gz index 6aa93b33d4..1f9f5daad8 100644 Binary files a/js/apps/system/_admin/aardvark/APP/frontend/build/style-minified.css.gz and b/js/apps/system/_admin/aardvark/APP/frontend/build/style-minified.css.gz differ diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/style.css b/js/apps/system/_admin/aardvark/APP/frontend/build/style.css index 4903f479e5..c0b5d474d2 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/style.css +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/style.css @@ -8022,7 +8022,7 @@ table.arangoDataTable tr.odd { display: none; } #documentsTableID_wrapper { - min-height: 480px !important; + min-height: 420px !important; padding-bottom: 0 !important; } #documentsTableID_wrapper .fg-toolbar { visibility: hidden; } @@ -8091,6 +8091,8 @@ table .sorting { .edit-index-table .icon_arangodb_roundminus { font-size: 20px; margin-left: 10px; } + .edit-index-table .fa { + margin-left: 13px; } .contentIn .arangoicon { font-size: 25px; diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/style.css.gz b/js/apps/system/_admin/aardvark/APP/frontend/build/style.css.gz index 1e8905f58a..1dca44f9ba 100644 Binary files a/js/apps/system/_admin/aardvark/APP/frontend/build/style.css.gz and b/js/apps/system/_admin/aardvark/APP/frontend/build/style.css.gz differ diff --git a/js/apps/system/_admin/aardvark/APP/frontend/js/models/arangoCollectionModel.js b/js/apps/system/_admin/aardvark/APP/frontend/js/models/arangoCollectionModel.js index 4b83a9417e..8b7fd2c9fd 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/js/models/arangoCollectionModel.js +++ b/js/apps/system/_admin/aardvark/APP/frontend/js/models/arangoCollectionModel.js @@ -112,6 +112,7 @@ window.arangoHelper.addAardvarkJob({ id: xhr.getResponseHeader('x-arango-async-id'), type: 'index', + desc: 'Creating index...', collection: self.get("id") }); callback(false, data); @@ -143,6 +144,7 @@ window.arangoHelper.addAardvarkJob({ id: xhr.getResponseHeader('x-arango-async-id'), type: 'index', + desc: 'Removing index...', collection: self.get("id") }); callback(false, data); @@ -176,7 +178,6 @@ loadCollection: function (callback) { $.ajax({ - async: true, cache: false, type: 'PUT', url: "/_api/collection/" + this.get("id") + "/load", @@ -192,7 +193,6 @@ unloadCollection: function (callback) { $.ajax({ - async: true, cache: false, type: 'PUT', url: "/_api/collection/" + this.get("id") + "/unload?flush=true", diff --git a/js/apps/system/_admin/aardvark/APP/frontend/js/views/collectionsItemView.js b/js/apps/system/_admin/aardvark/APP/frontend/js/views/collectionsItemView.js index b2f3cd57fe..325d1ca5b6 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/js/views/collectionsItemView.js +++ b/js/apps/system/_admin/aardvark/APP/frontend/js/views/collectionsItemView.js @@ -26,6 +26,13 @@ render: function () { if (this.model.get("locked")) { $(this.el).addClass('locked'); + } + else { + $(this.el).removeClass('locked'); + } + + if (this.model.get("status") === 'loading') { + $(this.el).addClass('locked'); } $(this.el).html(this.template.render({ model: this.model @@ -60,10 +67,19 @@ if (this.model.get("locked")) { return 0; } + if (this.model.get("status") === 'loading' ) { + return 0; + } + + if (this.model.get("status") === 'unloaded' ) { + this.loadCollection(); + } + else { + window.App.navigate( + "collection/" + encodeURIComponent(this.model.get("name")) + "/documents/1", {trigger: true} + ); + } - window.App.navigate( - "collection/" + encodeURIComponent(this.model.get("name")) + "/documents/1", {trigger: true} - ); }, noop: function(event) { diff --git a/js/apps/system/_admin/aardvark/APP/frontend/js/views/collectionsView.js b/js/apps/system/_admin/aardvark/APP/frontend/js/views/collectionsView.js index d1b2cee45a..74f2907241 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/js/views/collectionsView.js +++ b/js/apps/system/_admin/aardvark/APP/frontend/js/views/collectionsView.js @@ -31,12 +31,15 @@ }); this.collection.each(function(model) { - if (model.get("locked")) { + if (model.get("locked") || model.get("status") === 'loading') { $('#collection_' + model.get("name")).addClass('locked'); } else { $('#collection_' + model.get("name")).removeClass('locked'); } + if (model.get("status") === 'loading') { + $('#collection_' + model.get("name")).removeClass('loading'); + } }); }, diff --git a/js/apps/system/_admin/aardvark/APP/frontend/scss/_dataTables.scss b/js/apps/system/_admin/aardvark/APP/frontend/scss/_dataTables.scss index c9aa4adb71..8d445fc0fe 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/scss/_dataTables.scss +++ b/js/apps/system/_admin/aardvark/APP/frontend/scss/_dataTables.scss @@ -84,7 +84,7 @@ table.arangoDataTable tr.odd { } #documentsTableID_wrapper { - min-height: 480px !important; + min-height: 420px !important; padding-bottom: 0 !important; .fg-toolbar {