From 1cb973ea1ffc659742da3fe8a1f19d6c8f4835f8 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Fri, 27 May 2016 11:02:42 +0200 Subject: [PATCH 01/14] Current work --- arangod/RestServer/RestServerFeature.cpp | 25 +++++++++++++++++++++++- arangod/RestServer/RestServerFeature.h | 2 ++ 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/arangod/RestServer/RestServerFeature.cpp b/arangod/RestServer/RestServerFeature.cpp index 8e23f1bdf0..9f43198246 100644 --- a/arangod/RestServer/RestServerFeature.cpp +++ b/arangod/RestServer/RestServerFeature.cpp @@ -117,12 +117,16 @@ void RestServerFeature::collectOptions( "--server.authentication-system-only", "use HTTP authentication only for requests to /_api and /_admin", new BooleanParameter(&_authenticationSystemOnly)); - + #ifdef ARANGODB_HAVE_DOMAIN_SOCKETS options->addOption("--server.authentication-unix-sockets", "authentication for requests via UNIX domain sockets", new BooleanParameter(&_authenticationUnixSockets)); #endif + + options->addOption("--server.jwt-secret", + "secret to use when doing jwt authentication", + new StringParameter(&_jwtSecretArgument)); options->addSection("http", "HttpServer features"); @@ -232,6 +236,25 @@ void RestServerFeature::prepare() { void RestServerFeature::start() { RESTSERVER = this; + + size_t maxSize = sizeof(_jwtSecret); + if (!_jwtSecretArgument.empty()) { + if (_jwtSecretArgument.length() > maxSize) { + LOG(WARN) << "Given JWT secret too long. Will be truncated to " << maxSize; + } + + _jwtSecretLength = std::min(maxSize, _jwtSecretArgument.length()); + std::copy_n(_jwtSecretArgument.begin(), _jwtSecretLength, _jwtSecret); + } else { + std::default_random_engine generator; + std::uniform_int_distribution distribution(0,255); + + for (size_t i=0;ivocbase(); diff --git a/arangod/RestServer/RestServerFeature.h b/arangod/RestServer/RestServerFeature.h index ef36262825..bbd29865af 100644 --- a/arangod/RestServer/RestServerFeature.h +++ b/arangod/RestServer/RestServerFeature.h @@ -76,6 +76,8 @@ class RestServerFeature final bool _authentication; bool _authenticationUnixSockets; bool _authenticationSystemOnly; + std::string _jwtSecret; + bool _proxyCheck; std::vector _trustedProxies; std::vector _accessControlAllowOrigins; From 84a72137559d36e1a558e3101b79ad16ef3d5f93 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Mon, 30 May 2016 14:48:35 +0200 Subject: [PATCH 02/14] Add jwtsecret --- arangod/Cluster/AgencyComm.cpp | 28 ++++++++++++++-- arangod/Cluster/AgencyComm.h | 8 +---- arangod/RestServer/RestServerFeature.cpp | 41 +++++++++++++----------- arangod/RestServer/RestServerFeature.h | 7 +++- 4 files changed, 54 insertions(+), 30 deletions(-) diff --git a/arangod/Cluster/AgencyComm.cpp b/arangod/Cluster/AgencyComm.cpp index d7666d6d6a..585120bf19 100644 --- a/arangod/Cluster/AgencyComm.cpp +++ b/arangod/Cluster/AgencyComm.cpp @@ -39,12 +39,15 @@ #include "Random/RandomGenerator.h" #include "Rest/HttpRequest.h" #include "Rest/HttpResponse.h" +#include "RestServer/RestServerFeature.h" #include "SimpleHttpClient/GeneralClientConnection.h" #include "SimpleHttpClient/SimpleHttpClient.h" #include "SimpleHttpClient/SimpleHttpResult.h" using namespace arangodb; +using namespace arangodb::application_features; +using namespace basics::StringUtils; static void addEmptyVPackObject(std::string const& name, VPackBuilder& builder) { builder.add(VPackValue(name)); @@ -518,7 +521,7 @@ bool AgencyComm::initialize() { /// @brief will try to initialize a new agency ////////////////////////////////////////////////////////////////////////////// -bool AgencyComm::tryInitializeStructure() { +bool AgencyComm::tryInitializeStructure(std::string const& jwtSecret) { VPackBuilder builder; try { VPackObjectBuilder b(&builder); @@ -614,6 +617,10 @@ bool AgencyComm::tryInitializeStructure() { addEmptyVPackObject("DBServers", builder); } builder.add("InitDone", VPackValue(true)); + builder.add("Secret", VPackValue(encodeHex(jwtSecret))); + } catch (std::exception const& e) { + LOG_TOPIC(ERR, Logger::STARTUP) << "Couldn't create initializing structure " << e.what(); + return false; } catch (...) { LOG_TOPIC(ERR, Logger::STARTUP) << "Couldn't create initializing structure"; return false; @@ -668,13 +675,16 @@ bool AgencyComm::shouldInitializeStructure() { bool AgencyComm::ensureStructureInitialized() { LOG_TOPIC(TRACE, Logger::STARTUP) << "Checking if agency is initialized"; + + RestServerFeature* restServer = + application_features::ApplicationServer::getFeature("RestServer"); while (true) { while (shouldInitializeStructure()) { LOG_TOPIC(TRACE, Logger::STARTUP) << "Agency is fresh. Needs initial structure."; // mop: we initialized it .. great success - if (tryInitializeStructure()) { + if (tryInitializeStructure(restServer->jwtSecret())) { LOG_TOPIC(TRACE, Logger::STARTUP) << "Successfully initialized agency"; break; } @@ -693,7 +703,7 @@ bool AgencyComm::ensureStructureInitialized() { if (value.isBoolean() && value.getBoolean()) { // expecting a value of "true" LOG_TOPIC(TRACE, Logger::STARTUP) << "Found an initialized agency"; - return true; + break; } } @@ -702,6 +712,18 @@ bool AgencyComm::ensureStructureInitialized() { sleep(1); } // next attempt + + AgencyCommResult secretResult = getValues("Secret"); + VPackSlice secretValue = secretResult.slice()[0].get(std::vector( + {prefix(), "Secret"})); + + if (!secretValue.isString()) { + LOG(ERR) << "Couldn't find secret in agency!"; + return false; + } + + restServer->setJwtSecret(decodeHex(secretValue.copyString())); + return true; } //////////////////////////////////////////////////////////////////////////////// diff --git a/arangod/Cluster/AgencyComm.h b/arangod/Cluster/AgencyComm.h index dcadaf542d..d6551a10f0 100644 --- a/arangod/Cluster/AgencyComm.h +++ b/arangod/Cluster/AgencyComm.h @@ -764,13 +764,7 @@ class AgencyComm { /// @brief will try to initialize a new agency ////////////////////////////////////////////////////////////////////////////// - bool tryInitializeStructure(); - - ////////////////////////////////////////////////////////////////////////////// - /// @brief initialize key in etcd - ////////////////////////////////////////////////////////////////////////////// - - bool initFromVPackSlice(std::string key, arangodb::velocypack::Slice s); + bool tryInitializeStructure(std::string const& jwtSecret); ////////////////////////////////////////////////////////////////////////////// /// @brief checks if we are responsible for initializing the agency diff --git a/arangod/RestServer/RestServerFeature.cpp b/arangod/RestServer/RestServerFeature.cpp index 9f43198246..c37ff911d0 100644 --- a/arangod/RestServer/RestServerFeature.cpp +++ b/arangod/RestServer/RestServerFeature.cpp @@ -88,6 +88,7 @@ RestServerFeature::RestServerFeature( _authenticationUnixSockets(true), _authenticationSystemOnly(false), _proxyCheck(true), + _jwtSecret(""), _handlerFactory(nullptr), _jobManager(nullptr) { setOptional(true); @@ -126,7 +127,7 @@ void RestServerFeature::collectOptions( options->addOption("--server.jwt-secret", "secret to use when doing jwt authentication", - new StringParameter(&_jwtSecretArgument)); + new StringParameter(&_jwtSecret)); options->addSection("http", "HttpServer features"); @@ -184,6 +185,15 @@ void RestServerFeature::validateOptions(std::shared_ptr) { return basics::StringUtils::trim(value).empty(); }), _accessControlAllowOrigins.end()); } + + if (!_jwtSecret.empty()) { + if (_jwtSecret.length() > RestServerFeature::_maxSecretLength) { + LOG(ERR) << "Given JWT secret too long. Max length is " << RestServerFeature::_maxSecretLength; + FATAL_ERROR_EXIT(); + } + } else { + generateNewJwtSecret(); + } } static TRI_vocbase_t* LookupDatabaseFromRequest(HttpRequest* request, @@ -230,30 +240,23 @@ static bool SetRequestContext(HttpRequest* request, void* data) { return true; } +void RestServerFeature::generateNewJwtSecret() { + _jwtSecret = ""; + std::random_device rd; + std::mt19937 rng(rd()); + std::uniform_int_distribution distribution(0,255); + + for (size_t i=0;i maxSize) { - LOG(WARN) << "Given JWT secret too long. Will be truncated to " << maxSize; - } - - _jwtSecretLength = std::min(maxSize, _jwtSecretArgument.length()); - std::copy_n(_jwtSecretArgument.begin(), _jwtSecretLength, _jwtSecret); - } else { - std::default_random_engine generator; - std::uniform_int_distribution distribution(0,255); - - for (size_t i=0;i _trustedProxies; std::vector _accessControlAllowOrigins; + + std::string _jwtSecret; public: bool authentication() const { return _authentication; } @@ -88,6 +90,9 @@ class RestServerFeature final bool authenticationSystemOnly() const { return _authenticationSystemOnly; } bool proxyCheck() const { return _proxyCheck; } std::vector trustedProxies() const { return _trustedProxies; } + std::string jwtSecret() const { return _jwtSecret; } + void generateNewJwtSecret(); + void setJwtSecret(std::string const& jwtSecret) { _jwtSecret = jwtSecret; } private: void buildServers(); From 5b0055bfbfc6ff36613384133bde57be14d39a05 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Mon, 30 May 2016 18:47:04 +0200 Subject: [PATCH 03/14] jwt generation works --- arangod/CMakeLists.txt | 1 + arangod/RestHandler/RestAuthHandler.cpp | 132 +++++++++++++++++++++++ arangod/RestHandler/RestAuthHandler.h | 60 +++++++++++ arangod/RestServer/RestServerFeature.cpp | 5 + arangod/RestServer/VocbaseContext.cpp | 35 +++++- arangod/RestServer/VocbaseContext.h | 12 +++ arangod/VocBase/auth.cpp | 58 +++++----- arangod/VocBase/auth.h | 6 ++ lib/Ssl/SslInterface.cpp | 5 +- lib/V8/v8-utils.cpp | 4 +- 10 files changed, 283 insertions(+), 35 deletions(-) create mode 100644 arangod/RestHandler/RestAuthHandler.cpp create mode 100644 arangod/RestHandler/RestAuthHandler.h diff --git a/arangod/CMakeLists.txt b/arangod/CMakeLists.txt index f3f70cc572..9c4c150525 100644 --- a/arangod/CMakeLists.txt +++ b/arangod/CMakeLists.txt @@ -204,6 +204,7 @@ add_executable(${BIN_ARANGOD} Replication/InitialSyncer.cpp Replication/Syncer.cpp RestHandler/RestAdminLogHandler.cpp + RestHandler/RestAuthHandler.cpp RestHandler/RestBaseHandler.cpp RestHandler/RestBatchHandler.cpp RestHandler/RestCursorHandler.cpp diff --git a/arangod/RestHandler/RestAuthHandler.cpp b/arangod/RestHandler/RestAuthHandler.cpp new file mode 100644 index 0000000000..920da8ffab --- /dev/null +++ b/arangod/RestHandler/RestAuthHandler.cpp @@ -0,0 +1,132 @@ +//////////////////////////////////////////////////////////////////////////////// +/// DISCLAIMER +/// +/// Copyright 2014-2016 ArangoDB GmbH, Cologne, Germany +/// Copyright 2004-2014 triAGENS GmbH, Cologne, Germany +/// +/// Licensed under the Apache License, Version 2.0 (the "License"); +/// you may not use this file except in compliance with the License. +/// You may obtain a copy of the License at +/// +/// http://www.apache.org/licenses/LICENSE-2.0 +/// +/// Unless required by applicable law or agreed to in writing, software +/// distributed under the License is distributed on an "AS IS" BASIS, +/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +/// See the License for the specific language governing permissions and +/// limitations under the License. +/// +/// Copyright holder is ArangoDB GmbH, Cologne, Germany +/// +/// @author Andreas Streichardt +//////////////////////////////////////////////////////////////////////////////// + +#include "RestAuthHandler.h" + +#include +#include + +#include "Basics/StringUtils.h" +#include "Ssl/SslInterface.h" +#include "Logger/Logger.h" +#include "Rest/HttpRequest.h" +#include "VocBase/auth.h" + +using namespace arangodb; +using namespace arangodb::basics; +using namespace arangodb::rest; + +RestAuthHandler::RestAuthHandler(HttpRequest* request, std::string const* jwtSecret) + : RestVocbaseBaseHandler(request), _jwtSecret(*jwtSecret), _validFor(60 * 60 * 24 * 30) {} + +bool RestAuthHandler::isDirect() const { return false; } + +std::string RestAuthHandler::generateJwt(std::string const& username, std::string const& password) { + VPackBuilder headerBuilder; + { + VPackObjectBuilder h(&headerBuilder); + headerBuilder.add("alg", VPackValue("HS256")); + headerBuilder.add("typ", VPackValue("jwt")); + } + + std::chrono::seconds exp = std::chrono::duration_cast( + std::chrono::system_clock::now().time_since_epoch() + ) + _validFor; + VPackBuilder bodyBuilder; + { + VPackObjectBuilder p(&bodyBuilder); + bodyBuilder.add("username", VPackValue(username)); + bodyBuilder.add("iss", VPackValue("arangodb")); + bodyBuilder.add("exp", VPackValue(exp.count())); + } + + std::string fullMessage(StringUtils::encodeBase64(headerBuilder.toJson()) + "." + StringUtils::encodeBase64(bodyBuilder.toJson())); + std::string signature = sslHMAC(_jwtSecret.c_str(), _jwtSecret.length(), fullMessage.c_str(), fullMessage.length(), SslInterface::Algorithm::ALGORITHM_SHA256); + + return fullMessage + "." + StringUtils::encodeBase64(signature); +} + +//////////////////////////////////////////////////////////////////////////////// +/// @brief was docuBlock JSF_get_admin_modules_flush +//////////////////////////////////////////////////////////////////////////////// + +HttpHandler::status_t RestAuthHandler::execute() { + auto const type = _request->requestType(); + if (type != GeneralRequest::RequestType::POST) { + generateError(GeneralResponse::ResponseCode::METHOD_NOT_ALLOWED, + TRI_ERROR_HTTP_METHOD_NOT_ALLOWED); + return status_t(HANDLER_DONE); + } + + VPackOptions options = VPackOptions::Defaults; + options.checkAttributeUniqueness = true; + + bool parseSuccess; + std::shared_ptr parsedBody = + parseVelocyPackBody(&options, parseSuccess); + if (!parseSuccess) { + return badRequest(); + } + + VPackSlice slice = parsedBody->slice(); + if (!slice.isObject()) { + return badRequest(); + } + + VPackSlice usernameSlice = slice.get("username"); + VPackSlice passwordSlice = slice.get("password"); + + if (!usernameSlice.isString() || !passwordSlice.isString()) { + return badRequest(); + } + + std::string const username = usernameSlice.copyString(); + std::string const password = passwordSlice.copyString(); + + bool mustChange; + bool res = TRI_CheckUsernamePassword(_vocbase, username.c_str(), password.c_str(), &mustChange); + + if (res) { + VPackBuilder resultBuilder; + { + VPackObjectBuilder b(&resultBuilder); + std::string jwt = generateJwt(username, password); + resultBuilder.add("jwt", VPackValue(jwt)); + resultBuilder.add("must_change_password", VPackValue(mustChange)); + } + + generateDocument(resultBuilder.slice(), true, &VPackOptions::Defaults); + return status_t(HANDLER_DONE); + } else { + // mop: rfc 2616 10.4.2 (if credentials wrong 401) + generateError(GeneralResponse::ResponseCode::UNAUTHORIZED, TRI_ERROR_HTTP_UNAUTHORIZED, + "Wrong credentials"); + return status_t(HANDLER_DONE); + } +} + +HttpHandler::status_t RestAuthHandler::badRequest() { + generateError(GeneralResponse::ResponseCode::BAD, TRI_ERROR_HTTP_BAD_PARAMETER, + "invalid JSON"); + return status_t(HANDLER_DONE); +} diff --git a/arangod/RestHandler/RestAuthHandler.h b/arangod/RestHandler/RestAuthHandler.h new file mode 100644 index 0000000000..5a4497411e --- /dev/null +++ b/arangod/RestHandler/RestAuthHandler.h @@ -0,0 +1,60 @@ +//////////////////////////////////////////////////////////////////////////////// +/// DISCLAIMER +/// +/// Copyright 2014-2016 ArangoDB GmbH, Cologne, Germany +/// Copyright 2004-2014 triAGENS GmbH, Cologne, Germany +/// +/// Licensed under the Apache License, Version 2.0 (the "License"); +/// you may not use this file except in compliance with the License. +/// You may obtain a copy of the License at +/// +/// http://www.apache.org/licenses/LICENSE-2.0 +/// +/// Unless required by applicable law or agreed to in writing, software +/// distributed under the License is distributed on an "AS IS" BASIS, +/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +/// See the License for the specific language governing permissions and +/// limitations under the License. +/// +/// Copyright holder is ArangoDB GmbH, Cologne, Germany +/// +/// @author Andreas Streichardt +//////////////////////////////////////////////////////////////////////////////// + +#ifndef ARANGOD_REST_HANDLER_REST_AUTH_HANDLER_H +#define ARANGOD_REST_HANDLER_REST_AUTH_HANDLER_H 1 + +#include "Basics/Common.h" +#include "RestHandler/RestVocbaseBaseHandler.h" + +#include + +namespace arangodb { + +//////////////////////////////////////////////////////////////////////////////// +/// @brief auth handler +//////////////////////////////////////////////////////////////////////////////// + +class RestAuthHandler : public RestVocbaseBaseHandler { + public: + RestAuthHandler(HttpRequest*, std::string const* jwtSecret); + + std::string generateJwt(std::string const&, std::string const&); + + public: + bool isDirect() const override; + + ////////////////////////////////////////////////////////////////////////////// + /// @brief returns the log files (inheritDoc) + ////////////////////////////////////////////////////////////////////////////// + + status_t execute() override; + + private: + std::string _jwtSecret; + std::chrono::seconds _validFor; + status_t badRequest(); +}; +} + +#endif diff --git a/arangod/RestServer/RestServerFeature.cpp b/arangod/RestServer/RestServerFeature.cpp index c37ff911d0..427e9c0f0b 100644 --- a/arangod/RestServer/RestServerFeature.cpp +++ b/arangod/RestServer/RestServerFeature.cpp @@ -41,6 +41,7 @@ #include "ProgramOptions/Section.h" #include "Rest/Version.h" #include "RestHandler/RestAdminLogHandler.h" +#include "RestHandler/RestAuthHandler.h" #include "RestHandler/RestBatchHandler.h" #include "RestHandler/RestCursorHandler.h" #include "RestHandler/RestDebugHandler.h" @@ -510,6 +511,10 @@ void RestServerFeature::defineHandlers() { _handlerFactory->addPrefixHandler( "/_admin/shutdown", RestHandlerCreator::createNoData); + + _handlerFactory->addPrefixHandler( + "/_open/auth", + RestHandlerCreator::createData, &_jwtSecret); // ........................................................................... // /_admin diff --git a/arangod/RestServer/VocbaseContext.cpp b/arangod/RestServer/VocbaseContext.cpp index b9d0afe5a5..897a8aa10e 100644 --- a/arangod/RestServer/VocbaseContext.cpp +++ b/arangod/RestServer/VocbaseContext.cpp @@ -272,18 +272,37 @@ GeneralResponse::ResponseCode VocbaseContext::authenticate() { } std::string const& authStr = _request->header(StaticStrings::Authorization, found); - - if (!found || !TRI_CaseEqualString(authStr.c_str(), "basic ", 6)) { + + if (!found) { return GeneralResponse::ResponseCode::UNAUTHORIZED; } + size_t methodPos = authStr.find_first_of(' '); + if (methodPos == std::string::npos) { + return GeneralResponse::ResponseCode::UNAUTHORIZED; + } + // skip over "basic " - char const* auth = authStr.c_str() + 6; - + char const* auth = authStr.c_str() + methodPos; while (*auth == ' ') { ++auth; } + if (!TRI_CaseEqualString(authStr.c_str(), "basic ", 6)) { + return basicAuthentication(auth); + } else if (TRI_CaseEqualString(authStr.c_str(), "bearer ", 7)) { + return jwtAuthentication(auth); + } else { + // mop: hmmm is 403 the correct status code? or 401? or 400? :S + return GeneralResponse::ResponseCode::FORBIDDEN; + } +} + +//////////////////////////////////////////////////////////////////////////////// +/// @brief checks the authentication via basic +//////////////////////////////////////////////////////////////////////////////// + +GeneralResponse::ResponseCode VocbaseContext::basicAuthentication(const char* auth) { if (useClusterAuthentication()) { std::string const expected = ServerState::instance()->getAuthentication(); @@ -347,3 +366,11 @@ GeneralResponse::ResponseCode VocbaseContext::authenticate() { return GeneralResponse::ResponseCode::OK; } + +//////////////////////////////////////////////////////////////////////////////// +/// @brief checks the authentication via jwt +//////////////////////////////////////////////////////////////////////////////// + +GeneralResponse::ResponseCode VocbaseContext::jwtAuthentication(const char* auth) { + return GeneralResponse::ResponseCode::FORBIDDEN; +} diff --git a/arangod/RestServer/VocbaseContext.h b/arangod/RestServer/VocbaseContext.h index 6acc1d7317..4bc2cfa422 100644 --- a/arangod/RestServer/VocbaseContext.h +++ b/arangod/RestServer/VocbaseContext.h @@ -94,6 +94,18 @@ class VocbaseContext : public arangodb::RequestContext { ////////////////////////////////////////////////////////////////////////////// GeneralResponse::ResponseCode authenticate() override final; + + ////////////////////////////////////////////////////////////////////////////// + /// @brief checks the authentication (basic) + ////////////////////////////////////////////////////////////////////////////// + + GeneralResponse::ResponseCode basicAuthentication(const char*); + + ////////////////////////////////////////////////////////////////////////////// + /// @brief checks the authentication (jwt) + ////////////////////////////////////////////////////////////////////////////// + + GeneralResponse::ResponseCode jwtAuthentication(const char*); public: //////////////////////////////////////////////////////////////////////////////// diff --git a/arangod/VocBase/auth.cpp b/arangod/VocBase/auth.cpp index 5e7a980a39..b2111f6102 100644 --- a/arangod/VocBase/auth.cpp +++ b/arangod/VocBase/auth.cpp @@ -354,6 +354,37 @@ bool TRI_ExistsAuthenticationAuthInfo(TRI_vocbase_t* vocbase, bool TRI_CheckAuthenticationAuthInfo(TRI_vocbase_t* vocbase, char const* hash, char const* username, char const* password, bool* mustChange) { + bool res = TRI_CheckUsernamePassword(vocbase, username, password, mustChange); + + if (res && hash != nullptr) { + // insert item into the cache + auto cached = std::make_unique(); + + cached->_hash = std::string(hash); + cached->_username = std::string(username); + cached->_mustChange = *mustChange; + + if (cached->_hash.empty() || cached->_username.empty()) { + return res; + } + + WRITE_LOCKER(writeLocker, vocbase->_authInfoLock); + + auto it = vocbase->_authCache.find(cached->_hash); + + if (it != vocbase->_authCache.end()) { + delete (*it).second; + (*it).second = nullptr; + } + + vocbase->_authCache[cached->_hash] = cached.get(); + cached.release(); + } + + return res; +} + +bool TRI_CheckUsernamePassword(TRI_vocbase_t* vocbase, char const* username, char const* password, bool* mustChange) { TRI_ASSERT(vocbase != nullptr); bool res = false; VocbaseAuthInfo* auth = nullptr; @@ -443,31 +474,6 @@ bool TRI_CheckAuthenticationAuthInfo(TRI_vocbase_t* vocbase, char const* hash, TRI_FreeString(TRI_UNKNOWN_MEM_ZONE, salted); } - - if (res && hash != nullptr) { - // insert item into the cache - auto cached = std::make_unique(); - - cached->_hash = std::string(hash); - cached->_username = std::string(username); - cached->_mustChange = auth->mustChange(); - - if (cached->_hash.empty() || cached->_username.empty()) { - return res; - } - - WRITE_LOCKER(writeLocker, vocbase->_authInfoLock); - - auto it = vocbase->_authCache.find(cached->_hash); - - if (it != vocbase->_authCache.end()) { - delete (*it).second; - (*it).second = nullptr; - } - - vocbase->_authCache[cached->_hash] = cached.get(); - cached.release(); - } - + return res; } diff --git a/arangod/VocBase/auth.h b/arangod/VocBase/auth.h index cac207cd3f..8960a4a80f 100644 --- a/arangod/VocBase/auth.h +++ b/arangod/VocBase/auth.h @@ -153,4 +153,10 @@ bool TRI_CheckAuthenticationAuthInfo(TRI_vocbase_t*, char const* hash, char const* username, char const* password, bool* mustChange); +//////////////////////////////////////////////////////////////////////////////// +/// @brief check username password +//////////////////////////////////////////////////////////////////////////////// + +bool TRI_CheckUsernamePassword(TRI_vocbase_t*, char const* username, char const* password, bool* mustChange); + #endif diff --git a/lib/Ssl/SslInterface.cpp b/lib/Ssl/SslInterface.cpp index d6787f8ed1..613cc0904f 100644 --- a/lib/Ssl/SslInterface.cpp +++ b/lib/Ssl/SslInterface.cpp @@ -256,8 +256,7 @@ std::string sslHMAC(char const* key, size_t keyLength, char const* message, HMAC(evp_md, key, (int)keyLength, (const unsigned char*)message, messageLen, md, &md_len); - // return value as hex - std::string result = StringUtils::encodeHex(std::string((char*)md, md_len)); + std::string result = std::string((char*)md, md_len); TRI_SystemFree(md); return result; @@ -271,7 +270,7 @@ bool verifyHMAC(char const* challenge, size_t challengeLength, // result must == BASE64(response, responseLen) std::string s = - sslHMAC(challenge, challengeLength, secret, secretLen, algorithm); + StringUtils::encodeHex(sslHMAC(challenge, challengeLength, secret, secretLen, algorithm)); if (s.length() == responseLen && s.compare(std::string(response, responseLen)) == 0) { diff --git a/lib/V8/v8-utils.cpp b/lib/V8/v8-utils.cpp index 82792b08ba..073d9ea018 100644 --- a/lib/V8/v8-utils.cpp +++ b/lib/V8/v8-utils.cpp @@ -3154,8 +3154,8 @@ static void JS_HMAC(v8::FunctionCallbackInfo const& args) { } } - std::string result = SslInterface::sslHMAC( - key.c_str(), key.size(), message.c_str(), message.size(), al); + std::string result = StringUtils::encodeHex(SslInterface::sslHMAC( + key.c_str(), key.size(), message.c_str(), message.size(), al)); TRI_V8_RETURN_STD_STRING(result); TRI_V8_TRY_CATCH_END } From 87f09b986a78b74e35a96b690015f1f081bd4b17 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Tue, 31 May 2016 14:28:15 +0200 Subject: [PATCH 04/14] Compiles --- arangod/RestHandler/RestAuthHandler.cpp | 2 +- arangod/RestServer/RestServerFeature.cpp | 3 +- arangod/RestServer/RestServerFeature.h | 5 + arangod/RestServer/VocbaseContext.cpp | 138 ++++++++++++++++++++++- arangod/RestServer/VocbaseContext.h | 16 ++- lib/Ssl/SslInterface.cpp | 2 +- 6 files changed, 156 insertions(+), 10 deletions(-) diff --git a/arangod/RestHandler/RestAuthHandler.cpp b/arangod/RestHandler/RestAuthHandler.cpp index 920da8ffab..905c0b9a28 100644 --- a/arangod/RestHandler/RestAuthHandler.cpp +++ b/arangod/RestHandler/RestAuthHandler.cpp @@ -55,7 +55,7 @@ std::string RestAuthHandler::generateJwt(std::string const& username, std::strin VPackBuilder bodyBuilder; { VPackObjectBuilder p(&bodyBuilder); - bodyBuilder.add("username", VPackValue(username)); + bodyBuilder.add("preferred_username", VPackValue(username)); bodyBuilder.add("iss", VPackValue("arangodb")); bodyBuilder.add("exp", VPackValue(exp.count())); } diff --git a/arangod/RestServer/RestServerFeature.cpp b/arangod/RestServer/RestServerFeature.cpp index cad2b64ea1..6666606701 100644 --- a/arangod/RestServer/RestServerFeature.cpp +++ b/arangod/RestServer/RestServerFeature.cpp @@ -228,6 +228,7 @@ static TRI_vocbase_t* LookupDatabaseFromRequest(HttpRequest* request, } static bool SetRequestContext(HttpRequest* request, void* data) { + TRI_ASSERT(RestServerFeature::RESTSERVER != nullptr); TRI_server_t* server = static_cast(data); TRI_vocbase_t* vocbase = LookupDatabaseFromRequest(request, server); @@ -242,7 +243,7 @@ static bool SetRequestContext(HttpRequest* request, void* data) { return false; } - VocbaseContext* ctx = new arangodb::VocbaseContext(request, server, vocbase); + VocbaseContext* ctx = new arangodb::VocbaseContext(request, server, vocbase, RestServerFeature::getJwtSecret()); request->setRequestContext(ctx, true); // the "true" means the request is the owner of the context diff --git a/arangod/RestServer/RestServerFeature.h b/arangod/RestServer/RestServerFeature.h index ceb3e4c717..4389abf618 100644 --- a/arangod/RestServer/RestServerFeature.h +++ b/arangod/RestServer/RestServerFeature.h @@ -54,6 +54,11 @@ class RestServerFeature final return RESTSERVER->trustedProxies(); } + static std::string getJwtSecret() { + TRI_ASSERT(RESTSERVER != nullptr); + return RESTSERVER->jwtSecret(); + } + private: static RestServerFeature* RESTSERVER; static const size_t _maxSecretLength = 64; diff --git a/arangod/RestServer/VocbaseContext.cpp b/arangod/RestServer/VocbaseContext.cpp index 897a8aa10e..f777e8c2af 100644 --- a/arangod/RestServer/VocbaseContext.cpp +++ b/arangod/RestServer/VocbaseContext.cpp @@ -23,11 +23,19 @@ #include "VocbaseContext.h" +#include + +#include +#include +#include +#include + #include "Basics/MutexLocker.h" #include "Basics/tri-strings.h" #include "Cluster/ServerState.h" #include "Endpoint/ConnectionInfo.h" #include "Logger/Logger.h" +#include "Ssl/SslInterface.h" #include "VocBase/auth.h" #include "VocBase/server.h" #include "VocBase/vocbase.h" @@ -139,8 +147,8 @@ double VocbaseContext::accessSid(std::string const& database, } VocbaseContext::VocbaseContext(HttpRequest* request, TRI_server_t* server, - TRI_vocbase_t* vocbase) - : RequestContext(request), _server(server), _vocbase(vocbase) { + TRI_vocbase_t* vocbase, std::string const& jwtSecret) + : RequestContext(request), _server(server), _vocbase(vocbase), _jwtSecret(jwtSecret) { TRI_ASSERT(_server != nullptr); TRI_ASSERT(_vocbase != nullptr); } @@ -291,7 +299,7 @@ GeneralResponse::ResponseCode VocbaseContext::authenticate() { if (!TRI_CaseEqualString(authStr.c_str(), "basic ", 6)) { return basicAuthentication(auth); } else if (TRI_CaseEqualString(authStr.c_str(), "bearer ", 7)) { - return jwtAuthentication(auth); + return jwtAuthentication(std::string(auth)); } else { // mop: hmmm is 403 the correct status code? or 401? or 400? :S return GeneralResponse::ResponseCode::FORBIDDEN; @@ -371,6 +379,126 @@ GeneralResponse::ResponseCode VocbaseContext::basicAuthentication(const char* au /// @brief checks the authentication via jwt //////////////////////////////////////////////////////////////////////////////// -GeneralResponse::ResponseCode VocbaseContext::jwtAuthentication(const char* auth) { - return GeneralResponse::ResponseCode::FORBIDDEN; +GeneralResponse::ResponseCode VocbaseContext::jwtAuthentication(std::string const& auth) { + std::vector const parts = StringUtils::split(auth, '.'); + + if (parts.size() != 3) { + return GeneralResponse::ResponseCode::FORBIDDEN; + } + + std::string const& header = parts[0]; + std::string const& body = parts[1]; + std::string const& signature = parts[2]; + + std::string const message = header + "." + body; + + if (!validateJwtHeader(header)) { + LOG(DEBUG) << "Couldn't validate jwt header " << header; + return GeneralResponse::ResponseCode::FORBIDDEN; + } + + if (!validateJwtBody(body)) { + LOG(DEBUG) << "Couldn't validate jwt body " << body; + return GeneralResponse::ResponseCode::FORBIDDEN; + } + + if (!validateJwtHMAC256Signature(message, signature)) { + LOG(DEBUG) << "Couldn't validate jwt signature " << signature; + return GeneralResponse::ResponseCode::FORBIDDEN; + } + + return GeneralResponse::ResponseCode::OK; +} + +std::shared_ptr VocbaseContext::parseJson(std::string const& str, std::string const& hint) { + std::shared_ptr result; + VPackParser parser; + try { + parser.parse(str); + result = parser.steal(); + } catch (std::bad_alloc const&) { + LOG(ERR) << "Out of memory parsing " << hint << "!"; + } catch (VPackException const& ex) { + LOG(DEBUG) << "Couldn't parse " << hint << ": " << ex.what(); + } catch (...) { + LOG(ERR) << "Got unknown exception trying to parse " << hint; + } + + return result; +} + +bool VocbaseContext::validateJwtHeader(std::string const& header) { + std::shared_ptr headerBuilder = parseJson(StringUtils::decodeBase64(header), "jwt header"); + if (headerBuilder.get() == nullptr) { + return false; + } + + VPackSlice const headerSlice = headerBuilder->slice(); + if (!headerSlice.isObject()) { + return false; + } + + VPackSlice const algSlice = headerSlice.get("alg"); + VPackSlice const typSlice = headerSlice.get("typ"); + + if (!algSlice.isString()) { + return false; + } + + if (!typSlice.isString()) { + return false; + } + + if (algSlice.copyString() != "HS256") { + return false; + } + + if (typSlice.copyString() != "jwt") { + return false; + } + + return true; +} + +bool VocbaseContext::validateJwtBody(std::string const& body) { + std::shared_ptr bodyBuilder = parseJson(StringUtils::decodeBase64(body), "jwt body"); + if (bodyBuilder.get() == nullptr) { + return false; + } + + VPackSlice const bodySlice = bodyBuilder->slice(); + if (!bodySlice.isObject()) { + return false; + } + + VPackSlice const issSlice = bodySlice.get("iss"); + if (!issSlice.isString()) { + return false; + } + + if (issSlice.copyString() != "arangodb") { + return false; + } + + // mop: optional exp (cluster currently uses non expiring jwts) + if (bodySlice.hasKey("exp")) { + VPackSlice const expSlice = bodySlice.get("exp"); + + if (!expSlice.isNumber()) { + return false; + } + + std::chrono::system_clock::time_point expires(std::chrono::seconds(expSlice.getNumber())); + std::chrono::system_clock::time_point now = std::chrono::system_clock::now(); + + if (now >= expires) { + return false; + } + } + return true; +} + +bool VocbaseContext::validateJwtHMAC256Signature(std::string const& message, std::string const& signature) { + std::string decodedSignature = StringUtils::decodeBase64(signature); + return verifyHMAC(_jwtSecret.c_str(), _jwtSecret.length(), message.c_str(), message.length(), signature.c_str(), signature.length(), SslInterface::Algorithm::ALGORITHM_SHA256); } diff --git a/arangod/RestServer/VocbaseContext.h b/arangod/RestServer/VocbaseContext.h index 4bc2cfa422..9002b291fd 100644 --- a/arangod/RestServer/VocbaseContext.h +++ b/arangod/RestServer/VocbaseContext.h @@ -24,6 +24,9 @@ #ifndef ARANGOD_REST_SERVER_VOCBASE_CONTEXT_H #define ARANGOD_REST_SERVER_VOCBASE_CONTEXT_H 1 +#include +#include + #include "Basics/Common.h" #include "Rest/HttpRequest.h" #include "Rest/HttpResponse.h" @@ -66,7 +69,7 @@ class VocbaseContext : public arangodb::RequestContext { static double accessSid(std::string const& database, std::string const& sid); public: - VocbaseContext(HttpRequest*, TRI_server_t*, TRI_vocbase_t*); + VocbaseContext(HttpRequest*, TRI_server_t*, TRI_vocbase_t*, std::string const&); ~VocbaseContext(); @@ -95,6 +98,7 @@ class VocbaseContext : public arangodb::RequestContext { GeneralResponse::ResponseCode authenticate() override final; + private: ////////////////////////////////////////////////////////////////////////////// /// @brief checks the authentication (basic) ////////////////////////////////////////////////////////////////////////////// @@ -105,7 +109,13 @@ class VocbaseContext : public arangodb::RequestContext { /// @brief checks the authentication (jwt) ////////////////////////////////////////////////////////////////////////////// - GeneralResponse::ResponseCode jwtAuthentication(const char*); + GeneralResponse::ResponseCode jwtAuthentication(std::string const&); + + std::shared_ptr parseJson(std::string const&, std::string const&); + + bool validateJwtHeader(std::string const&); + bool validateJwtBody(std::string const&); + bool validateJwtHMAC256Signature(std::string const&, std::string const&); public: //////////////////////////////////////////////////////////////////////////////// @@ -126,6 +136,8 @@ class VocbaseContext : public arangodb::RequestContext { ////////////////////////////////////////////////////////////////////////////// TRI_vocbase_t* _vocbase; + + std::string const _jwtSecret; }; } diff --git a/lib/Ssl/SslInterface.cpp b/lib/Ssl/SslInterface.cpp index 613cc0904f..c4c9617074 100644 --- a/lib/Ssl/SslInterface.cpp +++ b/lib/Ssl/SslInterface.cpp @@ -270,7 +270,7 @@ bool verifyHMAC(char const* challenge, size_t challengeLength, // result must == BASE64(response, responseLen) std::string s = - StringUtils::encodeHex(sslHMAC(challenge, challengeLength, secret, secretLen, algorithm)); + sslHMAC(challenge, challengeLength, secret, secretLen, algorithm); if (s.length() == responseLen && s.compare(std::string(response, responseLen)) == 0) { From 66ed7b37f502142cf1cdca1c9759ad7608210023 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Tue, 31 May 2016 17:03:45 +0200 Subject: [PATCH 05/14] Verify jwt token --- arangod/RestServer/VocbaseContext.cpp | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/arangod/RestServer/VocbaseContext.cpp b/arangod/RestServer/VocbaseContext.cpp index f777e8c2af..45a5b805f2 100644 --- a/arangod/RestServer/VocbaseContext.cpp +++ b/arangod/RestServer/VocbaseContext.cpp @@ -296,13 +296,15 @@ GeneralResponse::ResponseCode VocbaseContext::authenticate() { ++auth; } - if (!TRI_CaseEqualString(authStr.c_str(), "basic ", 6)) { + LOG(DEBUG) << "Authorization header: " << authStr; + + if (TRI_CaseEqualString(authStr.c_str(), "basic ", 6)) { return basicAuthentication(auth); } else if (TRI_CaseEqualString(authStr.c_str(), "bearer ", 7)) { return jwtAuthentication(std::string(auth)); } else { // mop: hmmm is 403 the correct status code? or 401? or 400? :S - return GeneralResponse::ResponseCode::FORBIDDEN; + return GeneralResponse::ResponseCode::UNAUTHORIZED; } } @@ -383,7 +385,7 @@ GeneralResponse::ResponseCode VocbaseContext::jwtAuthentication(std::string cons std::vector const parts = StringUtils::split(auth, '.'); if (parts.size() != 3) { - return GeneralResponse::ResponseCode::FORBIDDEN; + return GeneralResponse::ResponseCode::UNAUTHORIZED; } std::string const& header = parts[0]; @@ -394,17 +396,17 @@ GeneralResponse::ResponseCode VocbaseContext::jwtAuthentication(std::string cons if (!validateJwtHeader(header)) { LOG(DEBUG) << "Couldn't validate jwt header " << header; - return GeneralResponse::ResponseCode::FORBIDDEN; + return GeneralResponse::ResponseCode::UNAUTHORIZED; } if (!validateJwtBody(body)) { LOG(DEBUG) << "Couldn't validate jwt body " << body; - return GeneralResponse::ResponseCode::FORBIDDEN; + return GeneralResponse::ResponseCode::UNAUTHORIZED; } if (!validateJwtHMAC256Signature(message, signature)) { LOG(DEBUG) << "Couldn't validate jwt signature " << signature; - return GeneralResponse::ResponseCode::FORBIDDEN; + return GeneralResponse::ResponseCode::UNAUTHORIZED; } return GeneralResponse::ResponseCode::OK; @@ -452,8 +454,10 @@ bool VocbaseContext::validateJwtHeader(std::string const& header) { if (algSlice.copyString() != "HS256") { return false; } - - if (typSlice.copyString() != "jwt") { + + std::string typ = typSlice.copyString(); + std::transform(typ.begin(), typ.end(), typ.begin(), ::tolower); + if (typ != "jwt") { return false; } @@ -500,5 +504,5 @@ bool VocbaseContext::validateJwtBody(std::string const& body) { bool VocbaseContext::validateJwtHMAC256Signature(std::string const& message, std::string const& signature) { std::string decodedSignature = StringUtils::decodeBase64(signature); - return verifyHMAC(_jwtSecret.c_str(), _jwtSecret.length(), message.c_str(), message.length(), signature.c_str(), signature.length(), SslInterface::Algorithm::ALGORITHM_SHA256); + return verifyHMAC(_jwtSecret.c_str(), _jwtSecret.length(), message.c_str(), message.length(), decodedSignature.c_str(), decodedSignature.length(), SslInterface::Algorithm::ALGORITHM_SHA256); } From b5f27100b125a40987b76cacae98b9e2d13d22f4 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Tue, 31 May 2016 17:22:28 +0200 Subject: [PATCH 06/14] oops...JWT should be uppercase in header --- arangod/RestHandler/RestAuthHandler.cpp | 2 +- arangod/RestServer/VocbaseContext.cpp | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/arangod/RestHandler/RestAuthHandler.cpp b/arangod/RestHandler/RestAuthHandler.cpp index 905c0b9a28..1f0605fcf7 100644 --- a/arangod/RestHandler/RestAuthHandler.cpp +++ b/arangod/RestHandler/RestAuthHandler.cpp @@ -46,7 +46,7 @@ std::string RestAuthHandler::generateJwt(std::string const& username, std::strin { VPackObjectBuilder h(&headerBuilder); headerBuilder.add("alg", VPackValue("HS256")); - headerBuilder.add("typ", VPackValue("jwt")); + headerBuilder.add("typ", VPackValue("JWT")); } std::chrono::seconds exp = std::chrono::duration_cast( diff --git a/arangod/RestServer/VocbaseContext.cpp b/arangod/RestServer/VocbaseContext.cpp index 45a5b805f2..5cadb0e2bb 100644 --- a/arangod/RestServer/VocbaseContext.cpp +++ b/arangod/RestServer/VocbaseContext.cpp @@ -456,8 +456,7 @@ bool VocbaseContext::validateJwtHeader(std::string const& header) { } std::string typ = typSlice.copyString(); - std::transform(typ.begin(), typ.end(), typ.begin(), ::tolower); - if (typ != "jwt") { + if (typ != "JWT") { return false; } From 9178e560eb35bc4525b8af59c438672dab04caab Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Tue, 31 May 2016 19:19:10 +0200 Subject: [PATCH 07/14] Implement jwt tests --- arangod/RestHandler/RestAuthHandler.cpp | 2 +- arangod/RestServer/VocbaseContext.cpp | 3 +- js/client/modules/@arangodb/testing.js | 3 +- js/client/tests/auth.js | 189 +++++++++++++++++++++++- 4 files changed, 192 insertions(+), 5 deletions(-) diff --git a/arangod/RestHandler/RestAuthHandler.cpp b/arangod/RestHandler/RestAuthHandler.cpp index 1f0605fcf7..7b81b924d8 100644 --- a/arangod/RestHandler/RestAuthHandler.cpp +++ b/arangod/RestHandler/RestAuthHandler.cpp @@ -63,7 +63,7 @@ std::string RestAuthHandler::generateJwt(std::string const& username, std::strin std::string fullMessage(StringUtils::encodeBase64(headerBuilder.toJson()) + "." + StringUtils::encodeBase64(bodyBuilder.toJson())); std::string signature = sslHMAC(_jwtSecret.c_str(), _jwtSecret.length(), fullMessage.c_str(), fullMessage.length(), SslInterface::Algorithm::ALGORITHM_SHA256); - return fullMessage + "." + StringUtils::encodeBase64(signature); + return fullMessage + "." + StringUtils::encodeBase64U(signature); } //////////////////////////////////////////////////////////////////////////////// diff --git a/arangod/RestServer/VocbaseContext.cpp b/arangod/RestServer/VocbaseContext.cpp index 5cadb0e2bb..8b50d59f90 100644 --- a/arangod/RestServer/VocbaseContext.cpp +++ b/arangod/RestServer/VocbaseContext.cpp @@ -502,6 +502,7 @@ bool VocbaseContext::validateJwtBody(std::string const& body) { } bool VocbaseContext::validateJwtHMAC256Signature(std::string const& message, std::string const& signature) { - std::string decodedSignature = StringUtils::decodeBase64(signature); + std::string decodedSignature = StringUtils::decodeBase64U(signature); + return verifyHMAC(_jwtSecret.c_str(), _jwtSecret.length(), message.c_str(), message.length(), decodedSignature.c_str(), decodedSignature.length(), SslInterface::Algorithm::ALGORITHM_SHA256); } diff --git a/js/client/modules/@arangodb/testing.js b/js/client/modules/@arangodb/testing.js index ac9ca1f756..adf2a7a7ec 100644 --- a/js/client/modules/@arangodb/testing.js +++ b/js/client/modules/@arangodb/testing.js @@ -2245,7 +2245,8 @@ testFuncs.authentication = function(options) { print(CYAN + "Authentication tests..." + RESET); let instanceInfo = startInstance("tcp", options, { - "server.authentication": "true" + "server.authentication": "true", + "server.jwt-secret": "haxxmann", }, "authentication"); if (instanceInfo === false) { diff --git a/js/client/tests/auth.js b/js/client/tests/auth.js index 5799e16f3f..505dd881f8 100644 --- a/js/client/tests/auth.js +++ b/js/client/tests/auth.js @@ -32,7 +32,10 @@ var jsunity = require("jsunity"); var arango = require("@arangodb").arango; var db = require("internal").db; var users = require("@arangodb/users"); - +var request = require('@arangodb/request'); +var crypto = require('@arangodb/crypto'); +var expect = require('expect.js'); +var print = require('internal').print; //////////////////////////////////////////////////////////////////////////////// /// @brief test suite @@ -40,6 +43,12 @@ var users = require("@arangodb/users"); function AuthSuite () { 'use strict'; + var baseUrl = function () { + return arango.getEndpoint().replace(/^tcp:/, 'http:').replace(/^ssl:/, 'https:'); + } + + const jwtSecret = 'haxxmann'; + return { //////////////////////////////////////////////////////////////////////////////// @@ -225,8 +234,184 @@ function AuthSuite () { } catch (err3) { } - } + }, + + testAuthOpen: function() { + var res = request(baseUrl() + "/_open/auth"); + expect(res).to.be.a(request.Response); + // mop: GET is an unsupported method, but it is skipping auth + expect(res).to.have.property('statusCode', 405); + }, + + testAuth: function() { + var res = request.post({ + url: baseUrl() + "/_open/auth", + body: JSON.stringify({"username": "root", "password": ""}) + }); + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 200); + expect(res.body).to.be.an('string'); + var obj = JSON.parse(res.body); + expect(obj).to.have.property('jwt'); + expect(obj).to.have.property('must_change_password'); + expect(obj.jwt).to.be.a('string'); + expect(obj.jwt.split('.').length).to.be(3); + expect(obj.must_change_password).to.be.a('boolean'); + }, + + testAuthNewUser: function() { + users.save("hackers@arangodb.com", "foobar"); + users.reload(); + + var res = request.post({ + url: baseUrl() + "/_open/auth", + body: JSON.stringify({"username": "hackers@arangodb.com", "password": "foobar"}) + }); + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 200); + expect(res.body).to.be.an('string'); + var obj = JSON.parse(res.body); + expect(obj).to.have.property('jwt'); + expect(obj).to.have.property('must_change_password'); + expect(obj.jwt).to.be.a('string'); + expect(obj.jwt.split('.').length).to.be(3); + expect(obj.must_change_password).to.be.a('boolean'); + }, + + testAuthNewWrongPassword: function() { + users.save("hackers@arangodb.com", "foobarJAJA"); + users.reload(); + + var res = request.post({ + url: baseUrl() + "/_open/auth", + body: JSON.stringify({"username": "hackers@arangodb.com", "password": "foobar"}) + }); + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 401); + }, + + testAuthNoPassword: function() { + var res = request.post({ + url: baseUrl() + "/_open/auth", + body: JSON.stringify({"username": "hackers@arangodb.com", "passwordaa": "foobar"}), + }); + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 400); + }, + + testAuthNoUsername: function() { + var res = request.post({ + url: baseUrl() + "/_open/auth", + body: JSON.stringify({"usern": "hackers@arangodb.com", "password": "foobar"}), + }); + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 400); + }, + + testAuthRequired: function() { + var res = request.get(baseUrl() + "/_api/version"); + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 401); + }, + + testFullAuthWorkflow: function() { + var res = request.post({ + url: baseUrl() + "/_open/auth", + body: JSON.stringify({"username": "root", "password": ""}), + }); + + var jwt = JSON.parse(res.body).jwt; + + var res = request.get({ + url: baseUrl() + "/_api/version", + auth: { + bearer: jwt, + } + }); + + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 200); + }, + + testViaJS: function() { + var jwt = crypto.jwtEncode(jwtSecret, {"iss": "arangodb", "exp": 90000000000 }, 'HS256'); + + var res = request.get({ + url: baseUrl() + "/_api/version", + auth: { + //bearer: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE0NjczMDU5MzIsImlzcyI6ImFyYW5nb2RiIiwicHJlZmVycmVkX3VzZXJuYW1lIjoicm9vdCJ9.79d6C8FxSSii7W37QiyXzYD6eJmNT2JLgom3LX7cnh4", + bearer: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE0NjczMDU5MzIsImlzcyI6ImFyYW5nb2RiIiwicHJlZmVycmVkX3VzZXJuYW1lIjoicm9vdGEifQ.taTTZoB12MUtDvUJWoosgq_pfcxQSxRYAvJAU71cw9Y", + } + }) + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 200); + }, + + testNoneAlgDisabled: function() { + var jwt = (new Buffer(JSON.stringify({"typ": "JWT","alg": "none"})).toString('base64')) + "." + (new Buffer(JSON.stringify({"iss": "arangodb"})).toString('base64')); + // not supported + var res = request.get({ + url: baseUrl() + "/_api/version", + auth: { + bearer: jwt, + } + }) + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 401); + }, + + testIssRequired: function() { + var jwt = crypto.jwtEncode(jwtSecret, {"exp": Math.floor(Date.now() / 1000) + 3600 }, 'HS256'); + // not supported + var res = request.get({ + url: baseUrl() + "/_api/version", + auth: { + bearer: jwt, + } + }) + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 401); + }, + + testIssArangodb: function() { + var jwt = crypto.jwtEncode(jwtSecret, {"iss": "arangodbaaa", "exp": Math.floor(Date.now() / 1000) + 3600 }, 'HS256'); + // not supported + var res = request.get({ + url: baseUrl() + "/_api/version", + auth: { + bearer: jwt, + } + }) + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 401); + }, + + testExpOptional: function() { + var jwt = crypto.jwtEncode(jwtSecret, {"iss": "arangodb" }, 'HS256'); + // not supported + var res = request.get({ + url: baseUrl() + "/_api/version", + auth: { + bearer: jwt, + } + }) + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 200); + }, + + testExp: function() { + var jwt = crypto.jwtEncode(jwtSecret, {"iss": "arangodbaaa", "exp": Math.floor(Date.now() / 1000) - 1000 }, 'HS256'); + // not supported + var res = request.get({ + url: baseUrl() + "/_api/version", + auth: { + bearer: jwt, + } + }) + expect(res).to.be.a(request.Response); + expect(res).to.have.property('statusCode', 401); + }, }; } From a6a6f162fab627b37bb0d2a56bbd9b15ecbfa8e2 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Tue, 31 May 2016 19:26:38 +0200 Subject: [PATCH 08/14] Fix hardcoded jwt --- js/client/tests/auth.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/js/client/tests/auth.js b/js/client/tests/auth.js index 505dd881f8..2304e94aca 100644 --- a/js/client/tests/auth.js +++ b/js/client/tests/auth.js @@ -322,7 +322,6 @@ function AuthSuite () { }); var jwt = JSON.parse(res.body).jwt; - var res = request.get({ url: baseUrl() + "/_api/version", auth: { @@ -340,8 +339,7 @@ function AuthSuite () { var res = request.get({ url: baseUrl() + "/_api/version", auth: { - //bearer: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE0NjczMDU5MzIsImlzcyI6ImFyYW5nb2RiIiwicHJlZmVycmVkX3VzZXJuYW1lIjoicm9vdCJ9.79d6C8FxSSii7W37QiyXzYD6eJmNT2JLgom3LX7cnh4", - bearer: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE0NjczMDU5MzIsImlzcyI6ImFyYW5nb2RiIiwicHJlZmVycmVkX3VzZXJuYW1lIjoicm9vdGEifQ.taTTZoB12MUtDvUJWoosgq_pfcxQSxRYAvJAU71cw9Y", + bearer: jwt, } }) expect(res).to.be.a(request.Response); From 2a1c9b93f472729fe5ba367fa3d9e30ad25b882e Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Wed, 1 Jun 2016 09:50:32 +0200 Subject: [PATCH 09/14] Fix eslint stuff --- js/common/tests/shell/shell-query-timecritical-spec.js | 2 +- js/server/modules/@arangodb/foxx/oauth2.js | 2 +- js/server/tests/shell/shell-foxx-legacy-query-spec.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/js/common/tests/shell/shell-query-timecritical-spec.js b/js/common/tests/shell/shell-query-timecritical-spec.js index 4aec61d574..be38f8f47f 100644 --- a/js/common/tests/shell/shell-query-timecritical-spec.js +++ b/js/common/tests/shell/shell-query-timecritical-spec.js @@ -1,5 +1,5 @@ /*jshint expr: true */ -/*eslint no-unused-expressions: false */ +/*eslint no-unused-expressions: 0 */ /*global describe, it, beforeEach, afterEach */ 'use strict'; const internal = require('internal'); diff --git a/js/server/modules/@arangodb/foxx/oauth2.js b/js/server/modules/@arangodb/foxx/oauth2.js index 5cbaefead5..db4b2997f4 100644 --- a/js/server/modules/@arangodb/foxx/oauth2.js +++ b/js/server/modules/@arangodb/foxx/oauth2.js @@ -1,4 +1,4 @@ -/*eslint camelcase:false */ +/*eslint camelcase: 0 */ 'use strict'; //////////////////////////////////////////////////////////////////////////////// diff --git a/js/server/tests/shell/shell-foxx-legacy-query-spec.js b/js/server/tests/shell/shell-foxx-legacy-query-spec.js index 2c11e6d8b4..18d8df8b53 100644 --- a/js/server/tests/shell/shell-foxx-legacy-query-spec.js +++ b/js/server/tests/shell/shell-foxx-legacy-query-spec.js @@ -1,5 +1,5 @@ /*jshint -W083 */ -/*eslint no-loop-func: false */ +/*eslint no-loop-func: 0 */ /*global describe, it, beforeEach, afterEach */ 'use strict'; From 979e0f2d07d0444479db2b861520ddbfaf795032 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Wed, 1 Jun 2016 09:59:24 +0200 Subject: [PATCH 10/14] proper expiry --- js/client/tests/auth.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/client/tests/auth.js b/js/client/tests/auth.js index 2304e94aca..b2b3cf7a55 100644 --- a/js/client/tests/auth.js +++ b/js/client/tests/auth.js @@ -334,7 +334,7 @@ function AuthSuite () { }, testViaJS: function() { - var jwt = crypto.jwtEncode(jwtSecret, {"iss": "arangodb", "exp": 90000000000 }, 'HS256'); + var jwt = crypto.jwtEncode(jwtSecret, {"iss": "arangodb", "exp": Math.floor(Date.now() / 1000) + 3600}, 'HS256'); var res = request.get({ url: baseUrl() + "/_api/version", From 52c8f272da35ce7e449684d5c99d0e18ac24eb84 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Wed, 1 Jun 2016 12:07:45 +0200 Subject: [PATCH 11/14] Reconnecting now uses the correct user --- arangosh/Shell/V8ClientConnection.cpp | 18 ++++++++++-------- arangosh/Shell/V8ClientConnection.h | 2 +- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/arangosh/Shell/V8ClientConnection.cpp b/arangosh/Shell/V8ClientConnection.cpp index a20f497c2a..ef63a15157 100644 --- a/arangosh/Shell/V8ClientConnection.cpp +++ b/arangosh/Shell/V8ClientConnection.cpp @@ -52,23 +52,25 @@ V8ClientConnection::V8ClientConnection( std::unique_ptr& connection, std::string const& database, std::string const& username, std::string const& password, double requestTimeout) - : _databaseName(database), - _username(username), - _password(password), - _requestTimeout(requestTimeout), + : _requestTimeout(requestTimeout), _client(nullptr), _lastHttpReturnCode(0), _lastErrorMessage(""), _httpResult(nullptr), _version("arango"), _mode("unknown mode") { - init(connection); + init(connection, username, password, database); } V8ClientConnection::~V8ClientConnection() {} void V8ClientConnection::init( - std::unique_ptr& connection) { + std::unique_ptr& connection, std::string const& username, + std::string const& password, std::string const& databaseName) { + _username = username; + _password = password; + _databaseName = databaseName; + _client.reset(new SimpleHttpClient(connection, _requestTimeout, false)); _client->setLocationRewriter(this, &rewriteLocation); _client->setUserNamePassword("/", _username, _password); @@ -169,7 +171,7 @@ void V8ClientConnection::reconnect(ClientFeature* client) { try { std::unique_ptr connection = client->createConnection(client->endpoint()); - init(connection); + init(connection, client->username(), client->password(), client->databaseName()); } catch (...) { std::string errorMessage = "error in '" + client->endpoint() + "'"; throw errorMessage; @@ -398,7 +400,7 @@ static void ClientConnection_reconnect( } else { password = TRI_ObjectToString(args[3]); } - + client->setEndpoint(endpoint); client->setDatabaseName(databaseName); client->setUsername(username); diff --git a/arangosh/Shell/V8ClientConnection.h b/arangosh/Shell/V8ClientConnection.h index 7508cc7692..76400de65c 100644 --- a/arangosh/Shell/V8ClientConnection.h +++ b/arangosh/Shell/V8ClientConnection.h @@ -109,7 +109,7 @@ class V8ClientConnection { static std::string rewriteLocation(void*, std::string const&); private: - void init(std::unique_ptr&); + void init(std::unique_ptr&, std::string const&, std::string const&, std::string const&); v8::Handle requestData( v8::Isolate* isolate, GeneralRequest::RequestType method, From 1fb57a2a93aa0a347184650e914218209fe2a188 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Wed, 1 Jun 2016 12:08:44 +0200 Subject: [PATCH 12/14] properly check for failures --- js/client/tests/auth.js | 83 ++++++++++++++++++++++++++++++++--------- 1 file changed, 65 insertions(+), 18 deletions(-) diff --git a/js/client/tests/auth.js b/js/client/tests/auth.js index b2b3cf7a55..a4036b8929 100644 --- a/js/client/tests/auth.js +++ b/js/client/tests/auth.js @@ -91,18 +91,21 @@ function AuthSuite () { assertTrue(db._collections().length > 0); // double check with wrong passwords + let isBroken; + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "foobar2"); - fail(); } catch (err1) { + isBroken = false; } + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", ""); - fail(); } catch (err2) { + isBroken = false; } }, @@ -120,11 +123,13 @@ function AuthSuite () { assertTrue(db._collections().length > 0); // double check with wrong password + let isBroken; + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "foobar"); - fail(); } catch (err1) { + isBroken = false; } }, @@ -142,25 +147,41 @@ function AuthSuite () { assertTrue(db._collections().length > 0); // double check with wrong passwords + let isBroken; + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "Foobar"); - fail(); + console.error("HASSMANN HIHI"); + assertTrue(db._collections().length > 0); } catch (err1) { + console.error("HASSMANN"); + isBroken = false; + } + if (isBroken) { + throw new Error("Wurst"); } + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "foobar"); - fail(); } catch (err2) { + isBroken = false; } - - try { - arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "FOOBAR"); + if (isBroken) { fail(); } + + isBroken = true; + try { + arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "FOOBAR"); + } catch (err3) { + isBroken = false; + } + if (isBroken) { + fail(); } }, @@ -178,25 +199,38 @@ function AuthSuite () { assertTrue(db._collections().length > 0); // double check with wrong passwords + let isBroken; + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "fuxx"); - fail(); } catch (err1) { + isBroken = false; + } + if (isBroken) { + fail(); } + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "bar"); - fail(); } catch (err2) { + isBroken = false; } - - try { - arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", ""); + if (isBroken) { fail(); } + + isBroken = true; + try { + arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", ""); + } catch (err3) { + isBroken = false; + } + if (isBroken) { + fail(); } }, @@ -214,25 +248,38 @@ function AuthSuite () { assertTrue(db._collections().length > 0); // double check with wrong passwords + let isBroken; + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "foobar"); - fail(); } catch (err1) { + isBroken = false; + } + if (isBroken) { + fail(); } + isBroken = true; try { arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", "\\abc'def: x-a"); - fail(); } catch (err2) { + isBroken = false; } - - try { - arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", ""); + if (isBroken) { fail(); } + + isBroken = true; + try { + arango.reconnect(arango.getEndpoint(), db._name(), "hackers@arangodb.com", ""); + } catch (err3) { + isBroken = false; + } + if (isBroken) { + fail(); } }, From 021b71a7c157bb983f53a6584bfc59d20bfbda12 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Wed, 1 Jun 2016 17:51:39 +0200 Subject: [PATCH 13/14] Frontend is working --- arangod/HttpServer/HttpCommTask.cpp | 2 +- arangod/RestServer/VocbaseContext.cpp | 32 +++++++-- arangod/RestServer/VocbaseContext.h | 9 ++- .../system/_admin/aardvark/APP/aardvark.js | 63 ++---------------- js/apps/system/_admin/aardvark/APP/cluster.js | 2 +- js/apps/system/_admin/aardvark/APP/foxxes.js | 2 +- .../aardvark/APP/frontend/build/app.min.js | 24 +++---- .../aardvark/APP/frontend/build/app.min.js.gz | Bin 123870 -> 123912 bytes .../APP/frontend/build/index-min.html | 2 +- .../APP/frontend/build/index-min.html.gz | Bin 28757 -> 28755 bytes .../aardvark/APP/frontend/js/arango/arango.js | 8 +++ .../frontend/js/collections/arangoUsers.js | 20 +++++- .../APP/frontend/js/routers/startApp.js | 7 ++ .../system/_admin/aardvark/APP/manifest.json | 2 +- .../system/_admin/aardvark/APP/statistics.js | 2 +- .../modules/@arangodb/foxx/router/request.js | 1 + 16 files changed, 88 insertions(+), 88 deletions(-) diff --git a/arangod/HttpServer/HttpCommTask.cpp b/arangod/HttpServer/HttpCommTask.cpp index 624cbaed11..350ad91867 100644 --- a/arangod/HttpServer/HttpCommTask.cpp +++ b/arangod/HttpServer/HttpCommTask.cpp @@ -559,7 +559,7 @@ bool HttpCommTask::processRead() { HttpResponse response(GeneralResponse::ResponseCode::UNAUTHORIZED); if (sendWwwAuthenticateHeader()) { std::string realm = - "basic realm=\"" + + "Bearer token_type=\"JWT\", realm=\"" + _server->handlerFactory()->authenticationRealm(_request) + "\""; response.setHeaderNC(StaticStrings::WwwAuthenticate, std::move(realm)); diff --git a/arangod/RestServer/VocbaseContext.cpp b/arangod/RestServer/VocbaseContext.cpp index 8b50d59f90..2bf4a40f0f 100644 --- a/arangod/RestServer/VocbaseContext.cpp +++ b/arangod/RestServer/VocbaseContext.cpp @@ -200,7 +200,21 @@ GeneralResponse::ResponseCode VocbaseContext::authenticate() { // no authentication required at all return GeneralResponse::ResponseCode::OK; } + + std::string const& path = _request->requestPath(); + // mop: inside authenticateRequest() _request->user will be populated + GeneralResponse::ResponseCode result = authenticateRequest(); + if (result == GeneralResponse::ResponseCode::UNAUTHORIZED || result == GeneralResponse::ResponseCode::FORBIDDEN) { + if (StringUtils::isPrefix(path, "/_open/") || + StringUtils::isPrefix(path, "/_admin/aardvark/") || path == "/") { + // mop: these paths are always callable...they will be able to check req.user when it could be validated + result = GeneralResponse::ResponseCode::OK; + } + } + return result; +} +GeneralResponse::ResponseCode VocbaseContext::authenticateRequest() { #ifdef ARANGODB_HAVE_DOMAIN_SOCKETS // check if we need to run authentication for this type of // endpoint @@ -230,11 +244,6 @@ GeneralResponse::ResponseCode VocbaseContext::authenticate() { } } - if (StringUtils::isPrefix(path, "/_open/") || - StringUtils::isPrefix(path, "/_admin/aardvark/") || path == "/") { - return GeneralResponse::ResponseCode::OK; - } - // ............................................................................. // authentication required // ............................................................................. @@ -399,7 +408,8 @@ GeneralResponse::ResponseCode VocbaseContext::jwtAuthentication(std::string cons return GeneralResponse::ResponseCode::UNAUTHORIZED; } - if (!validateJwtBody(body)) { + std::string username; + if (!validateJwtBody(body, &username)) { LOG(DEBUG) << "Couldn't validate jwt body " << body; return GeneralResponse::ResponseCode::UNAUTHORIZED; } @@ -408,6 +418,7 @@ GeneralResponse::ResponseCode VocbaseContext::jwtAuthentication(std::string cons LOG(DEBUG) << "Couldn't validate jwt signature " << signature; return GeneralResponse::ResponseCode::UNAUTHORIZED; } + _request->setUser(username); return GeneralResponse::ResponseCode::OK; } @@ -463,7 +474,7 @@ bool VocbaseContext::validateJwtHeader(std::string const& header) { return true; } -bool VocbaseContext::validateJwtBody(std::string const& body) { +bool VocbaseContext::validateJwtBody(std::string const& body, std::string* username) { std::shared_ptr bodyBuilder = parseJson(StringUtils::decodeBase64(body), "jwt body"); if (bodyBuilder.get() == nullptr) { return false; @@ -483,6 +494,13 @@ bool VocbaseContext::validateJwtBody(std::string const& body) { return false; } + VPackSlice const usernameSlice = bodySlice.get("preferred_username"); + if (!usernameSlice.isString()) { + return false; + } + + *username = usernameSlice.copyString(); + // mop: optional exp (cluster currently uses non expiring jwts) if (bodySlice.hasKey("exp")) { VPackSlice const expSlice = bodySlice.get("exp"); diff --git a/arangod/RestServer/VocbaseContext.h b/arangod/RestServer/VocbaseContext.h index 9002b291fd..ec70b8845a 100644 --- a/arangod/RestServer/VocbaseContext.h +++ b/arangod/RestServer/VocbaseContext.h @@ -114,8 +114,15 @@ class VocbaseContext : public arangodb::RequestContext { std::shared_ptr parseJson(std::string const&, std::string const&); bool validateJwtHeader(std::string const&); - bool validateJwtBody(std::string const&); + bool validateJwtBody(std::string const&, std::string*); bool validateJwtHMAC256Signature(std::string const&, std::string const&); + + private: + ////////////////////////////////////////////////////////////////////////////// + /// @brief checks the authentication header and sets user if successful + ////////////////////////////////////////////////////////////////////////////// + + GeneralResponse::ResponseCode authenticateRequest(); public: //////////////////////////////////////////////////////////////////////////////// diff --git a/js/apps/system/_admin/aardvark/APP/aardvark.js b/js/apps/system/_admin/aardvark/APP/aardvark.js index 31eb6b8bc4..0d9a3151dd 100644 --- a/js/apps/system/_admin/aardvark/APP/aardvark.js +++ b/js/apps/system/_admin/aardvark/APP/aardvark.js @@ -33,7 +33,6 @@ const errors = require('@arangodb').errors; const joinPath = require('path').posix.join; const notifications = require('@arangodb/configuration').notifications; const examples = require('@arangodb/graph-examples/example-graph'); -const systemStorage = require('@arangodb/foxx/sessions/storages/_system'); const createRouter = require('@arangodb/foxx/router'); const users = require('@arangodb/users'); const cluster = require('@arangodb/cluster'); @@ -42,7 +41,6 @@ const ERROR_USER_NOT_FOUND = errors.ERROR_USER_NOT_FOUND.code; const API_DOCS = require(module.context.fileName('api-docs.json')); API_DOCS.basePath = `/_db/${encodeURIComponent(db._name())}`; -const sessions = systemStorage(); const router = createRouter(); module.exports = router; @@ -89,7 +87,7 @@ router.get('/config.js', function(req, res) { }); router.get('/whoAmI', function(req, res) { - res.json({user: req.session.uid || null}); + res.json({user: req.user || null}); }) .summary('Return the current user') .description(dd` @@ -98,63 +96,12 @@ router.get('/whoAmI', function(req, res) { `); -router.post('/logout', function (req, res) { - sessions.clear(req.session); - delete req.session; - res.json({success: true}); -}) -.summary('Log out') -.description(dd` - Destroys the current session and revokes any authentication. -`); - - -router.post('/login', function (req, res) { - const currentDb = db._name(); - /* - const actualDb = req.body.database; - if (actualDb !== currentDb) { - res.redirect(307, joinPath( - '/_db', - encodeURIComponent(actualDb), - module.context.mount, - '/login' - )); - return; - } - */ - const user = req.body.username; - const valid = users.isValid(user, req.body.password); - - if (!valid) { - res.throw('unauthorized', 'Bad username or password'); - } - - sessions.setUser(req.session, user); - sessions.save(req.session); - - res.json({user}); -}) -.body({ - username: joi.string().required(), - password: joi.string().required().allow('') - //database: joi.string().default(db._name()) -}, 'Login credentials.') -.error('unauthorized', 'Invalid credentials.') -.summary('Log in') -.description(dd` - Authenticates the user for the active session with a username and password. - Creates a new session if none exists. -`); - - const authRouter = createRouter(); router.use(authRouter); - authRouter.use((req, res, next) => { if (global.AUTHENTICATION_ENABLED()) { - if (!req.session.uid) { + if (!req.user) { res.throw('unauthorized'); } } @@ -233,12 +180,11 @@ authRouter.post('/query/upload/:user', function(req, res) { let user; try { - user = users.document(req.session.uid); + user = users.document(req.user); } catch (e) { if (!e.isArangoError || e.errorNum !== ERROR_USER_NOT_FOUND) { throw e; } - sessions.setUser(req.session); res.throw('not found'); } @@ -276,12 +222,11 @@ authRouter.get('/query/download/:user', function(req, res) { let user; try { - user = users.document(req.session.uid); + user = users.document(req.user); } catch (e) { if (!e.isArangoError || e.errorNum !== ERROR_USER_NOT_FOUND) { throw e; } - sessions.setUser(req.session); res.throw('not found'); } diff --git a/js/apps/system/_admin/aardvark/APP/cluster.js b/js/apps/system/_admin/aardvark/APP/cluster.js index b324df6fd3..7b53c69dac 100644 --- a/js/apps/system/_admin/aardvark/APP/cluster.js +++ b/js/apps/system/_admin/aardvark/APP/cluster.js @@ -34,7 +34,7 @@ module.exports = router; router.use((req, res, next) => { if (global.AUTHENTICATION_ENABLED()) { - if (!req.session.uid) { + if (!req.user) { res.throw('unauthorized'); } } diff --git a/js/apps/system/_admin/aardvark/APP/foxxes.js b/js/apps/system/_admin/aardvark/APP/foxxes.js index 34acc55996..d2dfe69647 100644 --- a/js/apps/system/_admin/aardvark/APP/foxxes.js +++ b/js/apps/system/_admin/aardvark/APP/foxxes.js @@ -42,7 +42,7 @@ module.exports = router; router.use((req, res, next) => { if (global.AUTHENTICATION_ENABLED()) { - if (!req.session.uid) { + if (!req.user) { res.throw('unauthorized'); } } 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 c56b9a0015..354abb0ee7 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,14 +1,14 @@ -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){console.log(a.baseUrl);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,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,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){arangoHelper.arangoError("Server-side","createEdge was triggered.")},e.deleteEdge=function(a,b){arangoHelper.arangoError("Server-side","deleteEdge was triggered.")},e.patchEdge=function(a,b,c){arangoHelper.arangoError("Server-side","patchEdge was triggered.")},e.createNode=function(a,b){arangoHelper.arangoError("Server-side","createNode was triggered.")},e.deleteNode=function(a,b){arangoHelper.arangoError("Server-side","deleteNode was triggered."),arangoHelper.arangoError("Server-side","onNodeDelete was triggered.")},e.patchNode=function(a,b,c){arangoHelper.arangoError("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.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(){}),d()}),e=function(){h.events.CANCELCREATEEDGE(),c.removeCursorFollowingEdge(),h.bind("svg","mousemove",function(){})};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.getBoundingClientRect().width,e=a.getBoundingClientRect().height,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.getBoundingClientRect().width-81+20,q=d||a.getBoundingClientRect().height,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 console.log(q),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"),x(b,"configuredropdown","filterdropdown","nodedropdown"));i=new NodeShaperControls(c.nodes,g.nodeShaper),j=new EdgeShaperControls(c.edges,g.edgeShaper),k=new GharialAdapterControls(c.col,g.adapter),r.id="menubar",a.className="headerBar",b.id="modifiers",r.appendChild(a),r.appendChild(c.configure),r.appendChild(c.filter),r.appendChild(c.node),a.appendChild(b),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&&arangoHelper.arangoError("Graph","Sorry your graph seems to be empty")},a)}),f&&("string"==typeof f?g.loadGraph(f):g.loadGraphWithRandomStart(function(a){a&&a.errorCode&&arangoHelper.arangoError("Graph","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.getBoundingClientRect().width,f=d.getBoundingClientRect().height,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}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'+c+""),a.disabled||$("#subNavigationBar .bottom").children().last().bind("click",function(){window.App.navigate(a.route,{trigger:!0})})})},buildNodeSubNav:function(a,b,c){var d={Dashboard:{route:"#node/"+encodeURIComponent(a)},Logs:{route:"#nLogs/"+encodeURIComponent(a),disabled:!0}};d[b].active=!0,d[c].disabled=!0,this.buildSubNavBar(d)},scaleability:void 0,buildNodesSubNav:function(a){if(void 0===this.scaleability){var b=this;$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_admin/cluster/numberOfServers"),contentType:"application/json",processData:!1,success:function(a){null!==a.numberOfCoordinators&&null!==a.numberOfDBServers?(b.scaleability=!0,b.buildNodesSubNav()):b.scaleability=!1}})}var c={Coordinators:{route:"#cNodes"},DBServers:{route:"#dNodes"}};c.Scale={route:"#sNodes",disabled:!0},"coordinator"===a?c.Coordinators.active=!0:"scale"===a?this.scaleability===!0?c.Scale.active=!0:window.App.navigate("#nodes",{trigger:!0}):c.DBServers.active=!0,this.scaleability===!0&&(c.Scale.disabled=!1),this.buildSubNavBar(c)},buildCollectionSubNav:function(a,b){var c="#collection/"+encodeURIComponent(a),d={Content:{route:c+"/documents/1"},Indices:{route:"#cIndices/"+encodeURIComponent(a)},Info:{route:"#cInfo/"+encodeURIComponent(a)},Settings:{route:"#cSettings/"+encodeURIComponent(a)}};d[b].active=!0,this.buildSubNavBar(d)},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(a){var b=function(b,c){b?arangoHelper.arangoError("",""):$.ajax({type:"GET",cache:!1,url:this.databaseUrl("/_api/database/",c),contentType:"application/json",processData:!1,success:function(){a(!1,!0)},error:function(){a(!0,!1)}})}.bind(this);this.currentDatabase(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"})},arangoWarning:function(a,b,c){window.App.notificationList.add({title:a,content:b,info:c,type:"warning"})},hideArangoNotifications:function(){$.noty.clearQueue(),$.noty.closeAll()},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:this.databaseUrl("/_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:this.databaseUrl("/_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:this.databaseUrl("/_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){$.ajax({cache:!1,type:"GET",url:this.databaseUrl("/_admin/aardvark/job"),contentType:"application/json",processData:!1,success:function(b){a&&a(!1,b)},error:function(b){console.log("error"),a&&a(!0,b)}})},getPendingJobs:function(a){$.ajax({cache:!1,type:"GET",url:this.databaseUrl("/_api/job/pending"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},syncAndReturnUninishedAardvarkJobs:function(a,b){var c=function(c,d){if(c)b(!0);else{var e=function(c,e){if(c)arangoHelper.arangoError("","");else{var f=[];e.length>0?_.each(d,function(b){if(b.type===a||void 0===b.type){var c=!1;_.each(e,function(a){b.id===a&&(c=!0)}),c?f.push({collection:b.collection,id:b.id,type:b.type,desc:b.desc}):window.arangoHelper.deleteAardvarkJob(b.id)}}):d.length>0&&this.deleteAllAardvarkJobs(),b(!1,f)}}.bind(this);this.getPendingJobs(e)}}.bind(this);this.getAardvarkJobs(c)},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,c){if(b||void 0===this.CollectionTypes[a]){var d=function(b,c,d){b?arangoHelper.arangoError("Error","Could not detect collection type"):(this.CollectionTypes[a]=c.type,3===this.CollectionTypes[a]?d(!1,"edge"):d(!1,"document"))}.bind(this);this.arangoDocumentStore.getCollectionInfo(a,d,c)}else c(!1,this.CollectionTypes[a])},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,"'")},backendUrl:function(a){return frontendConfig.basePath+a},databaseUrl:function(a,b){if("/_db/"===a.substr(0,5))throw new Error("Calling databaseUrl with a databased url ("+a+") doesn't make any sense");return b||(b="_system",frontendConfig.db&&(b=frontendConfig.db)),this.backendUrl("/_db/"+encodeURIComponent(b)+a)}}}(),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){var c=_.template(b);return c=c(a)}}},a};window.templateEngine=new a}}(),function(){"use strict";window.dygraphConfig={defaultFrame:12e5,zeropad:function(a){return 10>a?"0"+a:a},xAxisFormat:function(a){if(-1===a)return"";var b=new Date(a);return this.zeropad(b.getHours())+":"+this.zeropad(b.getMinutes())+":"+this.zeropad(b.getSeconds())},mergeObjects:function(a,b,c){c||(c=[]);var d,e={};return c.forEach(function(c){var d=a[c],f=b[c];void 0===d&&(d={}),void 0===f&&(f={}),e[c]=_.extend(d,f)}),d=_.extend(a,b),Object.keys(e).forEach(function(a){d[a]=e[a]}),d},mapStatToFigure:{residentSize:["times","residentSizePercent"],pageFaults:["times","majorPageFaultsPerSecond","minorPageFaultsPerSecond"],systemUserTime:["times","systemTimePerSecond","userTimePerSecond"],totalTime:["times","avgQueueTime","avgRequestTime","avgIoTime"],dataTransfer:["times","bytesSentPerSecond","bytesReceivedPerSecond"],requests:["times","getsPerSecond","putsPerSecond","postsPerSecond","deletesPerSecond","patchesPerSecond","headsPerSecond","optionsPerSecond","othersPerSecond"]},colors:["rgb(95, 194, 135)","rgb(238, 190, 77)","#81ccd8","#7ca530","#3c3c3c","#aa90bd","#e1811d","#c7d4b2","#d0b2d4"],figureDependedOptions:{clusterRequestsPerSecond:{showLabelsOnHighlight:!0,title:"",header:"Cluster Requests per Second",stackedGraph:!0,div:"lineGraphLegend",labelsKMG2:!1,axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}}},residentSize:{header:"Memory",axes:{y:{labelsKMG2:!1,axisLabelFormatter:function(a){return parseFloat(100*a.toPrecision(3))+"%"},valueFormatter:function(a){return parseFloat(100*a.toPrecision(3))+"%"}}}},pageFaults:{header:"Page Faults",visibility:[!0,!1],labels:["datetime","Major Page","Minor Page"],div:"pageFaultsChart",labelsKMG2:!1,axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}}},systemUserTime:{div:"systemUserTimeChart",header:"System and User Time",labels:["datetime","System Time","User Time"],stackedGraph:!0,labelsKMG2:!1,axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}}},totalTime:{div:"totalTimeChart",header:"Total Time",labels:["datetime","Queue","Computation","I/O"],labelsKMG2:!1,axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}},stackedGraph:!0},dataTransfer:{header:"Data Transfer",labels:["datetime","Bytes sent","Bytes received"],stackedGraph:!0,div:"dataTransferChart"},requests:{header:"Requests",labels:["datetime","Reads","Writes"],stackedGraph:!0,div:"requestsChart",axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}}}},getDashBoardFigures:function(a){var b=[],c=this;return Object.keys(this.figureDependedOptions).forEach(function(d){"clusterRequestsPerSecond"!==d&&(c.figureDependedOptions[d].div||a)&&b.push(d)}),b},getDefaultConfig:function(a){var b=this,c={digitsAfterDecimal:1,drawGapPoints:!0,fillGraph:!0,fillAlpha:.85,showLabelsOnHighlight:!1,strokeWidth:0,lineWidth:0,strokeBorderWidth:0,includeZero:!0,highlightCircleSize:2.5,labelsSeparateLines:!0,strokeBorderColor:"rgba(0,0,0,0)",interactionModel:{},maxNumberWidth:10,colors:[this.colors[0]],xAxisLabelWidth:"50",rightGap:15,showRangeSelector:!1,rangeSelectorHeight:50,rangeSelectorPlotStrokeColor:"#365300",rangeSelectorPlotFillColor:"",pixelsPerLabel:50,labelsKMG2:!0,dateWindow:[(new Date).getTime()-this.defaultFrame,(new Date).getTime()],axes:{x:{valueFormatter:function(a){return b.xAxisFormat(a)}},y:{ticker:Dygraph.numericLinearTicks}}};return this.figureDependedOptions[a]&&(c=this.mergeObjects(c,this.figureDependedOptions[a],["axes"]),c.div&&c.labels&&(c.colors=this.getColors(c.labels),c.labelsDiv=document.getElementById(c.div+"Legend"),c.legend="always",c.showLabelsOnHighlight=!0)),c},getDetailChartConfig:function(a){var b=_.extend(this.getDefaultConfig(a),{showRangeSelector:!0,interactionModel:null,showLabelsOnHighlight:!0,highlightCircleSize:2.5,legend:"always",labelsDiv:"div#detailLegend.dashboard-legend-inner"});return"pageFaults"===a&&(b.visibility=[!0,!0]),b.labels||(b.labels=["datetime",b.header],b.colors=this.getColors(b.labels)),b},getColors:function(a){var b;return b=this.colors.concat([]),b.slice(0,a.length-1)}}}(),function(){"use strict";window.arangoCollectionModel=Backbone.Model.extend({idAttribute:"name",urlRoot:arangoHelper.databaseUrl("/_api/collection"),defaults:{id:"",name:"",status:"",type:"",isSystem:!1,picture:"",locked:!1,desc:void 0},getProperties:function(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/collection/"+encodeURIComponent(this.get("id"))+"/properties"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},getFigures:function(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/figures"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(){a(!0)}})},getRevision:function(a,b){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/revision"),contentType:"application/json",processData:!1,success:function(c){a(!1,c,b)},error:function(){a(!0)}})},getIndex:function(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/index/?collection="+this.get("id")),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},createIndex:function(a,b){var c=this;$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/index?collection="+c.get("id")),headers:{"x-arango-async":"store"},data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a,d,e){e.getResponseHeader("x-arango-async-id")?(window.arangoHelper.addAardvarkJob({id:e.getResponseHeader("x-arango-async-id"),type:"index",desc:"Creating Index",collection:c.get("id")}),b(!1,a)):b(!0,a)},error:function(a){b(!0,a)}})},deleteIndex:function(a,b){var c=this;$.ajax({cache:!1,type:"DELETE",url:arangoHelper.databaseUrl("/_api/index/"+this.get("name")+"/"+encodeURIComponent(a)),headers:{"x-arango-async":"store"},success:function(a,d,e){e.getResponseHeader("x-arango-async-id")?(window.arangoHelper.addAardvarkJob({id:e.getResponseHeader("x-arango-async-id"),type:"index",desc:"Removing Index",collection:c.get("id")}),b(!1,a)):b(!0,a)},error:function(a){b(!0,a)}}),b()},truncateCollection:function(){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/truncate"),success:function(){arangoHelper.arangoNotification("Collection truncated.")},error:function(){arangoHelper.arangoError("Collection error.")}})},loadCollection:function(a){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/load"),success:function(){a(!1)},error:function(){a(!0)}}),a()},unloadCollection:function(a){ -$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/unload?flush=true"),success:function(){a(!1)},error:function(){a(!0)}}),a()},renameCollection:function(a,b){var c=this;$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/rename"),data:JSON.stringify({name:a}),contentType:"application/json",processData:!1,success:function(){c.set("name",a),b(!1)},error:function(a){b(!0,a)}})},changeCollection:function(a,b,c,d){var e=!1;"true"===a?a=!0:"false"===a&&(a=!1);var f={waitForSync:a,journalSize:parseInt(b),indexBuckets:parseInt(c)};return $.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/properties"),data:JSON.stringify(f),contentType:"application/json",processData:!1,success:function(){d(!1)},error:function(a){d(!1,a)}}),e}})}(),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:arangoHelper.databaseUrl("/_api/database"),defaults:{}}),window.arangoDocumentModel=Backbone.Model.extend({initialize:function(){"use strict"},urlRoot:arangoHelper.databaseUrl("/_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:arangoHelper.databaseUrl("/_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()?arangoHelper.databaseUrl("/_api/user"):""!==this.get("user")?arangoHelper.databaseUrl("/_api/user/"+this.get("user")):arangoHelper.databaseUrl("/_api/user")},checkPassword:function(a,b){$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/user/"+this.get("user")),data:JSON.stringify({passwd:a}),contentType:"application/json",processData:!1,success:function(a){b(!1,a)},error:function(a){b(!0,a)}})},setPassword:function(a){$.ajax({cache:!1,type:"PATCH",url:arangoHelper.databaseUrl("/_api/user/"+this.get("user")),data:JSON.stringify({passwd:a}),contentType:"application/json",processData:!1})},setExtras:function(a,b,c){$.ajax({cache:!1,type:"PATCH",url:arangoHelper.databaseUrl("/_api/user/"+this.get("user")),data:JSON.stringify({extra:{name:a,img:b}}),contentType:"application/json",processData:!1,success:function(){c(!1)},error:function(){c(!0)}})}}),function(){"use strict";window.ClusterCoordinator=Backbone.Model.extend({defaults:{name:"",status:"ok",address:"",protocol:""},idAttribute:"name",forList:function(){return{name:this.get("name"),status:this.get("status"),url:this.get("url")}}})}(),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.Coordinator=Backbone.Model.extend({defaults:{address:"",protocol:"",name:"",status:""}})}(),function(){"use strict";window.CurrentDatabase=Backbone.Model.extend({url:arangoHelper.databaseUrl("/_api/database/current",frontendConfig.db),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=arangoHelper.databaseUrl("/_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(arangoHelper.databaseUrl("/_db/"+arango.getDatabaseName()+"/_admin/aardvark/foxxes/download/zip?mount="+this.encodedMount()))}})}(),function(){"use strict";window.Graph=Backbone.Model.extend({idAttribute:"_key",urlRoot:arangoHelper.databaseUrl("/_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.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())}})}(),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.ClusterStatisticsCollection=Backbone.Collection.extend({model:window.Statistics,url:"/_admin/statistics",updateUrl:function(){this.url=window.App.getNewRoute(this.host)+this.url},initialize:function(a,b){this.host=b.host,window.App.registerForUpdate(this)}}),function(){"use strict";window.arangoCollections=Backbone.Collection.extend({url:arangoHelper.databaseUrl("/_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"unloading";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.result,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.result},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){var c={};c.name=a.collName,c.waitForSync=a.wfs,a.journalSize>0&&(c.journalSize=a.journalSize),c.isSystem=a.isSystem,c.type=parseInt(a.collType,10),a.shards&&(c.numberOfShards=a.shards,c.shardKeys=a.keys),a.replicationFactor&&(c.replicationFactor=JSON.parse(a.replicationFactor)),$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/collection"),data:JSON.stringify(c),contentType:"application/json",processData:!1,success:function(a){b(!1,a)},error:function(a){b(!0,a)}})}})}(),function(){"use strict";window.ArangoDatabase=Backbone.Collection.extend({model:window.DatabaseModel,sortOptions:{desc:!1},url:arangoHelper.databaseUrl("/_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(a){$.ajax({type:"GET",cache:!1,url:this.url+"/user",contentType:"application/json",processData:!1,success:function(b){a(!1,b.result.sort())},error:function(){a(!0,[])}})},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("#service")&&(g="#services"),f+=g}return f},getCurrentDatabase:function(a){$.ajax({type:"GET",cache:!1,url:this.url+"/current",contentType:"application/json",processData:!1,success:function(b){200===b.code?a(!1,b.result.name):a(!1,b)},error:function(b){a(!0,b)}})},hasSystemAccess:function(a){var b=function(b,c){b?arangoHelper.arangoError("DB","Could not fetch databases"):a(!1,_.contains(c,"_system"))}.bind(this);this.getDatabasesForUser(b)}})}(),window.arangoDocument=Backbone.Collection.extend({url:"/_api/document/",model:arangoDocumentModel,collectionInfo:{},deleteEdge:function(a,b,c){this.deleteDocument(a,b,c)},deleteDocument:function(a,b,c){$.ajax({cache:!1,type:"DELETE",contentType:"application/json",url:arangoHelper.databaseUrl("/_api/document/"+encodeURIComponent(a)+"/"+encodeURIComponent(b)),success:function(){c(!1)},error:function(){c(!0)}})},addDocument:function(a,b){var c=this;c.createTypeDocument(a,b)},createTypeEdge:function(a,b,c,d,e){var f;f=d?JSON.stringify({_key:d,_from:b,_to:c}):JSON.stringify({_from:b,_to:c}),$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/document?collection="+encodeURIComponent(a)),data:f,contentType:"application/json",processData:!1,success:function(a){e(!1,a)},error:function(a){e(!0,a)}})},createTypeDocument:function(a,b,c){var d;d=b?JSON.stringify({_key:b}):JSON.stringify({}),$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/document?collection="+encodeURIComponent(a)),data:d,contentType:"application/json",processData:!1,success:function(a){c(!1,a._id)},error:function(a){c(!0,a._id)}})},getCollectionInfo:function(a,b,c){var d=this;$.ajax({cache:!1,type:"GET",url:arangoHelper.databaseUrl("/_api/collection/"+a+"?"+arangoHelper.getRandomToken()),contentType:"application/json",processData:!1,success:function(a){d.collectionInfo=a,b(!1,a,c)},error:function(a){b(!0,a,c)}})},getEdge:function(a,b,c){this.getDocument(a,b,c)},getDocument:function(a,b,c){var d=this;this.clearDocument(),$.ajax({cache:!1,type:"GET",url:arangoHelper.databaseUrl("/_api/document/"+encodeURIComponent(a)+"/"+encodeURIComponent(b)),contentType:"application/json",processData:!1,success:function(a){d.add(a),c(!1,a,"document")},error:function(a){d.add(!0,a)}})},saveEdge:function(a,b,c,d){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/edge/"+encodeURIComponent(a)+"/"+encodeURIComponent(b)),data:c,contentType:"application/json",processData:!1,success:function(a){d(!1,a)},error:function(a){d(!0,a)}})},saveDocument:function(a,b,c,d){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/document/"+encodeURIComponent(a)+"/"+encodeURIComponent(b)),data:c,contentType:"application/json",processData:!1,success:function(a){d(!1,a)},error:function(a){d(!0,a)}})},updateLocalDocument:function(a){this.clearDocument(),this.add(a)},clearDocument:function(){this.reset()}}),function(){"use strict";window.arangoDocuments=window.PaginatedCollection.extend({collectionID:1,filters:[],checkCursorTimer:void 0,MAX_SORT:12e3,lastQuery:{},sortAttribute:"",url:arangoHelper.databaseUrl("/_api/documents"),model:window.arangoDocumentModel,loadTotal:function(a){var b=this;$.ajax({cache:!1,type:"GET",url:arangoHelper.databaseUrl("/_api/collection/"+this.collectionID+"/count"),contentType:"application/json",processData:!1,success:function(c){b.setTotal(c.count),a(!1)},error:function(){a(!0)}})},setCollection:function(a){var b=function(a){a&&arangoHelper.arangoError("Documents","Could not fetch documents count")}.bind(this);this.resetFilter(),this.collectionID=a,this.setPage(1),this.loadTotal(b)},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",url:arangoHelper.databaseUrl("/_api/cursor"),data:JSON.stringify(g),contentType:"application/json",success:function(){$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/cursor"),data:JSON.stringify(h),contentType:"application/json",success:function(){d&&d(),window.progressView.hide()},error:function(){window.progressView.hide(),arangoHelper.arangoError("Document error","Documents inserted, but could not be removed.")}})},error:function(){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not move selected documents.")}})},getDocuments:function(a){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&&(a+=" SORT x."+this.getSort()),a+=" RETURN x",b={query:a,bindVars:c}},uploadDocuments:function(a,b){$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_api/import?type=auto&collection="+encodeURIComponent(this.collectionID)+"&createCollection=false"),data:a,processData:!1,contentType:"json",dataType:"json",complete:function(a){if(4===a.readyState&&201===a.status)b(!1);else try{var c=JSON.parse(a.responseText);if(c.errors>0){var d="At least one error occurred during upload";b(!1,d)}}catch(e){console.log(e)}}})}})}(),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,arangoHelper.databaseUrl(b)}})}(),function(){"use strict";window.ArangoQueries=Backbone.Collection.extend({initialize:function(a,b){var c=this;$.ajax("whoAmI?_="+Date.now(),{async:!0}).done(function(a){this.activeUser===!1?c.activeUser="root":c.activeUser=a.user})},url:arangoHelper.databaseUrl("/_api/user/"),model:ArangoQuery,activeUser:null,parse:function(a){var b,c=this;return this.activeUser===!1&&(this.activeUser="root"),_.each(a.result,function(a){if(a.user===c.activeUser)try{a.extra.queries&&(b=a.extra.queries)}catch(d){}}),b},saveCollectionQueries:function(a){if(0===this.activeUser)return!1;this.activeUser===!1&&(this.activeUser="root");var b=[];this.each(function(a){b.push({value:a.attributes.value,parameter:a.attributes.parameter,name:a.attributes.name})}),$.ajax({cache:!1,type:"PATCH",url:arangoHelper.databaseUrl("/_api/user/"+encodeURIComponent(this.activeUser)),data:JSON.stringify({extra:{queries:b}}),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(){a(!0)}})},saveImportQueries:function(a,b){return 0===this.activeUser?!1:(window.progressView.show("Fetching documents..."),void $.ajax({cache:!1,type:"POST",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(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/replication/logger-state"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},getApplyState:function(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/replication/applier-state"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})}}),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:frontendConfig.basePath+"/_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,c){var d=this;$.ajax("login",{method:"POST",data:JSON.stringify({username:a,password:b}),dataType:"json"}).success(function(a){d.activeUser=a.user,c(!1,d.activeUser)}).error(function(){d.activeUser=null,c(!0,null)})},setSortingDesc:function(a){this.sortOptions.desc=a},logout:function(){$.ajax("logout",{method:"POST"}),this.activeUser=null,this.reset(),window.App.navigate(""),window.location.reload()},setUserSettings:function(a,b){this.activeUserSettings.identifier=b},loadUserSettings:function(a){var b=this;$.ajax({type:"GET",cache:!1,url:frontendConfig.basePath+"/_api/user/"+encodeURIComponent(b.activeUser),contentType:"application/json",processData:!1,success:function(c){b.activeUserSettings=c.extra,a(!1,c)},error:function(b){a(!0,b)}})},saveUserSettings:function(a){var b=this;$.ajax({cache:!1,type:"PUT",url:frontendConfig.basePath+"/_api/user/"+encodeURIComponent(b.activeUser),data:JSON.stringify({extra:b.activeUserSettings}),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},parse:function(a){var b=[];return _.each(a.result,function(a){b.push(a)}),b},whoAmI:function(a){return this.activeUser?void a(!1,this.activeUser):void $.ajax("whoAmI?_="+Date.now()).success(function(b){a(!1,b.user)}).error(function(b){a(!0,null)})}}),function(){"use strict";window.ClusterCoordinators=window.AutomaticRetryCollection.extend({model:window.ClusterCoordinator,url:arangoHelper.databaseUrl("/_admin/aardvark/cluster/Coordinators"),updateUrl:function(){this.url=window.App.getNewRoute("Coordinators")},initialize:function(){},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()})}})}(),function(){"use strict";window.ClusterServers=window.AutomaticRetryCollection.extend({model:window.ClusterServer,host:"",url:arangoHelper.databaseUrl("/_admin/aardvark/cluster/DBServers"),updateUrl:function(){this.url=window.App.getNewRoute(this.host)+this.url},initialize:function(a,b){this.host=b.host},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)}).error(function(a){console.log("error"),console.log(a)})}},getList:function(){throw"Do not use"},getOverview:function(){throw"Do not use DbServer.getOverview"}})}(),function(){"use strict";window.CoordinatorCollection=Backbone.Collection.extend({model:window.Coordinator,url:arangoHelper.databaseUrl("/_admin/aardvark/cluster/Coordinators")})}(),function(){"use strict";window.FoxxCollection=Backbone.Collection.extend({model:window.Foxx,sortOptions:{desc:!1},url:arangoHelper.databaseUrl("/_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=arangoHelper.databaseUrl("/_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=arangoHelper.databaseUrl("/_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=arangoHelper.databaseUrl("/_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=arangoHelper.databaseUrl("/_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:frontendConfig.basePath+"/_api/gharial",dropAndDeleteGraph:function(a,b){$.ajax({type:"DELETE",url:frontendConfig.basePath+"/_api/gharial/"+encodeURIComponent(a)+"?dropCollections=true",contentType:"application/json",processData:!0,success:function(){b(!0)},error:function(){b(!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 frontendConfig.basePath+"/_api/query/current"},killRunningQuery:function(a,b){$.ajax({url:frontendConfig.basePath+"/_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",divs:["#readme","#swagger","#app-info","#sideinformation","#information","#settings"],navs:["#service-info","#service-api","#service-readme","#service-settings"],template:templateEngine.createTemplate("applicationDetailView.ejs"),events:{"click .open":"openApp","click .delete":"deleteApp","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 .subMenuEntries li":"changeSubview","mouseenter #app-scripts":"showDropdown","mouseleave #app-scripts":"hideDropdown"},changeSubview:function(a){_.each(this.navs,function(a){$(a).removeClass("active")}),$(a.currentTarget).addClass("active"),_.each(this.divs,function(a){$(".headerButtonBar").hide(),$(a).hide()}),"service-readme"===a.currentTarget.id?$("#readme").show():"service-api"===a.currentTarget.id?$("#swagger").show():"service-info"===a.currentTarget.id?(this.render(),$("#information").show(),$("#sideinformation").show()):"service-settings"===a.currentTarget.id&&(this.showConfigDialog(),$(".headerButtonBar").show(),$("#settings").show())},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").text("Set Production"),$("#app-development-indicator").css("display","inline"),$("#app-development-path").css("display","inline")):($(".app-switch-mode").text("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=function(b,c){var d=this;b?arangoHelper.arangoError("DB","Could not get current database"):($(this.el).html(this.template.render({app:this.model,db:c,mode:a})),$.get(this.appUrl(c)).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&&(d.render("readme"),$("#app-show-swagger").attr("disabled","true"))})),this.breadcrumb()}.bind(this);return arangoHelper.currentDatabase(b),_.isEmpty(this.model.get("config"))&&$("#service-settings").attr("disabled",!0),$(this.el)},breadcrumb:function(){var a="Service: "+this.model.get("name")+'',b='

    Contributors:';this.model.get("contributors")&&this.model.get("contributors").length>0?_.each(this.model.get("contributors"),function(a){b+=''+a.name+""}):b+="No contributors",b+="

    ",$(".information").append(b),this.model.get("author")&&$(".information").append('

    Author:'+this.model.get("author")+"

    "),this.model.get("mount")&&$(".information").append('

    Mount:'+this.model.get("mount")+"

    "),this.model.get("development")&&this.model.get("path")&&$(".information").append('

    Path:'+this.model.get("path")+"

    "),$("#subNavigationBar .breadcrumb").html(a)},openApp:function(){var a=function(a,b){a?arangoHelper.arangoError("DB","Could not get current database"):window.open(this.appUrl(b),this.model.get("title")).focus()}.bind(this);arangoHelper.currentDatabase(a)},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("services",{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(a){return window.location.origin+"/_db/"+encodeURIComponent(a)+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(){this.updateConfig(),arangoHelper.arangoNotification(this.model.get("name"),"Settings applied.")}.bind(this))},showConfigDialog:function(){if(_.isEmpty(this.model.get("config")))return void $("#settings .buttons").html($("#hidden_buttons").html());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,null,null,null,null,null,"settings"),$(".modal-footer").prepend($("#hidden_buttons").html())},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},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.ClusterView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("clusterView.ejs"),events:{},statsEnabled:!1,historyInit:!1,initDone:!1,interval:5e3,maxValues:100,knownServers:[],chartData:{},charts:{},nvcharts:[],startHistory:{},startHistoryAccumulated:{},initialize:function(a){var b=this;window.App.isCluster&&(this.dbServers=a.dbServers,this.coordinators=a.coordinators,this.updateServerTime(),window.setInterval(function(){if("#cluster"===window.location.hash||""===window.location.hash||"#"===window.location.hash){var a=function(a){b.rerenderValues(a),b.rerenderGraphs(a)};b.getCoordStatHistory(a)}},this.interval))},render:function(){this.$el.html(this.template.render({})),this.initDone||(void 0!==this.coordinators.first()?this.getServerStatistics():this.waitForCoordinators(),this.initDone=!0),this.initGraphs()},waitForCoordinators:function(){var a=this;window.setTimeout(function(){a.coordinators?a.getServerStatistics():a.waitForCoordinators()},500)},updateServerTime:function(){this.serverTime=(new Date).getTime()},getServerStatistics:function(){var a=this;this.data=void 0;var b=this.coordinators.first();this.statCollectCoord=new window.ClusterStatisticsCollection([],{host:b.get("address")}),this.statCollectDBS=new window.ClusterStatisticsCollection([],{host:b.get("address")});var c=[];_.each(this.dbServers,function(a){a.each(function(a){c.push(a)})}),_.each(c,function(c){if("ok"===c.get("status")){-1===a.knownServers.indexOf(c.id)&&a.knownServers.push(c.id);var d=new window.Statistics({name:c.id});d.url=b.get("protocol")+"://"+b.get("address")+"/_admin/clusterStatistics?DBserver="+c.get("name"),a.statCollectDBS.add(d)}}),this.coordinators.forEach(function(b){if("ok"===b.get("status")){-1===a.knownServers.indexOf(b.id)&&a.knownServers.push(b.id);var c=new window.Statistics({name:b.id});c.url=b.get("protocol")+"://"+b.get("address")+"/_admin/statistics",a.statCollectCoord.add(c)}});var d=function(b){a.rerenderValues(b),a.rerenderGraphs(b)}.bind(this);a.getCoordStatHistory(d),a.coordinators.fetch({success:function(){a.renderNode(!0)},error:function(){a.renderNode(!1)}})},rerenderValues:function(a){var b=this;this.coordinators.fetch({success:function(){b.renderNode(!0)},error:function(){b.renderNode(!1)}}),this.renderValue("#clusterConnections",Math.round(a.clientConnectionsCurrent)),this.renderValue("#clusterConnectionsAvg",Math.round(a.clientConnections15M));var c=a.physicalMemory,d=a.residentSizeCurrent;this.renderValue("#clusterRam",[d,c])},renderValue:function(a,b,c){if("number"==typeof b)$(a).html(b);else if($.isArray(b)){var d=b[0],e=b[1],f=1/(e/d)*100;$(a).html(f.toFixed(1)+" %")}else"string"==typeof b&&$(a).html(b);c?($(a).addClass("negative"),$(a).removeClass("positive")):($(a).addClass("positive"),$(a).removeClass("negative"))},renderNode:function(a){var b=0,c=0;if(a)if(this.coordinators.each(function(a){"ok"===a.toJSON().status?b++:c++}),c>0){var d=c+b;this.renderValue("#clusterNodes",b+"/"+d,!0)}else this.renderValue("#clusterNodes",b);else this.renderValue("#clusterNodes","OFFLINE",!0)},initValues:function(){var a=["#clusterNodes","#clusterRam","#clusterConnections","#clusterConnectionsAvg"];_.each(a,function(a){$(a).html('')})},graphData:{data:{sent:[],received:[]},http:[],average:[]},checkArraySizes:function(){var a=this;_.each(a.chartsOptions,function(b,c){_.each(b.options,function(b,d){b.values.length>a.maxValues-1&&a.chartsOptions[c].options[d].values.shift()})})},formatDataForGraph:function(a){var b=this;b.historyInit?(b.checkArraySizes(),b.chartsOptions[0].options[0].values.push({x:a.times[a.times.length-1],y:a.bytesSentPerSecond[a.bytesSentPerSecond.length-1]}),b.chartsOptions[0].options[1].values.push({x:a.times[a.times.length-1],y:a.bytesReceivedPerSecond[a.bytesReceivedPerSecond.length-1]}),b.chartsOptions[1].options[0].values.push({x:a.times[a.times.length-1],y:b.calcTotalHttp(a.http,a.bytesSentPerSecond.length-1)}),b.chartsOptions[2].options[0].values.push({x:a.times[a.times.length-1],y:a.avgRequestTime[a.bytesSentPerSecond.length-1]/b.coordinators.length})):(_.each(a.times,function(c,d){b.chartsOptions[0].options[0].values.push({x:c,y:a.bytesSentPerSecond[d]}),b.chartsOptions[0].options[1].values.push({x:c,y:a.bytesReceivedPerSecond[d]}),b.chartsOptions[1].options[0].values.push({x:c,y:b.calcTotalHttp(a.http,d)}),b.chartsOptions[2].options[0].values.push({x:c,y:a.avgRequestTime[d]/b.coordinators.length})}),b.historyInit=!0)},chartsOptions:[{id:"#clusterData",type:"bytes",count:2,options:[{area:!0,values:[],key:"Bytes out",color:"rgb(23,190,207)",strokeWidth:2,fillOpacity:.1},{area:!0,values:[],key:"Bytes in",color:"rgb(188, 189, 34)",strokeWidth:2,fillOpacity:.1}]},{id:"#clusterHttp",type:"bytes",options:[{area:!0,values:[],key:"Bytes",color:"rgb(0, 166, 90)",fillOpacity:.1}]},{id:"#clusterAverage",data:[],type:"seconds",options:[{area:!0,values:[],key:"Seconds",color:"rgb(243, 156, 18)",fillOpacity:.1}]}],initGraphs:function(){var a=this,b="Fetching data...";a.statsEnabled===!1&&(b="Statistics disabled."),_.each(a.chartsOptions,function(c){nv.addGraph(function(){a.charts[c.id]=nv.models.stackedAreaChart().options({useInteractiveGuideline:!0,showControls:!1,noData:b,duration:0}),a.charts[c.id].xAxis.axisLabel("").tickFormat(function(a){var b=new Date(1e3*a);return(b.getHours()<10?"0":"")+b.getHours()+":"+(b.getMinutes()<10?"0":"")+b.getMinutes()+":"+(b.getSeconds()<10?"0":"")+b.getSeconds()}).staggerLabels(!1),a.charts[c.id].yAxis.axisLabel("").tickFormat(function(a){var b;return"bytes"===c.type?null===a?"N/A":(b=parseFloat(d3.format(".2f")(a)),prettyBytes(b)):"seconds"===c.type?null===a?"N/A":b=parseFloat(d3.format(".3f")(a)):void 0});var d,e=a.returnGraphOptions(c.id);return e.length>0?_.each(e,function(a,b){c.options[b].values=a}):c.options[0].values=[],d=c.options,a.chartData[c.id]=d3.select(c.id).append("svg").datum(d).transition().duration(300).call(a.charts[c.id]).each("start",function(){window.setTimeout(function(){d3.selectAll(c.id+" *").each(function(){this.__transition__&&(this.__transition__.duration=0)})},0)}),nv.utils.windowResize(a.charts[c.id].update),a.nvcharts.push(a.charts[c.id]),a.charts[c.id]})})},returnGraphOptions:function(a){var b=[];return b="#clusterData"===a?[this.chartsOptions[0].options[0].values,this.chartsOptions[0].options[1].values]:"#clusterHttp"===a?[this.chartsOptions[1].options[0].values]:"#clusterAverage"===a?[this.chartsOptions[2].options[0].values]:[]},rerenderGraphs:function(a){if(this.statsEnabled){var b,c,d=this;this.formatDataForGraph(a),_.each(d.chartsOptions,function(a){c=d.returnGraphOptions(a.id),c.length>0?_.each(c,function(b,c){a.options[c].values=b}):a.options[0].values=[],b=a.options,b[0].values.length>0&&d.historyInit&&d.charts[a.id]&&d.charts[a.id].update()})}},calcTotalHttp:function(a,b){var c=0;return _.each(a,function(a){c+=a[b]}),c},getCoordStatHistory:function(a){var b,c=this,d=[],e={http:{}},f=function(a){return $.get(a,{count:c.statCollectCoord.size()},null,"json")},g=function(a){var b,d=["times"],f=["physicalMemory","residentSizeCurrent","clientConnections15M","clientConnectionsCurrent"],g=["optionsPerSecond","putsPerSecond","headsPerSecond","postsPerSecond","getsPerSecond","deletesPerSecond","othersPerSecond","patchesPerSecond"],h=["bytesSentPerSecond","bytesReceivedPerSecond","avgRequestTime"],i=0;_.each(a,function(a){a.enabled?c.statsEnabled=!0:c.statsEnabled=!1,"object"==typeof a&&(0===i?(_.each(d,function(b){e[b]=a[b]}),_.each(f,function(b){e[b]=a[b]}),_.each(g,function(b){e.http[b]=a[b]}),_.each(h,function(b){e[b]=a[b]})):(_.each(f,function(b){e[b]=e[b]+a[b]}),_.each(g,function(c){b=0,_.each(a[c],function(a){e.http[c][i]=e.http[c][i]+a,b++})}),_.each(h,function(c){b=0,_.each(a[c],function(a){e[c][i]=e[c][i]+a,b++})})),i++)})};this.statCollectCoord.each(function(a){b=a.url+"/short",d.push(f(b))}),$.when.apply($,d).done(function(){var b=[];_.each(d,function(a){b.push(a.responseJSON)}),g(b),a(e)})}})}(),function(){"use strict";window.CollectionListItemView=Backbone.View.extend({tagName:"div",className:"tile pure-u-1-1 pure-u-sm-1-2 pure-u-md-1-3 pure-u-lg-1-4 pure-u-xl-1-6",template:templateEngine.createTemplate("collectionsItemView.ejs"),initialize:function(a){this.collectionsView=a.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).addClass(this.model.get("lockType"))):$(this.el).removeClass("locked"),"loading"!==this.model.get("status")&&"unloading"!==this.model.get("status")||$(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:"loading"===this.model.get("status")?0:void("unloaded"===this.model.get("status")?this.loadCollection():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(),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=function(a,b){if(a)arangoHelper.arangoError("Error","Could not get coordinator info");else{var c;c=b?this.model.get("name"):$("#change-collection-name").val();var d=this.model.get("status");if("loaded"===d){var e;try{e=JSON.parse(1024*$("#change-collection-size").val()*1024)}catch(f){return arangoHelper.arangoError("Please enter a valid number"),0}var g;try{if(g=JSON.parse($("#change-index-buckets").val()),1>g||parseInt(g)!==Math.pow(2,Math.log2(g)))throw"invalid indexBuckets value"}catch(f){return arangoHelper.arangoError("Please enter a valid number of index buckets"),0}var h=function(a){a?arangoHelper.arangoError("Collection error: "+a.responseText):(this.collectionsView.render(),window.modalView.hide())}.bind(this),i=function(a){if(a)arangoHelper.arangoError("Collection error: "+a.responseText);else{var b=$("#change-collection-sync").val();this.model.changeCollection(b,e,g,h)}}.bind(this);this.model.renameCollection(c,i)}else if("unloaded"===d)if(this.model.get("name")!==c){var j=function(a,b){a?arangoHelper.arangoError("Collection error: "+b.responseText):(this.collectionsView.render(),window.modalView.hide())}.bind(this);this.model.renameCollection(c,j)}else window.modalView.hide()}}.bind(this);window.isCoordinator(a)},createEditPropertiesModal:function(){var a=function(a,b){if(a)arangoHelper.arangoError("Error","Could not get coordinator info");else{var c=!1;"loaded"===this.model.get("status")&&(c=!0);var d=[],e=[];b||e.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."}]));var f=function(){e.push(window.modalView.createReadOnlyEntry("change-collection-id","ID",this.model.get("id"),"")),e.push(window.modalView.createReadOnlyEntry("change-collection-type","Type",this.model.get("type"),"")),e.push(window.modalView.createReadOnlyEntry("change-collection-status","Status",this.model.get("status"),"")),d.push(window.modalView.createDeleteButton("Delete",this.deleteCollection.bind(this))),d.push(window.modalView.createDeleteButton("Truncate",this.truncateCollection.bind(this))),c?d.push(window.modalView.createNotificationButton("Unload",this.unloadCollection.bind(this))):d.push(window.modalView.createNotificationButton("Load",this.loadCollection.bind(this))),d.push(window.modalView.createSuccessButton("Save",this.saveModifiedCollection.bind(this)));var a=["General","Indices"],b=["modalTable.ejs","indicesView.ejs"];window.modalView.show(b,"Modify Collection",d,e,null,null,this.events,null,a),"loaded"===this.model.get("status")?this.getIndex():$($("#infoTab").children()[1]).remove()}.bind(this);if(c){var g=function(a,b){if(a)arangoHelper.arangoError("Collection","Could not fetch properties");else{var c=b.journalSize/1048576,d=b.indexBuckets,g=b.waitForSync;e.push(window.modalView.createTextEntry("change-collection-size","Journal size",c,"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."}])),e.push(window.modalView.createTextEntry("change-index-buckets","Index buckets",d,"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."}])),e.push(window.modalView.createSelectEntry("change-collection-sync","Wait for sync",g,"Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}]))}f()}.bind(this);this.model.getProperties(g)}else f()}}.bind(this);window.isCoordinator(a)},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()),"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],$(".index-button-bar2")[0]);$("#cancelIndex").is(":visible")&&($("#cancelIndex").detach().appendTo(b),$("#createIndex").detach().appendTo(b))}})},unbindIndexEvents:function(){$("#indexEditView #addIndex").unbind("click"),$("#newIndexType").unbind("change"),$("#infoTab a").unbind("click"),$(".deleteIndex").unbind("click")},createInfoModal:function(){var a=function(a,b,c){if(a)arangoHelper.arangoError("Figures","Could not get revision.");else{var d=[],e={figures:c,revision:b,model:this.model};window.modalView.show("modalCollectionInfo.ejs","Collection: "+this.model.get("name"),d,e)}}.bind(this),b=function(b,c){if(b)arangoHelper.arangoError("Figures","Could not get figures.");else{var d=c;this.model.getRevision(a,d)}}.bind(this);this.model.getFigures(b)},resetIndexForms:function(){$("#indexHeader input").val("").prop("checked",!1),$("#newIndexType").val("Geo").prop("selected",!0),this.selectIndexType()},createIndex:function(){var a,b,c,d=this,e=$("#newIndexType").val(),f={};switch(e){case"Geo":a=$("#newGeoFields").val();var g=d.checkboxToValue("#newGeoJson"),h=d.checkboxToValue("#newGeoConstraint"),i=d.checkboxToValue("#newGeoIgnoreNull");f={type:"geo",fields:d.stringToArray(a),geoJson:g,constraint:h,ignoreNull:i};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 j=parseInt($("#newFulltextMinLength").val(),10)||0;f={type:"fulltext",fields:d.stringToArray(a),minLength:j};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 k=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.");d.refreshCollectionsView()};window.modalView.hide(),d.model.createIndex(f,k)},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()})},refreshCollectionsView:function(){window.App.arangoCollectionsStore.fetch({success:function(){window.App.collectionsView.render()}})},deleteIndex:function(){var a=function(a){a?(arangoHelper.arangoError("Could not delete index"),$("tr th:contains('"+this.lastId+"')").parent().children().last().html(''),this.model.set("locked",!1),this.refreshCollectionsView()):a||void 0===a||($("tr th:contains('"+this.lastId+"')").parent().remove(),this.model.set("locked",!1),this.refreshCollectionsView()),this.refreshCollectionsView()}.bind(this);this.model.set("locked",!0),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(){var a=function(a,b){a?window.arangoHelper.arangoError("Index",b.errorMessage):this.renderIndex(b)}.bind(this);this.model.getIndex(a)},renderIndex:function(a){this.index=a;var b="collectionInfoTh modal-text";if(this.index){var c="",d="";_.each(this.index.indexes,function(a){d="primary"===a.type||"edge"===a.type?'':'',void 0!==a.fields&&(c=a.fields.join(", "));var e=a.id.indexOf("/"),f=a.id.substr(e+1,a.id.length),g=a.hasOwnProperty("selectivityEstimate")?(100*a.selectivityEstimate).toFixed(2)+"%":"n/a",h=a.hasOwnProperty("sparse")?a.sparse:"n/a";$("#collectionEditIndexTable").append(""+f+""+a.type+""+a.unique+""+h+""+g+""+c+""+d+"")})}this.bindIndexEvents()},toggleNewIndexView:function(){var a=$(".index-button-bar2")[0];$("#indexEditView").is(":visible")?($("#indexEditView").hide(),$("#newIndexView").show(),$("#cancelIndex").detach().appendTo("#modal-dialog .modal-footer"),$("#createIndex").detach().appendTo("#modal-dialog .modal-footer")):($("#indexEditView").show(),$("#newIndexView").hide(),$("#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:1e4,template:templateEngine.createTemplate("collectionsView.ejs"),refetchCollections:function(){var a=this;this.collection.fetch({success:function(){a.checkLockedCollections()}})},checkLockedCollections:function(){var a=function(a,b){var c=this;a?console.log("Could not check locked collections"):(this.collection.each(function(a){a.set("locked",!1)}),_.each(b,function(a){var b=c.collection.findWhere({id:a.collection});b.set("locked",!0),b.set("lockType",a.type),b.set("desc",a.desc)}),this.collection.each(function(a){a.get("locked")||($("#collection_"+a.get("name")).find(".corneredBadge").removeClass("loaded unloaded"),$("#collection_"+a.get("name")+" .corneredBadge").text(a.get("status")),$("#collection_"+a.get("name")+" .corneredBadge").addClass(a.get("status"))),a.get("locked")||"loading"===a.get("status")?($("#collection_"+a.get("name")).addClass("locked"),a.get("locked")?($("#collection_"+a.get("name")).find(".corneredBadge").removeClass("loaded unloaded"),$("#collection_"+a.get("name")).find(".corneredBadge").addClass("inProgress"),$("#collection_"+a.get("name")+" .corneredBadge").text(a.get("desc"))):$("#collection_"+a.get("name")+" .corneredBadge").text(a.get("status"))):($("#collection_"+a.get("name")).removeClass("locked"),$("#collection_"+a.get("name")+" .corneredBadge").text(a.get("status")),$("#collection_"+a.get("name")+" .corneredBadge").hasClass("inProgress")&&($("#collection_"+a.get("name")+" .corneredBadge").text(a.get("status")),$("#collection_"+a.get("name")+" .corneredBadge").removeClass("inProgress"),$("#collection_"+a.get("name")+" .corneredBadge").addClass("loaded")),"unloaded"===a.get("status")&&$("#collection_"+a.get("name")+" .icon_arangodb_info").addClass("disabled"))}))}.bind(this);window.arangoHelper.syncAndReturnUninishedAardvarkJobs("index",a)},initialize:function(){var a=this;window.setInterval(function(){"#collections"===window.location.hash&&window.VISIBLE&&a.refetchCollections()},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=function(a,b){if(a)arangoHelper.arangoError("DB","Could not check coordinator state");else{var c=$("#new-collection-name").val(),d=$("#new-collection-size").val(),e=$("#new-replication-factor").val(),f=$("#new-collection-type").val(),g=$("#new-collection-sync").val(),h=1,i=[];if(""===e&&(e=1),b){if(h=$("#new-collection-shards").val(),""===h&&(h=1),h=parseInt(h,10),1>h)return arangoHelper.arangoError("Number of shards has to be an integer value greater or equal 1"),0;i=_.pluck($("#new-collection-shardBy").select2("data"),"text"),0===i.length&&i.push("_key")}if("_"===c.substr(0,1))return arangoHelper.arangoError('No "_" allowed as first character!'),0;var j=!1,k="true"===g;if(d>0)try{d=1024*JSON.parse(d)*1024}catch(l){return arangoHelper.arangoError("Please enter a valid number"),0}if(""===c)return arangoHelper.arangoError("No collection name entered!"),0;var m=function(a,b){if(a)try{b=JSON.parse(b.responseText),arangoHelper.arangoError("Error",b.errorMessage)}catch(c){console.log(c)}else this.updateCollectionsView();window.modalView.hide()}.bind(this);this.collection.newCollection({collName:c,wfs:k,isSystem:j,collSize:d,replicationFactor:e,collType:f,shards:h,shardBy:i},m)}}.bind(this);window.isCoordinator(a)},createNewCollectionModal:function(){var a=function(a,b){if(a)arangoHelper.arangoError("DB","Could not check coordinator state");else{var c=[],d=[],e={},f=[];d.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."}])),d.push(window.modalView.createSelectEntry("new-collection-type","Type","","The type of the collection to create.",[{value:2,label:"Document"},{value:3,label:"Edge"}])),b&&(d.push(window.modalView.createTextEntry("new-collection-shards","Shards","","The number of shards to create. You cannot change this afterwards. Recommended: DBServers squared","",!0)),d.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))),c.push(window.modalView.createSuccessButton("Save",this.submitCreateCollection.bind(this))),f.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."}])),window.App.isCluster&&f.push(window.modalView.createTextEntry("new-replication-factor","Replication factor","","Numeric value. Must be at least 1. Description: TODO","",!1,[{rule:Joi.string().allow("").optional().regex(/^[0-9]*$/),msg:"Must be a number."}])),f.push(window.modalView.createSelectEntry("new-collection-sync","Wait for sync","","Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}])),e.header="Advanced",e.content=f,window.modalView.show("modalTable.ejs","New Collection",c,d,e)}}.bind(this);window.isCoordinator(a)}})}(),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:{"click .subViewNavbar .subMenuEntry":"toggleViews"},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(a){this.options=a,this.dygraphConfig=a.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=a.serverToShow,this.serverInfo?this.server=this.serverInfo.target:this.server="-local-",this.history[this.server]={}},toggleViews:function(a){var b=a.currentTarget.id.split("-")[0],c=this,d=["replication","requests","system"];_.each(d,function(a){b!==a?$("#"+a).hide():($("#"+a).show(),c.resize(),$(window).resize())}),$(".subMenuEntries").children().removeClass("active"),$("#"+b+"-statistics").addClass("active"),window.setTimeout(function(){c.resize(),$(window).resize()},200)},cleanupHistory:function(a){if(this.history[this.server].hasOwnProperty(a)&&this.history[this.server][a].length>this.defaultTimeFrame/this.interval)for(;this.history[this.server][a].length>this.defaultTimeFrame/this.interval;)this.history[this.server][a].shift()},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)){var f=0,g=0;9===c.length&&(f+=c[1],f+=c[6],f+=c[7],f+=c[8],g+=c[2],g+=c[3],g+=c[4],g+=c[5],c=[c[0],f,g]),d.history[d.server][e].push(c)}})},cutOffHistory:function(a,b){for(var c,d=this;0!==d.history[d.server][a].length&&(c=d.history[d.server][a][0][0],!(c>=b));)d.history[d.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(arangoHelper.databaseUrl("/_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,b){var c=this,d=arangoHelper.databaseUrl("/_admin/aardvark/statistics/short","_system"),e="?start=";e+=c.nextStart?c.nextStart:((new Date).getTime()-c.defaultTimeFrame)/1e3,"-local-"!==c.server&&(e+="&type=short&DBserver="+c.serverInfo.target,c.history.hasOwnProperty(c.server)||(c.history[c.server]={})),$.ajax(d+e,{async:!0,xhrFields:{withCredentials:!0},crossDomain:!0}).done(function(d){d.times.length>0&&(c.isUpdating=!0,c.mergeHistory(d)),c.isUpdating!==!1&&(a&&a(d.enabled,b),c.updateCharts())}).error(function(a){console.log("stat fetch req error"),console.log(a)}),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+arangoHelper.databaseUrl("/_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").append('

    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).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).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(){window.App.isCluster?window.location.hash.indexOf(a.serverInfo.target)>-1&&a.getStatistics():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){var b=function(a,b){return b||$(this.el).html(this.template.render()),a&&"_system"===frontendConfig.db?(this.prepareDygraphs(),this.isUpdating&&(this.prepareD3Charts(),this.prepareResidentSize(),this.updateTendencies(),$(window).trigger("resize")),this.startUpdating(),void $(window).resize()):($(this.el).html(""),void(this.server?$(this.el).append('
    Server statistics ('+this.server+") are disabled.
    "):$(this.el).append('
    Server statistics are disabled.
    ')))}.bind(this),c=function(){$(this.el).html(""),$(".contentDiv").remove(),$(".headerBar").remove(),$(".dashboard-headerbar").remove(),$(".dashboard-row").remove(),$(this.el).append('
    You do not have permission to view this page.
    '),$(this.el).append("
    You can switch to '_system' to see the dashboard.
    ")}.bind(this);if("_system"!==frontendConfig.db)return void c();var d=function(d,e){d||(e?this.getStatistics(b,a):c())}.bind(this);void 0===window.App.currentDB.get("name")?window.setTimeout(function(){return"_system"!==window.App.currentDB.get("name")?void c():void this.options.database.hasSystemAccess(d)}.bind(this),300):this.options.database.hasSystemAccess(d)}})}(),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"},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:!0})},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},render:function(){var a=function(a,b){a?arangoHelper.arangoError("DB","Could not get current db properties"):(this.currentDB=b,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())}.bind(this);return this.collection.getCurrentDatabase(a),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){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(){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:arangoHelper.databaseUrl("/_api/database/"+a)}),this.updateDatabases(),window.App.naviView.dbSelectionView.render($("#dbSelect")),window.modalView.hide()},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){var b=function(b,c){b?arangoHelper.arangoError("DB","Could not fetch databases"):(this.$el=a,this.$el.html(this.template.render({list:c,current:this.current.get("name")})),this.delegateEvents())}.bind(this);return this.collection.getDatabasesForUser(b),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,defaultMode:"tree",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","click .jsoneditor .modes":"storeMode"},checkSearchBox:function(a){""===$(a.currentTarget).val()&&this.editor.expandAll()},storeMode:function(){var a=this;$(".type-modes").on("click",function(b){a.defaultMode=$(b.currentTarget).text().toLowerCase()})},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){a=2===a?"document":"edge";var b=function(a,b,c){if(a)console.log(b),arangoHelper.arangoError("Error","Could not fetch data.");else{var d=c+": ";this.type=c,this.fillInfo(d),this.fillEditor()}}.bind(this);"edge"===a?this.collection.getEdge(this.colid,this.docid,b):"document"===a&&this.collection.getDocument(this.colid,this.docid,b)},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=function(){if(this.customView)this.customDeleteFunction();else{var a="collection/"+encodeURIComponent(this.colid)+"/documents/1";window.modalView.hide(),window.App.navigate(a,{trigger:!0})}}.bind(this);if("document"===this.type){var b=function(b){b?arangoHelper.arangoError("Error","Could not delete document"):a()}.bind(this);this.collection.deleteDocument(this.colid,this.docid,b)}else if("edge"===this.type){var c=function(b){b?arangoHelper.arangoError("Edge error","Could not delete edge"):a()}.bind(this);this.collection.deleteEdge(this.colid,this.docid,c)}},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);$(".disabledBread").last().text(this.collection.first().get("_key")),this.editor.set(a),$(".ace_content").attr("font-size","11pt")},jsonContentChanged:function(){this.enableSaveButton()},resize:function(){$("#documentEditor").height($(".centralRow").height()-300)},render:function(){$(this.el).html(this.template.render({})),$("#documentEditor").height($(".centralRow").height()-300),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.editor.setMode(this.defaultMode),this},removeReadonlyKeys:function(a){return _.omit(a,["_key","_id","_from","_to","_rev"])},saveDocument:function(){if(void 0===$("#saveDocumentButton").attr("disabled"))if("_"===this.collection.first().attributes._id.substr(0,1)){var a=[],b=[];b.push(window.modalView.createReadOnlyEntry("doc-save-system-button","Caution","You are modifying a system collection. Really continue?",void 0,void 0,!1,/[<>&'"]/)),a.push(window.modalView.createSuccessButton("Save",this.confirmSaveDocument.bind(this))),window.modalView.show("modalTable.ejs","Modify System Collection",a,b)}else this.confirmSaveDocument()},confirmSaveDocument:function(){window.modalView.hide();var a;try{a=this.editor.get()}catch(b){return this.errorConfirmation(b),void this.disableSaveButton()}if(a=JSON.stringify(a),"document"===this.type){var c=function(a){a?arangoHelper.arangoError("Error","Could not save document."):(this.successConfirmation(),this.disableSaveButton())}.bind(this);this.collection.saveDocument(this.colid,this.docid,a,c)}else if("edge"===this.type){var d=function(a){a?arangoHelper.arangoError("Error","Could not save edge."):(this.successConfirmation(),this.disableSaveButton())}.bind(this);this.collection.saveEdge(this.colid,this.docid,a,d)}},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("/");$("#subNavigationBar .breadcrumb").html('Collection: '+a[1]+'Document: '+a[2])},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(a){this.documentStore=a.documentStore,this.collectionsStore=a.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))},resize:function(){$("#docPureTable").height($(".centralRow").height()-210),$("#docPureTable .pure-table-body").css("max-height",$("#docPureTable").height()-47)},setCollectionId:function(a,b){this.collection.setCollection(a),this.collection.setPage(b),this.page=b;var c=function(b,c){b?arangoHelper.arangoError("Error","Could not get collection properties."):(this.type=c,this.collection.getDocuments(this.getDocsCallback.bind(this)),this.collectionModel=this.collectionsStore.get(a))}.bind(this);arangoHelper.collectionApiType(a,null,c)},getDocsCallback:function(a){$("#documents_last").css("visibility","hidden"),$("#documents_first").css("visibility","hidden"),a?(window.progressView.hide(),arangoHelper.arangoError("Document error","Could not fetch requested documents.")):a&&void 0===a||(window.progressView.hide(),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(){var a=function(a){a&&arangoHelper.arangoError("Document","Could not fetch documents count")}.bind(this);$("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(a),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=function(a,b){a?(arangoHelper.arangoError("Upload",b),this.hideSpinner()):(this.hideSpinner(),this.hideImportModal(),this.resetView())}.bind(this);this.allowUpload===!0&&(this.showSpinner(),this.collection.uploadDocuments(this.file,a))},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?($("#docPureTable .pure-table-body .pure-table-row").css("cursor","default"),$(".deleteButton").fadeIn(),$(".addButton").fadeIn(),$(".selected-row").removeClass("selected-row"),this.editMode=!1,this.tableView.setRowClick(this.clicked.bind(this))):($("#docPureTable .pure-table-body .pure-table-row").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,c=[];for(a in this.filters)if(this.filters.hasOwnProperty(a)){b=$("#attribute_value"+a).val();try{b=JSON.parse(b)}catch(d){b=String(b)}""!==$("#attribute_name"+a).val()&&c.push({attribute:$("#attribute_name"+a).val(),operator:$("#operator"+a).val(),value:b})}return c},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=function(a,d){a?arangoHelper.arangoError("Error","Could not fetch collection type"):"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))),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))}.bind(this);arangoHelper.collectionApiType(a,!0,d)},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(),f=function(b,c){if(b)arangoHelper.arangoError("Error","Could not create edge");else{window.modalView.hide(),c=c._id.split("/");try{a="collection/"+c[0]+"/"+c[1],decodeURI(a)}catch(d){a="collection/"+c[0]+"/"+encodeURIComponent(c[1])}window.location.hash=a}}.bind(this);""!==e||void 0!==e?this.documentStore.createTypeEdge(b,c,d,e,f):this.documentStore.createTypeEdge(b,c,d,null,f)},addDocument:function(){var a,b=window.location.hash.split("/")[1],c=$(".modal-body #new-document-key-attr").last().val(),d=function(b,c){if(b)arangoHelper.arangoError("Error","Could not create document");else{window.modalView.hide(),c=c.split("/");try{a="collection/"+c[0]+"/"+c[1],decodeURI(a)}catch(d){a="collection/"+c[0]+"/"+encodeURIComponent(c[1])}window.location.hash=a}}.bind(this);""!==c||void 0!==c?this.documentStore.createTypeDocument(b,c,d):this.documentStore.createTypeDocument(b,null,d)},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){if("document"===c.type){var d=function(a){a?(b.push(!1),arangoHelper.arangoError("Document error","Could not delete document.")):(b.push(!0),c.collection.setTotalMinusOne(),c.collection.getDocuments(this.getDocsCallback.bind(this)),$("#markDocuments").click(),window.modalView.hide())}.bind(c);c.documentStore.deleteDocument(c.collection.collectionID,a,d)}else if("edge"===c.type){var e=function(a){a?(b.push(!1),arangoHelper.arangoError("Edge error","Could not delete edge")):(c.collection.setTotalMinusOne(),b.push(!0),c.collection.getDocuments(this.getDocsCallback.bind(this)),$("#markDocuments").click(),window.modalView.hide())}.bind(c);c.documentStore.deleteEdge(c.collection.collectionID,a,e)}})},getSelectedDocs:function(){var a=[];return _.each($("#docPureTable .pure-table-body .pure-table-row"),function(b){$(b).hasClass("selected-row")&&a.push($($(b).children()[1]).find(".key").text())}),a},remove:function(a){this.docid=$(a.currentTarget).parent().parent().prev().find(".key").text(),$("#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(){if("document"===this.type){var a=function(a){a?arangoHelper.arangoError("Error","Could not delete document"):(this.collection.setTotalMinusOne(),this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#docDeleteModal").modal("hide"))}.bind(this);this.documentStore.deleteDocument(this.collection.collectionID,this.docid,a)}else if("edge"===this.type){var b=function(a){a?arangoHelper.arangoError("Edge error","Could not delete edge"):(this.collection.setTotalMinusOne(),this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#docDeleteModal").modal("hide"))}.bind(this);this.documentStore.deleteEdge(this.collection.collectionID,this.docid,b)}},editModeClick:function(a){var b=$(a.currentTarget);b.hasClass("selected-row")?b.removeClass("selected-row"):b.addClass("selected-row"),console.log(b);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,c=a.currentTarget,d=$(c).attr("id").substr(4);try{b="collection/"+this.collection.collectionID+"/"+d,decodeURI(d)}catch(e){b="collection/"+this.collection.collectionID+"/"+encodeURIComponent(d)}window.location.hash=b},drawTable:function(){this.tableView.setElement($("#docPureTable")).render(),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","top"),$(".prettify").snippet("javascript",{style:"nedit",menu:!1,startText:!1,transparent:!0,showNum:!1}),this.resize()},checkCollectionState:function(){this.lastCollectionName===this.collectionName?this.activeFilter&&(this.filterCollection(),this.restoreFilter()):void 0!==this.lastCollectionName&&(this.collection.resetFilter(),this.collection.setSort(""),this.restoredFilters=[],this.activeFilter=!1)},render:function(){return $(this.el).html(this.template.render({})),2===this.type?this.type="document":3===this.type&&(this.type="edge"),this.tableView.setElement($(this.table)).drawLoading(),this.collectionContext=this.collectionsStore.getPosition(this.collection.collectionID),this.collectionName=window.location.hash.split("/")[1],this.breadcrumb(),window.arangoHelper.buildCollectionSubNav(this.collectionName,"Content"),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.resize(),this},rerender:function(){this.collection.getDocuments(this.getDocsCallback.bind(this)),this.resize()},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(numeral(this.collection.getTotal()).format("0,0")+" document(s)"),"edge"===this.type&&a.html(numeral(this.collection.getTotal()).format("0,0")+" edge(s)")},breadcrumb:function(){$("#subNavigationBar .breadcrumb").html("Collection: "+this.collectionName)}})}(),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,timer:15e3,lap:0,timerFunction:null,events:{"click .footer-center p":"showShortcutModal"},initialize:function(){var a=this;window.setInterval(function(){a.getVersion()},a.timer),a.getVersion(),window.VISIBLE=!0,document.addEventListener("visibilitychange",function(){window.VISIBLE=!window.VISIBLE}),$("#offlinePlaceholder button").on("click",function(){a.getVersion()})},template:templateEngine.createTemplate("footerView.ejs"),showServerStatus:function(a){var b=this;window.App.isCluster?b.collection.fetch({success:function(){b.renderClusterState(!0)},error:function(){b.renderClusterState(!1)}}):a===!0?($("#healthStatus").removeClass("negative"),$("#healthStatus").addClass("positive"),$(".health-state").html("GOOD"),$(".health-icon").html(''),$("#offlinePlaceholder").hide()):($("#healthStatus").removeClass("positive"),$("#healthStatus").addClass("negative"),$(".health-state").html("UNKNOWN"),$(".health-icon").html(''),$("#offlinePlaceholder").show(),this.reconnectAnimation(0))},reconnectAnimation:function(a){var b=this;0===a&&(b.lap=a,$("#offlineSeconds").text(b.timer/1e3),clearTimeout(b.timerFunction)),b.lap0?($("#healthStatus").removeClass("positive"),$("#healthStatus").addClass("negative"),1===b?$(".health-state").html(b+" NODE ERROR"):$(".health-state").html(b+" NODES ERROR"),$(".health-icon").html('')):($("#healthStatus").removeClass("negative"),$("#healthStatus").addClass("positive"),$(".health-state").html("NODES OK"),$(".health-icon").html(''))):($("#healthStatus").removeClass("positive"),$("#healthStatus").addClass("negative"),$(".health-state").html(window.location.host+" OFFLINE"),$(".health-icon").html(''),$("#offlinePlaceholder").show(),this.reconnectAnimation(0))},showShortcutModal:function(){window.arangoHelper.hotkeysFunctions.showHotkeysModal()},getVersion:function(){var a=this;$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/version"), +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){console.log(a.baseUrl);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){arangoHelper.arangoError("Server-side","createEdge was triggered.")},e.deleteEdge=function(a,b){arangoHelper.arangoError("Server-side","deleteEdge was triggered.")},e.patchEdge=function(a,b,c){arangoHelper.arangoError("Server-side","patchEdge was triggered.")},e.createNode=function(a,b){arangoHelper.arangoError("Server-side","createNode was triggered.")},e.deleteNode=function(a,b){arangoHelper.arangoError("Server-side","deleteNode was triggered."),arangoHelper.arangoError("Server-side","onNodeDelete was triggered.")},e.patchNode=function(a,b,c){arangoHelper.arangoError("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.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.getBoundingClientRect().width,e=a.getBoundingClientRect().height,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.getBoundingClientRect().width-81+20,q=d||a.getBoundingClientRect().height,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 console.log(q),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"),x(b,"configuredropdown","filterdropdown","nodedropdown"));i=new NodeShaperControls(c.nodes,g.nodeShaper),j=new EdgeShaperControls(c.edges,g.edgeShaper),k=new GharialAdapterControls(c.col,g.adapter),r.id="menubar",a.className="headerBar",b.id="modifiers",r.appendChild(a),r.appendChild(c.configure),r.appendChild(c.filter),r.appendChild(c.node),a.appendChild(b),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&&arangoHelper.arangoError("Graph","Sorry your graph seems to be empty")},a)}),f&&("string"==typeof f?g.loadGraph(f):g.loadGraphWithRandomStart(function(a){a&&a.errorCode&&arangoHelper.arangoError("Graph","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.getBoundingClientRect().width,f=d.getBoundingClientRect().height,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}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'+c+""),a.disabled||$("#subNavigationBar .bottom").children().last().bind("click",function(){window.App.navigate(a.route,{trigger:!0})})})},buildNodeSubNav:function(a,b,c){var d={Dashboard:{route:"#node/"+encodeURIComponent(a)},Logs:{route:"#nLogs/"+encodeURIComponent(a),disabled:!0}};d[b].active=!0,d[c].disabled=!0,this.buildSubNavBar(d)},scaleability:void 0,buildNodesSubNav:function(a){if(void 0===this.scaleability){var b=this;$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_admin/cluster/numberOfServers"),contentType:"application/json",processData:!1,success:function(a){null!==a.numberOfCoordinators&&null!==a.numberOfDBServers?(b.scaleability=!0,b.buildNodesSubNav()):b.scaleability=!1}})}var c={Coordinators:{route:"#cNodes"},DBServers:{route:"#dNodes"}};c.Scale={route:"#sNodes",disabled:!0},"coordinator"===a?c.Coordinators.active=!0:"scale"===a?this.scaleability===!0?c.Scale.active=!0:window.App.navigate("#nodes",{trigger:!0}):c.DBServers.active=!0,this.scaleability===!0&&(c.Scale.disabled=!1),this.buildSubNavBar(c)},buildCollectionSubNav:function(a,b){var c="#collection/"+encodeURIComponent(a),d={Content:{route:c+"/documents/1"},Indices:{route:"#cIndices/"+encodeURIComponent(a)},Info:{route:"#cInfo/"+encodeURIComponent(a)},Settings:{route:"#cSettings/"+encodeURIComponent(a)}};d[b].active=!0,this.buildSubNavBar(d)},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(a){var b=function(b,c){b?arangoHelper.arangoError("",""):$.ajax({type:"GET",cache:!1,url:this.databaseUrl("/_api/database/",c),contentType:"application/json",processData:!1,success:function(){a(!1,!0)},error:function(){a(!0,!1)}})}.bind(this);this.currentDatabase(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"})},arangoWarning:function(a,b,c){window.App.notificationList.add({title:a,content:b,info:c,type:"warning"})},hideArangoNotifications:function(){$.noty.clearQueue(),$.noty.closeAll()},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:this.databaseUrl("/_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:this.databaseUrl("/_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:this.databaseUrl("/_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){$.ajax({cache:!1,type:"GET",url:this.databaseUrl("/_admin/aardvark/job"),contentType:"application/json",processData:!1,success:function(b){a&&a(!1,b)},error:function(b){console.log("error"),a&&a(!0,b)}})},getPendingJobs:function(a){$.ajax({cache:!1,type:"GET",url:this.databaseUrl("/_api/job/pending"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},syncAndReturnUninishedAardvarkJobs:function(a,b){var c=function(c,d){if(c)b(!0);else{var e=function(c,e){if(c)arangoHelper.arangoError("","");else{var f=[];e.length>0?_.each(d,function(b){if(b.type===a||void 0===b.type){var c=!1;_.each(e,function(a){b.id===a&&(c=!0)}),c?f.push({collection:b.collection,id:b.id,type:b.type,desc:b.desc}):window.arangoHelper.deleteAardvarkJob(b.id)}}):d.length>0&&this.deleteAllAardvarkJobs(),b(!1,f)}}.bind(this);this.getPendingJobs(e)}}.bind(this);this.getAardvarkJobs(c)},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,c){if(b||void 0===this.CollectionTypes[a]){var d=function(b,c,d){b?arangoHelper.arangoError("Error","Could not detect collection type"):(this.CollectionTypes[a]=c.type,3===this.CollectionTypes[a]?d(!1,"edge"):d(!1,"document"))}.bind(this);this.arangoDocumentStore.getCollectionInfo(a,d,c)}else c(!1,this.CollectionTypes[a])},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,"'")},backendUrl:function(a){return frontendConfig.basePath+a},databaseUrl:function(a,b){if("/_db/"===a.substr(0,5))throw new Error("Calling databaseUrl with a databased url ("+a+") doesn't make any sense");return b||(b="_system",frontendConfig.db&&(b=frontendConfig.db)),this.backendUrl("/_db/"+encodeURIComponent(b)+a)}}}(),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){var c=_.template(b);return c=c(a)}}},a};window.templateEngine=new a}}(),function(){"use strict";window.dygraphConfig={defaultFrame:12e5,zeropad:function(a){return 10>a?"0"+a:a},xAxisFormat:function(a){if(-1===a)return"";var b=new Date(a);return this.zeropad(b.getHours())+":"+this.zeropad(b.getMinutes())+":"+this.zeropad(b.getSeconds())},mergeObjects:function(a,b,c){c||(c=[]);var d,e={};return c.forEach(function(c){var d=a[c],f=b[c];void 0===d&&(d={}),void 0===f&&(f={}),e[c]=_.extend(d,f)}),d=_.extend(a,b),Object.keys(e).forEach(function(a){d[a]=e[a]}),d},mapStatToFigure:{residentSize:["times","residentSizePercent"],pageFaults:["times","majorPageFaultsPerSecond","minorPageFaultsPerSecond"],systemUserTime:["times","systemTimePerSecond","userTimePerSecond"],totalTime:["times","avgQueueTime","avgRequestTime","avgIoTime"],dataTransfer:["times","bytesSentPerSecond","bytesReceivedPerSecond"],requests:["times","getsPerSecond","putsPerSecond","postsPerSecond","deletesPerSecond","patchesPerSecond","headsPerSecond","optionsPerSecond","othersPerSecond"]},colors:["rgb(95, 194, 135)","rgb(238, 190, 77)","#81ccd8","#7ca530","#3c3c3c","#aa90bd","#e1811d","#c7d4b2","#d0b2d4"],figureDependedOptions:{clusterRequestsPerSecond:{showLabelsOnHighlight:!0,title:"",header:"Cluster Requests per Second",stackedGraph:!0,div:"lineGraphLegend",labelsKMG2:!1,axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}}},residentSize:{header:"Memory",axes:{y:{labelsKMG2:!1,axisLabelFormatter:function(a){return parseFloat(100*a.toPrecision(3))+"%"},valueFormatter:function(a){return parseFloat(100*a.toPrecision(3))+"%"}}}},pageFaults:{header:"Page Faults",visibility:[!0,!1],labels:["datetime","Major Page","Minor Page"],div:"pageFaultsChart",labelsKMG2:!1,axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}}},systemUserTime:{div:"systemUserTimeChart",header:"System and User Time",labels:["datetime","System Time","User Time"],stackedGraph:!0,labelsKMG2:!1,axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}}},totalTime:{div:"totalTimeChart",header:"Total Time",labels:["datetime","Queue","Computation","I/O"],labelsKMG2:!1,axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}},stackedGraph:!0},dataTransfer:{header:"Data Transfer",labels:["datetime","Bytes sent","Bytes received"],stackedGraph:!0,div:"dataTransferChart"},requests:{header:"Requests",labels:["datetime","Reads","Writes"],stackedGraph:!0,div:"requestsChart",axes:{y:{valueFormatter:function(a){return parseFloat(a.toPrecision(3))},axisLabelFormatter:function(a){return 0===a?0:parseFloat(a.toPrecision(3))}}}}},getDashBoardFigures:function(a){var b=[],c=this;return Object.keys(this.figureDependedOptions).forEach(function(d){"clusterRequestsPerSecond"!==d&&(c.figureDependedOptions[d].div||a)&&b.push(d)}),b},getDefaultConfig:function(a){var b=this,c={digitsAfterDecimal:1,drawGapPoints:!0,fillGraph:!0,fillAlpha:.85,showLabelsOnHighlight:!1,strokeWidth:0,lineWidth:0,strokeBorderWidth:0,includeZero:!0,highlightCircleSize:2.5,labelsSeparateLines:!0,strokeBorderColor:"rgba(0,0,0,0)",interactionModel:{},maxNumberWidth:10,colors:[this.colors[0]],xAxisLabelWidth:"50",rightGap:15,showRangeSelector:!1,rangeSelectorHeight:50,rangeSelectorPlotStrokeColor:"#365300",rangeSelectorPlotFillColor:"",pixelsPerLabel:50,labelsKMG2:!0,dateWindow:[(new Date).getTime()-this.defaultFrame,(new Date).getTime()],axes:{x:{valueFormatter:function(a){return b.xAxisFormat(a)}},y:{ticker:Dygraph.numericLinearTicks}}};return this.figureDependedOptions[a]&&(c=this.mergeObjects(c,this.figureDependedOptions[a],["axes"]),c.div&&c.labels&&(c.colors=this.getColors(c.labels),c.labelsDiv=document.getElementById(c.div+"Legend"),c.legend="always",c.showLabelsOnHighlight=!0)),c},getDetailChartConfig:function(a){var b=_.extend(this.getDefaultConfig(a),{showRangeSelector:!0,interactionModel:null,showLabelsOnHighlight:!0,highlightCircleSize:2.5,legend:"always",labelsDiv:"div#detailLegend.dashboard-legend-inner"});return"pageFaults"===a&&(b.visibility=[!0,!0]),b.labels||(b.labels=["datetime",b.header],b.colors=this.getColors(b.labels)),b},getColors:function(a){var b;return b=this.colors.concat([]),b.slice(0,a.length-1)}}}(),function(){"use strict";window.arangoCollectionModel=Backbone.Model.extend({idAttribute:"name",urlRoot:arangoHelper.databaseUrl("/_api/collection"),defaults:{id:"",name:"",status:"",type:"",isSystem:!1,picture:"",locked:!1,desc:void 0},getProperties:function(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/collection/"+encodeURIComponent(this.get("id"))+"/properties"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},getFigures:function(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/figures"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(){a(!0)}})},getRevision:function(a,b){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/revision"),contentType:"application/json",processData:!1,success:function(c){a(!1,c,b)},error:function(){a(!0)}})},getIndex:function(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/index/?collection="+this.get("id")),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},createIndex:function(a,b){var c=this;$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/index?collection="+c.get("id")),headers:{"x-arango-async":"store"},data:JSON.stringify(a),contentType:"application/json",processData:!1,success:function(a,d,e){e.getResponseHeader("x-arango-async-id")?(window.arangoHelper.addAardvarkJob({id:e.getResponseHeader("x-arango-async-id"),type:"index",desc:"Creating Index",collection:c.get("id")}),b(!1,a)):b(!0,a)},error:function(a){b(!0,a)}})},deleteIndex:function(a,b){var c=this;$.ajax({cache:!1,type:"DELETE",url:arangoHelper.databaseUrl("/_api/index/"+this.get("name")+"/"+encodeURIComponent(a)),headers:{"x-arango-async":"store"},success:function(a,d,e){e.getResponseHeader("x-arango-async-id")?(window.arangoHelper.addAardvarkJob({id:e.getResponseHeader("x-arango-async-id"),type:"index",desc:"Removing Index",collection:c.get("id")}),b(!1,a)):b(!0,a)},error:function(a){b(!0,a)}}),b()},truncateCollection:function(){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/truncate"),success:function(){arangoHelper.arangoNotification("Collection truncated.")},error:function(){arangoHelper.arangoError("Collection error.")}})},loadCollection:function(a){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/load"),success:function(){a(!1)},error:function(){ +a(!0)}}),a()},unloadCollection:function(a){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/unload?flush=true"),success:function(){a(!1)},error:function(){a(!0)}}),a()},renameCollection:function(a,b){var c=this;$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/rename"),data:JSON.stringify({name:a}),contentType:"application/json",processData:!1,success:function(){c.set("name",a),b(!1)},error:function(a){b(!0,a)}})},changeCollection:function(a,b,c,d){var e=!1;"true"===a?a=!0:"false"===a&&(a=!1);var f={waitForSync:a,journalSize:parseInt(b),indexBuckets:parseInt(c)};return $.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/collection/"+this.get("id")+"/properties"),data:JSON.stringify(f),contentType:"application/json",processData:!1,success:function(){d(!1)},error:function(a){d(!1,a)}}),e}})}(),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:arangoHelper.databaseUrl("/_api/database"),defaults:{}}),window.arangoDocumentModel=Backbone.Model.extend({initialize:function(){"use strict"},urlRoot:arangoHelper.databaseUrl("/_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:arangoHelper.databaseUrl("/_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()?arangoHelper.databaseUrl("/_api/user"):""!==this.get("user")?arangoHelper.databaseUrl("/_api/user/"+this.get("user")):arangoHelper.databaseUrl("/_api/user")},checkPassword:function(a,b){$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/user/"+this.get("user")),data:JSON.stringify({passwd:a}),contentType:"application/json",processData:!1,success:function(a){b(!1,a)},error:function(a){b(!0,a)}})},setPassword:function(a){$.ajax({cache:!1,type:"PATCH",url:arangoHelper.databaseUrl("/_api/user/"+this.get("user")),data:JSON.stringify({passwd:a}),contentType:"application/json",processData:!1})},setExtras:function(a,b,c){$.ajax({cache:!1,type:"PATCH",url:arangoHelper.databaseUrl("/_api/user/"+this.get("user")),data:JSON.stringify({extra:{name:a,img:b}}),contentType:"application/json",processData:!1,success:function(){c(!1)},error:function(){c(!0)}})}}),function(){"use strict";window.ClusterCoordinator=Backbone.Model.extend({defaults:{name:"",status:"ok",address:"",protocol:""},idAttribute:"name",forList:function(){return{name:this.get("name"),status:this.get("status"),url:this.get("url")}}})}(),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.Coordinator=Backbone.Model.extend({defaults:{address:"",protocol:"",name:"",status:""}})}(),function(){"use strict";window.CurrentDatabase=Backbone.Model.extend({url:arangoHelper.databaseUrl("/_api/database/current",frontendConfig.db),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=arangoHelper.databaseUrl("/_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(arangoHelper.databaseUrl("/_db/"+arango.getDatabaseName()+"/_admin/aardvark/foxxes/download/zip?mount="+this.encodedMount()))}})}(),function(){"use strict";window.Graph=Backbone.Model.extend({idAttribute:"_key",urlRoot:arangoHelper.databaseUrl("/_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.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())}})}(),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.ClusterStatisticsCollection=Backbone.Collection.extend({model:window.Statistics,url:"/_admin/statistics",updateUrl:function(){this.url=window.App.getNewRoute(this.host)+this.url},initialize:function(a,b){this.host=b.host,window.App.registerForUpdate(this)}}),function(){"use strict";window.arangoCollections=Backbone.Collection.extend({url:arangoHelper.databaseUrl("/_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"unloading";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.result,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.result},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){var c={};c.name=a.collName,c.waitForSync=a.wfs,a.journalSize>0&&(c.journalSize=a.journalSize),c.isSystem=a.isSystem,c.type=parseInt(a.collType,10),a.shards&&(c.numberOfShards=a.shards,c.shardKeys=a.keys),a.replicationFactor&&(c.replicationFactor=JSON.parse(a.replicationFactor)),$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/collection"),data:JSON.stringify(c),contentType:"application/json",processData:!1,success:function(a){b(!1,a)},error:function(a){b(!0,a)}})}})}(),function(){"use strict";window.ArangoDatabase=Backbone.Collection.extend({model:window.DatabaseModel,sortOptions:{desc:!1},url:arangoHelper.databaseUrl("/_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(a){$.ajax({type:"GET",cache:!1,url:this.url+"/user",contentType:"application/json",processData:!1,success:function(b){a(!1,b.result.sort())},error:function(){a(!0,[])}})},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("#service")&&(g="#services"),f+=g}return f},getCurrentDatabase:function(a){$.ajax({type:"GET",cache:!1,url:this.url+"/current",contentType:"application/json",processData:!1,success:function(b){200===b.code?a(!1,b.result.name):a(!1,b)},error:function(b){a(!0,b)}})},hasSystemAccess:function(a){var b=function(b,c){b?arangoHelper.arangoError("DB","Could not fetch databases"):a(!1,_.contains(c,"_system"))}.bind(this);this.getDatabasesForUser(b)}})}(),window.arangoDocument=Backbone.Collection.extend({url:"/_api/document/",model:arangoDocumentModel,collectionInfo:{},deleteEdge:function(a,b,c){this.deleteDocument(a,b,c)},deleteDocument:function(a,b,c){$.ajax({cache:!1,type:"DELETE",contentType:"application/json",url:arangoHelper.databaseUrl("/_api/document/"+encodeURIComponent(a)+"/"+encodeURIComponent(b)),success:function(){c(!1)},error:function(){c(!0)}})},addDocument:function(a,b){var c=this;c.createTypeDocument(a,b)},createTypeEdge:function(a,b,c,d,e){var f;f=d?JSON.stringify({_key:d,_from:b,_to:c}):JSON.stringify({_from:b,_to:c}),$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/document?collection="+encodeURIComponent(a)),data:f,contentType:"application/json",processData:!1,success:function(a){e(!1,a)},error:function(a){e(!0,a)}})},createTypeDocument:function(a,b,c){var d;d=b?JSON.stringify({_key:b}):JSON.stringify({}),$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/document?collection="+encodeURIComponent(a)),data:d,contentType:"application/json",processData:!1,success:function(a){c(!1,a._id)},error:function(a){c(!0,a._id)}})},getCollectionInfo:function(a,b,c){var d=this;$.ajax({cache:!1,type:"GET",url:arangoHelper.databaseUrl("/_api/collection/"+a+"?"+arangoHelper.getRandomToken()),contentType:"application/json",processData:!1,success:function(a){d.collectionInfo=a,b(!1,a,c)},error:function(a){b(!0,a,c)}})},getEdge:function(a,b,c){this.getDocument(a,b,c)},getDocument:function(a,b,c){var d=this;this.clearDocument(),$.ajax({cache:!1,type:"GET",url:arangoHelper.databaseUrl("/_api/document/"+encodeURIComponent(a)+"/"+encodeURIComponent(b)),contentType:"application/json",processData:!1,success:function(a){d.add(a),c(!1,a,"document")},error:function(a){d.add(!0,a)}})},saveEdge:function(a,b,c,d){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/edge/"+encodeURIComponent(a)+"/"+encodeURIComponent(b)),data:c,contentType:"application/json",processData:!1,success:function(a){d(!1,a)},error:function(a){d(!0,a)}})},saveDocument:function(a,b,c,d){$.ajax({cache:!1,type:"PUT",url:arangoHelper.databaseUrl("/_api/document/"+encodeURIComponent(a)+"/"+encodeURIComponent(b)),data:c,contentType:"application/json",processData:!1,success:function(a){d(!1,a)},error:function(a){d(!0,a)}})},updateLocalDocument:function(a){this.clearDocument(),this.add(a)},clearDocument:function(){this.reset()}}),function(){"use strict";window.arangoDocuments=window.PaginatedCollection.extend({collectionID:1,filters:[],checkCursorTimer:void 0,MAX_SORT:12e3,lastQuery:{},sortAttribute:"",url:arangoHelper.databaseUrl("/_api/documents"),model:window.arangoDocumentModel,loadTotal:function(a){var b=this;$.ajax({cache:!1,type:"GET",url:arangoHelper.databaseUrl("/_api/collection/"+this.collectionID+"/count"),contentType:"application/json",processData:!1,success:function(c){b.setTotal(c.count),a(!1)},error:function(){a(!0)}})},setCollection:function(a){var b=function(a){a&&arangoHelper.arangoError("Documents","Could not fetch documents count")}.bind(this);this.resetFilter(),this.collectionID=a,this.setPage(1),this.loadTotal(b)},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",url:arangoHelper.databaseUrl("/_api/cursor"),data:JSON.stringify(g),contentType:"application/json",success:function(){$.ajax({cache:!1,type:"POST",url:arangoHelper.databaseUrl("/_api/cursor"),data:JSON.stringify(h),contentType:"application/json",success:function(){d&&d(),window.progressView.hide()},error:function(){window.progressView.hide(),arangoHelper.arangoError("Document error","Documents inserted, but could not be removed.")}})},error:function(){window.progressView.hide(),arangoHelper.arangoError("Document error","Could not move selected documents.")}})},getDocuments:function(a){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&&(a+=" SORT x."+this.getSort()),a+=" RETURN x",b={query:a,bindVars:c}},uploadDocuments:function(a,b){$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_api/import?type=auto&collection="+encodeURIComponent(this.collectionID)+"&createCollection=false"),data:a,processData:!1,contentType:"json",dataType:"json",complete:function(a){if(4===a.readyState&&201===a.status)b(!1);else try{var c=JSON.parse(a.responseText);if(c.errors>0){var d="At least one error occurred during upload";b(!1,d)}}catch(e){console.log(e)}}})}})}(),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,arangoHelper.databaseUrl(b)}})}(),function(){"use strict";window.ArangoQueries=Backbone.Collection.extend({initialize:function(a,b){var c=this;$.ajax("whoAmI?_="+Date.now(),{async:!0}).done(function(a){this.activeUser===!1?c.activeUser="root":c.activeUser=a.user})},url:arangoHelper.databaseUrl("/_api/user/"),model:ArangoQuery,activeUser:null,parse:function(a){var b,c=this;return this.activeUser===!1&&(this.activeUser="root"),_.each(a.result,function(a){if(a.user===c.activeUser)try{a.extra.queries&&(b=a.extra.queries)}catch(d){}}),b},saveCollectionQueries:function(a){if(0===this.activeUser)return!1;this.activeUser===!1&&(this.activeUser="root");var b=[];this.each(function(a){b.push({value:a.attributes.value,parameter:a.attributes.parameter,name:a.attributes.name})}),$.ajax({cache:!1,type:"PATCH",url:arangoHelper.databaseUrl("/_api/user/"+encodeURIComponent(this.activeUser)),data:JSON.stringify({extra:{queries:b}}),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(){a(!0)}})},saveImportQueries:function(a,b){return 0===this.activeUser?!1:(window.progressView.show("Fetching documents..."),void $.ajax({cache:!1,type:"POST",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(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/replication/logger-state"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},getApplyState:function(a){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/replication/applier-state"),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})}}),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:frontendConfig.basePath+"/_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,c){var d=this;$.ajax("login",{method:"POST",data:JSON.stringify({username:a,password:b}),dataType:"json"}).success(function(a){d.activeUser=a.user,c(!1,d.activeUser)}).error(function(){d.activeUser=null,c(!0,null)})},setSortingDesc:function(a){this.sortOptions.desc=a},logout:function(){$.ajax("logout",{method:"POST"}),this.activeUser=null,this.reset(),window.App.navigate(""),window.location.reload()},setUserSettings:function(a,b){this.activeUserSettings.identifier=b},loadUserSettings:function(a){var b=this;$.ajax({type:"GET",cache:!1,url:frontendConfig.basePath+"/_api/user/"+encodeURIComponent(b.activeUser),contentType:"application/json",processData:!1,success:function(c){b.activeUserSettings=c.extra,a(!1,c)},error:function(b){a(!0,b)}})},saveUserSettings:function(a){var b=this;$.ajax({cache:!1,type:"PUT",url:frontendConfig.basePath+"/_api/user/"+encodeURIComponent(b.activeUser),data:JSON.stringify({extra:b.activeUserSettings}),contentType:"application/json",processData:!1,success:function(b){a(!1,b)},error:function(b){a(!0,b)}})},parse:function(a){var b=[];return _.each(a.result,function(a){b.push(a)}),b},whoAmI:function(a){return this.activeUser?void a(!1,this.activeUser):void $.ajax("whoAmI?_="+Date.now()).success(function(b){a(!1,b.user)}).error(function(b){a(!0,null)})}}),function(){"use strict";window.ClusterCoordinators=window.AutomaticRetryCollection.extend({model:window.ClusterCoordinator,url:arangoHelper.databaseUrl("/_admin/aardvark/cluster/Coordinators"),updateUrl:function(){this.url=window.App.getNewRoute("Coordinators")},initialize:function(){},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()})}})}(),function(){"use strict";window.ClusterServers=window.AutomaticRetryCollection.extend({model:window.ClusterServer,host:"",url:arangoHelper.databaseUrl("/_admin/aardvark/cluster/DBServers"),updateUrl:function(){this.url=window.App.getNewRoute(this.host)+this.url},initialize:function(a,b){this.host=b.host},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)}).error(function(a){console.log("error"),console.log(a)})}},getList:function(){throw"Do not use"},getOverview:function(){throw"Do not use DbServer.getOverview"}})}(),function(){"use strict";window.CoordinatorCollection=Backbone.Collection.extend({model:window.Coordinator,url:arangoHelper.databaseUrl("/_admin/aardvark/cluster/Coordinators")})}(),function(){"use strict";window.FoxxCollection=Backbone.Collection.extend({model:window.Foxx,sortOptions:{desc:!1},url:arangoHelper.databaseUrl("/_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=arangoHelper.databaseUrl("/_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=arangoHelper.databaseUrl("/_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=arangoHelper.databaseUrl("/_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=arangoHelper.databaseUrl("/_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:frontendConfig.basePath+"/_api/gharial",dropAndDeleteGraph:function(a,b){$.ajax({type:"DELETE",url:frontendConfig.basePath+"/_api/gharial/"+encodeURIComponent(a)+"?dropCollections=true",contentType:"application/json",processData:!0,success:function(){b(!0)},error:function(){b(!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 frontendConfig.basePath+"/_api/query/current"},killRunningQuery:function(a,b){$.ajax({url:frontendConfig.basePath+"/_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",divs:["#readme","#swagger","#app-info","#sideinformation","#information","#settings"],navs:["#service-info","#service-api","#service-readme","#service-settings"],template:templateEngine.createTemplate("applicationDetailView.ejs"),events:{"click .open":"openApp","click .delete":"deleteApp","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 .subMenuEntries li":"changeSubview","mouseenter #app-scripts":"showDropdown","mouseleave #app-scripts":"hideDropdown"},changeSubview:function(a){_.each(this.navs,function(a){$(a).removeClass("active")}),$(a.currentTarget).addClass("active"),_.each(this.divs,function(a){$(".headerButtonBar").hide(),$(a).hide()}),"service-readme"===a.currentTarget.id?$("#readme").show():"service-api"===a.currentTarget.id?$("#swagger").show():"service-info"===a.currentTarget.id?(this.render(),$("#information").show(),$("#sideinformation").show()):"service-settings"===a.currentTarget.id&&(this.showConfigDialog(),$(".headerButtonBar").show(),$("#settings").show())},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").text("Set Production"),$("#app-development-indicator").css("display","inline"),$("#app-development-path").css("display","inline")):($(".app-switch-mode").text("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=function(b,c){var d=this;b?arangoHelper.arangoError("DB","Could not get current database"):($(this.el).html(this.template.render({app:this.model,db:c,mode:a})),$.get(this.appUrl(c)).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&&(d.render("readme"),$("#app-show-swagger").attr("disabled","true"))})),this.breadcrumb()}.bind(this);return arangoHelper.currentDatabase(b),_.isEmpty(this.model.get("config"))&&$("#service-settings").attr("disabled",!0),$(this.el)},breadcrumb:function(){var a="Service: "+this.model.get("name")+'',b='

    Contributors:';this.model.get("contributors")&&this.model.get("contributors").length>0?_.each(this.model.get("contributors"),function(a){b+=''+a.name+""}):b+="No contributors",b+="

    ",$(".information").append(b),this.model.get("author")&&$(".information").append('

    Author:'+this.model.get("author")+"

    "),this.model.get("mount")&&$(".information").append('

    Mount:'+this.model.get("mount")+"

    "),this.model.get("development")&&this.model.get("path")&&$(".information").append('

    Path:'+this.model.get("path")+"

    "),$("#subNavigationBar .breadcrumb").html(a)},openApp:function(){var a=function(a,b){a?arangoHelper.arangoError("DB","Could not get current database"):window.open(this.appUrl(b),this.model.get("title")).focus()}.bind(this);arangoHelper.currentDatabase(a)},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("services",{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(a){return window.location.origin+"/_db/"+encodeURIComponent(a)+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(){this.updateConfig(),arangoHelper.arangoNotification(this.model.get("name"),"Settings applied.")}.bind(this))},showConfigDialog:function(){if(_.isEmpty(this.model.get("config")))return void $("#settings .buttons").html($("#hidden_buttons").html());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,null,null,null,null,null,"settings"),$(".modal-footer").prepend($("#hidden_buttons").html())},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},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.ClusterView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("clusterView.ejs"),events:{},statsEnabled:!1,historyInit:!1,initDone:!1,interval:5e3,maxValues:100,knownServers:[],chartData:{},charts:{},nvcharts:[],startHistory:{},startHistoryAccumulated:{},initialize:function(a){var b=this;window.App.isCluster&&(this.dbServers=a.dbServers,this.coordinators=a.coordinators,this.updateServerTime(),window.setInterval(function(){if("#cluster"===window.location.hash||""===window.location.hash||"#"===window.location.hash){var a=function(a){b.rerenderValues(a),b.rerenderGraphs(a)};b.getCoordStatHistory(a)}},this.interval))},render:function(){this.$el.html(this.template.render({})),this.initDone||(void 0!==this.coordinators.first()?this.getServerStatistics():this.waitForCoordinators(),this.initDone=!0),this.initGraphs()},waitForCoordinators:function(){var a=this;window.setTimeout(function(){a.coordinators?a.getServerStatistics():a.waitForCoordinators()},500)},updateServerTime:function(){this.serverTime=(new Date).getTime()},getServerStatistics:function(){var a=this;this.data=void 0;var b=this.coordinators.first();this.statCollectCoord=new window.ClusterStatisticsCollection([],{host:b.get("address")}),this.statCollectDBS=new window.ClusterStatisticsCollection([],{host:b.get("address")});var c=[];_.each(this.dbServers,function(a){a.each(function(a){c.push(a)})}),_.each(c,function(c){if("ok"===c.get("status")){-1===a.knownServers.indexOf(c.id)&&a.knownServers.push(c.id);var d=new window.Statistics({name:c.id});d.url=b.get("protocol")+"://"+b.get("address")+"/_admin/clusterStatistics?DBserver="+c.get("name"),a.statCollectDBS.add(d)}}),this.coordinators.forEach(function(b){if("ok"===b.get("status")){-1===a.knownServers.indexOf(b.id)&&a.knownServers.push(b.id);var c=new window.Statistics({name:b.id});c.url=b.get("protocol")+"://"+b.get("address")+"/_admin/statistics",a.statCollectCoord.add(c)}});var d=function(b){a.rerenderValues(b),a.rerenderGraphs(b)}.bind(this);a.getCoordStatHistory(d),a.coordinators.fetch({success:function(){a.renderNode(!0)},error:function(){a.renderNode(!1)}})},rerenderValues:function(a){var b=this;this.coordinators.fetch({success:function(){b.renderNode(!0)},error:function(){b.renderNode(!1)}}),this.renderValue("#clusterConnections",Math.round(a.clientConnectionsCurrent)),this.renderValue("#clusterConnectionsAvg",Math.round(a.clientConnections15M));var c=a.physicalMemory,d=a.residentSizeCurrent;this.renderValue("#clusterRam",[d,c])},renderValue:function(a,b,c){if("number"==typeof b)$(a).html(b);else if($.isArray(b)){var d=b[0],e=b[1],f=1/(e/d)*100;$(a).html(f.toFixed(1)+" %")}else"string"==typeof b&&$(a).html(b);c?($(a).addClass("negative"),$(a).removeClass("positive")):($(a).addClass("positive"),$(a).removeClass("negative"))},renderNode:function(a){var b=0,c=0;if(a)if(this.coordinators.each(function(a){"ok"===a.toJSON().status?b++:c++}),c>0){var d=c+b;this.renderValue("#clusterNodes",b+"/"+d,!0)}else this.renderValue("#clusterNodes",b);else this.renderValue("#clusterNodes","OFFLINE",!0)},initValues:function(){var a=["#clusterNodes","#clusterRam","#clusterConnections","#clusterConnectionsAvg"];_.each(a,function(a){$(a).html('')})},graphData:{data:{sent:[],received:[]},http:[],average:[]},checkArraySizes:function(){var a=this;_.each(a.chartsOptions,function(b,c){_.each(b.options,function(b,d){b.values.length>a.maxValues-1&&a.chartsOptions[c].options[d].values.shift()})})},formatDataForGraph:function(a){var b=this;b.historyInit?(b.checkArraySizes(),b.chartsOptions[0].options[0].values.push({x:a.times[a.times.length-1],y:a.bytesSentPerSecond[a.bytesSentPerSecond.length-1]}),b.chartsOptions[0].options[1].values.push({x:a.times[a.times.length-1],y:a.bytesReceivedPerSecond[a.bytesReceivedPerSecond.length-1]}),b.chartsOptions[1].options[0].values.push({x:a.times[a.times.length-1],y:b.calcTotalHttp(a.http,a.bytesSentPerSecond.length-1)}),b.chartsOptions[2].options[0].values.push({x:a.times[a.times.length-1],y:a.avgRequestTime[a.bytesSentPerSecond.length-1]/b.coordinators.length})):(_.each(a.times,function(c,d){b.chartsOptions[0].options[0].values.push({x:c,y:a.bytesSentPerSecond[d]}),b.chartsOptions[0].options[1].values.push({x:c,y:a.bytesReceivedPerSecond[d]}),b.chartsOptions[1].options[0].values.push({x:c,y:b.calcTotalHttp(a.http,d)}),b.chartsOptions[2].options[0].values.push({x:c,y:a.avgRequestTime[d]/b.coordinators.length})}),b.historyInit=!0)},chartsOptions:[{id:"#clusterData",type:"bytes",count:2,options:[{area:!0,values:[],key:"Bytes out",color:"rgb(23,190,207)",strokeWidth:2,fillOpacity:.1},{area:!0,values:[],key:"Bytes in",color:"rgb(188, 189, 34)",strokeWidth:2,fillOpacity:.1}]},{id:"#clusterHttp",type:"bytes",options:[{area:!0,values:[],key:"Bytes",color:"rgb(0, 166, 90)",fillOpacity:.1}]},{id:"#clusterAverage",data:[],type:"seconds",options:[{area:!0,values:[],key:"Seconds",color:"rgb(243, 156, 18)",fillOpacity:.1}]}],initGraphs:function(){var a=this,b="Fetching data...";a.statsEnabled===!1&&(b="Statistics disabled."),_.each(a.chartsOptions,function(c){nv.addGraph(function(){a.charts[c.id]=nv.models.stackedAreaChart().options({useInteractiveGuideline:!0,showControls:!1,noData:b,duration:0}),a.charts[c.id].xAxis.axisLabel("").tickFormat(function(a){var b=new Date(1e3*a);return(b.getHours()<10?"0":"")+b.getHours()+":"+(b.getMinutes()<10?"0":"")+b.getMinutes()+":"+(b.getSeconds()<10?"0":"")+b.getSeconds()}).staggerLabels(!1),a.charts[c.id].yAxis.axisLabel("").tickFormat(function(a){var b;return"bytes"===c.type?null===a?"N/A":(b=parseFloat(d3.format(".2f")(a)),prettyBytes(b)):"seconds"===c.type?null===a?"N/A":b=parseFloat(d3.format(".3f")(a)):void 0});var d,e=a.returnGraphOptions(c.id);return e.length>0?_.each(e,function(a,b){c.options[b].values=a}):c.options[0].values=[],d=c.options,a.chartData[c.id]=d3.select(c.id).append("svg").datum(d).transition().duration(300).call(a.charts[c.id]).each("start",function(){window.setTimeout(function(){d3.selectAll(c.id+" *").each(function(){this.__transition__&&(this.__transition__.duration=0)})},0)}),nv.utils.windowResize(a.charts[c.id].update),a.nvcharts.push(a.charts[c.id]),a.charts[c.id]})})},returnGraphOptions:function(a){var b=[];return b="#clusterData"===a?[this.chartsOptions[0].options[0].values,this.chartsOptions[0].options[1].values]:"#clusterHttp"===a?[this.chartsOptions[1].options[0].values]:"#clusterAverage"===a?[this.chartsOptions[2].options[0].values]:[]},rerenderGraphs:function(a){if(this.statsEnabled){var b,c,d=this;this.formatDataForGraph(a),_.each(d.chartsOptions,function(a){c=d.returnGraphOptions(a.id),c.length>0?_.each(c,function(b,c){a.options[c].values=b}):a.options[0].values=[],b=a.options,b[0].values.length>0&&d.historyInit&&d.charts[a.id]&&d.charts[a.id].update()})}},calcTotalHttp:function(a,b){var c=0;return _.each(a,function(a){c+=a[b]}),c},getCoordStatHistory:function(a){var b,c=this,d=[],e={http:{}},f=function(a){return $.get(a,{count:c.statCollectCoord.size()},null,"json")},g=function(a){var b,d=["times"],f=["physicalMemory","residentSizeCurrent","clientConnections15M","clientConnectionsCurrent"],g=["optionsPerSecond","putsPerSecond","headsPerSecond","postsPerSecond","getsPerSecond","deletesPerSecond","othersPerSecond","patchesPerSecond"],h=["bytesSentPerSecond","bytesReceivedPerSecond","avgRequestTime"],i=0;_.each(a,function(a){a.enabled?c.statsEnabled=!0:c.statsEnabled=!1,"object"==typeof a&&(0===i?(_.each(d,function(b){e[b]=a[b]}),_.each(f,function(b){e[b]=a[b]}),_.each(g,function(b){e.http[b]=a[b]}),_.each(h,function(b){e[b]=a[b]})):(_.each(f,function(b){e[b]=e[b]+a[b]}),_.each(g,function(c){b=0,_.each(a[c],function(a){e.http[c][i]=e.http[c][i]+a,b++})}),_.each(h,function(c){b=0,_.each(a[c],function(a){e[c][i]=e[c][i]+a,b++})})),i++)})};this.statCollectCoord.each(function(a){b=a.url+"/short",d.push(f(b))}),$.when.apply($,d).done(function(){var b=[];_.each(d,function(a){b.push(a.responseJSON)}),g(b),a(e)})}})}(),function(){"use strict";window.CollectionListItemView=Backbone.View.extend({tagName:"div",className:"tile pure-u-1-1 pure-u-sm-1-2 pure-u-md-1-3 pure-u-lg-1-4 pure-u-xl-1-6",template:templateEngine.createTemplate("collectionsItemView.ejs"),initialize:function(a){this.collectionsView=a.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).addClass(this.model.get("lockType"))):$(this.el).removeClass("locked"),("loading"===this.model.get("status")||"unloading"===this.model.get("status"))&&$(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:"loading"===this.model.get("status")?0:void("unloaded"===this.model.get("status")?this.loadCollection():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(),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=function(a,b){if(a)arangoHelper.arangoError("Error","Could not get coordinator info");else{var c;c=b?this.model.get("name"):$("#change-collection-name").val();var d=this.model.get("status");if("loaded"===d){var e;try{e=JSON.parse(1024*$("#change-collection-size").val()*1024)}catch(f){return arangoHelper.arangoError("Please enter a valid number"),0}var g;try{if(g=JSON.parse($("#change-index-buckets").val()),1>g||parseInt(g)!==Math.pow(2,Math.log2(g)))throw"invalid indexBuckets value"}catch(f){return arangoHelper.arangoError("Please enter a valid number of index buckets"),0}var h=function(a){a?arangoHelper.arangoError("Collection error: "+a.responseText):(this.collectionsView.render(),window.modalView.hide())}.bind(this),i=function(a){if(a)arangoHelper.arangoError("Collection error: "+a.responseText);else{var b=$("#change-collection-sync").val();this.model.changeCollection(b,e,g,h)}}.bind(this);this.model.renameCollection(c,i)}else if("unloaded"===d)if(this.model.get("name")!==c){var j=function(a,b){a?arangoHelper.arangoError("Collection error: "+b.responseText):(this.collectionsView.render(),window.modalView.hide())}.bind(this);this.model.renameCollection(c,j)}else window.modalView.hide()}}.bind(this);window.isCoordinator(a)},createEditPropertiesModal:function(){var a=function(a,b){if(a)arangoHelper.arangoError("Error","Could not get coordinator info");else{var c=!1;"loaded"===this.model.get("status")&&(c=!0);var d=[],e=[];b||e.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."}]));var f=function(){e.push(window.modalView.createReadOnlyEntry("change-collection-id","ID",this.model.get("id"),"")),e.push(window.modalView.createReadOnlyEntry("change-collection-type","Type",this.model.get("type"),"")),e.push(window.modalView.createReadOnlyEntry("change-collection-status","Status",this.model.get("status"),"")),d.push(window.modalView.createDeleteButton("Delete",this.deleteCollection.bind(this))),d.push(window.modalView.createDeleteButton("Truncate",this.truncateCollection.bind(this))),c?d.push(window.modalView.createNotificationButton("Unload",this.unloadCollection.bind(this))):d.push(window.modalView.createNotificationButton("Load",this.loadCollection.bind(this))),d.push(window.modalView.createSuccessButton("Save",this.saveModifiedCollection.bind(this)));var a=["General","Indices"],b=["modalTable.ejs","indicesView.ejs"];window.modalView.show(b,"Modify Collection",d,e,null,null,this.events,null,a),"loaded"===this.model.get("status")?this.getIndex():$($("#infoTab").children()[1]).remove()}.bind(this);if(c){var g=function(a,b){if(a)arangoHelper.arangoError("Collection","Could not fetch properties");else{var c=b.journalSize/1048576,d=b.indexBuckets,g=b.waitForSync;e.push(window.modalView.createTextEntry("change-collection-size","Journal size",c,"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."}])),e.push(window.modalView.createTextEntry("change-index-buckets","Index buckets",d,"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."}])),e.push(window.modalView.createSelectEntry("change-collection-sync","Wait for sync",g,"Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}]))}f()}.bind(this);this.model.getProperties(g)}else f()}}.bind(this);window.isCoordinator(a)},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()),"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],$(".index-button-bar2")[0]);$("#cancelIndex").is(":visible")&&($("#cancelIndex").detach().appendTo(b),$("#createIndex").detach().appendTo(b))}})},unbindIndexEvents:function(){$("#indexEditView #addIndex").unbind("click"),$("#newIndexType").unbind("change"),$("#infoTab a").unbind("click"),$(".deleteIndex").unbind("click")},createInfoModal:function(){var a=function(a,b,c){if(a)arangoHelper.arangoError("Figures","Could not get revision.");else{var d=[],e={figures:c,revision:b,model:this.model};window.modalView.show("modalCollectionInfo.ejs","Collection: "+this.model.get("name"),d,e)}}.bind(this),b=function(b,c){if(b)arangoHelper.arangoError("Figures","Could not get figures.");else{var d=c;this.model.getRevision(a,d)}}.bind(this);this.model.getFigures(b)},resetIndexForms:function(){$("#indexHeader input").val("").prop("checked",!1),$("#newIndexType").val("Geo").prop("selected",!0),this.selectIndexType()},createIndex:function(){var a,b,c,d=this,e=$("#newIndexType").val(),f={};switch(e){case"Geo":a=$("#newGeoFields").val();var g=d.checkboxToValue("#newGeoJson"),h=d.checkboxToValue("#newGeoConstraint"),i=d.checkboxToValue("#newGeoIgnoreNull");f={type:"geo",fields:d.stringToArray(a),geoJson:g,constraint:h,ignoreNull:i};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 j=parseInt($("#newFulltextMinLength").val(),10)||0;f={type:"fulltext",fields:d.stringToArray(a),minLength:j};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 k=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.");d.refreshCollectionsView()};window.modalView.hide(),d.model.createIndex(f,k)},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()})},refreshCollectionsView:function(){window.App.arangoCollectionsStore.fetch({success:function(){window.App.collectionsView.render()}})},deleteIndex:function(){var a=function(a){a?(arangoHelper.arangoError("Could not delete index"),$("tr th:contains('"+this.lastId+"')").parent().children().last().html(''),this.model.set("locked",!1),this.refreshCollectionsView()):a||void 0===a||($("tr th:contains('"+this.lastId+"')").parent().remove(),this.model.set("locked",!1),this.refreshCollectionsView()),this.refreshCollectionsView()}.bind(this);this.model.set("locked",!0),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(){var a=function(a,b){a?window.arangoHelper.arangoError("Index",b.errorMessage):this.renderIndex(b)}.bind(this);this.model.getIndex(a)},renderIndex:function(a){this.index=a;var b="collectionInfoTh modal-text";if(this.index){var c="",d="";_.each(this.index.indexes,function(a){d="primary"===a.type||"edge"===a.type?'':'',void 0!==a.fields&&(c=a.fields.join(", "));var e=a.id.indexOf("/"),f=a.id.substr(e+1,a.id.length),g=a.hasOwnProperty("selectivityEstimate")?(100*a.selectivityEstimate).toFixed(2)+"%":"n/a",h=a.hasOwnProperty("sparse")?a.sparse:"n/a";$("#collectionEditIndexTable").append(""+f+""+a.type+""+a.unique+""+h+""+g+""+c+""+d+"")})}this.bindIndexEvents()},toggleNewIndexView:function(){var a=$(".index-button-bar2")[0];$("#indexEditView").is(":visible")?($("#indexEditView").hide(),$("#newIndexView").show(),$("#cancelIndex").detach().appendTo("#modal-dialog .modal-footer"),$("#createIndex").detach().appendTo("#modal-dialog .modal-footer")):($("#indexEditView").show(),$("#newIndexView").hide(),$("#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:1e4,template:templateEngine.createTemplate("collectionsView.ejs"),refetchCollections:function(){var a=this;this.collection.fetch({success:function(){a.checkLockedCollections()}})},checkLockedCollections:function(){var a=function(a,b){var c=this;a?console.log("Could not check locked collections"):(this.collection.each(function(a){a.set("locked",!1)}),_.each(b,function(a){var b=c.collection.findWhere({id:a.collection});b.set("locked",!0),b.set("lockType",a.type),b.set("desc",a.desc)}),this.collection.each(function(a){a.get("locked")||($("#collection_"+a.get("name")).find(".corneredBadge").removeClass("loaded unloaded"),$("#collection_"+a.get("name")+" .corneredBadge").text(a.get("status")),$("#collection_"+a.get("name")+" .corneredBadge").addClass(a.get("status"))),a.get("locked")||"loading"===a.get("status")?($("#collection_"+a.get("name")).addClass("locked"),a.get("locked")?($("#collection_"+a.get("name")).find(".corneredBadge").removeClass("loaded unloaded"),$("#collection_"+a.get("name")).find(".corneredBadge").addClass("inProgress"),$("#collection_"+a.get("name")+" .corneredBadge").text(a.get("desc"))):$("#collection_"+a.get("name")+" .corneredBadge").text(a.get("status"))):($("#collection_"+a.get("name")).removeClass("locked"),$("#collection_"+a.get("name")+" .corneredBadge").text(a.get("status")),$("#collection_"+a.get("name")+" .corneredBadge").hasClass("inProgress")&&($("#collection_"+a.get("name")+" .corneredBadge").text(a.get("status")),$("#collection_"+a.get("name")+" .corneredBadge").removeClass("inProgress"),$("#collection_"+a.get("name")+" .corneredBadge").addClass("loaded")),"unloaded"===a.get("status")&&$("#collection_"+a.get("name")+" .icon_arangodb_info").addClass("disabled"))}))}.bind(this);window.arangoHelper.syncAndReturnUninishedAardvarkJobs("index",a)},initialize:function(){var a=this;window.setInterval(function(){"#collections"===window.location.hash&&window.VISIBLE&&a.refetchCollections()},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=function(a,b){if(a)arangoHelper.arangoError("DB","Could not check coordinator state");else{var c=$("#new-collection-name").val(),d=$("#new-collection-size").val(),e=$("#new-replication-factor").val(),f=$("#new-collection-type").val(),g=$("#new-collection-sync").val(),h=1,i=[];if(""===e&&(e=1),b){if(h=$("#new-collection-shards").val(),""===h&&(h=1),h=parseInt(h,10),1>h)return arangoHelper.arangoError("Number of shards has to be an integer value greater or equal 1"),0;i=_.pluck($("#new-collection-shardBy").select2("data"),"text"),0===i.length&&i.push("_key")}if("_"===c.substr(0,1))return arangoHelper.arangoError('No "_" allowed as first character!'),0;var j=!1,k="true"===g;if(d>0)try{d=1024*JSON.parse(d)*1024}catch(l){return arangoHelper.arangoError("Please enter a valid number"),0}if(""===c)return arangoHelper.arangoError("No collection name entered!"),0;var m=function(a,b){if(a)try{b=JSON.parse(b.responseText),arangoHelper.arangoError("Error",b.errorMessage)}catch(c){console.log(c)}else this.updateCollectionsView();window.modalView.hide()}.bind(this);this.collection.newCollection({collName:c,wfs:k,isSystem:j,collSize:d,replicationFactor:e,collType:f,shards:h,shardBy:i},m)}}.bind(this);window.isCoordinator(a)},createNewCollectionModal:function(){var a=function(a,b){if(a)arangoHelper.arangoError("DB","Could not check coordinator state");else{var c=[],d=[],e={},f=[];d.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."}])),d.push(window.modalView.createSelectEntry("new-collection-type","Type","","The type of the collection to create.",[{value:2,label:"Document"},{value:3,label:"Edge"}])),b&&(d.push(window.modalView.createTextEntry("new-collection-shards","Shards","","The number of shards to create. You cannot change this afterwards. Recommended: DBServers squared","",!0)),d.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))),c.push(window.modalView.createSuccessButton("Save",this.submitCreateCollection.bind(this))),f.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."}])),window.App.isCluster&&f.push(window.modalView.createTextEntry("new-replication-factor","Replication factor","","Numeric value. Must be at least 1. Description: TODO","",!1,[{rule:Joi.string().allow("").optional().regex(/^[0-9]*$/),msg:"Must be a number."}])),f.push(window.modalView.createSelectEntry("new-collection-sync","Wait for sync","","Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}])),e.header="Advanced",e.content=f,window.modalView.show("modalTable.ejs","New Collection",c,d,e)}}.bind(this);window.isCoordinator(a)}})}(),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:{"click .subViewNavbar .subMenuEntry":"toggleViews"},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(a){this.options=a,this.dygraphConfig=a.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=a.serverToShow,this.serverInfo?this.server=this.serverInfo.target:this.server="-local-",this.history[this.server]={}},toggleViews:function(a){var b=a.currentTarget.id.split("-")[0],c=this,d=["replication","requests","system"];_.each(d,function(a){b!==a?$("#"+a).hide():($("#"+a).show(),c.resize(),$(window).resize())}),$(".subMenuEntries").children().removeClass("active"),$("#"+b+"-statistics").addClass("active"),window.setTimeout(function(){c.resize(),$(window).resize()},200)},cleanupHistory:function(a){if(this.history[this.server].hasOwnProperty(a)&&this.history[this.server][a].length>this.defaultTimeFrame/this.interval)for(;this.history[this.server][a].length>this.defaultTimeFrame/this.interval;)this.history[this.server][a].shift()},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)){var f=0,g=0;9===c.length&&(f+=c[1],f+=c[6],f+=c[7],f+=c[8],g+=c[2],g+=c[3],g+=c[4],g+=c[5],c=[c[0],f,g]),d.history[d.server][e].push(c)}})},cutOffHistory:function(a,b){for(var c,d=this;0!==d.history[d.server][a].length&&(c=d.history[d.server][a][0][0],!(c>=b));)d.history[d.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(arangoHelper.databaseUrl("/_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,b){var c=this,d=arangoHelper.databaseUrl("/_admin/aardvark/statistics/short","_system"),e="?start=";e+=c.nextStart?c.nextStart:((new Date).getTime()-c.defaultTimeFrame)/1e3,"-local-"!==c.server&&(e+="&type=short&DBserver="+c.serverInfo.target,c.history.hasOwnProperty(c.server)||(c.history[c.server]={})),$.ajax(d+e,{async:!0,xhrFields:{withCredentials:!0},crossDomain:!0}).done(function(d){d.times.length>0&&(c.isUpdating=!0,c.mergeHistory(d)),c.isUpdating!==!1&&(a&&a(d.enabled,b),c.updateCharts())}).error(function(a){console.log("stat fetch req error"),console.log(a)}),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+arangoHelper.databaseUrl("/_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").append('

    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).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).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(){window.App.isCluster?window.location.hash.indexOf(a.serverInfo.target)>-1&&a.getStatistics():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){var b=function(a,b){return b||$(this.el).html(this.template.render()),a&&"_system"===frontendConfig.db?(this.prepareDygraphs(),this.isUpdating&&(this.prepareD3Charts(),this.prepareResidentSize(),this.updateTendencies(),$(window).trigger("resize")),this.startUpdating(),void $(window).resize()):($(this.el).html(""),void(this.server?$(this.el).append('
    Server statistics ('+this.server+") are disabled.
    "):$(this.el).append('
    Server statistics are disabled.
    ')))}.bind(this),c=function(){$(this.el).html(""),$(".contentDiv").remove(),$(".headerBar").remove(),$(".dashboard-headerbar").remove(),$(".dashboard-row").remove(),$(this.el).append('
    You do not have permission to view this page.
    '),$(this.el).append("
    You can switch to '_system' to see the dashboard.
    ")}.bind(this);if("_system"!==frontendConfig.db)return void c();var d=function(d,e){d||(e?this.getStatistics(b,a):c())}.bind(this);void 0===window.App.currentDB.get("name")?window.setTimeout(function(){return"_system"!==window.App.currentDB.get("name")?void c():void this.options.database.hasSystemAccess(d)}.bind(this),300):this.options.database.hasSystemAccess(d)}})}(),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"},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:!0})},checkBoxes:function(a){var b=a.currentTarget.id;$("#"+b).click()},render:function(){var a=function(a,b){a?arangoHelper.arangoError("DB","Could not get current db properties"):(this.currentDB=b,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())}.bind(this);return this.collection.getCurrentDatabase(a),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){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(){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:arangoHelper.databaseUrl("/_api/database/"+a)}),this.updateDatabases(),window.App.naviView.dbSelectionView.render($("#dbSelect")),window.modalView.hide()},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){var b=function(b,c){b?arangoHelper.arangoError("DB","Could not fetch databases"):(this.$el=a,this.$el.html(this.template.render({list:c,current:this.current.get("name")})),this.delegateEvents())}.bind(this);return this.collection.getDatabasesForUser(b),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,defaultMode:"tree",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","click .jsoneditor .modes":"storeMode"},checkSearchBox:function(a){""===$(a.currentTarget).val()&&this.editor.expandAll()},storeMode:function(){var a=this;$(".type-modes").on("click",function(b){a.defaultMode=$(b.currentTarget).text().toLowerCase()})},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){a=2===a?"document":"edge";var b=function(a,b,c){if(a)console.log(b),arangoHelper.arangoError("Error","Could not fetch data.");else{var d=c+": ";this.type=c,this.fillInfo(d),this.fillEditor()}}.bind(this);"edge"===a?this.collection.getEdge(this.colid,this.docid,b):"document"===a&&this.collection.getDocument(this.colid,this.docid,b)},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=function(){if(this.customView)this.customDeleteFunction();else{var a="collection/"+encodeURIComponent(this.colid)+"/documents/1";window.modalView.hide(),window.App.navigate(a,{trigger:!0})}}.bind(this);if("document"===this.type){var b=function(b){b?arangoHelper.arangoError("Error","Could not delete document"):a()}.bind(this);this.collection.deleteDocument(this.colid,this.docid,b)}else if("edge"===this.type){var c=function(b){b?arangoHelper.arangoError("Edge error","Could not delete edge"):a()}.bind(this);this.collection.deleteEdge(this.colid,this.docid,c)}},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);$(".disabledBread").last().text(this.collection.first().get("_key")),this.editor.set(a),$(".ace_content").attr("font-size","11pt")},jsonContentChanged:function(){this.enableSaveButton()},resize:function(){$("#documentEditor").height($(".centralRow").height()-300)},render:function(){$(this.el).html(this.template.render({})),$("#documentEditor").height($(".centralRow").height()-300),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.editor.setMode(this.defaultMode),this},removeReadonlyKeys:function(a){return _.omit(a,["_key","_id","_from","_to","_rev"])},saveDocument:function(){if(void 0===$("#saveDocumentButton").attr("disabled"))if("_"===this.collection.first().attributes._id.substr(0,1)){var a=[],b=[];b.push(window.modalView.createReadOnlyEntry("doc-save-system-button","Caution","You are modifying a system collection. Really continue?",void 0,void 0,!1,/[<>&'"]/)),a.push(window.modalView.createSuccessButton("Save",this.confirmSaveDocument.bind(this))),window.modalView.show("modalTable.ejs","Modify System Collection",a,b)}else this.confirmSaveDocument()},confirmSaveDocument:function(){window.modalView.hide();var a;try{a=this.editor.get()}catch(b){return this.errorConfirmation(b),void this.disableSaveButton()}if(a=JSON.stringify(a),"document"===this.type){var c=function(a){a?arangoHelper.arangoError("Error","Could not save document."):(this.successConfirmation(),this.disableSaveButton())}.bind(this);this.collection.saveDocument(this.colid,this.docid,a,c)}else if("edge"===this.type){var d=function(a){a?arangoHelper.arangoError("Error","Could not save edge."):(this.successConfirmation(),this.disableSaveButton())}.bind(this);this.collection.saveEdge(this.colid,this.docid,a,d)}},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("/");$("#subNavigationBar .breadcrumb").html('Collection: '+a[1]+'Document: '+a[2])},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(a){this.documentStore=a.documentStore,this.collectionsStore=a.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))},resize:function(){$("#docPureTable").height($(".centralRow").height()-210),$("#docPureTable .pure-table-body").css("max-height",$("#docPureTable").height()-47)},setCollectionId:function(a,b){this.collection.setCollection(a),this.collection.setPage(b),this.page=b;var c=function(b,c){b?arangoHelper.arangoError("Error","Could not get collection properties."):(this.type=c,this.collection.getDocuments(this.getDocsCallback.bind(this)),this.collectionModel=this.collectionsStore.get(a))}.bind(this);arangoHelper.collectionApiType(a,null,c)},getDocsCallback:function(a){$("#documents_last").css("visibility","hidden"),$("#documents_first").css("visibility","hidden"),a?(window.progressView.hide(),arangoHelper.arangoError("Document error","Could not fetch requested documents.")):a&&void 0===a||(window.progressView.hide(),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(){var a=function(a){a&&arangoHelper.arangoError("Document","Could not fetch documents count")}.bind(this);$("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(a),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=function(a,b){a?(arangoHelper.arangoError("Upload",b),this.hideSpinner()):(this.hideSpinner(),this.hideImportModal(),this.resetView())}.bind(this);this.allowUpload===!0&&(this.showSpinner(),this.collection.uploadDocuments(this.file,a))},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?($("#docPureTable .pure-table-body .pure-table-row").css("cursor","default"),$(".deleteButton").fadeIn(),$(".addButton").fadeIn(),$(".selected-row").removeClass("selected-row"),this.editMode=!1,this.tableView.setRowClick(this.clicked.bind(this))):($("#docPureTable .pure-table-body .pure-table-row").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,c=[];for(a in this.filters)if(this.filters.hasOwnProperty(a)){b=$("#attribute_value"+a).val();try{b=JSON.parse(b)}catch(d){b=String(b)}""!==$("#attribute_name"+a).val()&&c.push({attribute:$("#attribute_name"+a).val(),operator:$("#operator"+a).val(),value:b})}return c},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=function(a,d){a?arangoHelper.arangoError("Error","Could not fetch collection type"):"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))),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))}.bind(this);arangoHelper.collectionApiType(a,!0,d)},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(),f=function(b,c){if(b)arangoHelper.arangoError("Error","Could not create edge");else{window.modalView.hide(),c=c._id.split("/");try{a="collection/"+c[0]+"/"+c[1],decodeURI(a)}catch(d){a="collection/"+c[0]+"/"+encodeURIComponent(c[1])}window.location.hash=a}}.bind(this);""!==e||void 0!==e?this.documentStore.createTypeEdge(b,c,d,e,f):this.documentStore.createTypeEdge(b,c,d,null,f)},addDocument:function(){var a,b=window.location.hash.split("/")[1],c=$(".modal-body #new-document-key-attr").last().val(),d=function(b,c){if(b)arangoHelper.arangoError("Error","Could not create document");else{window.modalView.hide(),c=c.split("/");try{a="collection/"+c[0]+"/"+c[1],decodeURI(a)}catch(d){a="collection/"+c[0]+"/"+encodeURIComponent(c[1])}window.location.hash=a}}.bind(this);""!==c||void 0!==c?this.documentStore.createTypeDocument(b,c,d):this.documentStore.createTypeDocument(b,null,d)},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){if("document"===c.type){var d=function(a){a?(b.push(!1),arangoHelper.arangoError("Document error","Could not delete document.")):(b.push(!0),c.collection.setTotalMinusOne(),c.collection.getDocuments(this.getDocsCallback.bind(this)),$("#markDocuments").click(),window.modalView.hide())}.bind(c);c.documentStore.deleteDocument(c.collection.collectionID,a,d)}else if("edge"===c.type){var e=function(a){a?(b.push(!1),arangoHelper.arangoError("Edge error","Could not delete edge")):(c.collection.setTotalMinusOne(),b.push(!0),c.collection.getDocuments(this.getDocsCallback.bind(this)),$("#markDocuments").click(),window.modalView.hide())}.bind(c);c.documentStore.deleteEdge(c.collection.collectionID,a,e)}})},getSelectedDocs:function(){var a=[];return _.each($("#docPureTable .pure-table-body .pure-table-row"),function(b){$(b).hasClass("selected-row")&&a.push($($(b).children()[1]).find(".key").text())}),a},remove:function(a){this.docid=$(a.currentTarget).parent().parent().prev().find(".key").text(),$("#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(){if("document"===this.type){var a=function(a){a?arangoHelper.arangoError("Error","Could not delete document"):(this.collection.setTotalMinusOne(),this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#docDeleteModal").modal("hide"))}.bind(this);this.documentStore.deleteDocument(this.collection.collectionID,this.docid,a)}else if("edge"===this.type){var b=function(a){a?arangoHelper.arangoError("Edge error","Could not delete edge"):(this.collection.setTotalMinusOne(),this.collection.getDocuments(this.getDocsCallback.bind(this)),$("#docDeleteModal").modal("hide"))}.bind(this);this.documentStore.deleteEdge(this.collection.collectionID,this.docid,b)}},editModeClick:function(a){var b=$(a.currentTarget);b.hasClass("selected-row")?b.removeClass("selected-row"):b.addClass("selected-row"),console.log(b);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,c=a.currentTarget,d=$(c).attr("id").substr(4);try{b="collection/"+this.collection.collectionID+"/"+d,decodeURI(d)}catch(e){b="collection/"+this.collection.collectionID+"/"+encodeURIComponent(d)}window.location.hash=b},drawTable:function(){this.tableView.setElement($("#docPureTable")).render(),arangoHelper.fixTooltips(".icon_arangodb, .arangoicon","top"),$(".prettify").snippet("javascript",{style:"nedit",menu:!1,startText:!1,transparent:!0,showNum:!1}),this.resize()},checkCollectionState:function(){this.lastCollectionName===this.collectionName?this.activeFilter&&(this.filterCollection(),this.restoreFilter()):void 0!==this.lastCollectionName&&(this.collection.resetFilter(),this.collection.setSort(""),this.restoredFilters=[],this.activeFilter=!1)},render:function(){return $(this.el).html(this.template.render({})),2===this.type?this.type="document":3===this.type&&(this.type="edge"),this.tableView.setElement($(this.table)).drawLoading(),this.collectionContext=this.collectionsStore.getPosition(this.collection.collectionID),this.collectionName=window.location.hash.split("/")[1],this.breadcrumb(),window.arangoHelper.buildCollectionSubNav(this.collectionName,"Content"),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.resize(),this},rerender:function(){this.collection.getDocuments(this.getDocsCallback.bind(this)),this.resize()},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(numeral(this.collection.getTotal()).format("0,0")+" document(s)"),"edge"===this.type&&a.html(numeral(this.collection.getTotal()).format("0,0")+" edge(s)")},breadcrumb:function(){$("#subNavigationBar .breadcrumb").html("Collection: "+this.collectionName)}})}(),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,timer:15e3,lap:0,timerFunction:null,events:{"click .footer-center p":"showShortcutModal"},initialize:function(){var a=this;window.setInterval(function(){a.getVersion()},a.timer),a.getVersion(),window.VISIBLE=!0,document.addEventListener("visibilitychange",function(){window.VISIBLE=!window.VISIBLE}),$("#offlinePlaceholder button").on("click",function(){a.getVersion()})},template:templateEngine.createTemplate("footerView.ejs"),showServerStatus:function(a){var b=this;window.App.isCluster?b.collection.fetch({success:function(){b.renderClusterState(!0)},error:function(){b.renderClusterState(!1)}}):a===!0?($("#healthStatus").removeClass("negative"),$("#healthStatus").addClass("positive"),$(".health-state").html("GOOD"),$(".health-icon").html(''),$("#offlinePlaceholder").hide()):($("#healthStatus").removeClass("positive"),$("#healthStatus").addClass("negative"),$(".health-state").html("UNKNOWN"),$(".health-icon").html(''),$("#offlinePlaceholder").show(),this.reconnectAnimation(0))},reconnectAnimation:function(a){var b=this;0===a&&(b.lap=a,$("#offlineSeconds").text(b.timer/1e3),clearTimeout(b.timerFunction)),b.lap0?($("#healthStatus").removeClass("positive"),$("#healthStatus").addClass("negative"),1===b?$(".health-state").html(b+" NODE ERROR"):$(".health-state").html(b+" NODES ERROR"),$(".health-icon").html('')):($("#healthStatus").removeClass("negative"),$("#healthStatus").addClass("positive"),$(".health-state").html("NODES OK"),$(".health-icon").html(''))):($("#healthStatus").removeClass("positive"),$("#healthStatus").addClass("negative"),$(".health-state").html(window.location.host+" OFFLINE"),$(".health-icon").html(''),$("#offlinePlaceholder").show(),this.reconnectAnimation(0))},showShortcutModal:function(){window.arangoHelper.hotkeysFunctions.showHotkeysModal()},getVersion:function(){var a=this;$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_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(){a.isOffline=!0,a.isOfflineCounter++,a.isOfflineCounter>=1&&a.showServerStatus(!1)}}),a.system.hasOwnProperty("database")||$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_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,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 pure-u-1-1 pure-u-sm-1-2 pure-u-md-1-3 pure-u-lg-1-4 pure-u-xl-1-6",template:templateEngine.createTemplate("foxxActiveView.ejs"),_show:!0,events:{click:"openAppDetailView"},openAppDetailView:function(){window.App.navigate("service/"+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(){$(this.el).html(this.template.render({model:this.model}));var a=function(){this.model.needsConfiguration()&&($(this.el).find(".warning-icons").length>0?$(this.el).find(".warning-icons").append(''):$(this.el).find("img").after(''))}.bind(this),b=function(){this.model.hasUnconfiguredDependencies()&&($(this.el).find(".warning-icons").length>0?$(this.el).find(".warning-icons").append(''):$(this.el).find("img").after(''))}.bind(this);return this.model.getConfiguration(a),this.model.getDependencies(b),$(this.el)}})}(),function(){"use strict";var a={ERROR_APPLICATION_DOWNLOAD_FAILED:{code:1752,message:"application download failed"}},b=templateEngine.createTemplate("applicationListView.ejs"),c=function(a){this.collection=a.collection},d=function(b){var c=this;if(b.error===!1)this.collection.fetch({success:function(){window.modalView.hide(),c.reload()}});else{var d=b;switch(b.hasOwnProperty("responseJSON")&&(d=b.responseJSON),d.errorNum){case a.ERROR_APPLICATION_DOWNLOAD_FAILED.code:arangoHelper.arangoError("Services","Unable to download application from the given repository.");break;default:arangoHelper.arangoError("Services",d.errorNum+". "+d.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()),documentCollections:_.map($("#new-app-document-collections").select2("data"),function(a){return window.arangoHelper.escapeHtml(a.text)}),edgeCollections:_.map($("#new-app-edge-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-document-collections").select2({tags:[],showSearchBox:!1,minimumResultsForSearch:-1,width:"336px"}),$("#new-app-edge-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-document-collections").select2("close"),$("#s2id_new-app-edge-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:arangoHelper.databaseUrl("/_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,initialize:function(a){this.options=a},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-success").css("display","none"):$("#modal-dialog .modal-footer .button-success").css("display","initial")},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,b){var c=function(b){if(b)arangoHelper.arangoError("","");else{var c=this.collection.get(a).get("edgeDefinitions");if(!c||0===c.length)return;var d={type:"gharial",graphName:a,baseUrl:arangoHelper.databaseUrl("/")},e=$("#content").width()-75;$("#content").html("");var f=arangoHelper.calculateCenterDivHeight();this.ui=new GraphViewerUI($("#content")[0],d,e,$(".centralRow").height()-135,{nodeShaper:{label:"_key",color:{type:"attribute",key:"_key"}}},!0),$(".contentDiv").height(f)}}.bind(this);b?this.collection.fetch({success:function(){c()}}):c()},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(),arangoHelper.arangoError("Graph","Could not delete Graph."))}.bind(this);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:arangoHelper.databaseUrl("/_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(a,b){var c=this;return this.collection.fetch({success:function(){c.collection.sort(),$(c.el).html(c.template.render({graphs:c.collection,searchString:""})),c.dropdownVisible===!0&&($("#graphManagementDropdown2").show(),$("#graphSortDesc").attr("checked",c.collection.sortOptions.desc),$("#graphManagementToggle").toggleClass("activated"),$("#graphManagementDropdown").show()),c.events["click .tableRow"]=c.showHideDefinition.bind(c),c.events['change tr[id*="newEdgeDefinitions"]']=c.setFromAndTo.bind(c),c.events["click .graphViewer-icon-button"]=c.addRemoveDefinition.bind(c),c.events["click #graphTab a"]=c.toggleTab.bind(c),c.events["click .createExampleGraphs"]=c.createExampleGraphs.bind(c),c.events["focusout .select2-search-field input"]=function(a){$(".select2-drop").is(":visible")&&($("#select2-search-field input").is(":focus")||window.setTimeout(function(){$(a.currentTarget).parent().parent().parent().select2("close")},80))}.bind(c),arangoHelper.setCheckboxStatus("#graphManagementDropdown")}}),a&&this.loadGraphViewer(a,b),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 $("#s2id_newEdgeDefinitions0 .select2-choices").css("border-color","red"),$("#s2id_newEdgeDefinitions0").parent().parent().next().find(".select2-choices").css("border-color","red"),void $("#s2id_newEdgeDefinitions0").parent().parent().next().next().find(".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}))}),0===h.length?($("#s2id_newEdgeDefinitions0 .select2-choices").css("border-color","red"),$("#s2id_newEdgeDefinitions0").parent().parent().next().find(".select2-choices").css("border-color","red"),void $("#s2id_newEdgeDefinitions0").parent().parent().next().next().find(".select2-choices").css("border-color","red")):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.HelpUsView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("helpUsView.ejs"),render:function(){this.$el.html(this.template.render({}))}})}(),function(){"use strict";window.IndicesView=Backbone.View.extend({el:"#content",initialize:function(a){this.collectionName=a.collectionName,this.model=this.collection},template:templateEngine.createTemplate("indicesView.ejs"),events:{},render:function(){$(this.el).html(this.template.render({model:this.model})),this.breadcrumb(),window.arangoHelper.buildCollectionSubNav(this.collectionName,"Indices"),this.getIndex()},breadcrumb:function(){$("#subNavigationBar .breadcrumb").html("Collection: "+this.collectionName)},getIndex:function(){var a=function(a,b){a?window.arangoHelper.arangoError("Index",b.errorMessage):this.renderIndex(b)}.bind(this);this.model.getIndex(a)},createIndex:function(){var a,b,c,d=this,e=$("#newIndexType").val(),f={};switch(e){case"Geo":a=$("#newGeoFields").val();var g=d.checkboxToValue("#newGeoJson");f={type:"geo",fields:d.stringToArray(a),geoJson:g};break;case"Persistent":a=$("#newPersistentFields").val(),b=d.checkboxToValue("#newPersistentUnique"),c=d.checkboxToValue("#newPersistentSparse"),f={type:"rocksdb",fields:d.stringToArray(a),unique:b,sparse:c};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 h=parseInt($("#newFulltextMinLength").val(),10)||0;f={type:"fulltext",fields:d.stringToArray(a),minLength:h};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 i=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.");d.toggleNewIndexView(),d.render()};this.model.createIndex(f,i)},bindIndexEvents:function(){this.unbindIndexEvents();var a=this;$("#indexEditView #addIndex").bind("click",function(){a.toggleNewIndexView(),$("#cancelIndex").unbind("click"),$("#cancelIndex").bind("click",function(){a.toggleNewIndexView(),a.render()}),$("#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(),$("#indexHeaderContent #modal-dialog .modal-footer .button-danger").hide(),$("#indexHeaderContent #modal-dialog .modal-footer .button-success").hide(),$("#indexHeaderContent #modal-dialog .modal-footer .button-notification").hide()),"General"===$(a.currentTarget).html()&&!$(a.currentTarget).parent().hasClass("active")){$("#indexHeaderContent #modal-dialog .modal-footer .button-danger").show(),$("#indexHeaderContent #modal-dialog .modal-footer .button-success").show(),$("#indexHeaderContent #modal-dialog .modal-footer .button-notification").show();var b=$(".index-button-bar2")[0];$("#cancelIndex").is(":visible")&&($("#cancelIndex").detach().appendTo(b),$("#createIndex").detach().appendTo(b))}})},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()})},unbindIndexEvents:function(){$("#indexEditView #addIndex").unbind("click"),$("#newIndexType").unbind("change"),$("#infoTab a").unbind("click"),$(".deleteIndex").unbind("click")},deleteIndex:function(){var a=function(a){a?(arangoHelper.arangoError("Could not delete index"),$("tr th:contains('"+this.lastId+"')").parent().children().last().html(''),this.model.set("locked",!1)):a||void 0===a||($("tr th:contains('"+this.lastId+"')").parent().remove(),this.model.set("locked",!1))}.bind(this);this.model.set("locked",!0),this.model.deleteIndex(this.lastId,a),$("tr th:contains('"+this.lastId+"')").parent().children().last().html('')},renderIndex:function(a){this.index=a;var b="collectionInfoTh modal-text";if(this.index){var c="",d="";_.each(this.index.indexes,function(a){d="primary"===a.type||"edge"===a.type?'':'',void 0!==a.fields&&(c=a.fields.join(", "));var e=a.id.indexOf("/"),f=a.id.substr(e+1,a.id.length),g=a.hasOwnProperty("selectivityEstimate")?(100*a.selectivityEstimate).toFixed(2)+"%":"n/a",h=a.hasOwnProperty("sparse")?a.sparse:"n/a";$("#collectionEditIndexTable").append(""+f+""+a.type+""+a.unique+""+h+""+g+""+c+""+d+"")})}this.bindIndexEvents()},selectIndexType:function(){$(".newIndexClass").hide();var a=$("#newIndexType").val();$("#newIndexType"+a).show()},resetIndexForms:function(){$("#indexHeader input").val("").prop("checked",!1),$("#newIndexType").val("Geo").prop("selected",!0),this.selectIndexType()},toggleNewIndexView:function(){var a=$(".index-button-bar2")[0];$("#indexEditView").is(":visible")?($("#indexEditView").hide(),$("#newIndexView").show(),$("#cancelIndex").detach().appendTo("#indexHeaderContent #modal-dialog .modal-footer"),$("#createIndex").detach().appendTo("#indexHeaderContent #modal-dialog .modal-footer")):($("#indexEditView").show(),$("#newIndexView").hide(),$("#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.InfoView=Backbone.View.extend({el:"#content",initialize:function(a){this.collectionName=a.collectionName,this.model=this.collection},events:{},render:function(){this.breadcrumb(),window.arangoHelper.buildCollectionSubNav(this.collectionName,"Info"),this.renderInfoView()},breadcrumb:function(){$("#subNavigationBar .breadcrumb").html("Collection: "+this.collectionName)},renderInfoView:function(){if(this.model.get("locked"))return 0;var a=function(a,b,c){if(a)arangoHelper.arangoError("Figures","Could not get revision.");else{var d=[],e={figures:c,revision:b,model:this.model};window.modalView.show("modalCollectionInfo.ejs","Collection: "+this.model.get("name"),d,e,null,null,null,null,null,"content")}}.bind(this),b=function(b,c){if(b)arangoHelper.arangoError("Figures","Could not get figures.");else{var d=c;this.model.getRevision(a,d)}}.bind(this);this.model.getFigures(b)}})}(),function(){"use strict";window.loginView=Backbone.View.extend({el:"#content", -el2:".header",el3:".footer",loggedIn:!1,events:{"keyPress #loginForm input":"keyPress","click #submitLogin":"validate","submit #dbForm":"goTo","click #logout":"logout","change #loginDatabase":"renderDBS"},template:templateEngine.createTemplate("loginView.ejs"),render:function(a){var b=this;if($(this.el).html(this.template.render({})),$(this.el2).hide(),$(this.el3).hide(),frontendConfig.authenticationEnabled&&a!==!0)window.setTimeout(function(){$("#loginUsername").focus()},300);else{var c=arangoHelper.databaseUrl("/_api/database/user");frontendConfig.authenticationEnabled===!1&&($("#logout").hide(),$(".login-window #databases").css("height","90px")),$("#loginForm").hide(),$(".login-window #databases").show(),$.ajax(c).success(function(a){$("#loginDatabase").html(""),_.each(a.result,function(a){$("#loginDatabase").append("")}),b.renderDBS()})}return $(".bodyWrapper").show(),this},clear:function(){$("#loginForm input").removeClass("form-error"),$(".wrong-credentials").hide()},keyPress:function(a){a.ctrlKey&&13===a.keyCode?(a.preventDefault(),this.validate()):a.metaKey&&13===a.keyCode&&(a.preventDefault(),this.validate())},validate:function(a){a.preventDefault(),this.clear();var b=$("#loginUsername").val(),c=$("#loginPassword").val();if(b){var d=function(a){var b=this;if(a)$(".wrong-credentials").show(),$("#loginDatabase").html(""),$("#loginDatabase").append("");else{var c=arangoHelper.databaseUrl("/_api/database/user","_system");frontendConfig.authenticationEnabled===!1&&(c=arangoHelper.databaseUrl("/_api/database/user")),$(".wrong-credentials").hide(),b.loggedIn=!0,$.ajax(c).success(function(a){$("#loginForm").hide(),$("#databases").show(),$("#loginDatabase").html(""),_.each(a.result,function(a){$("#loginDatabase").append("")}),b.renderDBS()})}}.bind(this);this.collection.login(b,c,d)}},renderDBS:function(){var a=$("#loginDatabase").val();$("#goToDatabase").html("Select: "+a),window.setInterval(function(){$("#goToDatabase").focus()},300)},logout:function(){this.collection.logout()},goTo:function(a){a.preventDefault();var b=$("#loginUsername").val(),c=$("#loginDatabase").val();console.log(window.App.dbSet),window.App.dbSet=c,console.log(window.App.dbSet);var d=function(a){a&&arangoHelper.arangoError("User","Could not fetch user settings")},e=window.location.protocol+"//"+window.location.host+frontendConfig.basePath+"/_db/"+c+"/_admin/aardvark/index.html";window.location.href=e,$(this.el2).show(),$(this.el3).show(),$(".bodyWrapper").show(),$(".navbar").show(),$("#currentUser").text(b),this.collection.loadUserSettings(d)}})}(),function(){"use strict";window.LogsView=window.PaginationView.extend({el:"#content",id:"#logContent",paginationDiv:"#logPaginationDiv",idPrefix:"logTable",fetchedAmount:!1,initialize:function(a){this.options=a,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:[["All","logall"],["Info","loginfo"],["Error","logerror"],["Warning","logwarning"],["Debug","logdebug"]]},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,j){var k,l,m=this,n=!1;c=c||[],h=Boolean(h),this.clearValidators(),c.length>0?(c.forEach(function(a){a.type===m.buttons.CLOSE&&(n=!0),a.type===m.buttons.DELETE&&(l=l||a.confirm)}),n||(k=c.pop(),c.push(m.createCloseButton("Cancel")),c.push(k))):c.push(m.createCloseButton("Close")),j?($("#"+j).html(this.baseTemplate.render({title:b,buttons:c,hideFooter:this.hideFooter,confirm:l,tabBar:i})),$("#"+j+" #modal-dialog").removeClass("fade hide modal"),$("#"+j+" .modal-header").remove(),$("#"+j+" .modal-tabbar").remove(),$("#"+j+" .modal-tabbar").remove(),$("#"+j+" .button-close").remove(),0===$("#"+j+" .modal-footer").children().length&&$("#"+j+" .modal-footer").remove()):$(this.el).html(this.baseTemplate.render({title:b,buttons:c,hideFooter:this.hideFooter,confirm:l,tabBar:i})),_.each(c,function(a,b){return!a.disabled&&a.callback?a.type!==m.buttons.DELETE||h?void $("#modalButton"+b).bind("click",a.callback):void $("#modalButton"+b).bind("click",function(){$(m.confirm.yes).unbind("click"),$(m.confirm.yes).bind("click",a.callback),$(m.confirm.list).css("display","block")}):void 0}),$(this.confirm.no).bind("click",function(){$(m.confirm.list).css("display","none")});var o;if("string"==typeof a)o=templateEngine.createTemplate(a),j?$("#"+j+" .createModalDialog .modal-body").html(o.render({content:d,advancedContent:e,info:f})):$("#modalPlaceholder .createModalDialog .modal-body").html(o.render({content:d,advancedContent:e,info:f}));else{var p=0;_.each(a,function(a){o=templateEngine.createTemplate(a),$(".createModalDialog .modal-body .tab-content #"+i[p]).html(o.render({content:d,advancedContent:e,info:f})),p++})}$(".createModalDialog .modalTooltips").tooltip({position:{my:"left top",at:"right+55 top-1"}});var q=d||[];e&&e.content&&(q=q.concat(e.content)),_.each(q,function(a){m.modalBindValidation(a),a.type===m.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)),j||$("#modal-dialog").modal("show"),this.enabledHotkey===!1&&(this.createInitModalHotkeys(),this.enabledHotkey=!0),this.enableHotKeys&&this.createModalHotkeys();var r=$("#modal-dialog").find("input");r&&setTimeout(function(){var a=$("#modal-dialog");a.length>0&&(a=a.find("input"),a.length>0&&$(a[0]).focus())},400)},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",subEl:"#subNavigationBar",events:{"change #arangoCollectionSelect":"navigateBySelect","click .tab":"navigateByTab","click li":"switchTab","click .arangodbLogo":"selectMenuItem","mouseenter .dropdown > *":"showDropdown","click .shortcut-icons p":"showShortcutModal","mouseleave .dropdown":"hideDropdown"},renderFirst:!0,activeSubMenu:void 0,changeDB:function(){window.location.hash="#login"},initialize:function(a){var b=this;this.userCollection=a.userCollection,this.currentDB=a.currentDB,this.dbSelectionView=new window.DBSelectionView({collection:a.database,current:this.currentDB}),this.userBarView=new window.UserBarView({userCollection:this.userCollection}),this.notificationView=new window.NotificationView({collection:a.notificationCollection}),this.statisticBarView=new window.StatisticBarView({currentDB:this.currentDB}),this.isCluster=a.isCluster,this.handleKeyboardHotkeys(),Backbone.history.on("all",function(){b.selectMenuItem()})},showShortcutModal:function(){arangoHelper.hotkeysFunctions.showHotkeysModal()},handleSelectDatabase:function(){this.dbSelectionView.render($("#dbSelect"))},template:templateEngine.createTemplate("navigationView.ejs"),templateSub:templateEngine.createTemplate("subNavigationView.ejs"),render:function(){var a=this;$(this.el).html(this.template.render({currentDB:this.currentDB,isCluster:this.isCluster})),"_system"!==this.currentDB.get("name")&&$("#dashboard").parent().remove(),$(this.subEl).html(this.templateSub.render({currentDB:this.currentDB.toJSON()})),this.dbSelectionView.render($("#dbSelect"));var b=function(a){a||this.userBarView.render()}.bind(this);return this.userCollection.whoAmI(b),this.renderFirst&&(this.renderFirst=!1,this.selectMenuItem(),$(".arangodbLogo").on("click",function(){a.selectMenuItem()}),$("#dbStatus").on("click",function(){a.changeDB()})),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;$(b).hasClass("fa")||(""===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()})},subViewConfig:{documents:"collections",collection:"collections"},subMenuConfig:{cluster:[{name:"Dashboard",view:void 0,active:!0},{name:"Logs",view:void 0,disabled:!0}],collections:[{name:"",view:void 0,active:!1}],queries:[{name:"Editor",route:"query",active:!0},{name:"Running Queries",route:"queryManagement",params:{active:!0},active:void 0},{name:"Slow Query History",route:"queryManagement",params:{active:!1},active:void 0}]},renderSubMenu:function(a){var b=this;if(void 0===a&&(a=window.isCluster?"cluster":"dashboard"),this.subMenuConfig[a]){$(this.subEl+" .bottom").html("");var c="";_.each(this.subMenuConfig[a],function(a){c=a.active?"active":"",a.disabled&&(c="disabled"),$(b.subEl+" .bottom").append('"),a.disabled||$(b.subEl+" .bottom").children().last().bind("click",function(c){b.activeSubMenu=a,b.renderSubView(a,c)})})}},renderSubView:function(a,b){window.App[a.route]&&(window.App[a.route].resetState&&window.App[a.route].resetState(),window.App[a.route]()),$(this.subEl+" .bottom").children().removeClass("active"),$(b.currentTarget).addClass("active")},switchTab:function(a){var b=$(a.currentTarget).children().first().attr("id");b&&this.selectMenuItem(b+"-menu")},selectMenuItem:function(a,b){void 0===a&&(a=window.location.hash.split("/")[0],a=a.substr(1,a.length-1)),""===a?a=window.App.isCluster?"cluster":"dashboard":"cNodes"!==a&&"dNodes"!==a||(a="nodes");try{this.renderSubMenu(a.split("-")[0])}catch(c){this.renderSubMenu(a)}$(".navlist li").removeClass("active"),"string"==typeof a&&(b?$("."+this.subViewConfig[a]+"-menu").addClass("active"):a&&($("."+a).addClass("active"),$("."+a+"-menu").addClass("active"))),arangoHelper.hideArangoNotifications()},showSubDropdown:function(a){console.log($(a.currentTarget)),console.log($(a.currentTarget).find(".subBarDropdown")),$(a.currentTarget).find(".subBarDropdown").toggle()},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.NodeView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("nodeView.ejs"),interval:5e3,dashboards:[],events:{},initialize:function(a){window.App.isCluster&&(this.coordinators=a.coordinators,this.dbServers=a.dbServers,this.coordname=a.coordname,this.updateServerTime(),window.setInterval(function(){if(0===window.location.hash.indexOf("#node/"));},this.interval))},breadcrumb:function(a){$("#subNavigationBar .breadcrumb").html("Node: "+a)},render:function(){this.$el.html(this.template.render({coords:[]}));var a=function(){this.continueRender(),this.breadcrumb(this.coordname),$(window).trigger("resize")}.bind(this),b=function(){console.log("")};this.initCoordDone||this.waitForCoordinators(b),this.initDBDone?(this.coordname=window.location.hash.split("/")[1],this.coordinator=this.coordinators.findWhere({name:this.coordname}),a()):this.waitForDBServers(a)},continueRender:function(){var a=this;this.dashboards[this.coordinator.get("name")]=new window.DashboardView({dygraphConfig:window.dygraphConfig,database:window.App.arangoDatabase,serverToShow:{raw:this.coordinator.get("address"),isDBServer:!1,endpoint:this.coordinator.get("protocol")+"://"+this.coordinator.get("address"),target:this.coordinator.get("name")}}),this.dashboards[this.coordinator.get("name")].render(),window.setTimeout(function(){a.dashboards[a.coordinator.get("name")].resize()},500)},waitForCoordinators:function(a){var b=this;window.setTimeout(function(){0===b.coordinators.length?b.waitForCoordinators(a):(b.coordinator=b.coordinators.findWhere({name:b.coordname}),b.initCoordDone=!0,a())},200)},waitForDBServers:function(a){var b=this;window.setTimeout(function(){0===b.dbServers[0].length?b.waitForDBServers(a):(b.initDBDone=!0,b.dbServer=b.dbServers[0],b.dbServer.each(function(a){"DBServer1"===a.get("name")&&(b.dbServer=a)}),a())},200)},updateServerTime:function(){this.serverTime=(new Date).getTime()}})}(),function(){"use strict";window.NodesView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("nodesView.ejs"),interval:5e3,knownServers:[],events:{"click #nodesContent .pure-table-body .pure-table-row":"navigateToNode"},initialize:function(a){window.App.isCluster&&(this.dbServers=a.dbServers,this.coordinators=a.coordinators,this.updateServerTime(),this.toRender=a.toRender,window.setInterval(function(){if("#cNodes"===window.location.hash||"#dNodes"===window.location.hash);},this.interval))},navigateToNode:function(a){if("#dNodes"!==window.location.hash){var b=$(a.currentTarget).attr("node");window.App.navigate("#node/"+encodeURIComponent(b),{trigger:!0})}},render:function(){var a=function(){this.continueRender()}.bind(this);this.initDoneCoords?a():this.waitForCoordinators(a)},continueRender:function(){var a;a="coordinator"===this.toRender?this.coordinators.toJSON():this.dbServers.toJSON(),this.$el.html(this.template.render({coords:a,type:this.toRender})),window.arangoHelper.buildNodesSubNav(this.toRender)},waitForCoordinators:function(a){var b=this;window.setTimeout(function(){0===b.coordinators.length?b.waitForCoordinators(a):(this.initDoneCoords=!0,a())},200)},updateServerTime:function(){this.serverTime=(new Date).getTime()}})}(),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)),window.setTimeout(function(){frontendConfig.authenticationEnabled===!1&&window.arangoHelper.arangoWarning("Warning","Authentication is disabled. Do not use this setup in production mode.")},2e3)},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,e=this.collection.at(this.collection.length-1),f=e.get("title"),g=3e3,h=["click"];if(e.get("content")&&(f=f+": "+e.get("content")),"error"===e.get("type")?(g=!1,h=["button"],d=[{addClass:"button-danger",text:"Close",onClick:function(a){a.close()}}]):"warning"===e.get("type")&&(g=2e4),$.noty.clearQueue(),$.noty.closeAll(),noty({theme:"relax",text:f,template:'
    ',maxVisible:1,closeWith:["click"],type:e.get("type"),layout:"bottom",timeout:g,buttons:d,animation:{open:{height:"show"},close:{height:"hide"},easing:"swing",speed:200,closeWith:h}}),"success"===e.get("type"))return void e.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(){"function"==typeof this.action&&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"),active:!0,shouldRender:!0,timer:0,refreshRate:2e3,initialize:function(){var a=this;this.activeCollection=new window.QueryManagementActive,this.slowCollection=new window.QueryManagementSlow,this.convertModelToJSON(!0),window.setInterval(function(){"#queries"===window.location.hash&&window.VISIBLE&&a.shouldRender&&"queryManagement"===arangoHelper.getCurrentSub().route&&(a.active?$("#arangoQueryManagementTable").is(":visible")&&a.convertModelToJSON(!0):$("#arangoQueryManagementTable").is(":visible")&&a.convertModelToJSON(!1))},a.refreshRate)},events:{"click #deleteSlowQueryHistory":"deleteSlowQueryHistoryModal","click #arangoQueryManagementTable .fa-minus-circle":"deleteRunningQueryModal"},tableDescription:{id:"arangoQueryManagementTable",titles:["ID","Query String","Runtime","Started",""],rows:[],unescaped:[!1,!1,!1,!1,!0]},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(){var a=arangoHelper.getCurrentSub();a.params.active?(this.active=!0,this.convertModelToJSON(!0)):(this.active=!1,this.convertModelToJSON(!1))},addEvents:function(){var a=this;$("#queryManagementContent tbody").on("mousedown",function(){clearTimeout(a.timer),a.shouldRender=!1}),$("#queryManagementContent tbody").on("mouseup",function(){a.timer=window.setTimeout(function(){a.shouldRender=!0},3e3)})},renderActive:function(){this.$el.html(this.templateActive.render({})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#activequeries").addClass("arango-active-tab"),this.addEvents()},renderSlow:function(){this.$el.html(this.templateSlow.render({})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#slowqueries").addClass("arango-active-tab"),this.addEvents()},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({success:function(){a.updateLocalQueries(),a.renderSelectboxes(),a.updateTable(),a.allowUpload=!1,$("#customs-switch").click(),$("#confirmQueryImport").addClass("disabled"),$("#queryImportDialog").modal("hide")},error:function(a){arangoHelper.arangoError("Custom Queries",a.responseText)}})}.bind(this);a.collection.saveImportQueries(a.file,b.bind(this))}},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()).success(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(a){var b=this;this.collection.fetch({success:function(){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})});var e=function(a,b){a?arangoHelper.arangoError("Custom Queries","Could not import old local storage queries"):localStorage.removeItem("customQueries")}.bind(b);b.collection.saveCollectionQueries(e)}b.updateLocalQueries(),a&&a()}})},deleteAQL:function(a){var b=function(a){a?arangoHelper.arangoError("Query","Could not delete query."):(this.updateLocalQueries(),this.renderSelectboxes(),this.updateTable())}.bind(this),c=$(a.target).parent().parent().parent().children().first().text(),d=this.collection.findWhere({name:c});this.collection.remove(d),this.collection.saveCollectionQueries(b)},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})}var i=function(a){if(a)arangoHelper.arangoError("Query","Could not save query");else{var b=this;this.collection.fetch({success:function(){b.updateLocalQueries(),b.renderSelectboxes(),$("#querySelect").val(d)}})}}.bind(this);this.collection.saveCollectionQueries(i),window.modalView.hide()}},getSystemQueries:function(a){var b=this;$.ajax({type:"GET",cache:!1,url:"js/arango/aqltemplates.json",contentType:"application/json",processData:!1,success:function(c){a&&a(!1),b.queries=c},error:function(){a&&a(!0),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){var b=this,c=function(c){if(c)arangoHelper.arangoError("Query","Could not reload Queries");else if(b.updateLocalQueries(),a){var d=$("#querySelect").val();b.renderSelectboxes(),$("#querySelect").val(d)}}.bind(b),d=function(){b.getSystemQueries(c)}.bind(b);this.getAQL(d)},importSelected:function(a){var b=ace.edit("aqlEditor"),c=ace.edit("varsEditor");_.each(this.queries,function(d){$("#"+a.currentTarget.id).val()===d.name&&(b.setValue(d.value),d.hasOwnProperty("parameter")?(""!==d.parameter&&void 0!==d.parameter||(d.parameter="{}"),"object"==typeof d.parameter?c.setValue(JSON.stringify(d.parameter)):c.setValue(d.parameter)):c.setValue("{}"))}),_.each(this.customQueries,function(d){$("#"+a.currentTarget.id).val()===d.name&&(b.setValue(d.value),d.hasOwnProperty("parameter")?(""!==d.parameter&&void 0!==d.parameter&&"{}"!==JSON.stringify(d.parameter)||(d.parameter="{}"),c.setValue(d.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="-";a&&a.extra&&a.extra.stats&&(e=a.extra.stats.executionTime.toFixed(3)+" s"),$(".queryExecutionTime").text("Execution time: "+e),c.deselect(d),$("#downloadQueryResult").show(),"function"==typeof b&&b()},h=function(){$.ajax({type:"PUT",url:arangoHelper.databaseUrl("/_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:arangoHelper.databaseUrl("/_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.queryView2=Backbone.View.extend({el:"#content",bindParamId:"#bindParamEditor",myQueriesId:"#queryTable",template:templateEngine.createTemplate("queryView2.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),outputDiv:"#outputEditors",outputTemplate:templateEngine.createTemplate("queryViewOutput.ejs"),outputCounter:0,allowUpload:!1,customQueries:[],queries:[],state:{lastQuery:{query:void 0,bindParam:void 0}},settings:{aqlWidth:void 0},currentQuery:{},initDone:!1,bindParamRegExp:/@(@?\w+\d*)/,bindParamTableObj:{},bindParamTableDesc:{id:"arangoBindParamTable",titles:["Key","Value"],rows:[]},myQueriesTableDesc:{id:"arangoMyQueriesTable",titles:["Name","Actions"],rows:[]},execPending:!1,aqlEditor:null,queryPreview:null,initialize:function(){this.refreshAQL()},allowParamToggle:!0,events:{"click #executeQuery":"executeQuery","click #explainQuery":"explainQuery","click #clearQuery":"clearQuery","click .outputEditorWrapper #downloadQueryResult":"downloadQueryResult","click .outputEditorWrapper .switchAce":"switchAce","click .outputEditorWrapper .fa-close":"closeResult","click #toggleQueries1":"toggleQueries","click #toggleQueries2":"toggleQueries","click #saveCurrentQuery":"addAQL","click #exportQuery":"exportCustomQueries","click #importQuery":"openImportDialog","click #removeResults":"removeResults","click #querySpotlight":"showSpotlight","click #deleteQuery":"selectAndDeleteQueryFromTable","click #explQuery":"selectAndExplainQueryFromTable","keydown #arangoBindParamTable input":"updateBindParams","change #arangoBindParamTable input":"updateBindParams","click #arangoMyQueriesTable tbody tr":"showQueryPreview","dblclick #arangoMyQueriesTable tbody tr":"selectQueryFromTable","click #arangoMyQueriesTable #copyQuery":"selectQueryFromTable","click #closeQueryModal":"closeExportDialog","click #confirmQueryImport":"importCustomQueries","click #switchTypes":"toggleBindParams","click #arangoMyQueriesTable #runQuery":"selectAndRunQueryFromTable"},clearQuery:function(){this.aqlEditor.setValue("",1)},toggleBindParams:function(){this.allowParamToggle?($("#bindParamEditor").toggle(),$("#bindParamAceEditor").toggle(),"JSON"===$("#switchTypes").text()?($("#switchTypes").text("Table"),this.updateQueryTable(),this.bindParamAceEditor.setValue(JSON.stringify(this.bindParamTableObj,null," "),1),this.deselect(this.bindParamAceEditor)):($("#switchTypes").text("JSON"),this.renderBindParamTable())):arangoHelper.arangoError("Bind parameter","Could not parse bind parameter"),this.resize()},openExportDialog:function(){$("#queryImportDialog").modal("show")},closeExportDialog:function(){$("#queryImportDialog").modal("hide")},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({success:function(){a.updateLocalQueries(),a.updateQueryTable(),a.resize(),a.allowUpload=!1,$("#confirmQueryImport").addClass("disabled"),$("#queryImportDialog").modal("hide")},error:function(a){arangoHelper.arangoError("Custom Queries",a.responseText)}})}.bind(this);a.collection.saveImportQueries(a.file,b.bind(this))}},removeResults:function(){$(".outputEditorWrapper").hide("fast",function(){$(".outputEditorWrapper").remove()}),$("#removeResults").hide()},getCustomQueryParameterByName:function(a){return this.collection.findWhere({name:a}).get("parameter")},getCustomQueryValueByName:function(a){var b;return a&&(b=this.collection.findWhere({name:a})),b?b=b.get("value"):_.each(this.queries,function(c){c.name===a&&(b=c.value)}),b},openImportDialog:function(){$("#queryImportDialog").modal("show")},closeImportDialog:function(){$("#queryImportDialog").modal("hide")},exportCustomQueries:function(){var a;$.ajax("whoAmI?_="+Date.now()).success(function(b){a=b.user,null!==a&&a!==!1||(a="root"),window.open("query/download/"+encodeURIComponent(a))})},toggleQueries:function(a){a&&"toggleQueries1"===a.currentTarget.id?(this.updateQueryTable(),$("#bindParamAceEditor").hide(),$("#bindParamEditor").show(),$("#switchTypes").text("JSON"),$(".aqlEditorWrapper").first().width(.33*$(window).width()),this.queryPreview.setValue("No query selected.",1),this.deselect(this.queryPreview)):void 0===this.settings.aqlWidth?$(".aqlEditorWrapper").first().width(.33*$(window).width()):$(".aqlEditorWrapper").first().width(this.settings.aqlWidth),this.resize();var b=["aqlEditor","queryTable","previewWrapper","querySpotlight","bindParamEditor","toggleQueries1","toggleQueries2","saveCurrentQuery","querySize","executeQuery","switchTypes","explainQuery","importQuery","exportQuery"];_.each(b,function(a){$("#"+a).toggle()}),this.resize()},showQueryPreview:function(a){$("#arangoMyQueriesTable tr").removeClass("selected"),$(a.currentTarget).addClass("selected");var b=this.getQueryNameFromTable(a);this.queryPreview.setValue(this.getCustomQueryValueByName(b),1),this.deselect(this.queryPreview)},getQueryNameFromTable:function(a){var b;return $(a.currentTarget).is("tr")?b=$(a.currentTarget).children().first().text():$(a.currentTarget).is("span")&&(b=$(a.currentTarget).parent().parent().prev().text()),b},deleteQueryModal:function(a){var b=[],c=[];c.push(window.modalView.createReadOnlyEntry(void 0,a,"Do you want to delete the query?",void 0,void 0,!1,void 0)),b.push(window.modalView.createDeleteButton("Delete",this.deleteAQL.bind(this,a))),window.modalView.show("modalTable.ejs","Delete Query",b,c)},selectAndDeleteQueryFromTable:function(a){var b=this.getQueryNameFromTable(a);this.deleteQueryModal(b)},selectAndExplainQueryFromTable:function(a){this.selectQueryFromTable(a,!1),this.explainQuery()},selectAndRunQueryFromTable:function(a){this.selectQueryFromTable(a,!1),this.executeQuery()},selectQueryFromTable:function(a,b){var c=this.getQueryNameFromTable(a),d=this;void 0===b&&this.toggleQueries(),this.state.lastQuery.query=this.aqlEditor.getValue(),this.state.lastQuery.bindParam=this.bindParamTableObj,this.aqlEditor.setValue(this.getCustomQueryValueByName(c),1),this.fillBindParamTable(this.getCustomQueryParameterByName(c)),this.updateBindParams(),$("#lastQuery").remove(),$("#queryContent .arangoToolbarTop .pull-left").append('Previous Query'),$("#lastQuery").hide().fadeIn(500).on("click",function(){d.aqlEditor.setValue(d.state.lastQuery.query,1),d.fillBindParamTable(d.state.lastQuery.bindParam),d.updateBindParams(),$("#lastQuery").fadeOut(500,function(){$(this).remove()})})},deleteAQL:function(a){var b=function(a){a?arangoHelper.arangoError("Query","Could not delete query."):(this.updateLocalQueries(),this.updateQueryTable(),this.resize(),window.modalView.hide())}.bind(this),c=this.collection.findWhere({name:a});this.collection.remove(c),this.collection.saveCollectionQueries(b)},switchAce:function(a){var b=$(a.currentTarget).attr("counter");"Result"===$(a.currentTarget).text()?$(a.currentTarget).text("AQL"):$(a.currentTarget).text("Result"),$("#outputEditor"+b).toggle(),$("#sentWrapper"+b).toggle(),this.deselect(ace.edit("outputEditor"+b)),this.deselect(ace.edit("sentQueryEditor"+b)),this.deselect(ace.edit("sentBindParamEditor"+b))},downloadQueryResult:function(a){var b=$(a.currentTarget).attr("counter"),c=ace.edit("sentQueryEditor"+b),d=c.getValue();""!==d||void 0!==d||null!==d?0===Object.keys(this.bindParamTableObj).length?window.open("query/result/download/"+encodeURIComponent(btoa(JSON.stringify({query:d})))):window.open("query/result/download/"+encodeURIComponent(btoa(JSON.stringify({query:d,bindVars:this.bindParamTableObj})))):arangoHelper.arangoError("Query error","could not query result.")},explainQuery:function(){if(!this.verifyQueryAndParams()){this.$(this.outputDiv).prepend(this.outputTemplate.render({counter:this.outputCounter,type:"Explain"}));var a=this.outputCounter,b=ace.edit("outputEditor"+a),c=ace.edit("sentQueryEditor"+a),d=ace.edit("sentBindParamEditor"+a);c.getSession().setMode("ace/mode/aql"),c.setOption("vScrollBarAlwaysVisible",!0),c.setReadOnly(!0),this.setEditorAutoHeight(c),b.setReadOnly(!0),b.getSession().setMode("ace/mode/json"),b.setOption("vScrollBarAlwaysVisible",!0),this.setEditorAutoHeight(b),d.setValue(JSON.stringify(this.bindParamTableObj),1),d.setOption("vScrollBarAlwaysVisible",!0),d.getSession().setMode("ace/mode/json"),d.setReadOnly(!0),this.setEditorAutoHeight(d),this.fillExplain(b,c,a),this.outputCounter++}},fillExplain:function(a,b,c){b.setValue(this.aqlEditor.getValue(),1);var d=this,e=this.readQueryData();if($("#outputEditorWrapper"+c+" .queryExecutionTime").text(""),this.execPending=!1,e){var f=function(){$("#outputEditorWrapper"+c+" #spinner").remove(),$("#outputEditor"+c).css("opacity","1"),$("#outputEditorWrapper"+c+" .fa-close").show(),$("#outputEditorWrapper"+c+" .switchAce").show()};$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_admin/aardvark/query/explain/"),data:e,contentType:"application/json",processData:!1,success:function(b){b.msg.includes("errorMessage")?(d.removeOutputEditor(c),arangoHelper.arangoError("Explain",b.msg)):(a.setValue(b.msg,1),d.deselect(a),$.noty.clearQueue(),$.noty.closeAll(),d.handleResult(c)),f()},error:function(a){try{var b=JSON.parse(a.responseText);arangoHelper.arangoError("Explain",b.errorMessage)}catch(e){arangoHelper.arangoError("Explain","ERROR")}d.handleResult(c),d.removeOutputEditor(c),f()}})}},removeOutputEditor:function(a){$("#outputEditorWrapper"+a).hide(),$("#outputEditorWrapper"+a).remove(),0===$(".outputEditorWrapper").length&&$("#removeResults").hide()},getCachedQueryAfterRender:function(){var a=this.getCachedQuery(),b=this;if(null!==a&&void 0!==a&&""!==a&&(this.aqlEditor.setValue(a.query,1),this.aqlEditor.getSession().setUndoManager(new ace.UndoManager),""!==a.parameter||void 0!==a))try{b.bindParamTableObj=JSON.parse(a.parameter);var c;_.each($("#arangoBindParamTable input"),function(a){c=$(a).attr("name"),$(a).val(b.bindParamTableObj[c])}),b.setCachedQuery(b.aqlEditor.getValue(),JSON.stringify(b.bindParamTableObj))}catch(d){}},getCachedQuery:function(){if("undefined"!==Storage){var a=localStorage.getItem("cachedQuery");if(void 0!==a){var b=JSON.parse(a);this.currentQuery=b;try{this.bindParamTableObj=JSON.parse(b.parameter)}catch(c){}return b}}},setCachedQuery:function(a,b){if("undefined"!==Storage){var c={query:a,parameter:b};this.currentQuery=c,localStorage.setItem("cachedQuery",JSON.stringify(c))}},closeResult:function(a){var b=$("#"+$(a.currentTarget).attr("element")).parent();$(b).hide("fast",function(){$(b).remove(),0===$(".outputEditorWrapper").length&&$("#removeResults").hide()})},fillSelectBoxes:function(){var a=1e3,b=$("#querySize");b.empty(),[100,250,500,1e3,2500,5e3,1e4,"all"].forEach(function(c){b.append('")})},render:function(){this.$el.html(this.template.render({})),this.afterRender(),this.initDone||(this.settings.aqlWidth=$(".aqlEditorWrapper").width()),this.initDone=!0,this.renderBindParamTable(!0)},afterRender:function(){var a=this;this.initAce(),this.initTables(),this.fillSelectBoxes(),this.makeResizeable(),this.initQueryImport(),this.getCachedQueryAfterRender(),$(".inputEditorWrapper").height($(window).height()/10*5+25),window.setTimeout(function(){a.resize()},10),a.deselect(a.aqlEditor)},showSpotlight:function(a){var b,c;if(void 0!==a&&"click"!==a.type||(a="aql"),"aql"===a)b=function(a){this.aqlEditor.insert(a),$("#aqlEditor .ace_text-input").focus()}.bind(this),c=function(){$("#aqlEditor .ace_text-input").focus()};else{var d=$(":focus");b=function(a){var b=$(d).val();$(d).val(b+a),$(d).focus()}.bind(this),c=function(){$(d).focus()}}window.spotlightView.show(b,c,a)},resize:function(){this.resizeFunction()},resizeFunction:function(){$("#toggleQueries1").is(":visible")?(this.aqlEditor.resize(),$("#arangoBindParamTable thead").css("width",$("#bindParamEditor").width()),$("#arangoBindParamTable thead th").css("width",$("#bindParamEditor").width()/2),$("#arangoBindParamTable tr").css("width",$("#bindParamEditor").width()),$("#arangoBindParamTable tbody").css("height",$("#aqlEditor").height()-35),$("#arangoBindParamTable tbody").css("width",$("#bindParamEditor").width()),$("#arangoBindParamTable tbody tr").css("width",$("#bindParamEditor").width()),$("#arangoBindParamTable tbody td").css("width",$("#bindParamEditor").width()/2)):(this.queryPreview.resize(),$("#arangoMyQueriesTable thead").css("width",$("#queryTable").width()),$("#arangoMyQueriesTable thead th").css("width",$("#queryTable").width()/2),$("#arangoMyQueriesTable tr").css("width",$("#queryTable").width()),$("#arangoMyQueriesTable tbody").css("height",$("#queryTable").height()-35),$("#arangoMyQueriesTable tbody").css("width",$("#queryTable").width()),$("#arangoMyQueriesTable tbody td").css("width",$("#queryTable").width()/2))},makeResizeable:function(){var a=this;$(".aqlEditorWrapper").resizable({resize:function(){a.resizeFunction(),a.settings.aqlWidth=$(".aqlEditorWrapper").width()},handles:"e"}),$(".inputEditorWrapper").resizable({resize:function(){a.resizeFunction()},handles:"s"}),this.resizeFunction()},initTables:function(){this.$(this.bindParamId).html(this.table.render({content:this.bindParamTableDesc})),this.$(this.myQueriesId).html(this.table.render({content:this.myQueriesTableDesc}))},checkType:function(a){var b="stringtype";try{a=JSON.parse(a),b=a instanceof Array?"arraytype":typeof a+"type"}catch(c){}return b},updateBindParams:function(a){var b,c=this;if(a){b=$(a.currentTarget).attr("name"),this.bindParamTableObj[b]=arangoHelper.parseInput(a.currentTarget);var d=["arraytype","objecttype","booleantype","numbertype","stringtype"];_.each(d,function(b){$(a.currentTarget).removeClass(b)}),$(a.currentTarget).addClass(c.checkType($(a.currentTarget).val()))}else _.each($("#arangoBindParamTable input"),function(a){b=$(a).attr("name"),c.bindParamTableObj[b]=arangoHelper.parseInput(a)});this.setCachedQuery(this.aqlEditor.getValue(),JSON.stringify(this.bindParamTableObj)),a&&((a.ctrlKey||a.metaKey)&&13===a.keyCode&&(a.preventDefault(),this.executeQuery()),(a.ctrlKey||a.metaKey)&&32===a.keyCode&&(a.preventDefault(),this.showSpotlight("bind")))},parseQuery:function(a){var b=0,c=1,d=2,e=3,f=4,g=5,h=6,i=7;a+=" ";var j,k,l,m=this,n=b,o=a.length,p=[];for(k=0;o>k;++k)switch(l=a.charAt(k),n){case b:"@"===l?(n=h,j=k):"'"===l?n=c:'"'===l?n=d:"`"===l?n=e:"´"===l?n=i:"/"===l&&o>k+1&&("/"===a.charAt(k+1)?(n=f,++k):"*"===a.charAt(k+1)&&(n=g,++k));break;case f:"\r"!==l&&"\n"!==l||(n=b);break;case g:"*"===l&&o>=k+1&&"/"===a.charAt(k+1)&&(n=b,++k);break;case c:"\\"===l?++k:"'"===l&&(n=b);break;case d:"\\"===l?++k:'"'===l&&(n=b);break;case e:"`"===l&&(n=b);break;case i:"´"===l&&(n=b);break;case h:/^[@a-zA-Z0-9_]+$/.test(l)||(p.push(a.substring(j,k)),n=b,j=void 0)}var q;return _.each(p,function(a,b){q=a.match(m.bindParamRegExp),q&&(p[b]=q[1])}),{query:a,bindParams:p}},checkForNewBindParams:function(){var a=this,b=this.parseQuery(this.aqlEditor.getValue()).bindParams,c={};_.each(b,function(b){a.bindParamTableObj[b]?c[b]=a.bindParamTableObj[b]:c[b]=""}),Object.keys(b).forEach(function(b){Object.keys(a.bindParamTableObj).forEach(function(d){b===d&&(c[b]=a.bindParamTableObj[d])})}),a.bindParamTableObj=c},renderBindParamTable:function(a){$("#arangoBindParamTable tbody").html(""),a&&this.getCachedQuery();var b=0;_.each(this.bindParamTableObj,function(a,c){$("#arangoBindParamTable tbody").append(""+c+"'),b++,_.each($("#arangoBindParamTable input"),function(b){$(b).attr("name")===c&&(a instanceof Array?$(b).val(JSON.stringify(a)).addClass("arraytype"):"object"==typeof a?$(b).val(JSON.stringify(a)).addClass(typeof a+"type"):$(b).val(a).addClass(typeof a+"type"))})}),0===b&&$("#arangoBindParamTable tbody").append('No bind parameters defined.')},fillBindParamTable:function(a){_.each(a,function(a,b){_.each($("#arangoBindParamTable input"),function(c){$(c).attr("name")===b&&$(c).val(a)})})},initAce:function(){var a=this;this.aqlEditor=ace.edit("aqlEditor"),this.aqlEditor.getSession().setMode("ace/mode/aql"),this.aqlEditor.setFontSize("10pt"),this.aqlEditor.setShowPrintMargin(!1),this.bindParamAceEditor=ace.edit("bindParamAceEditor"),this.bindParamAceEditor.getSession().setMode("ace/mode/json"),this.bindParamAceEditor.setFontSize("10pt"),this.bindParamAceEditor.setShowPrintMargin(!1),this.bindParamAceEditor.getSession().on("change",function(){try{a.bindParamTableObj=JSON.parse(a.bindParamAceEditor.getValue()),a.allowParamToggle=!0,a.setCachedQuery(a.aqlEditor.getValue(),JSON.stringify(a.bindParamTableObj))}catch(b){""===a.bindParamAceEditor.getValue()?(_.each(a.bindParamTableObj,function(b,c){a.bindParamTableObj[c]=""}),a.allowParamToggle=!0):a.allowParamToggle=!1}}),this.aqlEditor.getSession().on("change",function(){a.checkForNewBindParams(),a.renderBindParamTable(),a.initDone&&a.setCachedQuery(a.aqlEditor.getValue(),JSON.stringify(a.bindParamTableObj)),a.bindParamAceEditor.setValue(JSON.stringify(a.bindParamTableObj,null," "),1),$("#aqlEditor .ace_text-input").focus(),a.resize()}),this.aqlEditor.commands.addCommand({name:"togglecomment",bindKey:{win:"Ctrl-Shift-C",linux:"Ctrl-Shift-C",mac:"Command-Shift-C"},exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEach"}),this.aqlEditor.commands.addCommand({name:"executeQuery",bindKey:{win:"Ctrl-Return",mac:"Command-Return",linux:"Ctrl-Return"},exec:function(){a.executeQuery()}}),this.aqlEditor.commands.addCommand({name:"saveQuery",bindKey:{win:"Ctrl-Shift-S",mac:"Command-Shift-S",linux:"Ctrl-Shift-S"},exec:function(){a.addAQL()}}),this.aqlEditor.commands.addCommand({name:"explainQuery",bindKey:{win:"Ctrl-Shift-Return",mac:"Command-Shift-Return",linux:"Ctrl-Shift-Return"},exec:function(){a.explainQuery()}}),this.aqlEditor.commands.addCommand({name:"togglecomment",bindKey:{win:"Ctrl-Shift-C",linux:"Ctrl-Shift-C",mac:"Command-Shift-C"},exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEach"}),this.aqlEditor.commands.addCommand({name:"showSpotlight",bindKey:{win:"Ctrl-Space",mac:"Ctrl-Space",linux:"Ctrl-Space"},exec:function(){a.showSpotlight()}}),this.queryPreview=ace.edit("queryPreview"),this.queryPreview.getSession().setMode("ace/mode/aql"),this.queryPreview.setReadOnly(!0),this.queryPreview.setFontSize("13px"),$("#aqlEditor .ace_text-input").focus(); -},updateQueryTable:function(){function a(a,b){var c;return c=a.nameb.name?1:0}var b=this;this.updateLocalQueries(),this.myQueriesTableDesc.rows=this.customQueries,_.each(this.myQueriesTableDesc.rows,function(a){a.secondRow='
    ',a.hasOwnProperty("parameter")&&delete a.parameter,delete a.value}),this.myQueriesTableDesc.rows.sort(a),_.each(this.queries,function(a){a.hasOwnProperty("parameter")&&delete a.parameter,b.myQueriesTableDesc.rows.push({name:a.name,thirdRow:''})}),this.myQueriesTableDesc.unescaped=[!1,!0,!0],this.$(this.myQueriesId).html(this.table.render({content:this.myQueriesTableDesc}))},listenKey:function(a){13===a.keyCode&&this.saveAQL(a),this.checkSaveName()},addAQL:function(){this.refreshAQL(!0),this.createCustomQueryModal(),setTimeout(function(){$("#new-query-name").focus()},500)},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)})},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"))},saveAQL:function(a){a.stopPropagation(),this.refreshAQL();var b=$("#new-query-name").val(),c=this.bindParamTableObj;if(!$("#new-query-name").hasClass("invalid-input")&&""!==b.trim()){var d=this.aqlEditor.getValue(),e=!1;if(_.each(this.customQueries,function(a){return a.name===b?(a.value=d,void(e=!0)):void 0}),e===!0)this.collection.findWhere({name:b}).set("value",d);else{if(""!==c&&void 0!==c||(c="{}"),"string"==typeof c)try{c=JSON.parse(c)}catch(f){arangoHelper.arangoError("Query","Could not parse bind parameter")}this.collection.add({name:b,parameter:c,value:d})}var g=function(a){if(a)arangoHelper.arangoError("Query","Could not save query");else{var b=this;this.collection.fetch({success:function(){b.updateLocalQueries()}})}}.bind(this);this.collection.saveCollectionQueries(g),window.modalView.hide()}},verifyQueryAndParams:function(){var a=!1;0===this.aqlEditor.getValue().length&&(arangoHelper.arangoError("Query","Your query is empty"),a=!0);var b=[];return _.each(this.bindParamTableObj,function(c,d){""===c&&(a=!0,b.push(d))}),b.length>0&&arangoHelper.arangoError("Bind Parameter",JSON.stringify(b)+" not defined."),a},executeQuery:function(){if(!this.verifyQueryAndParams()){this.$(this.outputDiv).prepend(this.outputTemplate.render({counter:this.outputCounter,type:"Query"})),$("#outputEditorWrapper"+this.outputCounter).hide(),$("#outputEditorWrapper"+this.outputCounter).show("fast");var a=this.outputCounter,b=ace.edit("outputEditor"+a),c=ace.edit("sentQueryEditor"+a),d=ace.edit("sentBindParamEditor"+a);c.getSession().setMode("ace/mode/aql"),c.setOption("vScrollBarAlwaysVisible",!0),c.setFontSize("13px"),c.setReadOnly(!0),this.setEditorAutoHeight(c),b.setFontSize("13px"),b.getSession().setMode("ace/mode/json"),b.setReadOnly(!0),b.setOption("vScrollBarAlwaysVisible",!0),b.setShowPrintMargin(!1),this.setEditorAutoHeight(b),d.setValue(JSON.stringify(this.bindParamTableObj),1),d.setOption("vScrollBarAlwaysVisible",!0),d.getSession().setMode("ace/mode/json"),d.setReadOnly(!0),this.setEditorAutoHeight(d),this.fillResult(b,c,a),this.outputCounter++}},readQueryData:function(){var a=this.aqlEditor.session.getTextRange(this.aqlEditor.getSelectionRange()),b=$("#querySize"),c={query:a||this.aqlEditor.getValue(),id:"currentFrontendQuery"};return"all"===b.val()?c.batchSize=1e6:c.batchSize=parseInt(b.val(),10),Object.keys(this.bindParamTableObj).length>0&&(c.bindVars=this.bindParamTableObj),JSON.stringify(c)},fillResult:function(a,b,c){var d=this,e=this.readQueryData();e&&(b.setValue(d.aqlEditor.getValue(),1),$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_api/cursor"),headers:{"x-arango-async":"store"},data:e,contentType:"application/json",processData:!1,success:function(b,e,f){f.getResponseHeader("x-arango-async-id")&&d.queryCallbackFunction(f.getResponseHeader("x-arango-async-id"),a,c),$.noty.clearQueue(),$.noty.closeAll(),d.handleResult(c)},error:function(a){try{var b=JSON.parse(a.responseText);arangoHelper.arangoError("["+b.errorNum+"]",b.errorMessage)}catch(e){arangoHelper.arangoError("Query error","ERROR")}d.handleResult(c)}}))},handleResult:function(){window.progressView.hide(),$("#removeResults").show(),$(".centralRow").animate({scrollTop:$("#queryContent").height()},"fast")},setEditorAutoHeight:function(a){var b=$(".centralRow").height(),c=(b-250)/17;a.setOptions({maxLines:c,minLines:10})},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()},queryCallbackFunction:function(a,b,c){var d=this,e=function(a,b){$.ajax({url:arangoHelper.databaseUrl("/_api/job/"+encodeURIComponent(a)+"/cancel"),type:"PUT",success:function(){window.clearTimeout(d.checkQueryTimer),$("#outputEditorWrapper"+b).remove(),arangoHelper.arangoNotification("Query","Query canceled.")}})};$("#outputEditorWrapper"+c+" #cancelCurrentQuery").bind("click",function(){e(a,c)}),$("#outputEditorWrapper"+c+" #copy2aqlEditor").bind("click",function(){$("#toggleQueries1").is(":visible")||d.toggleQueries();var a=ace.edit("sentQueryEditor"+c).getValue(),b=JSON.parse(ace.edit("sentBindParamEditor"+c).getValue());d.aqlEditor.setValue(a,1),d.deselect(d.aqlEditor),Object.keys(b).length>0&&(d.bindParamTableObj=b,d.setCachedQuery(d.aqlEditor.getValue(),JSON.stringify(d.bindParamTableObj)),$("#bindParamEditor").is(":visible")?d.renderBindParamTable():(d.bindParamAceEditor.setValue(JSON.stringify(b),1),d.deselect(d.bindParamAceEditor))),$(".centralRow").animate({scrollTop:0},"fast"),d.resize()}),this.execPending=!1;var f=function(a){var c="";a.extra&&a.extra.warnings&&a.extra.warnings.length>0&&(c+="Warnings:\r\n\r\n",a.extra.warnings.forEach(function(a){c+="["+a.code+"], '"+a.message+"'\r\n"})),""!==c&&(c+="\r\nResult:\r\n\r\n"),b.setValue(c+JSON.stringify(a.result,void 0,2),1),b.getSession().setScrollTop(0)},g=function(a){f(a),window.progressView.hide();var e=function(a,b){$("#outputEditorWrapper"+c+" .arangoToolbarTop .pull-left").append(''+a+"")};$("#outputEditorWrapper"+c+" .pull-left #spinner").remove();var g="-";a&&a.extra&&a.extra.stats&&(g=a.extra.stats.executionTime.toFixed(3)+" s"),e(a.result.length+" elements","fa-calculator"),e(g,"fa-clock-o"),a.extra&&a.extra.stats&&(console.log(a.result.length),(a.extra.stats.writesExecuted>0||a.extra.stats.writesIgnored>0)&&(e(a.extra.stats.writesExecuted+" writes","fa-check-circle positive"),0===a.extra.stats.writesIgnored?e(a.extra.stats.writesIgnored+" writes ignored","fa-check-circle positive"):e(a.extra.stats.writesIgnored+" writes ignored","fa-exclamation-circle warning")),a.extra.stats.scannedFull>0?e("full collection scan","fa-exclamation-circle warning"):e("no full collection scan","fa-check-circle positive")),$("#outputEditorWrapper"+c+" .switchAce").show(),$("#outputEditorWrapper"+c+" .fa-close").show(),$("#outputEditor"+c).css("opacity","1"),$("#outputEditorWrapper"+c+" #downloadQueryResult").show(),$("#outputEditorWrapper"+c+" #copy2aqlEditor").show(),$("#outputEditorWrapper"+c+" #cancelCurrentQuery").remove(),d.setEditorAutoHeight(b),d.deselect(b),a.id&&$.ajax({url:"/_api/cursor/"+encodeURIComponent(a.id),type:"DELETE",error:function(a){console.log(a)}})},h=function(){$.ajax({type:"PUT",url:arangoHelper.databaseUrl("/_api/job/"+encodeURIComponent(a)),contentType:"application/json",processData:!1,success:function(a,b,c){201===c.status?g(a):204===c.status&&(d.checkQueryTimer=window.setTimeout(function(){h()},500))},error:function(a){var b;try{if("Gone"===a.statusText)return arangoHelper.arangoNotification("Query","Query execution aborted."),void d.removeOutputEditor(c);b=JSON.parse(a.responseText),arangoHelper.arangoError("Query",b.errorMessage),b.errorMessage&&(null!==b.errorMessage.match(/\d+:\d+/g)?d.markPositionError(b.errorMessage.match(/'.*'/g)[0],b.errorMessage.match(/\d+:\d+/g)[0]):d.markPositionError(b.errorMessage.match(/\(\w+\)/g)[0]),d.removeOutputEditor(c))}catch(e){console.log(b),400!==b.code&&arangoHelper.arangoError("Query","Successfully aborted."),d.removeOutputEditor(c)}window.progressView.hide()}})};h()},markPositionError:function(a,b){var c;b&&(c=b.split(":")[0],a=a.substr(1,a.length-2));var d=this.aqlEditor.find(a);!d&&b&&(this.aqlEditor.selection.moveCursorToPosition({row:c,column:0}),this.aqlEditor.selection.selectLine()),window.setTimeout(function(){$(".ace_start").first().css("background","rgba(255, 129, 129, 0.7)")},100)},refreshAQL:function(){var a=this,b=function(b){b?arangoHelper.arangoError("Query","Could not reload Queries"):(a.updateLocalQueries(),a.updateQueryTable())}.bind(a),c=function(){a.getSystemQueries(b)}.bind(a);this.getAQL(c)},getSystemQueries:function(a){var b=this;$.ajax({type:"GET",cache:!1,url:"js/arango/aqltemplates.json",contentType:"application/json",processData:!1,success:function(c){a&&a(!1),b.queries=c},error:function(){a&&a(!0),arangoHelper.arangoNotification("Query","Error while loading system templates")}})},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")})})},getAQL:function(a){var b=this;this.collection.fetch({success:function(){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})});var e=function(a){a?arangoHelper.arangoError("Custom Queries","Could not import old local storage queries"):localStorage.removeItem("customQueries")}.bind(b);b.collection.saveCollectionQueries(e)}b.updateLocalQueries(),a&&a()}})}})}(),function(){"use strict";window.ScaleView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("scaleView.ejs"),interval:5e3,knownServers:[],events:{"click #addCoord":"addCoord","click #removeCoord":"removeCoord","click #addDBs":"addDBs","click #removeDBs":"removeDBs"},setCoordSize:function(a){$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_admin/cluster/setCoordSize"),contentType:"application/json",data:JSON.stringify({value:a}),success:function(){$("#plannedCoords").html(a)},error:function(){arangoHelper.arangoError("Scale","Could not set coordinator size.")}})},setDBsSize:function(a){$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_admin/cluster/setDBsSize"),contentType:"application/json",data:JSON.stringify({value:a}),success:function(){$("#plannedCoords").html(a)},error:function(){arangoHelper.arangoError("Scale","Could not set coordinator size.")}})},addCoord:function(){this.setCoordSize(this.readNumberFromID("#plannedCoords",!0))},removeCoord:function(){this.setCoordSize(this.readNumberFromID("#plannedCoords",!1,!0))},addDBs:function(){this.setDBsSize(this.readNumberFromID("#plannedDBs",!0))},removeDBs:function(){this.setDBsSize(this.readNumberFromID("#plannedDBs",!1,!0))},readNumberFromID:function(a,b,c){var d=$(a).html(),e=!1;try{e=JSON.parse(d)}catch(f){}return b&&e++,c&&1!==e&&e--,e},initialize:function(a){window.App.isCluster&&(this.dbServers=a.dbServers,this.coordinators=a.coordinators,this.updateServerTime(),window.setInterval(function(){if("#sNodes"===window.location.hash);},this.interval))},render:function(){var a=this,b=function(){var b=function(){a.continueRender()}.bind(this);this.waitForDBServers(b)}.bind(this);this.initDoneCoords?b():this.waitForCoordinators(b),window.arangoHelper.buildNodesSubNav("scale")},continueRender:function(){var a,b,c=this;a=this.coordinators.toJSON(),b=this.dbServers.toJSON(),this.$el.html(this.template.render({runningCoords:a.length,runningDBs:b.length,plannedCoords:void 0,plannedDBs:void 0})),$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_admin/cluster/numberOfServers"),contentType:"application/json",processData:!1,success:function(a){c.updateTable(a)}})},updateTable:function(a){$("#plannedCoords").html(a.numberOfCoordinators),$("#plannedDBs").html(a.numberOfDBServers);var b='scaling in progress',c='no scaling process active';this.coordinators.toJSON().length===a.numberOfCoordinators?$("#statusCoords").html(c):$("#statusCoords").html(b),this.dbServers.toJSON().length===a.numberOfDBServers?$("#statusDBs").html(c):$("#statusDBs").html(b)},waitForDBServers:function(a){var b=this;0===this.dbServers.length?window.setInterval(function(){b.waitForDBServers(a)},300):a()},waitForCoordinators:function(a){var b=this;window.setTimeout(function(){0===b.coordinators.length?b.waitForCoordinators(a):(this.initDoneCoords=!0,a())},200)},updateServerTime:function(){this.serverTime=(new Date).getTime()}})}(),function(){"use strict";window.SettingsView=Backbone.View.extend({el:"#content",initialize:function(a){this.collectionName=a.collectionName,this.model=this.collection},events:{},render:function(){this.breadcrumb(),window.arangoHelper.buildCollectionSubNav(this.collectionName,"Settings"),this.renderSettings()},breadcrumb:function(){$("#subNavigationBar .breadcrumb").html("Collection: "+this.collectionName)},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(),window.modalView.hide()},deleteCollection:function(){this.model.destroy({error:function(){arangoHelper.arangoError("Could not delete collection.")},success:function(){window.App.navigate("#collections",{trigger:!0})}})},saveModifiedCollection:function(){var a=function(a,b){if(a)arangoHelper.arangoError("Error","Could not get coordinator info");else{var c;c=b?this.model.get("name"):$("#change-collection-name").val();var d=this.model.get("status");if("loaded"===d){var e;try{e=JSON.parse(1024*$("#change-collection-size").val()*1024)}catch(f){return arangoHelper.arangoError("Please enter a valid number"),0}var g;try{if(g=JSON.parse($("#change-index-buckets").val()),1>g||parseInt(g)!==Math.pow(2,Math.log2(g)))throw"invalid indexBuckets value"}catch(f){return arangoHelper.arangoError("Please enter a valid number of index buckets"),0}var h=function(a){a?arangoHelper.arangoError("Collection error: "+a.responseText):(this.collectionsView.render(),window.modalView.hide())}.bind(this),i=function(a){if(a)arangoHelper.arangoError("Collection error: "+a.responseText);else{var b=$("#change-collection-sync").val();this.model.changeCollection(b,e,g,h)}}.bind(this);this.model.renameCollection(c,i)}else if("unloaded"===d)if(this.model.get("name")!==c){var j=function(a,b){a?arangoHelper.arangoError("Collection error: "+b.responseText):(this.collectionsView.render(),window.modalView.hide())}.bind(this);this.model.renameCollection(c,j)}else window.modalView.hide()}}.bind(this);window.isCoordinator(a)},renderSettings:function(){var a=function(a,b){if(a)arangoHelper.arangoError("Error","Could not get coordinator info");else{var c=!1;"loaded"===this.model.get("status")&&(c=!0);var d=[],e=[];b||e.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."}]));var f=function(){e.push(window.modalView.createReadOnlyEntry("change-collection-id","ID",this.model.get("id"),"")),e.push(window.modalView.createReadOnlyEntry("change-collection-type","Type",this.model.get("type"),"")),e.push(window.modalView.createReadOnlyEntry("change-collection-status","Status",this.model.get("status"),"")),d.push(window.modalView.createDeleteButton("Delete",this.deleteCollection.bind(this))),d.push(window.modalView.createDeleteButton("Truncate",this.truncateCollection.bind(this))),c?d.push(window.modalView.createNotificationButton("Unload",this.unloadCollection.bind(this))):d.push(window.modalView.createNotificationButton("Load",this.loadCollection.bind(this))),d.push(window.modalView.createSuccessButton("Save",this.saveModifiedCollection.bind(this)));var a=["General","Indices"],b=["modalTable.ejs","indicesView.ejs"];window.modalView.show(b,"Modify Collection",d,e,null,null,this.events,null,a,"content"),$($("#infoTab").children()[1]).remove()}.bind(this);if(c){var g=function(a,b){if(a)arangoHelper.arangoError("Collection","Could not fetch properties");else{var c=b.journalSize/1048576,d=b.indexBuckets,g=b.waitForSync;e.push(window.modalView.createTextEntry("change-collection-size","Journal size",c,"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."}])),e.push(window.modalView.createTextEntry("change-index-buckets","Index buckets",d,"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."}])),e.push(window.modalView.createSelectEntry("change-collection-sync","Wait for sync",g,"Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}]))}f()}.bind(this);this.model.getProperties(g)}else f()}}.bind(this);window.isCoordinator(a)}})}(),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(a){this.options=a,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.SpotlightView=Backbone.View.extend({template:templateEngine.createTemplate("spotlightView.ejs"),el:"#spotlightPlaceholder",displayLimit:8,typeahead:null,callbackSuccess:null,callbackCancel:null,collections:{system:[],doc:[],edge:[]},events:{"focusout #spotlight .tt-input":"hide","keyup #spotlight .typeahead":"listenKey"},aqlKeywordsArray:[],aqlBuiltinFunctionsArray:[],aqlKeywords:"for|return|filter|sort|limit|let|collect|asc|desc|in|into|insert|update|remove|replace|upsert|options|with|and|or|not|distinct|graph|outbound|inbound|any|all|none|aggregate|like|count",aqlBuiltinFunctions:"to_bool|to_number|to_string|to_list|is_null|is_bool|is_number|is_string|is_list|is_document|typename|concat|concat_separator|char_length|lower|upper|substring|left|right|trim|reverse|contains|like|floor|ceil|round|abs|rand|sqrt|pow|length|min|max|average|sum|median|variance_population|variance_sample|first|last|unique|matches|merge|merge_recursive|has|attributes|values|unset|unset_recursive|keep|near|within|within_rectangle|is_in_polygon|fulltext|paths|traversal|traversal_tree|edges|stddev_sample|stddev_population|slice|nth|position|translate|zip|call|apply|push|append|pop|shift|unshift|remove_valueremove_nth|graph_paths|shortest_path|graph_shortest_path|graph_distance_to|graph_traversal|graph_traversal_tree|graph_edges|graph_vertices|neighbors|graph_neighbors|graph_common_neighbors|graph_common_properties|graph_eccentricity|graph_betweenness|graph_closeness|graph_absolute_eccentricity|remove_values|graph_absolute_betweenness|graph_absolute_closeness|graph_diameter|graph_radius|date_now|date_timestamp|date_iso8601|date_dayofweek|date_year|date_month|date_day|date_hour|date_minute|date_second|date_millisecond|date_dayofyear|date_isoweek|date_leapyear|date_quarter|date_days_in_month|date_add|date_subtract|date_diff|date_compare|date_format|fail|passthru|sleep|not_null|first_list|first_document|parse_identifier|current_user|current_database|collections|document|union|union_distinct|intersection|flatten|ltrim|rtrim|find_first|find_last|split|substitute|md5|sha1|hash|random_token|AQL_LAST_ENTRY",listenKey:function(a){27===a.keyCode?(this.callbackSuccess&&this.callbackCancel(),this.hide()):13===a.keyCode&&this.callbackSuccess&&(this.callbackSuccess($(this.typeahead).val()),this.hide())},substringMatcher:function(a){return function(b,c){var d,e;d=[],e=new RegExp(b,"i"),_.each(a,function(a){e.test(a)&&d.push(a)}),c(d)}},updateDatasets:function(){var a=this;this.collections={system:[],doc:[],edge:[]},window.App.arangoCollectionsStore.each(function(b){b.get("isSystem")?a.collections.system.push(b.get("name")):"document"===b.get("type")?a.collections.doc.push(b.get("name")):a.collections.edge.push(b.get("name"))})},stringToArray:function(){var a=this;_.each(this.aqlKeywords.split("|"),function(b){a.aqlKeywordsArray.push(b.toUpperCase())}),_.each(this.aqlBuiltinFunctions.split("|"),function(b){a.aqlBuiltinFunctionsArray.push(b.toUpperCase())}),a.aqlKeywordsArray.push(!0),a.aqlKeywordsArray.push(!1),a.aqlKeywordsArray.push(null)},show:function(a,b,c){this.callbackSuccess=a,this.callbackCancel=b,this.stringToArray(),this.updateDatasets();var d=function(a,b,c){var d='

    '+a+"

    ";return b&&(d+=''),c&&(d+=''+c.toUpperCase()+""),d+="
    "};$(this.el).html(this.template.render({})),$(this.el).show(),"aql"===c?this.typeahead=$("#spotlight .typeahead").typeahead({hint:!0,highlight:!0,minLength:1},{name:"Functions",source:this.substringMatcher(this.aqlBuiltinFunctionsArray),limit:this.displayLimit,templates:{header:d("Functions","fa-code","aql")}},{name:"Keywords",source:this.substringMatcher(this.aqlKeywordsArray),limit:this.displayLimit,templates:{header:d("Keywords","fa-code","aql")}},{name:"Documents",source:this.substringMatcher(this.collections.doc),limit:this.displayLimit,templates:{header:d("Documents","fa-file-text-o","Collection")}},{name:"Edges",source:this.substringMatcher(this.collections.edge),limit:this.displayLimit,templates:{header:d("Edges","fa-share-alt","Collection")}},{name:"System",limit:this.displayLimit,source:this.substringMatcher(this.collections.system),templates:{header:d("System","fa-cogs","Collection")}}):this.typeahead=$("#spotlight .typeahead").typeahead({hint:!0,highlight:!0,minLength:1},{name:"Documents",source:this.substringMatcher(this.collections.doc),limit:this.displayLimit,templates:{header:d("Documents","fa-file-text-o","Collection")}},{name:"Edges",source:this.substringMatcher(this.collections.edge),limit:this.displayLimit,templates:{header:d("Edges","fa-share-alt","Collection")}},{name:"System",limit:this.displayLimit,source:this.substringMatcher(this.collections.system),templates:{header:d("System","fa-cogs","Collection")}}),$("#spotlight .typeahead").focus()},hide:function(){$(this.el).hide(), -this.typeahead=$("#spotlight .typeahead").typeahead("destroy")}})}(),function(){"use strict";window.StatisticBarView=Backbone.View.extend({el:"#statisticBar",events:{"change #arangoCollectionSelect":"navigateBySelect","click .tab":"navigateByTab"},template:templateEngine.createTemplate("statisticBarView.ejs"),initialize:function(a){this.currentDB=a.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(a){this.rowClickCallback=a.rowClick},events:{"click .pure-table-body .pure-table-row":"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 #userLogoutIcon":"userLogout","click #userLogout":"userLogout"},initialize:function(a){this.userCollection=a.userCollection,this.userCollection.fetch({async:!0}),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())},toggleUserMenu:function(){$("#userBar .subBarDropdown").toggle()},showDropdown:function(){$("#user_dropdown").fadeIn(1)},hideDropdown:function(){$("#user_dropdown").fadeOut(1)},render:function(){if(frontendConfig.authenticationEnabled!==!1){var a=this,b=function(a,b){if(a)arangoHelper.arangoErro("User","Could not fetch user.");else{var c=null,d=null,e=!1,f=null;if(b!==!1)return f=this.userCollection.findWhere({user:b}),f.set({loggedIn:!0}),d=f.get("extra").name,c=f.get("extra").img,e=f.get("active"),c=c?"https://s.gravatar.com/avatar/"+c+"?s=80":"img/default_user.png",d||(d=""),this.$el=$("#userBar"),this.$el.html(this.template.render({img:c,name:d,username:b,active:e})),this.delegateEvents(),this.$el}}.bind(this);$("#userBar").on("click",function(){a.toggleUserMenu()}),this.userCollection.whoAmI(b)}},userLogout:function(){var a=function(a){a?arangoHelper.arangoError("User","Logout error"):this.userCollection.logout()}.bind(this);this.userCollection.whoAmI(a)}})}(),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(){var a=this,b=function(a,b){frontendConfig.authenticationEnabled===!0&&(a||null===b?arangoHelper.arangoError("User","Could not fetch user data"):this.currentUser=this.collection.findWhere({user:b}))}.bind(this);this.collection.fetch({success:function(){a.collection.whoAmI(b)}})},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){arangoHelper.parseError("User",b,a)},success:function(){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){if("createUser"!==$(a.currentTarget).find("a").attr("id")){$(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},toggleView:function(){$("#userSortDesc").attr("checked",this.collection.sortOptions.desc),$("#userManagementToggle").toggleClass("activated"),$("#userManagementDropdown2").slideToggle(200)},setFilterValues:function(){},evaluateUserName:function(a,b){if(a){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,e=function(a,e){a?arangoHelper.arangoError("User","Could not verify old password"):e&&(b!==c&&(arangoHelper.arangoError("User","New passwords do not match"),d=!0),d||(this.currentUser.setPassword(b),arangoHelper.arangoNotification("User","Password changed"),window.modalView.hide()))}.bind(this);this.currentUser.checkPassword(a,e)},submitEditCurrentUserProfile:function(){var a=$("#editCurrentName").val(),b=$("#editCurrentUserProfileImg").val();b=this.parseImgString(b);var c=function(a){a?arangoHelper.arangoError("User","Could not edit user settings"):(arangoHelper.arangoNotification("User","Changes confirmed."),this.updateUserProfile())}.bind(this);this.currentUser.setExtras(a,b,c),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({toUpdate:[],dbServers:[],isCluster:void 0,routes:{"":"cluster",dashboard:"dashboard",collections:"collections","new":"newCollection",login:"login","collection/:colid/documents/:pageid":"documents","cIndices/:colname":"cIndices","cSettings/:colname":"cSettings","cInfo/:colname":"cInfo","collection/:colid/:docid":"document",shell:"shell",queries:"query",workMonitor:"workMonitor",databases:"databases",settings:"databases",services:"applications","service/:mount":"applicationDetail",graphs:"graphManagement","graphs/:name":"showGraph",users:"userManagement",userProfile:"userProfile",cluster:"cluster",nodes:"cNodes",cNodes:"cNodes",dNodes:"dNodes",sNodes:"sNodes","node/:name":"node",logs:"logs",helpus:"helpUs"},execute:function(a,b){$("#subNavigationBar .breadcrumb").html(""),$("#subNavigationBar .bottom").html(""),$("#loadingScreen").hide(),$("#content").show(),a&&a.apply(this,b)},checkUser:function(){if("#login"!==window.location.hash){var a=function(){this.initOnce(),$(".bodyWrapper").show(),$(".navbar").show()}.bind(this),b=function(b,c){frontendConfig.authenticationEnabled&&(b||null===c)?"#login"!==window.location.hash&&this.navigate("login",{trigger:!0}):a()}.bind(this);frontendConfig.authenticationEnabled?this.userCollection.whoAmI(b):(this.initOnce(),$(".bodyWrapper").show(),$(".navbar").show())}},waitForInit:function(a,b,c){this.initFinished?(b||a(!0),b&&!c&&a(b,!0),b&&c&&a(b,c,!0)):setTimeout(function(){b||a(!1),b&&!c&&a(b,!1),b&&c&&a(b,c,!1)},350)},initFinished:!1,initialize:function(){frontendConfig.isCluster===!0&&(this.isCluster=!0),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(){};var b=function(b,c){a=this,c===!0&&a.coordinatorCollection.fetch({success:function(){a.fetchDBS()}})}.bind(this);window.isCoordinator(b),frontendConfig.isCluster===!1&&(this.initFinished=!0),this.arangoDatabase=new window.ArangoDatabase,this.currentDB=new window.CurrentDatabase,this.arangoCollectionsStore=new window.arangoCollections,this.arangoDocumentStore=new window.arangoDocument,this.coordinatorCollection=new window.ClusterCoordinators,arangoHelper.setDocumentStore(this.arangoDocumentStore),this.arangoCollectionsStore.fetch(),window.spotlightView=new window.SpotlightView({collection:this.arangoCollectionsStore}),this.footerView=new window.FooterView({collection:a.coordinatorCollection}),this.notificationList=new window.NotificationCollection,this.currentDB.fetch({success:function(){a.naviView=new window.NavigationView({database:a.arangoDatabase,currentDB:a.currentDB,notificationCollection:a.notificationList,userCollection:a.userCollection,isCluster:a.isCluster}),a.naviView.render()}}),this.queryCollection=new window.ArangoQueries,this.footerView.render(),window.checkVersion()}.bind(this),$(window).resize(function(){a.handleResize()}),$(window).scroll(function(){})},handleScroll:function(){$(window).scrollTop()>50?($(".navbar > .secondary").css("top",$(window).scrollTop()),$(".navbar > .secondary").css("position","absolute"),$(".navbar > .secondary").css("z-index","10"),$(".navbar > .secondary").css("width",$(window).width())):($(".navbar > .secondary").css("top","0"),$(".navbar > .secondary").css("position","relative"),$(".navbar > .secondary").css("width",""))},cluster:function(a){return this.checkUser(),a?this.isCluster===!1||void 0===this.isCluster?void("_system"===this.currentDB.get("name")?(this.routes[""]="dashboard",this.navigate("#dashboard",{trigger:!0})):(this.routes[""]="collections",this.navigate("#collections",{trigger:!0}))):(this.clusterView||(this.clusterView=new window.ClusterView({coordinators:this.coordinatorCollection,dbServers:this.dbServers})),void this.clusterView.render()):void this.waitForInit(this.cluster.bind(this))},node:function(a,b){return this.checkUser(),b&&void 0!==this.isCluster?this.isCluster===!1?(this.routes[""]="dashboard",void this.navigate("#dashboard",{trigger:!0})):(this.nodeView||(this.nodeView=new window.NodeView({coordname:a,coordinators:this.coordinatorCollection,dbServers:this.dbServers})),void this.nodeView.render()):void this.waitForInit(this.node.bind(this),a)},cNodes:function(a){return this.checkUser(),a&&void 0!==this.isCluster?this.isCluster===!1?(this.routes[""]="dashboard",void this.navigate("#dashboard",{trigger:!0})):(this.nodesView=new window.NodesView({coordinators:this.coordinatorCollection,dbServers:this.dbServers[0],toRender:"coordinator"}),void this.nodesView.render()):void this.waitForInit(this.cNodes.bind(this))},dNodes:function(a){return this.checkUser(),a&&void 0!==this.isCluster?this.isCluster===!1?(this.routes[""]="dashboard",void this.navigate("#dashboard",{trigger:!0})):0===this.dbServers.length?void this.navigate("#cNodes",{trigger:!0}):(this.nodesView=new window.NodesView({coordinators:this.coordinatorCollection,dbServers:this.dbServers[0],toRender:"dbserver"}),void this.nodesView.render()):void this.waitForInit(this.dNodes.bind(this))},sNodes:function(a){return this.checkUser(),a&&void 0!==this.isCluster?this.isCluster===!1?(this.routes[""]="dashboard",void this.navigate("#dashboard",{trigger:!0})):(this.scaleView=new window.ScaleView({coordinators:this.coordinatorCollection,dbServers:this.dbServers[0]}),void this.scaleView.render()):void this.waitForInit(this.sNodes.bind(this))},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))},logs:function(a,b){if(this.checkUser(),!b)return void this.waitForInit(this.logs.bind(this),a);if(!this.logsView){var c=new window.ArangoLogs({upto:!0,loglevel:4}),d=new window.ArangoLogs({loglevel:4}),e=new window.ArangoLogs({loglevel:3}),f=new window.ArangoLogs({loglevel:2}),g=new window.ArangoLogs({loglevel:1});this.logsView=new window.LogsView({logall:c,logdebug:d,loginfo:e,logwarning:f,logerror:g})}this.logsView.render()},applicationDetail:function(a,b){if(this.checkUser(),!b)return void this.waitForInit(this.applicationDetail.bind(this),a);var c=function(){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")}.bind(this);0===this.foxxList.length?this.foxxList.fetch({success:function(){c()}}):c()},login:function(){var a=function(a,b){this.loginView||(this.loginView=new window.loginView({collection:this.userCollection})),a||null===b?this.loginView.render():this.loginView.render(!0)}.bind(this);this.userCollection.whoAmI(a)},collections:function(a){if(this.checkUser(),!a)return void this.waitForInit(this.collections.bind(this));var b=this;this.collectionsView||(this.collectionsView=new window.CollectionsView({collection:this.arangoCollectionsStore})),this.arangoCollectionsStore.fetch({success:function(){b.collectionsView.render()}})},cIndices:function(a,b){var c=this;return this.checkUser(),b?void this.arangoCollectionsStore.fetch({success:function(){c.indicesView=new window.IndicesView({collectionName:a,collection:c.arangoCollectionsStore.findWhere({name:a})}),c.indicesView.render()}}):void this.waitForInit(this.cIndices.bind(this),a)},cSettings:function(a,b){var c=this;return this.checkUser(),b?void this.arangoCollectionsStore.fetch({success:function(){c.settingsView=new window.SettingsView({collectionName:a,collection:c.arangoCollectionsStore.findWhere({name:a})}),c.settingsView.render()}}):void this.waitForInit(this.cSettings.bind(this),a)},cInfo:function(a,b){var c=this;return this.checkUser(),b?void this.arangoCollectionsStore.fetch({success:function(){c.infoView=new window.InfoView({collectionName:a,collection:c.arangoCollectionsStore.findWhere({name:a})}),c.infoView.render()}}):void this.waitForInit(this.cInfo.bind(this),a)},documents:function(a,b,c){return this.checkUser(),c?(this.documentsView||(this.documentsView=new window.DocumentsView({collection:new window.arangoDocuments,documentStore:this.arangoDocumentStore,collectionsStore:this.arangoCollectionsStore})),this.documentsView.setCollectionId(a,b),void this.documentsView.render()):void this.waitForInit(this.documents.bind(this),a,b)},document:function(a,b,c){if(this.checkUser(),!c)return void this.waitForInit(this.document.bind(this),a,b);this.documentView||(this.documentView=new window.DocumentView({collection:this.arangoDocumentStore})),this.documentView.colid=a;var d=window.location.hash.split("/")[2],e=(d.split("%").length-1)%3;decodeURI(d)!==d&&0!==e&&(d=decodeURIComponent(d)),this.documentView.docid=d,this.documentView.render();var f=function(a,b){a?console.log("Error","Could not fetch collection type"):this.documentView.setType(b)}.bind(this);arangoHelper.collectionApiType(a,null,f)},shell:function(a){return this.checkUser(),a?(this.shellView||(this.shellView=new window.shellView),void this.shellView.render()):void this.waitForInit(this.shell.bind(this))},query:function(a){return this.checkUser(),a?(this.queryView2||(this.queryView2=new window.queryView2({collection:this.queryCollection})),void this.queryView2.render()):void this.waitForInit(this.query.bind(this)); +el2:".header",el3:".footer",loggedIn:!1,events:{"keyPress #loginForm input":"keyPress","click #submitLogin":"validate","submit #dbForm":"goTo","click #logout":"logout","change #loginDatabase":"renderDBS"},template:templateEngine.createTemplate("loginView.ejs"),render:function(a){var b=this;if($(this.el).html(this.template.render({})),$(this.el2).hide(),$(this.el3).hide(),frontendConfig.authenticationEnabled&&a!==!0)window.setTimeout(function(){$("#loginUsername").focus()},300);else{var c=arangoHelper.databaseUrl("/_api/database/user");frontendConfig.authenticationEnabled===!1&&($("#logout").hide(),$(".login-window #databases").css("height","90px")),$("#loginForm").hide(),$(".login-window #databases").show(),$.ajax(c).success(function(a){$("#loginDatabase").html(""),_.each(a.result,function(a){$("#loginDatabase").append("")}),b.renderDBS()})}return $(".bodyWrapper").show(),this},clear:function(){$("#loginForm input").removeClass("form-error"),$(".wrong-credentials").hide()},keyPress:function(a){a.ctrlKey&&13===a.keyCode?(a.preventDefault(),this.validate()):a.metaKey&&13===a.keyCode&&(a.preventDefault(),this.validate())},validate:function(a){a.preventDefault(),this.clear();var b=$("#loginUsername").val(),c=$("#loginPassword").val();if(b){var d=function(a){var b=this;if(a)$(".wrong-credentials").show(),$("#loginDatabase").html(""),$("#loginDatabase").append("");else{var c=arangoHelper.databaseUrl("/_api/database/user","_system");frontendConfig.authenticationEnabled===!1&&(c=arangoHelper.databaseUrl("/_api/database/user")),$(".wrong-credentials").hide(),b.loggedIn=!0,$.ajax(c).success(function(a){$("#loginForm").hide(),$("#databases").show(),$("#loginDatabase").html(""),_.each(a.result,function(a){$("#loginDatabase").append("")}),b.renderDBS()})}}.bind(this);this.collection.login(b,c,d)}},renderDBS:function(){var a=$("#loginDatabase").val();$("#goToDatabase").html("Select: "+a),window.setInterval(function(){$("#goToDatabase").focus()},300)},logout:function(){this.collection.logout()},goTo:function(a){a.preventDefault();var b=$("#loginUsername").val(),c=$("#loginDatabase").val();console.log(window.App.dbSet),window.App.dbSet=c,console.log(window.App.dbSet);var d=function(a){a&&arangoHelper.arangoError("User","Could not fetch user settings")},e=window.location.protocol+"//"+window.location.host+frontendConfig.basePath+"/_db/"+c+"/_admin/aardvark/index.html";window.location.href=e,$(this.el2).show(),$(this.el3).show(),$(".bodyWrapper").show(),$(".navbar").show(),$("#currentUser").text(b),this.collection.loadUserSettings(d)}})}(),function(){"use strict";window.LogsView=window.PaginationView.extend({el:"#content",id:"#logContent",paginationDiv:"#logPaginationDiv",idPrefix:"logTable",fetchedAmount:!1,initialize:function(a){this.options=a,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:[["All","logall"],["Info","loginfo"],["Error","logerror"],["Warning","logwarning"],["Debug","logdebug"]]},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,j){var k,l,m=this,n=!1;c=c||[],h=Boolean(h),this.clearValidators(),c.length>0?(c.forEach(function(a){a.type===m.buttons.CLOSE&&(n=!0),a.type===m.buttons.DELETE&&(l=l||a.confirm)}),n||(k=c.pop(),c.push(m.createCloseButton("Cancel")),c.push(k))):c.push(m.createCloseButton("Close")),j?($("#"+j).html(this.baseTemplate.render({title:b,buttons:c,hideFooter:this.hideFooter,confirm:l,tabBar:i})),$("#"+j+" #modal-dialog").removeClass("fade hide modal"),$("#"+j+" .modal-header").remove(),$("#"+j+" .modal-tabbar").remove(),$("#"+j+" .modal-tabbar").remove(),$("#"+j+" .button-close").remove(),0===$("#"+j+" .modal-footer").children().length&&$("#"+j+" .modal-footer").remove()):$(this.el).html(this.baseTemplate.render({title:b,buttons:c,hideFooter:this.hideFooter,confirm:l,tabBar:i})),_.each(c,function(a,b){return!a.disabled&&a.callback?a.type!==m.buttons.DELETE||h?void $("#modalButton"+b).bind("click",a.callback):void $("#modalButton"+b).bind("click",function(){$(m.confirm.yes).unbind("click"),$(m.confirm.yes).bind("click",a.callback),$(m.confirm.list).css("display","block")}):void 0}),$(this.confirm.no).bind("click",function(){$(m.confirm.list).css("display","none")});var o;if("string"==typeof a)o=templateEngine.createTemplate(a),j?$("#"+j+" .createModalDialog .modal-body").html(o.render({content:d,advancedContent:e,info:f})):$("#modalPlaceholder .createModalDialog .modal-body").html(o.render({content:d,advancedContent:e,info:f}));else{var p=0;_.each(a,function(a){o=templateEngine.createTemplate(a),$(".createModalDialog .modal-body .tab-content #"+i[p]).html(o.render({content:d,advancedContent:e,info:f})),p++})}$(".createModalDialog .modalTooltips").tooltip({position:{my:"left top",at:"right+55 top-1"}});var q=d||[];e&&e.content&&(q=q.concat(e.content)),_.each(q,function(a){m.modalBindValidation(a),a.type===m.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)),j||$("#modal-dialog").modal("show"),this.enabledHotkey===!1&&(this.createInitModalHotkeys(),this.enabledHotkey=!0),this.enableHotKeys&&this.createModalHotkeys();var r=$("#modal-dialog").find("input");r&&setTimeout(function(){var a=$("#modal-dialog");a.length>0&&(a=a.find("input"),a.length>0&&$(a[0]).focus())},400)},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",subEl:"#subNavigationBar",events:{"change #arangoCollectionSelect":"navigateBySelect","click .tab":"navigateByTab","click li":"switchTab","click .arangodbLogo":"selectMenuItem","mouseenter .dropdown > *":"showDropdown","click .shortcut-icons p":"showShortcutModal","mouseleave .dropdown":"hideDropdown"},renderFirst:!0,activeSubMenu:void 0,changeDB:function(){window.location.hash="#login"},initialize:function(a){var b=this;this.userCollection=a.userCollection,this.currentDB=a.currentDB,this.dbSelectionView=new window.DBSelectionView({collection:a.database,current:this.currentDB}),this.userBarView=new window.UserBarView({userCollection:this.userCollection}),this.notificationView=new window.NotificationView({collection:a.notificationCollection}),this.statisticBarView=new window.StatisticBarView({currentDB:this.currentDB}),this.isCluster=a.isCluster,this.handleKeyboardHotkeys(),Backbone.history.on("all",function(){b.selectMenuItem()})},showShortcutModal:function(){arangoHelper.hotkeysFunctions.showHotkeysModal()},handleSelectDatabase:function(){this.dbSelectionView.render($("#dbSelect"))},template:templateEngine.createTemplate("navigationView.ejs"),templateSub:templateEngine.createTemplate("subNavigationView.ejs"),render:function(){var a=this;$(this.el).html(this.template.render({currentDB:this.currentDB,isCluster:this.isCluster})),"_system"!==this.currentDB.get("name")&&$("#dashboard").parent().remove(),$(this.subEl).html(this.templateSub.render({currentDB:this.currentDB.toJSON()})),this.dbSelectionView.render($("#dbSelect"));var b=function(a){a||this.userBarView.render()}.bind(this);return this.userCollection.whoAmI(b),this.renderFirst&&(this.renderFirst=!1,this.selectMenuItem(),$(".arangodbLogo").on("click",function(){a.selectMenuItem()}),$("#dbStatus").on("click",function(){a.changeDB()})),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;$(b).hasClass("fa")||(""===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()})},subViewConfig:{documents:"collections",collection:"collections"},subMenuConfig:{cluster:[{name:"Dashboard",view:void 0,active:!0},{name:"Logs",view:void 0,disabled:!0}],collections:[{name:"",view:void 0,active:!1}],queries:[{name:"Editor",route:"query",active:!0},{name:"Running Queries",route:"queryManagement",params:{active:!0},active:void 0},{name:"Slow Query History",route:"queryManagement",params:{active:!1},active:void 0}]},renderSubMenu:function(a){var b=this;if(void 0===a&&(a=window.isCluster?"cluster":"dashboard"),this.subMenuConfig[a]){$(this.subEl+" .bottom").html("");var c="";_.each(this.subMenuConfig[a],function(a){c=a.active?"active":"",a.disabled&&(c="disabled"),$(b.subEl+" .bottom").append('"),a.disabled||$(b.subEl+" .bottom").children().last().bind("click",function(c){b.activeSubMenu=a,b.renderSubView(a,c)})})}},renderSubView:function(a,b){window.App[a.route]&&(window.App[a.route].resetState&&window.App[a.route].resetState(),window.App[a.route]()),$(this.subEl+" .bottom").children().removeClass("active"),$(b.currentTarget).addClass("active")},switchTab:function(a){var b=$(a.currentTarget).children().first().attr("id");b&&this.selectMenuItem(b+"-menu")},selectMenuItem:function(a,b){void 0===a&&(a=window.location.hash.split("/")[0],a=a.substr(1,a.length-1)),""===a?a=window.App.isCluster?"cluster":"dashboard":("cNodes"===a||"dNodes"===a)&&(a="nodes");try{this.renderSubMenu(a.split("-")[0])}catch(c){this.renderSubMenu(a)}$(".navlist li").removeClass("active"),"string"==typeof a&&(b?$("."+this.subViewConfig[a]+"-menu").addClass("active"):a&&($("."+a).addClass("active"),$("."+a+"-menu").addClass("active"))),arangoHelper.hideArangoNotifications()},showSubDropdown:function(a){console.log($(a.currentTarget)),console.log($(a.currentTarget).find(".subBarDropdown")),$(a.currentTarget).find(".subBarDropdown").toggle()},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.NodeView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("nodeView.ejs"),interval:5e3,dashboards:[],events:{},initialize:function(a){window.App.isCluster&&(this.coordinators=a.coordinators,this.dbServers=a.dbServers,this.coordname=a.coordname,this.updateServerTime(),window.setInterval(function(){if(0===window.location.hash.indexOf("#node/"));},this.interval))},breadcrumb:function(a){$("#subNavigationBar .breadcrumb").html("Node: "+a)},render:function(){this.$el.html(this.template.render({coords:[]}));var a=function(){this.continueRender(),this.breadcrumb(this.coordname),$(window).trigger("resize")}.bind(this),b=function(){console.log("")};this.initCoordDone||this.waitForCoordinators(b),this.initDBDone?(this.coordname=window.location.hash.split("/")[1],this.coordinator=this.coordinators.findWhere({name:this.coordname}),a()):this.waitForDBServers(a)},continueRender:function(){var a=this;this.dashboards[this.coordinator.get("name")]=new window.DashboardView({dygraphConfig:window.dygraphConfig,database:window.App.arangoDatabase,serverToShow:{raw:this.coordinator.get("address"),isDBServer:!1,endpoint:this.coordinator.get("protocol")+"://"+this.coordinator.get("address"),target:this.coordinator.get("name")}}),this.dashboards[this.coordinator.get("name")].render(),window.setTimeout(function(){a.dashboards[a.coordinator.get("name")].resize()},500)},waitForCoordinators:function(a){var b=this;window.setTimeout(function(){0===b.coordinators.length?b.waitForCoordinators(a):(b.coordinator=b.coordinators.findWhere({name:b.coordname}),b.initCoordDone=!0,a())},200)},waitForDBServers:function(a){var b=this;window.setTimeout(function(){0===b.dbServers[0].length?b.waitForDBServers(a):(b.initDBDone=!0,b.dbServer=b.dbServers[0],b.dbServer.each(function(a){"DBServer1"===a.get("name")&&(b.dbServer=a)}),a())},200)},updateServerTime:function(){this.serverTime=(new Date).getTime()}})}(),function(){"use strict";window.NodesView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("nodesView.ejs"),interval:5e3,knownServers:[],events:{"click #nodesContent .pure-table-body .pure-table-row":"navigateToNode"},initialize:function(a){window.App.isCluster&&(this.dbServers=a.dbServers,this.coordinators=a.coordinators,this.updateServerTime(),this.toRender=a.toRender,window.setInterval(function(){if("#cNodes"===window.location.hash||"#dNodes"===window.location.hash);},this.interval))},navigateToNode:function(a){if("#dNodes"!==window.location.hash){var b=$(a.currentTarget).attr("node");window.App.navigate("#node/"+encodeURIComponent(b),{trigger:!0})}},render:function(){var a=function(){this.continueRender()}.bind(this);this.initDoneCoords?a():this.waitForCoordinators(a)},continueRender:function(){var a;a="coordinator"===this.toRender?this.coordinators.toJSON():this.dbServers.toJSON(),this.$el.html(this.template.render({coords:a,type:this.toRender})),window.arangoHelper.buildNodesSubNav(this.toRender)},waitForCoordinators:function(a){var b=this;window.setTimeout(function(){0===b.coordinators.length?b.waitForCoordinators(a):(this.initDoneCoords=!0,a())},200)},updateServerTime:function(){this.serverTime=(new Date).getTime()}})}(),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)),window.setTimeout(function(){frontendConfig.authenticationEnabled===!1&&window.arangoHelper.arangoWarning("Warning","Authentication is disabled. Do not use this setup in production mode.")},2e3)},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,e=this.collection.at(this.collection.length-1),f=e.get("title"),g=3e3,h=["click"];if(e.get("content")&&(f=f+": "+e.get("content")),"error"===e.get("type")?(g=!1,h=["button"],d=[{addClass:"button-danger",text:"Close",onClick:function(a){a.close()}}]):"warning"===e.get("type")&&(g=2e4),$.noty.clearQueue(),$.noty.closeAll(),noty({theme:"relax",text:f,template:'
    ',maxVisible:1,closeWith:["click"],type:e.get("type"),layout:"bottom",timeout:g,buttons:d,animation:{open:{height:"show"},close:{height:"hide"},easing:"swing",speed:200,closeWith:h}}),"success"===e.get("type"))return void e.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(){"function"==typeof this.action&&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"),active:!0,shouldRender:!0,timer:0,refreshRate:2e3,initialize:function(){var a=this;this.activeCollection=new window.QueryManagementActive,this.slowCollection=new window.QueryManagementSlow,this.convertModelToJSON(!0),window.setInterval(function(){"#queries"===window.location.hash&&window.VISIBLE&&a.shouldRender&&"queryManagement"===arangoHelper.getCurrentSub().route&&(a.active?$("#arangoQueryManagementTable").is(":visible")&&a.convertModelToJSON(!0):$("#arangoQueryManagementTable").is(":visible")&&a.convertModelToJSON(!1))},a.refreshRate)},events:{"click #deleteSlowQueryHistory":"deleteSlowQueryHistoryModal","click #arangoQueryManagementTable .fa-minus-circle":"deleteRunningQueryModal"},tableDescription:{id:"arangoQueryManagementTable",titles:["ID","Query String","Runtime","Started",""],rows:[],unescaped:[!1,!1,!1,!1,!0]},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(){var a=arangoHelper.getCurrentSub();a.params.active?(this.active=!0,this.convertModelToJSON(!0)):(this.active=!1,this.convertModelToJSON(!1))},addEvents:function(){var a=this;$("#queryManagementContent tbody").on("mousedown",function(){clearTimeout(a.timer),a.shouldRender=!1}),$("#queryManagementContent tbody").on("mouseup",function(){a.timer=window.setTimeout(function(){a.shouldRender=!0},3e3)})},renderActive:function(){this.$el.html(this.templateActive.render({})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#activequeries").addClass("arango-active-tab"),this.addEvents()},renderSlow:function(){this.$el.html(this.templateSlow.render({})),$(this.id).append(this.table.render({content:this.tableDescription})),$("#slowqueries").addClass("arango-active-tab"),this.addEvents()},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({success:function(){a.updateLocalQueries(),a.renderSelectboxes(),a.updateTable(),a.allowUpload=!1,$("#customs-switch").click(),$("#confirmQueryImport").addClass("disabled"),$("#queryImportDialog").modal("hide")},error:function(a){arangoHelper.arangoError("Custom Queries",a.responseText)}})}.bind(this);a.collection.saveImportQueries(a.file,b.bind(this))}},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()).success(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(a){var b=this;this.collection.fetch({success:function(){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})});var e=function(a,b){a?arangoHelper.arangoError("Custom Queries","Could not import old local storage queries"):localStorage.removeItem("customQueries")}.bind(b);b.collection.saveCollectionQueries(e)}b.updateLocalQueries(),a&&a()}})},deleteAQL:function(a){var b=function(a){a?arangoHelper.arangoError("Query","Could not delete query."):(this.updateLocalQueries(),this.renderSelectboxes(),this.updateTable())}.bind(this),c=$(a.target).parent().parent().parent().children().first().text(),d=this.collection.findWhere({name:c});this.collection.remove(d),this.collection.saveCollectionQueries(b)},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})}var i=function(a){if(a)arangoHelper.arangoError("Query","Could not save query");else{var b=this;this.collection.fetch({success:function(){b.updateLocalQueries(),b.renderSelectboxes(),$("#querySelect").val(d)}})}}.bind(this);this.collection.saveCollectionQueries(i),window.modalView.hide()}},getSystemQueries:function(a){var b=this;$.ajax({type:"GET",cache:!1,url:"js/arango/aqltemplates.json",contentType:"application/json",processData:!1,success:function(c){a&&a(!1),b.queries=c},error:function(){a&&a(!0),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){var b=this,c=function(c){if(c)arangoHelper.arangoError("Query","Could not reload Queries");else if(b.updateLocalQueries(),a){var d=$("#querySelect").val();b.renderSelectboxes(),$("#querySelect").val(d)}}.bind(b),d=function(){b.getSystemQueries(c)}.bind(b);this.getAQL(d)},importSelected:function(a){var b=ace.edit("aqlEditor"),c=ace.edit("varsEditor");_.each(this.queries,function(d){$("#"+a.currentTarget.id).val()===d.name&&(b.setValue(d.value),d.hasOwnProperty("parameter")?((""===d.parameter||void 0===d.parameter)&&(d.parameter="{}"),"object"==typeof d.parameter?c.setValue(JSON.stringify(d.parameter)):c.setValue(d.parameter)):c.setValue("{}"))}),_.each(this.customQueries,function(d){$("#"+a.currentTarget.id).val()===d.name&&(b.setValue(d.value),d.hasOwnProperty("parameter")?((""===d.parameter||void 0===d.parameter||"{}"===JSON.stringify(d.parameter))&&(d.parameter="{}"),c.setValue(d.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="-";a&&a.extra&&a.extra.stats&&(e=a.extra.stats.executionTime.toFixed(3)+" s"),$(".queryExecutionTime").text("Execution time: "+e),c.deselect(d),$("#downloadQueryResult").show(),"function"==typeof b&&b()},h=function(){$.ajax({type:"PUT",url:arangoHelper.databaseUrl("/_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:arangoHelper.databaseUrl("/_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.queryView2=Backbone.View.extend({el:"#content",bindParamId:"#bindParamEditor",myQueriesId:"#queryTable",template:templateEngine.createTemplate("queryView2.ejs"),table:templateEngine.createTemplate("arangoTable.ejs"),outputDiv:"#outputEditors",outputTemplate:templateEngine.createTemplate("queryViewOutput.ejs"),outputCounter:0,allowUpload:!1,customQueries:[],queries:[],state:{lastQuery:{query:void 0,bindParam:void 0}},settings:{aqlWidth:void 0},currentQuery:{},initDone:!1,bindParamRegExp:/@(@?\w+\d*)/,bindParamTableObj:{},bindParamTableDesc:{id:"arangoBindParamTable",titles:["Key","Value"],rows:[]},myQueriesTableDesc:{id:"arangoMyQueriesTable",titles:["Name","Actions"],rows:[]},execPending:!1,aqlEditor:null,queryPreview:null,initialize:function(){this.refreshAQL()},allowParamToggle:!0,events:{"click #executeQuery":"executeQuery","click #explainQuery":"explainQuery","click #clearQuery":"clearQuery","click .outputEditorWrapper #downloadQueryResult":"downloadQueryResult","click .outputEditorWrapper .switchAce":"switchAce","click .outputEditorWrapper .fa-close":"closeResult","click #toggleQueries1":"toggleQueries","click #toggleQueries2":"toggleQueries","click #saveCurrentQuery":"addAQL","click #exportQuery":"exportCustomQueries","click #importQuery":"openImportDialog","click #removeResults":"removeResults","click #querySpotlight":"showSpotlight","click #deleteQuery":"selectAndDeleteQueryFromTable","click #explQuery":"selectAndExplainQueryFromTable","keydown #arangoBindParamTable input":"updateBindParams","change #arangoBindParamTable input":"updateBindParams","click #arangoMyQueriesTable tbody tr":"showQueryPreview","dblclick #arangoMyQueriesTable tbody tr":"selectQueryFromTable","click #arangoMyQueriesTable #copyQuery":"selectQueryFromTable","click #closeQueryModal":"closeExportDialog","click #confirmQueryImport":"importCustomQueries","click #switchTypes":"toggleBindParams","click #arangoMyQueriesTable #runQuery":"selectAndRunQueryFromTable"},clearQuery:function(){this.aqlEditor.setValue("",1)},toggleBindParams:function(){this.allowParamToggle?($("#bindParamEditor").toggle(),$("#bindParamAceEditor").toggle(),"JSON"===$("#switchTypes").text()?($("#switchTypes").text("Table"),this.updateQueryTable(),this.bindParamAceEditor.setValue(JSON.stringify(this.bindParamTableObj,null," "),1),this.deselect(this.bindParamAceEditor)):($("#switchTypes").text("JSON"),this.renderBindParamTable())):arangoHelper.arangoError("Bind parameter","Could not parse bind parameter"),this.resize()},openExportDialog:function(){$("#queryImportDialog").modal("show")},closeExportDialog:function(){$("#queryImportDialog").modal("hide")},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({success:function(){a.updateLocalQueries(),a.updateQueryTable(),a.resize(),a.allowUpload=!1,$("#confirmQueryImport").addClass("disabled"),$("#queryImportDialog").modal("hide")},error:function(a){arangoHelper.arangoError("Custom Queries",a.responseText)}})}.bind(this);a.collection.saveImportQueries(a.file,b.bind(this))}},removeResults:function(){$(".outputEditorWrapper").hide("fast",function(){$(".outputEditorWrapper").remove()}),$("#removeResults").hide()},getCustomQueryParameterByName:function(a){return this.collection.findWhere({name:a}).get("parameter")},getCustomQueryValueByName:function(a){var b;return a&&(b=this.collection.findWhere({name:a})),b?b=b.get("value"):_.each(this.queries,function(c){c.name===a&&(b=c.value)}),b},openImportDialog:function(){$("#queryImportDialog").modal("show")},closeImportDialog:function(){$("#queryImportDialog").modal("hide")},exportCustomQueries:function(){var a;$.ajax("whoAmI?_="+Date.now()).success(function(b){a=b.user,(null===a||a===!1)&&(a="root"),window.open("query/download/"+encodeURIComponent(a))})},toggleQueries:function(a){a&&"toggleQueries1"===a.currentTarget.id?(this.updateQueryTable(),$("#bindParamAceEditor").hide(),$("#bindParamEditor").show(),$("#switchTypes").text("JSON"),$(".aqlEditorWrapper").first().width(.33*$(window).width()),this.queryPreview.setValue("No query selected.",1),this.deselect(this.queryPreview)):void 0===this.settings.aqlWidth?$(".aqlEditorWrapper").first().width(.33*$(window).width()):$(".aqlEditorWrapper").first().width(this.settings.aqlWidth),this.resize();var b=["aqlEditor","queryTable","previewWrapper","querySpotlight","bindParamEditor","toggleQueries1","toggleQueries2","saveCurrentQuery","querySize","executeQuery","switchTypes","explainQuery","importQuery","exportQuery"];_.each(b,function(a){$("#"+a).toggle()}),this.resize()},showQueryPreview:function(a){$("#arangoMyQueriesTable tr").removeClass("selected"),$(a.currentTarget).addClass("selected");var b=this.getQueryNameFromTable(a);this.queryPreview.setValue(this.getCustomQueryValueByName(b),1),this.deselect(this.queryPreview)},getQueryNameFromTable:function(a){var b;return $(a.currentTarget).is("tr")?b=$(a.currentTarget).children().first().text():$(a.currentTarget).is("span")&&(b=$(a.currentTarget).parent().parent().prev().text()),b},deleteQueryModal:function(a){var b=[],c=[];c.push(window.modalView.createReadOnlyEntry(void 0,a,"Do you want to delete the query?",void 0,void 0,!1,void 0)),b.push(window.modalView.createDeleteButton("Delete",this.deleteAQL.bind(this,a))),window.modalView.show("modalTable.ejs","Delete Query",b,c)},selectAndDeleteQueryFromTable:function(a){var b=this.getQueryNameFromTable(a);this.deleteQueryModal(b)},selectAndExplainQueryFromTable:function(a){this.selectQueryFromTable(a,!1),this.explainQuery()},selectAndRunQueryFromTable:function(a){this.selectQueryFromTable(a,!1),this.executeQuery()},selectQueryFromTable:function(a,b){var c=this.getQueryNameFromTable(a),d=this;void 0===b&&this.toggleQueries(),this.state.lastQuery.query=this.aqlEditor.getValue(),this.state.lastQuery.bindParam=this.bindParamTableObj,this.aqlEditor.setValue(this.getCustomQueryValueByName(c),1),this.fillBindParamTable(this.getCustomQueryParameterByName(c)),this.updateBindParams(),$("#lastQuery").remove(),$("#queryContent .arangoToolbarTop .pull-left").append('Previous Query'),$("#lastQuery").hide().fadeIn(500).on("click",function(){d.aqlEditor.setValue(d.state.lastQuery.query,1),d.fillBindParamTable(d.state.lastQuery.bindParam),d.updateBindParams(),$("#lastQuery").fadeOut(500,function(){$(this).remove()})})},deleteAQL:function(a){var b=function(a){a?arangoHelper.arangoError("Query","Could not delete query."):(this.updateLocalQueries(),this.updateQueryTable(),this.resize(),window.modalView.hide())}.bind(this),c=this.collection.findWhere({name:a});this.collection.remove(c),this.collection.saveCollectionQueries(b)},switchAce:function(a){var b=$(a.currentTarget).attr("counter");"Result"===$(a.currentTarget).text()?$(a.currentTarget).text("AQL"):$(a.currentTarget).text("Result"),$("#outputEditor"+b).toggle(),$("#sentWrapper"+b).toggle(),this.deselect(ace.edit("outputEditor"+b)),this.deselect(ace.edit("sentQueryEditor"+b)),this.deselect(ace.edit("sentBindParamEditor"+b))},downloadQueryResult:function(a){var b=$(a.currentTarget).attr("counter"),c=ace.edit("sentQueryEditor"+b),d=c.getValue();""!==d||void 0!==d||null!==d?0===Object.keys(this.bindParamTableObj).length?window.open("query/result/download/"+encodeURIComponent(btoa(JSON.stringify({query:d})))):window.open("query/result/download/"+encodeURIComponent(btoa(JSON.stringify({query:d,bindVars:this.bindParamTableObj})))):arangoHelper.arangoError("Query error","could not query result.")},explainQuery:function(){if(!this.verifyQueryAndParams()){this.$(this.outputDiv).prepend(this.outputTemplate.render({counter:this.outputCounter,type:"Explain"}));var a=this.outputCounter,b=ace.edit("outputEditor"+a),c=ace.edit("sentQueryEditor"+a),d=ace.edit("sentBindParamEditor"+a);c.getSession().setMode("ace/mode/aql"),c.setOption("vScrollBarAlwaysVisible",!0),c.setReadOnly(!0),this.setEditorAutoHeight(c),b.setReadOnly(!0),b.getSession().setMode("ace/mode/json"),b.setOption("vScrollBarAlwaysVisible",!0),this.setEditorAutoHeight(b),d.setValue(JSON.stringify(this.bindParamTableObj),1),d.setOption("vScrollBarAlwaysVisible",!0),d.getSession().setMode("ace/mode/json"),d.setReadOnly(!0),this.setEditorAutoHeight(d),this.fillExplain(b,c,a),this.outputCounter++}},fillExplain:function(a,b,c){b.setValue(this.aqlEditor.getValue(),1);var d=this,e=this.readQueryData();if($("#outputEditorWrapper"+c+" .queryExecutionTime").text(""),this.execPending=!1,e){var f=function(){$("#outputEditorWrapper"+c+" #spinner").remove(),$("#outputEditor"+c).css("opacity","1"),$("#outputEditorWrapper"+c+" .fa-close").show(),$("#outputEditorWrapper"+c+" .switchAce").show()};$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_admin/aardvark/query/explain/"),data:e,contentType:"application/json",processData:!1,success:function(b){b.msg.includes("errorMessage")?(d.removeOutputEditor(c),arangoHelper.arangoError("Explain",b.msg)):(a.setValue(b.msg,1),d.deselect(a),$.noty.clearQueue(),$.noty.closeAll(),d.handleResult(c)),f()},error:function(a){try{var b=JSON.parse(a.responseText);arangoHelper.arangoError("Explain",b.errorMessage)}catch(e){arangoHelper.arangoError("Explain","ERROR")}d.handleResult(c),d.removeOutputEditor(c),f()}})}},removeOutputEditor:function(a){$("#outputEditorWrapper"+a).hide(),$("#outputEditorWrapper"+a).remove(),0===$(".outputEditorWrapper").length&&$("#removeResults").hide()},getCachedQueryAfterRender:function(){var a=this.getCachedQuery(),b=this;if(null!==a&&void 0!==a&&""!==a&&(this.aqlEditor.setValue(a.query,1),this.aqlEditor.getSession().setUndoManager(new ace.UndoManager),""!==a.parameter||void 0!==a))try{b.bindParamTableObj=JSON.parse(a.parameter);var c;_.each($("#arangoBindParamTable input"),function(a){c=$(a).attr("name"),$(a).val(b.bindParamTableObj[c])}),b.setCachedQuery(b.aqlEditor.getValue(),JSON.stringify(b.bindParamTableObj))}catch(d){}},getCachedQuery:function(){if("undefined"!==Storage){var a=localStorage.getItem("cachedQuery");if(void 0!==a){var b=JSON.parse(a);this.currentQuery=b;try{this.bindParamTableObj=JSON.parse(b.parameter)}catch(c){}return b}}},setCachedQuery:function(a,b){if("undefined"!==Storage){var c={query:a,parameter:b};this.currentQuery=c,localStorage.setItem("cachedQuery",JSON.stringify(c))}},closeResult:function(a){var b=$("#"+$(a.currentTarget).attr("element")).parent();$(b).hide("fast",function(){$(b).remove(),0===$(".outputEditorWrapper").length&&$("#removeResults").hide()})},fillSelectBoxes:function(){var a=1e3,b=$("#querySize");b.empty(),[100,250,500,1e3,2500,5e3,1e4,"all"].forEach(function(c){b.append('")})},render:function(){this.$el.html(this.template.render({})),this.afterRender(),this.initDone||(this.settings.aqlWidth=$(".aqlEditorWrapper").width()),this.initDone=!0,this.renderBindParamTable(!0)},afterRender:function(){var a=this;this.initAce(),this.initTables(),this.fillSelectBoxes(),this.makeResizeable(),this.initQueryImport(),this.getCachedQueryAfterRender(),$(".inputEditorWrapper").height($(window).height()/10*5+25),window.setTimeout(function(){a.resize()},10),a.deselect(a.aqlEditor)},showSpotlight:function(a){var b,c;if((void 0===a||"click"===a.type)&&(a="aql"),"aql"===a)b=function(a){this.aqlEditor.insert(a),$("#aqlEditor .ace_text-input").focus()}.bind(this),c=function(){$("#aqlEditor .ace_text-input").focus()};else{var d=$(":focus");b=function(a){var b=$(d).val();$(d).val(b+a),$(d).focus()}.bind(this),c=function(){$(d).focus()}}window.spotlightView.show(b,c,a)},resize:function(){this.resizeFunction()},resizeFunction:function(){$("#toggleQueries1").is(":visible")?(this.aqlEditor.resize(),$("#arangoBindParamTable thead").css("width",$("#bindParamEditor").width()),$("#arangoBindParamTable thead th").css("width",$("#bindParamEditor").width()/2),$("#arangoBindParamTable tr").css("width",$("#bindParamEditor").width()),$("#arangoBindParamTable tbody").css("height",$("#aqlEditor").height()-35),$("#arangoBindParamTable tbody").css("width",$("#bindParamEditor").width()),$("#arangoBindParamTable tbody tr").css("width",$("#bindParamEditor").width()),$("#arangoBindParamTable tbody td").css("width",$("#bindParamEditor").width()/2)):(this.queryPreview.resize(),$("#arangoMyQueriesTable thead").css("width",$("#queryTable").width()),$("#arangoMyQueriesTable thead th").css("width",$("#queryTable").width()/2),$("#arangoMyQueriesTable tr").css("width",$("#queryTable").width()),$("#arangoMyQueriesTable tbody").css("height",$("#queryTable").height()-35),$("#arangoMyQueriesTable tbody").css("width",$("#queryTable").width()),$("#arangoMyQueriesTable tbody td").css("width",$("#queryTable").width()/2))},makeResizeable:function(){var a=this;$(".aqlEditorWrapper").resizable({resize:function(){a.resizeFunction(),a.settings.aqlWidth=$(".aqlEditorWrapper").width()},handles:"e"}),$(".inputEditorWrapper").resizable({resize:function(){a.resizeFunction()},handles:"s"}),this.resizeFunction()},initTables:function(){this.$(this.bindParamId).html(this.table.render({content:this.bindParamTableDesc})),this.$(this.myQueriesId).html(this.table.render({content:this.myQueriesTableDesc}))},checkType:function(a){var b="stringtype";try{a=JSON.parse(a),b=a instanceof Array?"arraytype":typeof a+"type"}catch(c){}return b},updateBindParams:function(a){var b,c=this;if(a){b=$(a.currentTarget).attr("name"),this.bindParamTableObj[b]=arangoHelper.parseInput(a.currentTarget);var d=["arraytype","objecttype","booleantype","numbertype","stringtype"];_.each(d,function(b){$(a.currentTarget).removeClass(b)}),$(a.currentTarget).addClass(c.checkType($(a.currentTarget).val()))}else _.each($("#arangoBindParamTable input"),function(a){b=$(a).attr("name"),c.bindParamTableObj[b]=arangoHelper.parseInput(a)});this.setCachedQuery(this.aqlEditor.getValue(),JSON.stringify(this.bindParamTableObj)),a&&((a.ctrlKey||a.metaKey)&&13===a.keyCode&&(a.preventDefault(),this.executeQuery()),(a.ctrlKey||a.metaKey)&&32===a.keyCode&&(a.preventDefault(),this.showSpotlight("bind")))},parseQuery:function(a){var b=0,c=1,d=2,e=3,f=4,g=5,h=6,i=7;a+=" ";var j,k,l,m=this,n=b,o=a.length,p=[];for(k=0;o>k;++k)switch(l=a.charAt(k),n){case b:"@"===l?(n=h,j=k):"'"===l?n=c:'"'===l?n=d:"`"===l?n=e:"´"===l?n=i:"/"===l&&o>k+1&&("/"===a.charAt(k+1)?(n=f,++k):"*"===a.charAt(k+1)&&(n=g,++k));break;case f:("\r"===l||"\n"===l)&&(n=b);break;case g:"*"===l&&o>=k+1&&"/"===a.charAt(k+1)&&(n=b,++k);break;case c:"\\"===l?++k:"'"===l&&(n=b);break;case d:"\\"===l?++k:'"'===l&&(n=b);break;case e:"`"===l&&(n=b);break;case i:"´"===l&&(n=b);break;case h:/^[@a-zA-Z0-9_]+$/.test(l)||(p.push(a.substring(j,k)),n=b,j=void 0)}var q;return _.each(p,function(a,b){q=a.match(m.bindParamRegExp),q&&(p[b]=q[1])}),{query:a,bindParams:p}},checkForNewBindParams:function(){var a=this,b=this.parseQuery(this.aqlEditor.getValue()).bindParams,c={};_.each(b,function(b){a.bindParamTableObj[b]?c[b]=a.bindParamTableObj[b]:c[b]=""}),Object.keys(b).forEach(function(b){Object.keys(a.bindParamTableObj).forEach(function(d){b===d&&(c[b]=a.bindParamTableObj[d])})}),a.bindParamTableObj=c},renderBindParamTable:function(a){$("#arangoBindParamTable tbody").html(""),a&&this.getCachedQuery();var b=0;_.each(this.bindParamTableObj,function(a,c){$("#arangoBindParamTable tbody").append(""+c+"'),b++,_.each($("#arangoBindParamTable input"),function(b){$(b).attr("name")===c&&(a instanceof Array?$(b).val(JSON.stringify(a)).addClass("arraytype"):"object"==typeof a?$(b).val(JSON.stringify(a)).addClass(typeof a+"type"):$(b).val(a).addClass(typeof a+"type"))})}),0===b&&$("#arangoBindParamTable tbody").append('No bind parameters defined.')},fillBindParamTable:function(a){_.each(a,function(a,b){_.each($("#arangoBindParamTable input"),function(c){$(c).attr("name")===b&&$(c).val(a)})})},initAce:function(){var a=this;this.aqlEditor=ace.edit("aqlEditor"),this.aqlEditor.getSession().setMode("ace/mode/aql"),this.aqlEditor.setFontSize("10pt"),this.aqlEditor.setShowPrintMargin(!1),this.bindParamAceEditor=ace.edit("bindParamAceEditor"),this.bindParamAceEditor.getSession().setMode("ace/mode/json"),this.bindParamAceEditor.setFontSize("10pt"),this.bindParamAceEditor.setShowPrintMargin(!1),this.bindParamAceEditor.getSession().on("change",function(){try{a.bindParamTableObj=JSON.parse(a.bindParamAceEditor.getValue()),a.allowParamToggle=!0,a.setCachedQuery(a.aqlEditor.getValue(),JSON.stringify(a.bindParamTableObj))}catch(b){""===a.bindParamAceEditor.getValue()?(_.each(a.bindParamTableObj,function(b,c){a.bindParamTableObj[c]=""}),a.allowParamToggle=!0):a.allowParamToggle=!1}}),this.aqlEditor.getSession().on("change",function(){a.checkForNewBindParams(),a.renderBindParamTable(),a.initDone&&a.setCachedQuery(a.aqlEditor.getValue(),JSON.stringify(a.bindParamTableObj)),a.bindParamAceEditor.setValue(JSON.stringify(a.bindParamTableObj,null," "),1),$("#aqlEditor .ace_text-input").focus(),a.resize()}),this.aqlEditor.commands.addCommand({name:"togglecomment",bindKey:{win:"Ctrl-Shift-C",linux:"Ctrl-Shift-C",mac:"Command-Shift-C"},exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEach"}),this.aqlEditor.commands.addCommand({name:"executeQuery",bindKey:{win:"Ctrl-Return",mac:"Command-Return",linux:"Ctrl-Return"},exec:function(){a.executeQuery()}}),this.aqlEditor.commands.addCommand({name:"saveQuery",bindKey:{win:"Ctrl-Shift-S",mac:"Command-Shift-S",linux:"Ctrl-Shift-S"},exec:function(){a.addAQL()}}),this.aqlEditor.commands.addCommand({name:"explainQuery",bindKey:{win:"Ctrl-Shift-Return",mac:"Command-Shift-Return",linux:"Ctrl-Shift-Return"},exec:function(){a.explainQuery()}}),this.aqlEditor.commands.addCommand({name:"togglecomment",bindKey:{win:"Ctrl-Shift-C",linux:"Ctrl-Shift-C",mac:"Command-Shift-C"},exec:function(a){a.toggleCommentLines()},multiSelectAction:"forEach"}),this.aqlEditor.commands.addCommand({name:"showSpotlight",bindKey:{win:"Ctrl-Space",mac:"Ctrl-Space",linux:"Ctrl-Space"},exec:function(){a.showSpotlight()}}),this.queryPreview=ace.edit("queryPreview"),this.queryPreview.getSession().setMode("ace/mode/aql"),this.queryPreview.setReadOnly(!0),this.queryPreview.setFontSize("13px"), +$("#aqlEditor .ace_text-input").focus()},updateQueryTable:function(){function a(a,b){var c;return c=a.nameb.name?1:0}var b=this;this.updateLocalQueries(),this.myQueriesTableDesc.rows=this.customQueries,_.each(this.myQueriesTableDesc.rows,function(a){a.secondRow='
    ',a.hasOwnProperty("parameter")&&delete a.parameter,delete a.value}),this.myQueriesTableDesc.rows.sort(a),_.each(this.queries,function(a){a.hasOwnProperty("parameter")&&delete a.parameter,b.myQueriesTableDesc.rows.push({name:a.name,thirdRow:''})}),this.myQueriesTableDesc.unescaped=[!1,!0,!0],this.$(this.myQueriesId).html(this.table.render({content:this.myQueriesTableDesc}))},listenKey:function(a){13===a.keyCode&&this.saveAQL(a),this.checkSaveName()},addAQL:function(){this.refreshAQL(!0),this.createCustomQueryModal(),setTimeout(function(){$("#new-query-name").focus()},500)},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)})},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"))},saveAQL:function(a){a.stopPropagation(),this.refreshAQL();var b=$("#new-query-name").val(),c=this.bindParamTableObj;if(!$("#new-query-name").hasClass("invalid-input")&&""!==b.trim()){var d=this.aqlEditor.getValue(),e=!1;if(_.each(this.customQueries,function(a){return a.name===b?(a.value=d,void(e=!0)):void 0}),e===!0)this.collection.findWhere({name:b}).set("value",d);else{if((""===c||void 0===c)&&(c="{}"),"string"==typeof c)try{c=JSON.parse(c)}catch(f){arangoHelper.arangoError("Query","Could not parse bind parameter")}this.collection.add({name:b,parameter:c,value:d})}var g=function(a){if(a)arangoHelper.arangoError("Query","Could not save query");else{var b=this;this.collection.fetch({success:function(){b.updateLocalQueries()}})}}.bind(this);this.collection.saveCollectionQueries(g),window.modalView.hide()}},verifyQueryAndParams:function(){var a=!1;0===this.aqlEditor.getValue().length&&(arangoHelper.arangoError("Query","Your query is empty"),a=!0);var b=[];return _.each(this.bindParamTableObj,function(c,d){""===c&&(a=!0,b.push(d))}),b.length>0&&arangoHelper.arangoError("Bind Parameter",JSON.stringify(b)+" not defined."),a},executeQuery:function(){if(!this.verifyQueryAndParams()){this.$(this.outputDiv).prepend(this.outputTemplate.render({counter:this.outputCounter,type:"Query"})),$("#outputEditorWrapper"+this.outputCounter).hide(),$("#outputEditorWrapper"+this.outputCounter).show("fast");var a=this.outputCounter,b=ace.edit("outputEditor"+a),c=ace.edit("sentQueryEditor"+a),d=ace.edit("sentBindParamEditor"+a);c.getSession().setMode("ace/mode/aql"),c.setOption("vScrollBarAlwaysVisible",!0),c.setFontSize("13px"),c.setReadOnly(!0),this.setEditorAutoHeight(c),b.setFontSize("13px"),b.getSession().setMode("ace/mode/json"),b.setReadOnly(!0),b.setOption("vScrollBarAlwaysVisible",!0),b.setShowPrintMargin(!1),this.setEditorAutoHeight(b),d.setValue(JSON.stringify(this.bindParamTableObj),1),d.setOption("vScrollBarAlwaysVisible",!0),d.getSession().setMode("ace/mode/json"),d.setReadOnly(!0),this.setEditorAutoHeight(d),this.fillResult(b,c,a),this.outputCounter++}},readQueryData:function(){var a=this.aqlEditor.session.getTextRange(this.aqlEditor.getSelectionRange()),b=$("#querySize"),c={query:a||this.aqlEditor.getValue(),id:"currentFrontendQuery"};return"all"===b.val()?c.batchSize=1e6:c.batchSize=parseInt(b.val(),10),Object.keys(this.bindParamTableObj).length>0&&(c.bindVars=this.bindParamTableObj),JSON.stringify(c)},fillResult:function(a,b,c){var d=this,e=this.readQueryData();e&&(b.setValue(d.aqlEditor.getValue(),1),$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_api/cursor"),headers:{"x-arango-async":"store"},data:e,contentType:"application/json",processData:!1,success:function(b,e,f){f.getResponseHeader("x-arango-async-id")&&d.queryCallbackFunction(f.getResponseHeader("x-arango-async-id"),a,c),$.noty.clearQueue(),$.noty.closeAll(),d.handleResult(c)},error:function(a){try{var b=JSON.parse(a.responseText);arangoHelper.arangoError("["+b.errorNum+"]",b.errorMessage)}catch(e){arangoHelper.arangoError("Query error","ERROR")}d.handleResult(c)}}))},handleResult:function(){window.progressView.hide(),$("#removeResults").show(),$(".centralRow").animate({scrollTop:$("#queryContent").height()},"fast")},setEditorAutoHeight:function(a){var b=$(".centralRow").height(),c=(b-250)/17;a.setOptions({maxLines:c,minLines:10})},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()},queryCallbackFunction:function(a,b,c){var d=this,e=function(a,b){$.ajax({url:arangoHelper.databaseUrl("/_api/job/"+encodeURIComponent(a)+"/cancel"),type:"PUT",success:function(){window.clearTimeout(d.checkQueryTimer),$("#outputEditorWrapper"+b).remove(),arangoHelper.arangoNotification("Query","Query canceled.")}})};$("#outputEditorWrapper"+c+" #cancelCurrentQuery").bind("click",function(){e(a,c)}),$("#outputEditorWrapper"+c+" #copy2aqlEditor").bind("click",function(){$("#toggleQueries1").is(":visible")||d.toggleQueries();var a=ace.edit("sentQueryEditor"+c).getValue(),b=JSON.parse(ace.edit("sentBindParamEditor"+c).getValue());d.aqlEditor.setValue(a,1),d.deselect(d.aqlEditor),Object.keys(b).length>0&&(d.bindParamTableObj=b,d.setCachedQuery(d.aqlEditor.getValue(),JSON.stringify(d.bindParamTableObj)),$("#bindParamEditor").is(":visible")?d.renderBindParamTable():(d.bindParamAceEditor.setValue(JSON.stringify(b),1),d.deselect(d.bindParamAceEditor))),$(".centralRow").animate({scrollTop:0},"fast"),d.resize()}),this.execPending=!1;var f=function(a){var c="";a.extra&&a.extra.warnings&&a.extra.warnings.length>0&&(c+="Warnings:\r\n\r\n",a.extra.warnings.forEach(function(a){c+="["+a.code+"], '"+a.message+"'\r\n"})),""!==c&&(c+="\r\nResult:\r\n\r\n"),b.setValue(c+JSON.stringify(a.result,void 0,2),1),b.getSession().setScrollTop(0)},g=function(a){f(a),window.progressView.hide();var e=function(a,b){$("#outputEditorWrapper"+c+" .arangoToolbarTop .pull-left").append(''+a+"")};$("#outputEditorWrapper"+c+" .pull-left #spinner").remove();var g="-";a&&a.extra&&a.extra.stats&&(g=a.extra.stats.executionTime.toFixed(3)+" s"),e(a.result.length+" elements","fa-calculator"),e(g,"fa-clock-o"),a.extra&&a.extra.stats&&(console.log(a.result.length),(a.extra.stats.writesExecuted>0||a.extra.stats.writesIgnored>0)&&(e(a.extra.stats.writesExecuted+" writes","fa-check-circle positive"),0===a.extra.stats.writesIgnored?e(a.extra.stats.writesIgnored+" writes ignored","fa-check-circle positive"):e(a.extra.stats.writesIgnored+" writes ignored","fa-exclamation-circle warning")),a.extra.stats.scannedFull>0?e("full collection scan","fa-exclamation-circle warning"):e("no full collection scan","fa-check-circle positive")),$("#outputEditorWrapper"+c+" .switchAce").show(),$("#outputEditorWrapper"+c+" .fa-close").show(),$("#outputEditor"+c).css("opacity","1"),$("#outputEditorWrapper"+c+" #downloadQueryResult").show(),$("#outputEditorWrapper"+c+" #copy2aqlEditor").show(),$("#outputEditorWrapper"+c+" #cancelCurrentQuery").remove(),d.setEditorAutoHeight(b),d.deselect(b),a.id&&$.ajax({url:"/_api/cursor/"+encodeURIComponent(a.id),type:"DELETE",error:function(a){console.log(a)}})},h=function(){$.ajax({type:"PUT",url:arangoHelper.databaseUrl("/_api/job/"+encodeURIComponent(a)),contentType:"application/json",processData:!1,success:function(a,b,c){201===c.status?g(a):204===c.status&&(d.checkQueryTimer=window.setTimeout(function(){h()},500))},error:function(a){var b;try{if("Gone"===a.statusText)return arangoHelper.arangoNotification("Query","Query execution aborted."),void d.removeOutputEditor(c);b=JSON.parse(a.responseText),arangoHelper.arangoError("Query",b.errorMessage),b.errorMessage&&(null!==b.errorMessage.match(/\d+:\d+/g)?d.markPositionError(b.errorMessage.match(/'.*'/g)[0],b.errorMessage.match(/\d+:\d+/g)[0]):d.markPositionError(b.errorMessage.match(/\(\w+\)/g)[0]),d.removeOutputEditor(c))}catch(e){console.log(b),400!==b.code&&arangoHelper.arangoError("Query","Successfully aborted."),d.removeOutputEditor(c)}window.progressView.hide()}})};h()},markPositionError:function(a,b){var c;b&&(c=b.split(":")[0],a=a.substr(1,a.length-2));var d=this.aqlEditor.find(a);!d&&b&&(this.aqlEditor.selection.moveCursorToPosition({row:c,column:0}),this.aqlEditor.selection.selectLine()),window.setTimeout(function(){$(".ace_start").first().css("background","rgba(255, 129, 129, 0.7)")},100)},refreshAQL:function(){var a=this,b=function(b){b?arangoHelper.arangoError("Query","Could not reload Queries"):(a.updateLocalQueries(),a.updateQueryTable())}.bind(a),c=function(){a.getSystemQueries(b)}.bind(a);this.getAQL(c)},getSystemQueries:function(a){var b=this;$.ajax({type:"GET",cache:!1,url:"js/arango/aqltemplates.json",contentType:"application/json",processData:!1,success:function(c){a&&a(!1),b.queries=c},error:function(){a&&a(!0),arangoHelper.arangoNotification("Query","Error while loading system templates")}})},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")})})},getAQL:function(a){var b=this;this.collection.fetch({success:function(){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})});var e=function(a){a?arangoHelper.arangoError("Custom Queries","Could not import old local storage queries"):localStorage.removeItem("customQueries")}.bind(b);b.collection.saveCollectionQueries(e)}b.updateLocalQueries(),a&&a()}})}})}(),function(){"use strict";window.ScaleView=Backbone.View.extend({el:"#content",template:templateEngine.createTemplate("scaleView.ejs"),interval:5e3,knownServers:[],events:{"click #addCoord":"addCoord","click #removeCoord":"removeCoord","click #addDBs":"addDBs","click #removeDBs":"removeDBs"},setCoordSize:function(a){$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_admin/cluster/setCoordSize"),contentType:"application/json",data:JSON.stringify({value:a}),success:function(){$("#plannedCoords").html(a)},error:function(){arangoHelper.arangoError("Scale","Could not set coordinator size.")}})},setDBsSize:function(a){$.ajax({type:"POST",url:arangoHelper.databaseUrl("/_admin/cluster/setDBsSize"),contentType:"application/json",data:JSON.stringify({value:a}),success:function(){$("#plannedCoords").html(a)},error:function(){arangoHelper.arangoError("Scale","Could not set coordinator size.")}})},addCoord:function(){this.setCoordSize(this.readNumberFromID("#plannedCoords",!0))},removeCoord:function(){this.setCoordSize(this.readNumberFromID("#plannedCoords",!1,!0))},addDBs:function(){this.setDBsSize(this.readNumberFromID("#plannedDBs",!0))},removeDBs:function(){this.setDBsSize(this.readNumberFromID("#plannedDBs",!1,!0))},readNumberFromID:function(a,b,c){var d=$(a).html(),e=!1;try{e=JSON.parse(d)}catch(f){}return b&&e++,c&&1!==e&&e--,e},initialize:function(a){window.App.isCluster&&(this.dbServers=a.dbServers,this.coordinators=a.coordinators,this.updateServerTime(),window.setInterval(function(){if("#sNodes"===window.location.hash);},this.interval))},render:function(){var a=this,b=function(){var b=function(){a.continueRender()}.bind(this);this.waitForDBServers(b)}.bind(this);this.initDoneCoords?b():this.waitForCoordinators(b),window.arangoHelper.buildNodesSubNav("scale")},continueRender:function(){var a,b,c=this;a=this.coordinators.toJSON(),b=this.dbServers.toJSON(),this.$el.html(this.template.render({runningCoords:a.length,runningDBs:b.length,plannedCoords:void 0,plannedDBs:void 0})),$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_admin/cluster/numberOfServers"),contentType:"application/json",processData:!1,success:function(a){c.updateTable(a)}})},updateTable:function(a){$("#plannedCoords").html(a.numberOfCoordinators),$("#plannedDBs").html(a.numberOfDBServers);var b='scaling in progress',c='no scaling process active';this.coordinators.toJSON().length===a.numberOfCoordinators?$("#statusCoords").html(c):$("#statusCoords").html(b),this.dbServers.toJSON().length===a.numberOfDBServers?$("#statusDBs").html(c):$("#statusDBs").html(b)},waitForDBServers:function(a){var b=this;0===this.dbServers.length?window.setInterval(function(){b.waitForDBServers(a)},300):a()},waitForCoordinators:function(a){var b=this;window.setTimeout(function(){0===b.coordinators.length?b.waitForCoordinators(a):(this.initDoneCoords=!0,a())},200)},updateServerTime:function(){this.serverTime=(new Date).getTime()}})}(),function(){"use strict";window.SettingsView=Backbone.View.extend({el:"#content",initialize:function(a){this.collectionName=a.collectionName,this.model=this.collection},events:{},render:function(){this.breadcrumb(),window.arangoHelper.buildCollectionSubNav(this.collectionName,"Settings"),this.renderSettings()},breadcrumb:function(){$("#subNavigationBar .breadcrumb").html("Collection: "+this.collectionName)},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(),window.modalView.hide()},deleteCollection:function(){this.model.destroy({error:function(){arangoHelper.arangoError("Could not delete collection.")},success:function(){window.App.navigate("#collections",{trigger:!0})}})},saveModifiedCollection:function(){var a=function(a,b){if(a)arangoHelper.arangoError("Error","Could not get coordinator info");else{var c;c=b?this.model.get("name"):$("#change-collection-name").val();var d=this.model.get("status");if("loaded"===d){var e;try{e=JSON.parse(1024*$("#change-collection-size").val()*1024)}catch(f){return arangoHelper.arangoError("Please enter a valid number"),0}var g;try{if(g=JSON.parse($("#change-index-buckets").val()),1>g||parseInt(g)!==Math.pow(2,Math.log2(g)))throw"invalid indexBuckets value"}catch(f){return arangoHelper.arangoError("Please enter a valid number of index buckets"),0}var h=function(a){a?arangoHelper.arangoError("Collection error: "+a.responseText):(this.collectionsView.render(),window.modalView.hide())}.bind(this),i=function(a){if(a)arangoHelper.arangoError("Collection error: "+a.responseText);else{var b=$("#change-collection-sync").val();this.model.changeCollection(b,e,g,h)}}.bind(this);this.model.renameCollection(c,i)}else if("unloaded"===d)if(this.model.get("name")!==c){var j=function(a,b){a?arangoHelper.arangoError("Collection error: "+b.responseText):(this.collectionsView.render(),window.modalView.hide())}.bind(this);this.model.renameCollection(c,j)}else window.modalView.hide()}}.bind(this);window.isCoordinator(a)},renderSettings:function(){var a=function(a,b){if(a)arangoHelper.arangoError("Error","Could not get coordinator info");else{var c=!1;"loaded"===this.model.get("status")&&(c=!0);var d=[],e=[];b||e.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."}]));var f=function(){e.push(window.modalView.createReadOnlyEntry("change-collection-id","ID",this.model.get("id"),"")),e.push(window.modalView.createReadOnlyEntry("change-collection-type","Type",this.model.get("type"),"")),e.push(window.modalView.createReadOnlyEntry("change-collection-status","Status",this.model.get("status"),"")),d.push(window.modalView.createDeleteButton("Delete",this.deleteCollection.bind(this))),d.push(window.modalView.createDeleteButton("Truncate",this.truncateCollection.bind(this))),c?d.push(window.modalView.createNotificationButton("Unload",this.unloadCollection.bind(this))):d.push(window.modalView.createNotificationButton("Load",this.loadCollection.bind(this))),d.push(window.modalView.createSuccessButton("Save",this.saveModifiedCollection.bind(this)));var a=["General","Indices"],b=["modalTable.ejs","indicesView.ejs"];window.modalView.show(b,"Modify Collection",d,e,null,null,this.events,null,a,"content"),$($("#infoTab").children()[1]).remove()}.bind(this);if(c){var g=function(a,b){if(a)arangoHelper.arangoError("Collection","Could not fetch properties");else{var c=b.journalSize/1048576,d=b.indexBuckets,g=b.waitForSync;e.push(window.modalView.createTextEntry("change-collection-size","Journal size",c,"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."}])),e.push(window.modalView.createTextEntry("change-index-buckets","Index buckets",d,"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."}])),e.push(window.modalView.createSelectEntry("change-collection-sync","Wait for sync",g,"Synchronize to disk before returning from a create or update of a document.",[{value:!1,label:"No"},{value:!0,label:"Yes"}]))}f()}.bind(this);this.model.getProperties(g)}else f()}}.bind(this);window.isCoordinator(a)}})}(),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(a){this.options=a,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.SpotlightView=Backbone.View.extend({template:templateEngine.createTemplate("spotlightView.ejs"),el:"#spotlightPlaceholder",displayLimit:8,typeahead:null,callbackSuccess:null,callbackCancel:null,collections:{system:[],doc:[],edge:[]},events:{"focusout #spotlight .tt-input":"hide","keyup #spotlight .typeahead":"listenKey"},aqlKeywordsArray:[],aqlBuiltinFunctionsArray:[],aqlKeywords:"for|return|filter|sort|limit|let|collect|asc|desc|in|into|insert|update|remove|replace|upsert|options|with|and|or|not|distinct|graph|outbound|inbound|any|all|none|aggregate|like|count",aqlBuiltinFunctions:"to_bool|to_number|to_string|to_list|is_null|is_bool|is_number|is_string|is_list|is_document|typename|concat|concat_separator|char_length|lower|upper|substring|left|right|trim|reverse|contains|like|floor|ceil|round|abs|rand|sqrt|pow|length|min|max|average|sum|median|variance_population|variance_sample|first|last|unique|matches|merge|merge_recursive|has|attributes|values|unset|unset_recursive|keep|near|within|within_rectangle|is_in_polygon|fulltext|paths|traversal|traversal_tree|edges|stddev_sample|stddev_population|slice|nth|position|translate|zip|call|apply|push|append|pop|shift|unshift|remove_valueremove_nth|graph_paths|shortest_path|graph_shortest_path|graph_distance_to|graph_traversal|graph_traversal_tree|graph_edges|graph_vertices|neighbors|graph_neighbors|graph_common_neighbors|graph_common_properties|graph_eccentricity|graph_betweenness|graph_closeness|graph_absolute_eccentricity|remove_values|graph_absolute_betweenness|graph_absolute_closeness|graph_diameter|graph_radius|date_now|date_timestamp|date_iso8601|date_dayofweek|date_year|date_month|date_day|date_hour|date_minute|date_second|date_millisecond|date_dayofyear|date_isoweek|date_leapyear|date_quarter|date_days_in_month|date_add|date_subtract|date_diff|date_compare|date_format|fail|passthru|sleep|not_null|first_list|first_document|parse_identifier|current_user|current_database|collections|document|union|union_distinct|intersection|flatten|ltrim|rtrim|find_first|find_last|split|substitute|md5|sha1|hash|random_token|AQL_LAST_ENTRY",listenKey:function(a){27===a.keyCode?(this.callbackSuccess&&this.callbackCancel(),this.hide()):13===a.keyCode&&this.callbackSuccess&&(this.callbackSuccess($(this.typeahead).val()),this.hide())},substringMatcher:function(a){return function(b,c){var d,e;d=[],e=new RegExp(b,"i"),_.each(a,function(a){e.test(a)&&d.push(a)}),c(d)}},updateDatasets:function(){var a=this;this.collections={system:[],doc:[],edge:[]},window.App.arangoCollectionsStore.each(function(b){b.get("isSystem")?a.collections.system.push(b.get("name")):"document"===b.get("type")?a.collections.doc.push(b.get("name")):a.collections.edge.push(b.get("name"))})},stringToArray:function(){var a=this;_.each(this.aqlKeywords.split("|"),function(b){a.aqlKeywordsArray.push(b.toUpperCase())}),_.each(this.aqlBuiltinFunctions.split("|"),function(b){a.aqlBuiltinFunctionsArray.push(b.toUpperCase())}),a.aqlKeywordsArray.push(!0),a.aqlKeywordsArray.push(!1),a.aqlKeywordsArray.push(null)},show:function(a,b,c){this.callbackSuccess=a,this.callbackCancel=b,this.stringToArray(),this.updateDatasets();var d=function(a,b,c){var d='

    '+a+"

    ";return b&&(d+=''),c&&(d+=''+c.toUpperCase()+""),d+="
    "};$(this.el).html(this.template.render({})),$(this.el).show(),"aql"===c?this.typeahead=$("#spotlight .typeahead").typeahead({hint:!0,highlight:!0,minLength:1},{name:"Functions",source:this.substringMatcher(this.aqlBuiltinFunctionsArray),limit:this.displayLimit,templates:{header:d("Functions","fa-code","aql")}},{name:"Keywords",source:this.substringMatcher(this.aqlKeywordsArray),limit:this.displayLimit,templates:{header:d("Keywords","fa-code","aql")}},{name:"Documents",source:this.substringMatcher(this.collections.doc),limit:this.displayLimit,templates:{header:d("Documents","fa-file-text-o","Collection")}},{name:"Edges",source:this.substringMatcher(this.collections.edge),limit:this.displayLimit,templates:{header:d("Edges","fa-share-alt","Collection")}},{name:"System",limit:this.displayLimit,source:this.substringMatcher(this.collections.system),templates:{header:d("System","fa-cogs","Collection")}}):this.typeahead=$("#spotlight .typeahead").typeahead({hint:!0,highlight:!0,minLength:1},{name:"Documents",source:this.substringMatcher(this.collections.doc),limit:this.displayLimit,templates:{header:d("Documents","fa-file-text-o","Collection")}},{name:"Edges",source:this.substringMatcher(this.collections.edge),limit:this.displayLimit,templates:{header:d("Edges","fa-share-alt","Collection")}},{name:"System",limit:this.displayLimit,source:this.substringMatcher(this.collections.system),templates:{header:d("System","fa-cogs","Collection")}}),$("#spotlight .typeahead").focus(); +},hide:function(){$(this.el).hide(),this.typeahead=$("#spotlight .typeahead").typeahead("destroy")}})}(),function(){"use strict";window.StatisticBarView=Backbone.View.extend({el:"#statisticBar",events:{"change #arangoCollectionSelect":"navigateBySelect","click .tab":"navigateByTab"},template:templateEngine.createTemplate("statisticBarView.ejs"),initialize:function(a){this.currentDB=a.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(a){this.rowClickCallback=a.rowClick},events:{"click .pure-table-body .pure-table-row":"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 #userLogoutIcon":"userLogout","click #userLogout":"userLogout"},initialize:function(a){this.userCollection=a.userCollection,this.userCollection.fetch({async:!0}),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())},toggleUserMenu:function(){$("#userBar .subBarDropdown").toggle()},showDropdown:function(){$("#user_dropdown").fadeIn(1)},hideDropdown:function(){$("#user_dropdown").fadeOut(1)},render:function(){if(frontendConfig.authenticationEnabled!==!1){var a=this,b=function(a,b){if(a)arangoHelper.arangoErro("User","Could not fetch user.");else{var c=null,d=null,e=!1,f=null;if(b!==!1)return f=this.userCollection.findWhere({user:b}),f.set({loggedIn:!0}),d=f.get("extra").name,c=f.get("extra").img,e=f.get("active"),c=c?"https://s.gravatar.com/avatar/"+c+"?s=80":"img/default_user.png",d||(d=""),this.$el=$("#userBar"),this.$el.html(this.template.render({img:c,name:d,username:b,active:e})),this.delegateEvents(),this.$el}}.bind(this);$("#userBar").on("click",function(){a.toggleUserMenu()}),this.userCollection.whoAmI(b)}},userLogout:function(){var a=function(a){a?arangoHelper.arangoError("User","Logout error"):this.userCollection.logout()}.bind(this);this.userCollection.whoAmI(a)}})}(),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(){var a=this,b=function(a,b){frontendConfig.authenticationEnabled===!0&&(a||null===b?arangoHelper.arangoError("User","Could not fetch user data"):this.currentUser=this.collection.findWhere({user:b}))}.bind(this);this.collection.fetch({success:function(){a.collection.whoAmI(b)}})},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){arangoHelper.parseError("User",b,a)},success:function(){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){if("createUser"!==$(a.currentTarget).find("a").attr("id")){$(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){if(a){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,e=function(a,e){a?arangoHelper.arangoError("User","Could not verify old password"):e&&(b!==c&&(arangoHelper.arangoError("User","New passwords do not match"),d=!0),d||(this.currentUser.setPassword(b),arangoHelper.arangoNotification("User","Password changed"),window.modalView.hide()))}.bind(this);this.currentUser.checkPassword(a,e)},submitEditCurrentUserProfile:function(){var a=$("#editCurrentName").val(),b=$("#editCurrentUserProfileImg").val();b=this.parseImgString(b);var c=function(a){a?arangoHelper.arangoError("User","Could not edit user settings"):(arangoHelper.arangoNotification("User","Changes confirmed."),this.updateUserProfile())}.bind(this);this.currentUser.setExtras(a,b,c),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({toUpdate:[],dbServers:[],isCluster:void 0,routes:{"":"cluster",dashboard:"dashboard",collections:"collections","new":"newCollection",login:"login","collection/:colid/documents/:pageid":"documents","cIndices/:colname":"cIndices","cSettings/:colname":"cSettings","cInfo/:colname":"cInfo","collection/:colid/:docid":"document",shell:"shell",queries:"query",workMonitor:"workMonitor",databases:"databases",settings:"databases",services:"applications","service/:mount":"applicationDetail",graphs:"graphManagement","graphs/:name":"showGraph",users:"userManagement",userProfile:"userProfile",cluster:"cluster",nodes:"cNodes",cNodes:"cNodes",dNodes:"dNodes",sNodes:"sNodes","node/:name":"node",logs:"logs",helpus:"helpUs"},execute:function(a,b){$("#subNavigationBar .breadcrumb").html(""),$("#subNavigationBar .bottom").html(""),$("#loadingScreen").hide(),$("#content").show(),a&&a.apply(this,b)},checkUser:function(){if("#login"!==window.location.hash){var a=function(){this.initOnce(),$(".bodyWrapper").show(),$(".navbar").show()}.bind(this),b=function(b,c){frontendConfig.authenticationEnabled&&(b||null===c)?"#login"!==window.location.hash&&this.navigate("login",{trigger:!0}):a()}.bind(this);frontendConfig.authenticationEnabled?this.userCollection.whoAmI(b):(this.initOnce(),$(".bodyWrapper").show(),$(".navbar").show())}},waitForInit:function(a,b,c){this.initFinished?(b||a(!0),b&&!c&&a(b,!0),b&&c&&a(b,c,!0)):setTimeout(function(){b||a(!1),b&&!c&&a(b,!1),b&&c&&a(b,c,!1)},350)},initFinished:!1,initialize:function(){frontendConfig.isCluster===!0&&(this.isCluster=!0),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(){};var b=function(b,c){a=this,c===!0&&a.coordinatorCollection.fetch({success:function(){a.fetchDBS()}})}.bind(this);window.isCoordinator(b),frontendConfig.isCluster===!1&&(this.initFinished=!0),this.arangoDatabase=new window.ArangoDatabase,this.currentDB=new window.CurrentDatabase,this.arangoCollectionsStore=new window.arangoCollections,this.arangoDocumentStore=new window.arangoDocument,this.coordinatorCollection=new window.ClusterCoordinators,arangoHelper.setDocumentStore(this.arangoDocumentStore),this.arangoCollectionsStore.fetch(),window.spotlightView=new window.SpotlightView({collection:this.arangoCollectionsStore}),this.footerView=new window.FooterView({collection:a.coordinatorCollection}),this.notificationList=new window.NotificationCollection,this.currentDB.fetch({success:function(){a.naviView=new window.NavigationView({database:a.arangoDatabase,currentDB:a.currentDB,notificationCollection:a.notificationList,userCollection:a.userCollection,isCluster:a.isCluster}),a.naviView.render()}}),this.queryCollection=new window.ArangoQueries,this.footerView.render(),window.checkVersion()}.bind(this),$(window).resize(function(){a.handleResize()}),$(window).scroll(function(){})},handleScroll:function(){$(window).scrollTop()>50?($(".navbar > .secondary").css("top",$(window).scrollTop()),$(".navbar > .secondary").css("position","absolute"),$(".navbar > .secondary").css("z-index","10"),$(".navbar > .secondary").css("width",$(window).width())):($(".navbar > .secondary").css("top","0"),$(".navbar > .secondary").css("position","relative"),$(".navbar > .secondary").css("width",""))},cluster:function(a){return this.checkUser(),a?this.isCluster===!1||void 0===this.isCluster?void("_system"===this.currentDB.get("name")?(this.routes[""]="dashboard",this.navigate("#dashboard",{trigger:!0})):(this.routes[""]="collections",this.navigate("#collections",{trigger:!0}))):(this.clusterView||(this.clusterView=new window.ClusterView({coordinators:this.coordinatorCollection,dbServers:this.dbServers})),void this.clusterView.render()):void this.waitForInit(this.cluster.bind(this))},node:function(a,b){return this.checkUser(),b&&void 0!==this.isCluster?this.isCluster===!1?(this.routes[""]="dashboard",void this.navigate("#dashboard",{trigger:!0})):(this.nodeView||(this.nodeView=new window.NodeView({coordname:a,coordinators:this.coordinatorCollection,dbServers:this.dbServers})),void this.nodeView.render()):void this.waitForInit(this.node.bind(this),a)},cNodes:function(a){return this.checkUser(),a&&void 0!==this.isCluster?this.isCluster===!1?(this.routes[""]="dashboard",void this.navigate("#dashboard",{trigger:!0})):(this.nodesView=new window.NodesView({coordinators:this.coordinatorCollection,dbServers:this.dbServers[0],toRender:"coordinator"}),void this.nodesView.render()):void this.waitForInit(this.cNodes.bind(this))},dNodes:function(a){return this.checkUser(),a&&void 0!==this.isCluster?this.isCluster===!1?(this.routes[""]="dashboard",void this.navigate("#dashboard",{trigger:!0})):0===this.dbServers.length?void this.navigate("#cNodes",{trigger:!0}):(this.nodesView=new window.NodesView({coordinators:this.coordinatorCollection,dbServers:this.dbServers[0],toRender:"dbserver"}),void this.nodesView.render()):void this.waitForInit(this.dNodes.bind(this))},sNodes:function(a){return this.checkUser(),a&&void 0!==this.isCluster?this.isCluster===!1?(this.routes[""]="dashboard",void this.navigate("#dashboard",{trigger:!0})):(this.scaleView=new window.ScaleView({coordinators:this.coordinatorCollection,dbServers:this.dbServers[0]}),void this.scaleView.render()):void this.waitForInit(this.sNodes.bind(this))},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))},logs:function(a,b){if(this.checkUser(),!b)return void this.waitForInit(this.logs.bind(this),a);if(!this.logsView){var c=new window.ArangoLogs({upto:!0,loglevel:4}),d=new window.ArangoLogs({loglevel:4}),e=new window.ArangoLogs({loglevel:3}),f=new window.ArangoLogs({loglevel:2}),g=new window.ArangoLogs({loglevel:1});this.logsView=new window.LogsView({logall:c,logdebug:d,loginfo:e,logwarning:f,logerror:g})}this.logsView.render()},applicationDetail:function(a,b){if(this.checkUser(),!b)return void this.waitForInit(this.applicationDetail.bind(this),a);var c=function(){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")}.bind(this);0===this.foxxList.length?this.foxxList.fetch({success:function(){c()}}):c()},login:function(){var a=function(a,b){this.loginView||(this.loginView=new window.loginView({collection:this.userCollection})),a||null===b?this.loginView.render():this.loginView.render(!0)}.bind(this);this.userCollection.whoAmI(a)},collections:function(a){if(this.checkUser(),!a)return void this.waitForInit(this.collections.bind(this));var b=this;this.collectionsView||(this.collectionsView=new window.CollectionsView({collection:this.arangoCollectionsStore})),this.arangoCollectionsStore.fetch({success:function(){b.collectionsView.render()}})},cIndices:function(a,b){var c=this;return this.checkUser(),b?void this.arangoCollectionsStore.fetch({success:function(){c.indicesView=new window.IndicesView({collectionName:a,collection:c.arangoCollectionsStore.findWhere({name:a})}),c.indicesView.render()}}):void this.waitForInit(this.cIndices.bind(this),a)},cSettings:function(a,b){var c=this;return this.checkUser(),b?void this.arangoCollectionsStore.fetch({success:function(){c.settingsView=new window.SettingsView({collectionName:a,collection:c.arangoCollectionsStore.findWhere({name:a})}),c.settingsView.render()}}):void this.waitForInit(this.cSettings.bind(this),a)},cInfo:function(a,b){var c=this;return this.checkUser(),b?void this.arangoCollectionsStore.fetch({success:function(){c.infoView=new window.InfoView({collectionName:a,collection:c.arangoCollectionsStore.findWhere({name:a})}),c.infoView.render()}}):void this.waitForInit(this.cInfo.bind(this),a)},documents:function(a,b,c){return this.checkUser(),c?(this.documentsView||(this.documentsView=new window.DocumentsView({collection:new window.arangoDocuments,documentStore:this.arangoDocumentStore,collectionsStore:this.arangoCollectionsStore})),this.documentsView.setCollectionId(a,b),void this.documentsView.render()):void this.waitForInit(this.documents.bind(this),a,b)},document:function(a,b,c){if(this.checkUser(),!c)return void this.waitForInit(this.document.bind(this),a,b);this.documentView||(this.documentView=new window.DocumentView({collection:this.arangoDocumentStore})),this.documentView.colid=a;var d=window.location.hash.split("/")[2],e=(d.split("%").length-1)%3;decodeURI(d)!==d&&0!==e&&(d=decodeURIComponent(d)),this.documentView.docid=d,this.documentView.render();var f=function(a,b){a?console.log("Error","Could not fetch collection type"):this.documentView.setType(b)}.bind(this);arangoHelper.collectionApiType(a,null,f)},shell:function(a){return this.checkUser(),a?(this.shellView||(this.shellView=new window.shellView),void this.shellView.render()):void this.waitForInit(this.shell.bind(this))},query:function(a){return this.checkUser(),a?(this.queryView2||(this.queryView2=new window.queryView2({collection:this.queryCollection})),void this.queryView2.render()):void this.waitForInit(this.query.bind(this)); },helpUs:function(a){return this.checkUser(),a?(this.testView||(this.helpUsView=new window.HelpUsView({})),void this.helpUsView.render()):void this.waitForInit(this.helpUs.bind(this))},workMonitor:function(a){return this.checkUser(),a?(this.workMonitorCollection||(this.workMonitorCollection=new window.WorkMonitorCollection),this.workMonitorView||(this.workMonitorView=new window.workMonitorView({collection:this.workMonitorCollection})),void this.workMonitorView.render()):void this.waitForInit(this.workMonitor.bind(this))},queryManagement:function(a){return this.checkUser(),a?(this.queryManagementView||(this.queryManagementView=new window.queryManagementView({collection:void 0})),void this.queryManagementView.render()):void this.waitForInit(this.queryManagement.bind(this))},databases:function(a){if(this.checkUser(),!a)return void this.waitForInit(this.databases.bind(this));var b=function(a){a?(arangoHelper.arangoError("DB","Could not get list of allowed databases"),this.navigate("#",{trigger:!0}),$("#databaseNavi").css("display","none"),$("#databaseNaviSelect").css("display","none")):(this.databaseView||(this.databaseView=new window.databaseView({users:this.userCollection,collection:this.arangoDatabase})),this.databaseView.render())}.bind(this);arangoHelper.databaseAllowed(b)},dashboard:function(a){return this.checkUser(),a?(void 0===this.dashboardView&&(this.dashboardView=new window.DashboardView({dygraphConfig:window.dygraphConfig,database:this.arangoDatabase})),void this.dashboardView.render()):void this.waitForInit(this.dashboard.bind(this))},graphManagement:function(a){return this.checkUser(),a?(this.graphManagementView||(this.graphManagementView=new window.GraphManagementView({collection:new window.GraphCollection,collectionCollection:this.arangoCollectionsStore})),void this.graphManagementView.render()):void this.waitForInit(this.graphManagement.bind(this))},showGraph:function(a,b){return this.checkUser(),b?void(this.graphManagementView?this.graphManagementView.loadGraphViewer(a):(this.graphManagementView=new window.GraphManagementView({collection:new window.GraphCollection,collectionCollection:this.arangoCollectionsStore}),this.graphManagementView.render(a,!0))):void this.waitForInit(this.showGraph.bind(this),a)},applications:function(a){return this.checkUser(),a?(void 0===this.applicationsView&&(this.applicationsView=new window.ApplicationsView({collection:this.foxxList})),void this.applicationsView.reload()):void this.waitForInit(this.applications.bind(this))},handleSelectDatabase:function(a){return this.checkUser(),a?void this.naviView.handleSelectDatabase():void this.waitForInit(this.handleSelectDatabase.bind(this))},handleResize:function(){this.dashboardView&&this.dashboardView.resize(),this.graphManagementView&&this.graphManagementView.handleResize($("#content").width()),this.queryView&&this.queryView.resize(),this.queryView2&&this.queryView2.resize(),this.documentsView&&this.documentsView.resize(),this.documentView&&this.documentView.resize()},userManagement:function(a){return this.checkUser(),a?(this.userManagementView||(this.userManagementView=new window.userManagementView({collection:this.userCollection})),void this.userManagementView.render()):void this.waitForInit(this.userManagement.bind(this))},userProfile:function(a){return this.checkUser(),a?(this.userManagementView||(this.userManagementView=new window.userManagementView({collection:this.userCollection})),void this.userManagementView.render(!0)):void this.waitForInit(this.userProfile.bind(this))},fetchDBS:function(a){var b=this,c=!1;this.coordinatorCollection.each(function(a){b.dbServers.push(new window.ClusterServers([],{host:a.get("address")}))}),this.initFinished=!0,_.each(this.dbServers,function(b){b.fetch({success:function(){c===!1&&a&&(a(),c=!0)}})})},getNewRoute:function(a){return"http://"+a},registerForUpdate:function(a){this.toUpdate.push(a),a.updateUrl()}})}(),function(){"use strict";var a=function(a,b){var c=[];c.push(window.modalView.createSuccessButton("Download Page",function(){window.open("https://www.arangodb.com/download","_blank"),window.modalView.hide()}));var d=[],e=window.modalView.createReadOnlyEntry.bind(window.modalView);d.push(e("current","Current",a.toString())),b.major&&d.push(e("major","Major",b.major.version)),b.minor&&d.push(e("minor","Minor",b.minor.version)),b.bugfix&&d.push(e("bugfix","Bugfix",b.bugfix.version)),window.modalView.show("modalTable.ejs","New Version Available",c,d)};window.checkVersion=function(){$.ajax({type:"GET",cache:!1,url:arangoHelper.databaseUrl("/_api/version"),contentType:"application/json",processData:!1,async:!0,success:function(b){var c=window.versionHelper.fromString(b.version);$(".navbar #currentVersion").text(" "+b.version.substr(0,3)),window.parseVersions=function(b){return _.isEmpty(b)?void $("#currentVersion").addClass("up-to-date"):($("#currentVersion").addClass("out-of-date"),void $("#currentVersion").click(function(){a(c,b)}))},$.ajax({type:"GET",async:!0,crossDomain:!0,timeout:3e3,dataType:"jsonp",url:"https://www.arangodb.com/repositories/versions.php?jsonp=parseVersions&version="+encodeURIComponent(c.toString())})}})}}(),function(){"use strict";window.hasOwnProperty("TEST_BUILD")||($(document).ready(function(){window.App=new window.Router,Backbone.history.start(),window.App.handleResize()}),$(document).click(function(a){a.stopPropagation(),$(a.target).hasClass("subBarDropdown")||$(a.target).hasClass("dropdown-header")||$(a.target).hasClass("dropdown-footer")||$(a.target).hasClass("toggle")||$("#userInfo").is(":visible")&&$(".subBarDropdown").hide()}))}(); \ 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 2dd799b3165139b4f152353442194facfb8e5688..4b8af83add76989da72f2d91fd0f22bbd744b5f0 100644 GIT binary patch delta 113182 zcmV(LF?u%PxQmWe_Fg=9|{-F>8@DPNY~e>EY8lMm*OAW@r2 zAa}IDY&1EpWo$GDl?@I<^!Du9PE9Y75bud+-fGE~x3aV?09&K$DlSeUBjc7aKXGFL z&*+rN`@Io_iI9dN#1d*-u7g64UQ>fxQC!JwprKiN%~$l#urK=}AL%t8L2f@6$tH?I zfq+=@lX=nHd%eGVf4KkR<)hFN%V<7CP1LsxO@DzS%McSZ;2Ch7L(^@PCfCr2nl4`L z9`60P*n_H3VpCYmPnpG6aC-)aPi_$*ohMPSj%au4HUMO-f)O?0Df3!alDBG?faXMN<-24Tw zU9&K{hAc)36Rn|r8Ly#z3+)M%T9BC{7^Iuq!Qt-fLtWJUM^C~4Jn@HVdt(>e_ zo}ixTNb80|lYOM^yWCM>9RLpI)ogm24Mg4y;ue5-Z}-LC{|)V0?L3H0$&E>6&x)A3`PIDakMm|$|VeN zG?0uFrh}_1y;IBCcQ&D90Gq*Z`$6nnIYJOKmESv_kYn~0Hv`<1#VslA!y;{Mjepfm z2^>bWEzDLXA<|oVg>iaV!RBEhelM-ilU=h<;`MCQf0<=7T6-JGErS?Y(Jg*^*{ywm z@Yenm>8*XB_}2ZV{1#3k@B)E!+3qX;cAOlYBK?Cg0piVHi1xlogd+r-LLuhGAx~o4 zYVQBntKAom%=Xvfh)-z>@-_fBx1SHdPtPA);h7^!bjR0{I2+~cAbdrKZ{Lf7@?JI` z(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Aw%%07NwwNdN!< diff --git a/js/apps/system/_admin/aardvark/APP/frontend/build/index-min.html b/js/apps/system/_admin/aardvark/APP/frontend/build/index-min.html index ab563d8f85..88b7c03928 100644 --- a/js/apps/system/_admin/aardvark/APP/frontend/build/index-min.html +++ b/js/apps/system/_admin/aardvark/APP/frontend/build/index-min.html @@ -3122,4 +3122,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/index-min.html.gz b/js/apps/system/_admin/aardvark/APP/frontend/build/index-min.html.gz index bb5faf01e5bcd680b4cdd019c6ecc31c72f8223a..fd8e821062cc3e5e29a07cc3d89bc166ece3b961 100644 GIT binary patch delta 25314 zcmV(xKze{-{}3WdoKuYc1j_H^DDUCU z^2^DnH_HKJSX^a;5ondv?GCwem&UDg@L7icd`V)>eEO&dj^H8K@9+RVf5`6Ly?YDg zxdN)pM+Uo^_n+tE`IGT%TI5xRM?&mH@2cOMW|R47)E(t#7)7m#x}zea4psS-Iiwh$ zmEa!1)Iqz>dV^VUMP2C~9HG$OZV#jx6^lV(blM>?jE6rQtp+g#0WR|;P+oF@)qpUo zXT|s&!_(F^M(9|J)Pe2of6hmd)NUMgbmp^JIrd{TEGmrp^@D6&jzONrfk>a(Kq z1HwZRD=|y-c!{ifl?Wkm(r7Fr1c?VfhB4&;dXd z$a7)ib?Br(7m+IT*S}UwI?SDC>xw7l#2U9BTChA3|5EQ!Bo$e(jau%Lu zWjUfr9A41pj?7)bf9cdd)sWk}1;)s+d_=AYy}gs2&BvJ7FYrgb zix3q`QERDNK*ZIW<8B7p&wBk%HtfxMI&AwLVpM7a4S+y+;CAsu6R+N6jSWDrTiH*y z>$u4jrH19d7Vb$QgEv%)cV~Gui@fAnrO~ezHa`Q0y$;NAf5Ncdk-u9pB)%S%y!QtLQj z;ofKdw^GBfA=yIY&}Hx{AC(ix%-PoMZ?>@3XFp8K;hZ^e>jA$w%wrjnMs*ss4Q8^! zo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nZjAwlr33A9^olN~2t0^J!7tH=AkPXl zt8z^Cp=4okTmr8U%EfNs`Q?(Hxta)eLH-W_ow4~tQh|19trrn5S_j}+IEDq0N86|N zb^((+vybA#+rx9|%NOtH-?O(C`DT$V9E_8=d@Agzj7QjId@gwL={#YgIDg`7@zf@= z65ZyvjiPw_ZPJ?WKa7gJNO(kES$*B13(Q7MTY_!RHFdU-xJJiHR51i|Zd?=lOt^wA zU!$Jm0j(s-3H`*9{b^-RRnctEx{Fv7hj#tz{mh`g#R;*%;abeTiGvJ)F1|SU_i~I5|u2t^0sbW?}vt)^cwSkpiODs5Q>zBGRiK+ z { if (global.AUTHENTICATION_ENABLED()) { - if (!req.session.uid) { + if (!req.user) { throw new httperr.Unauthorized(); } } diff --git a/js/server/modules/@arangodb/foxx/router/request.js b/js/server/modules/@arangodb/foxx/router/request.js index 39dfe781e5..bb4b323dda 100644 --- a/js/server/modules/@arangodb/foxx/router/request.js +++ b/js/server/modules/@arangodb/foxx/router/request.js @@ -35,6 +35,7 @@ const crypto = require('@arangodb/crypto'); module.exports = class SyntheticRequest { constructor(req, context) { + this.user = req.user; this._url = parseUrl(req.url); this._raw = req; this.context = context; From b00322b2e1c2562e8231260a4f93d4306f08a0e1 Mon Sep 17 00:00:00 2001 From: Andreas Streichardt Date: Wed, 1 Jun 2016 17:54:14 +0200 Subject: [PATCH 14/14] Classic --- js/apps/system/_admin/aardvark/APP/manifest.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/apps/system/_admin/aardvark/APP/manifest.json b/js/apps/system/_admin/aardvark/APP/manifest.json index 9cb528f93f..db19c6b1d7 100644 --- a/js/apps/system/_admin/aardvark/APP/manifest.json +++ b/js/apps/system/_admin/aardvark/APP/manifest.json @@ -58,7 +58,7 @@ "gzip": true }, "/app.js": { - "path": "frontend/build/app.js", + "path": "frontend/build/app.min.js", "gzip": true }, "/libs.js": {