Compare commits
7 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
01b8d12979 | |
|
|
d53a714ad2 | |
|
|
a4f04c9d78 | |
|
|
6a6dbc8651 | |
|
|
db2424ba64 | |
|
|
40e06ca5ce | |
|
|
cfbf197413 |
135
code-payload.js
135
code-payload.js
|
|
@ -6,7 +6,7 @@
|
|||
// @require http://ajax.googleapis.com/ajax/libs/jqueryui/1.11.1/jquery-ui.min.js
|
||||
// @grant GM_addStyle
|
||||
// @grant GM_setClipboard
|
||||
// @version 0.0.6
|
||||
// @version 0.0.13
|
||||
// ==/UserScript==
|
||||
|
||||
// draw frame
|
||||
|
|
@ -56,9 +56,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
"auth",
|
||||
"compute",
|
||||
"jobs",
|
||||
"dlt",
|
||||
"odbc",
|
||||
"sql",
|
||||
"webapp"
|
||||
"webapp",
|
||||
"accountConsole"
|
||||
];
|
||||
|
||||
var regionArray = [
|
||||
|
|
@ -88,6 +90,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
"southcentralus",
|
||||
"southeastasia",
|
||||
"southindia",
|
||||
"swedencentral",
|
||||
"switzerlandnorth",
|
||||
"switzerlandwest",
|
||||
"uaenorth",
|
||||
|
|
@ -117,9 +120,12 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
var authGroup = $("div.form-group").filter(":contains('Authentication')");
|
||||
var computeGroup = $("div.form-group").filter(":contains('Compute Service')");
|
||||
var jobsGroup = $("div.form-group").filter(":contains('Jobs Service')");
|
||||
var dltGroup = $("div.form-group").filter(":contains('Delta Live Tables')");
|
||||
var odbcGroup = $("div.form-group").filter(":contains('ODBC/JDBC Service')");
|
||||
var webappGroup = $("div.form-group").filter(":contains('User Interface')");
|
||||
var sqlGroup = $("div.form-group").filter(":contains('Databricks SQL')");
|
||||
var accountConsoleGroup = $("div.form-group").filter(":contains('Account Console')");
|
||||
|
||||
|
||||
// write component HTML template
|
||||
var componentsHTML = '<center>' +
|
||||
|
|
@ -129,9 +135,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
'<button id="authButton">Auth</button>' +
|
||||
'<button id="computeButton" type="button">Compute</button>' +
|
||||
'<button id="jobsButton" type="button">Jobs</button>' +
|
||||
'<button id="dltButton" type="button">DLT</button>' +
|
||||
'<button id="odbcButton" type="button">ODBC/JDBC</button>' +
|
||||
'<button id="webappButton" type="button">Webapp</button>' +
|
||||
'<button id="sqlButton" type="button">SQL</button>' +
|
||||
'<button id="accountConsoleButton" type="button">Accounts</button>' +
|
||||
'</center></br></br>';
|
||||
|
||||
// regional functions
|
||||
|
|
@ -171,6 +179,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
var buttonRegions = ["westindia"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function swedencentralButtonClickAction(zEvent) {
|
||||
var buttonName = "swedencentralButton";
|
||||
var buttonRegions = ["swedencentral"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function switzerlandnorthButtonClickAction(zEvent) {
|
||||
var buttonName = "switzerlandnorthButton";
|
||||
var buttonRegions = ["switzerlandnorth"];
|
||||
|
|
@ -368,7 +381,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
};
|
||||
function stage1ButtonClickAction(zEvent) {
|
||||
var buttonName = "stage1Button";
|
||||
var buttonRegions = ["canadacentral", "canadaeast", "centralindia", "southindia", "westindia", "switzerlandnorth", "switzerlandwest", "norwayeast", "germanywestcentral"];
|
||||
var buttonRegions = ["canadacentral", "canadaeast", "centralindia", "southindia", "westindia", "swedencentral", "switzerlandnorth", "switzerlandwest", "norwayeast", "germanywestcentral"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function stage1point5ButtonClickAction(zEvent) {
|
||||
|
|
@ -419,6 +432,10 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
toggleComponent("jobs");
|
||||
toggleButtonColor("jobsButton");
|
||||
};
|
||||
function dltButtonClickAction(zEvent) {
|
||||
toggleComponent("dlt");
|
||||
toggleButtonColor("dltButton");
|
||||
};
|
||||
function odbcButtonClickAction(zEvent) {
|
||||
toggleComponent("odbc");
|
||||
toggleButtonColor("odbcButton");
|
||||
|
|
@ -431,6 +448,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
toggleComponent("sql");
|
||||
toggleButtonColor("sqlButton");
|
||||
};
|
||||
function accountConsoleButtonClickAction(zEvent) {
|
||||
toggleComponent("accountConsole");
|
||||
toggleButtonColor("accountConsoleButton");
|
||||
};
|
||||
|
||||
|
||||
// profile management functions
|
||||
function loadDataplanes() {
|
||||
|
|
@ -444,8 +466,9 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
'<button id="southindiaButton" style="width:156px" type="button">South India</button>' +
|
||||
'<button id="westindiaButton" style="width:156px" type="button">West India</button>' +
|
||||
'</br>' +
|
||||
'<button id="switzerlandnorthButton" style="width:234px" type="button">Switzerland North</button>' +
|
||||
'<button id="switzerlandwestButton" style="width:234px" type="button">Switzerland West</button>' +
|
||||
'<button id="swedencentralButton" style="width:156px" type="button">Sweden Central</button>' +
|
||||
'<button id="switzerlandnorthButton" style="width:156px" type="button">Switzerland North</button>' +
|
||||
'<button id="switzerlandwestButton" style="width:156px" type="button">Switzerland West</button>' +
|
||||
'</br>' +
|
||||
'<button id="norwayeastButton" style="width:234px" type="button">Norway East</button>' +
|
||||
'<button id="germanywestcentralButton" style="width:234px" type="button">Germany West Central</button>' +
|
||||
|
|
@ -522,6 +545,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
"southcentralus",
|
||||
"southeastasia",
|
||||
"southindia",
|
||||
"swedencentral",
|
||||
"switzerlandnorth",
|
||||
"switzerlandwest",
|
||||
"uaenorth",
|
||||
|
|
@ -543,6 +567,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
document.getElementById("centralindiaButton").addEventListener("click", centralindiaButtonClickAction, false);
|
||||
document.getElementById("southindiaButton").addEventListener("click", southindiaButtonClickAction, false);
|
||||
document.getElementById("westindiaButton").addEventListener("click", westindiaButtonClickAction, false);
|
||||
document.getElementById("swedencentralButton").addEventListener("click", swedencentralButtonClickAction, false);
|
||||
document.getElementById("switzerlandnorthButton").addEventListener("click", switzerlandnorthButtonClickAction, false);
|
||||
document.getElementById("switzerlandwestButton").addEventListener("click", switzerlandwestButtonClickAction, false);
|
||||
document.getElementById("norwayeastButton").addEventListener("click", norwayeastButtonClickAction, false);
|
||||
|
|
@ -588,9 +613,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -604,8 +631,9 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
'<button id="canadacentralButton" style="width:234px" type="button">Canada Central</button>' +
|
||||
'<button id="centralindiaButton" style="width:234px" type="button">Central India</button>' +
|
||||
'</br>' +
|
||||
'<button id="switzerlandnorthButton" style="width:234px" type="button">Switzerland North</button>' +
|
||||
'<button id="switzerlandwestButton" style="width:234px" type="button">Switzerland West</button>' +
|
||||
'<button id="swedencentralButton" style="width:156px" type="button">Sweden Central</button>' +
|
||||
'<button id="switzerlandnorthButton" style="width:156px" type="button">Switzerland North</button>' +
|
||||
'<button id="switzerlandwestButton" style="width:156px" type="button">Switzerland West</button>' +
|
||||
'</br>' +
|
||||
'<button id="norwayeastButton" style="width:234px" type="button">Norway East</button>' +
|
||||
'<button id="germanywestcentralButton" style="width:234px" type="button">Germany West Central</button>' +
|
||||
|
|
@ -654,6 +682,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
"norwayeast",
|
||||
"southafricanorth",
|
||||
"southeastasia",
|
||||
"swedencentral",
|
||||
"switzerlandnorth",
|
||||
"switzerlandwest",
|
||||
"uaenorth",
|
||||
|
|
@ -669,6 +698,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
|
||||
// regional listeners
|
||||
document.getElementById("canadacentralButton").addEventListener("click", canadacentralCPButtonClickAction, false);
|
||||
document.getElementById("swedencentralButton").addEventListener("click", swedencentralButtonClickAction, false);
|
||||
document.getElementById("switzerlandnorthButton").addEventListener("click", switzerlandnorthButtonClickAction, false);
|
||||
document.getElementById("switzerlandwestButton").addEventListener("click", switzerlandwestButtonClickAction, false);
|
||||
document.getElementById("centralindiaButton").addEventListener("click", centralindiaCPButtonClickAction, false);
|
||||
|
|
@ -703,9 +733,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -765,9 +797,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -820,12 +854,15 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
"auth",
|
||||
"compute",
|
||||
"jobs",
|
||||
"dlt",
|
||||
"odbc",
|
||||
"sql",
|
||||
"webapp"
|
||||
"webapp",
|
||||
"accountConsole"
|
||||
];
|
||||
var regionArray = [
|
||||
"ap-northeast-1",
|
||||
"ap-northeast-2",
|
||||
"ap-south-1",
|
||||
"ap-southeast-1",
|
||||
"ap-southeast-2",
|
||||
|
|
@ -856,9 +893,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
var authGroup = $("div.form-group").filter(":contains('Authentication')");
|
||||
var computeGroup = $("div.form-group").filter(":contains('Compute Service')");
|
||||
var jobsGroup = $("div.form-group").filter(":contains('Jobs Service')");
|
||||
var dltGroup = $("div.form-group").filter(":contains('Delta Live Tables')");
|
||||
var odbcGroup = $("div.form-group").filter(":contains('ODBC/JDBC Service')");
|
||||
var webappGroup = $("div.form-group").filter(":contains('User Interface')");
|
||||
var sqlGroup = $("div.form-group").filter(":contains('Databricks SQL')");
|
||||
var accountConsoleGroup = $("div.form-group").filter(":contains('Account Console')");
|
||||
var ceGroup = $("div.form-group").filter(":contains('Community Edition')");
|
||||
|
||||
// write component HTML template
|
||||
|
|
@ -869,9 +908,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
'<button id="authButton">Auth</button>' +
|
||||
'<button id="computeButton" type="button">Compute</button>' +
|
||||
'<button id="jobsButton" type="button">Jobs</button>' +
|
||||
'<button id="dltButton" type="button">DLT</button>' +
|
||||
'<button id="odbcButton" type="button">ODBC/JDBC</button>' +
|
||||
'<button id="webappButton" type="button">Webapp</button>' +
|
||||
'<button id="sqlButton" type="button">SQL</button>' +
|
||||
'<button id="accountConsoleButton" type="button">Accounts</button>' +
|
||||
'</center></br>';
|
||||
|
||||
// regional functions
|
||||
|
|
@ -935,6 +976,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
var buttonRegions = ["ap-northeast-1"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function apnortheast2ButtonClickAction(zEvent) {
|
||||
var buttonName = "apnortheast2Button";
|
||||
var buttonRegions = ["ap-northeast-2"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function euwest1ButtonClickAction(zEvent) {
|
||||
var buttonName = "euwest1Button";
|
||||
var buttonRegions = ["eu-west-1"];
|
||||
|
|
@ -957,7 +1003,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
};
|
||||
function stage3amButtonClickAction(zEvent) {
|
||||
var buttonName = "stage3amButton";
|
||||
var buttonRegions = ["ap-south-1", "ap-southeast-2", "ap-northeast-1"];
|
||||
var buttonRegions = ["ap-south-1", "ap-southeast-2", "ap-northeast-1", "ap-northeast-2"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function stage3pmButtonClickAction(zEvent) {
|
||||
|
|
@ -983,6 +1029,10 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
toggleComponent("jobs");
|
||||
toggleButtonColor("jobsButton");
|
||||
};
|
||||
function dltButtonClickAction(zEvent) {
|
||||
toggleComponent("dlt");
|
||||
toggleButtonColor("dltButton");
|
||||
};
|
||||
function odbcButtonClickAction(zEvent) {
|
||||
toggleComponent("odbc");
|
||||
toggleButtonColor("odbcButton");
|
||||
|
|
@ -995,6 +1045,10 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
toggleComponent("sql");
|
||||
toggleButtonColor("sqlButton");
|
||||
};
|
||||
function accountConsoleButtonClickAction(zEvent) {
|
||||
toggleComponent("accountConsole");
|
||||
toggleButtonColor("accountConsoleButton");
|
||||
};
|
||||
|
||||
// profile management functions
|
||||
function loadDataplanes() {
|
||||
|
|
@ -1014,9 +1068,10 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
'</br>' +
|
||||
'<button id="apsoutheast1Button" style="width:468px" type="button">ap-southeast-1</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="apsouth1Button" style="width:156px" type="button">ap-south-1</button>' +
|
||||
'<button id="apsoutheast2Button" style="width:156px" type="button">ap-southeast-2</button>' +
|
||||
'<button id="apnortheast1Button" style="width:156px" type="button">ap-northeast-1</button>' +
|
||||
'<button id="apsouth1Button" style="width:117px" type="button">ap-south-1</button>' +
|
||||
'<button id="apsoutheast2Button" style="width:117px" type="button">ap-southeast-2</button>' +
|
||||
'<button id="apnortheast1Button" style="width:117px" type="button">ap-northeast-1</button>' +
|
||||
'<button id="apnortheast2Button" style="width:117px" type="button">ap-northeast-2</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="euwest1Button" style="width:468px" type="button">eu-west-1</button>' +
|
||||
'</center>';
|
||||
|
|
@ -1029,6 +1084,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
// array of active buttons
|
||||
buttonArray = [
|
||||
"apnortheast1",
|
||||
"apnortheast2",
|
||||
"apsouth1",
|
||||
"apsoutheast1",
|
||||
"apsoutheast2",
|
||||
|
|
@ -1058,6 +1114,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("apsoutheast1Button").addEventListener("click", apsoutheast1ButtonClickAction, false);
|
||||
document.getElementById("apsoutheast2Button").addEventListener("click", apsoutheast2ButtonClickAction, false);
|
||||
document.getElementById("apnortheast1Button").addEventListener("click", apnortheast1ButtonClickAction, false);
|
||||
document.getElementById("apnortheast2Button").addEventListener("click", apnortheast2ButtonClickAction, false);
|
||||
document.getElementById("euwest1Button").addEventListener("click", euwest1ButtonClickAction, false);
|
||||
document.getElementById("ceButton").addEventListener("click", ceButtonClickAction, false);
|
||||
|
||||
|
|
@ -1073,9 +1130,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1096,9 +1155,10 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
'<button id="useast2Button" style="width:117px" type="button">us-east-2</button>' +
|
||||
'<button id="apsoutheast1Button" style="width:117px" type="button">ap-southeast-1</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="apsouth1Button" style="width:156px" type="button">ap-south-1</button>' +
|
||||
'<button id="apsoutheast2Button" style="width:156px" type="button">ap-southeast-2</button>' +
|
||||
'<button id="apnortheast1Button" style="width:156px" type="button">ap-northeast-1</button>' +
|
||||
'<button id="apsouth1Button" style="width:117px" type="button">ap-south-1</button>' +
|
||||
'<button id="apsoutheast2Button" style="width:117px" type="button">ap-southeast-2</button>' +
|
||||
'<button id="apnortheast1Button" style="width:117px" type="button">ap-northeast-1</button>' +
|
||||
'<button id="apnortheast2Button" style="width:117px" type="button">ap-northeast-2</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="euwest1Button" style="width:468px" type="button">eu-west-1</button>' +
|
||||
'</center>';
|
||||
|
|
@ -1111,6 +1171,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
// array of active buttons
|
||||
buttonArray = [
|
||||
"apnortheast1",
|
||||
"apnortheast2",
|
||||
"apsouth1",
|
||||
"apsoutheast1",
|
||||
"apsoutheast2",
|
||||
|
|
@ -1138,6 +1199,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("apsoutheast1Button").addEventListener("click", apsoutheast1ButtonClickAction, false);
|
||||
document.getElementById("apsoutheast2Button").addEventListener("click", apsoutheast2ButtonClickAction, false);
|
||||
document.getElementById("apnortheast1Button").addEventListener("click", apnortheast1ButtonClickAction, false);
|
||||
document.getElementById("apnortheast2Button").addEventListener("click", apnortheast2ButtonClickAction, false);
|
||||
document.getElementById("euwest1Button").addEventListener("click", euwest1ButtonClickAction, false);
|
||||
document.getElementById("ceButton").addEventListener("click", ceButtonClickAction, false);
|
||||
|
||||
|
|
@ -1153,9 +1215,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1205,9 +1269,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1259,7 +1325,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
"jobs",
|
||||
"odbc",
|
||||
"sql",
|
||||
"webapp"
|
||||
"webapp",
|
||||
"accountConsole"
|
||||
];
|
||||
var regionArray = [
|
||||
"australia-southeast1",
|
||||
|
|
@ -1270,7 +1337,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
"us-east1",
|
||||
"us-east4",
|
||||
"us-west1",
|
||||
"us-west4"
|
||||
"us-west4",
|
||||
"europe-west3"
|
||||
];
|
||||
var buttonArray = [];
|
||||
|
||||
|
|
@ -1291,6 +1359,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
var odbcGroup = $("div.form-group").filter(":contains('ODBC/JDBC Service')");
|
||||
var webappGroup = $("div.form-group").filter(":contains('User Interface')");
|
||||
var sqlGroup = $("div.form-group").filter(":contains('Databricks SQL')");
|
||||
var accountConsoleGroup = $("div.form-group").filter(":contains('Account Console')");
|
||||
|
||||
|
||||
// write component HTML template
|
||||
var componentsHTML = '<center>' +
|
||||
|
|
@ -1303,6 +1373,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
'<button id="odbcButton" type="button">ODBC/JDBC</button>' +
|
||||
'<button id="webappButton" type="button">Webapp</button>' +
|
||||
'<button id="sqlButton" type="button">SQL</button>' +
|
||||
'<button id="accountConsoleButton" type="button">Accounts</button>' +
|
||||
'</center></br></br>';
|
||||
|
||||
// regional functions
|
||||
|
|
@ -1351,6 +1422,11 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
var buttonRegions = ["us-west4"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function europewest3ButtonClickAction(zEvent) {
|
||||
var buttonName = "europewest3Button";
|
||||
var buttonRegions = ["europe-west3"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function stage1ButtonClickAction(zEvent) {
|
||||
var buttonName = "stage1Button";
|
||||
var buttonRegions = ["europe-west1"];
|
||||
|
|
@ -1368,7 +1444,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
};
|
||||
function stage3pmButtonClickAction(zEvent) {
|
||||
var buttonName = "stage3pmButton";
|
||||
var buttonRegions = ["us-west4"];
|
||||
var buttonRegions = ["us-west4", "europe-west3"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
|
||||
|
|
@ -1401,6 +1477,10 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
toggleComponent("sql");
|
||||
toggleButtonColor("sqlButton");
|
||||
};
|
||||
function sqlButtonClickAction(zEvent) {
|
||||
toggleComponent("accountConsole");
|
||||
toggleButtonColor("accountConsoleButton");
|
||||
};
|
||||
|
||||
function loadControlplanes() {
|
||||
currentMode = "controlplane";
|
||||
|
|
@ -1418,7 +1498,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
'<button id="australiasoutheast1Button" style="width:234px" type="button">Australia-Southeast1</button>' +
|
||||
'<button id="asiasoutheast1Button" style="width:234px" type="button">Asia-Southeast1</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="uswest4Button" style="width:468px" type="button">US-West4</button>' +
|
||||
'<button id="uswest4Button" style="width:234px" type="button">US-West4</button>' +
|
||||
'<button id="europewest3Button" style="width:234px" type="button">EU-West3</button>' +
|
||||
'</br></center>'
|
||||
;
|
||||
zNode.innerHTML = profilesHTML + '<hr class="solid">' + controlplaneHTML + '<hr class="solid">' + componentsHTML + auxHTML;
|
||||
|
|
@ -1436,7 +1517,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
"useast1",
|
||||
"useast4",
|
||||
"uswest1",
|
||||
"uswest4"
|
||||
"uswest4",
|
||||
"europewest3"
|
||||
];
|
||||
if (debugFlag == true) {
|
||||
console.log("buttonArray: " + buttonArray);
|
||||
|
|
@ -1455,6 +1537,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
document.getElementById("useast4Button").addEventListener("click", useast4ButtonClickAction, false);
|
||||
document.getElementById("uswest1Button").addEventListener("click", uswest1ButtonClickAction, false);
|
||||
document.getElementById("uswest4Button").addEventListener("click", uswest4ButtonClickAction, false);
|
||||
document.getElementById("europewest3Button").addEventListener("click", europewest3ButtonClickAction, false);
|
||||
|
||||
// profile listeners
|
||||
document.getElementById("controlplanesButton").addEventListener("click", controlplanesButtonClickAction, false);
|
||||
|
|
@ -1470,6 +1553,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1522,6 +1606,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1683,12 +1768,22 @@ function checkButtonColor(buttonName) {
|
|||
return color;
|
||||
};
|
||||
function selectCheckbox(box) {
|
||||
try {
|
||||
box.filter("A")[0].classList.add("checked");
|
||||
box.filter("INPUT")[0].checked = true;
|
||||
} catch (e) {
|
||||
console.log(box + " does not appear to exist");
|
||||
}
|
||||
|
||||
};
|
||||
function deselectCheckbox(box) {
|
||||
try {
|
||||
box.filter("A")[0].classList.remove("checked");
|
||||
box.filter("INPUT")[0].checked = false;
|
||||
} catch (e) {
|
||||
console.log(box + " does not appear to exist");
|
||||
}
|
||||
|
||||
};
|
||||
function apply() {
|
||||
if (debugFlag == true) {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
// @description Effort to simplify configuration of incidents/maintenance windows
|
||||
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js
|
||||
// @require http://ajax.googleapis.com/ajax/libs/jqueryui/1.11.1/jquery-ui.min.js
|
||||
// @version 0.0.6
|
||||
// @version 0.0.13
|
||||
// @downloadUrl https://gitea.frijole.lol/o0beaner/js-statusio-selector/raw/branch/main/statusio-selector.user.js
|
||||
// @updateURL https://gitea.frijole.lol/o0beaner/js-statusio-selector/raw/branch/main/statusio-selector.user.js
|
||||
// @include /^https?://app\.status\.io/dashboard/.*/?(maintenance|incident)/create$/
|
||||
|
|
@ -92,9 +92,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
"auth",
|
||||
"compute",
|
||||
"jobs",
|
||||
"dlt",
|
||||
"odbc",
|
||||
"sql",
|
||||
"webapp"
|
||||
"webapp",
|
||||
"accountConsole"
|
||||
];
|
||||
|
||||
var regionArray = [
|
||||
|
|
@ -124,6 +126,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
"southcentralus",
|
||||
"southeastasia",
|
||||
"southindia",
|
||||
"swedencentral",
|
||||
"switzerlandnorth",
|
||||
"switzerlandwest",
|
||||
"uaenorth",
|
||||
|
|
@ -153,9 +156,12 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
var authGroup = $("div.form-group").filter(":contains('Authentication')");
|
||||
var computeGroup = $("div.form-group").filter(":contains('Compute Service')");
|
||||
var jobsGroup = $("div.form-group").filter(":contains('Jobs Service')");
|
||||
var dltGroup = $("div.form-group").filter(":contains('Delta Live Tables')");
|
||||
var odbcGroup = $("div.form-group").filter(":contains('ODBC/JDBC Service')");
|
||||
var webappGroup = $("div.form-group").filter(":contains('User Interface')");
|
||||
var sqlGroup = $("div.form-group").filter(":contains('Databricks SQL')");
|
||||
var accountConsoleGroup = $("div.form-group").filter(":contains('Account Console')");
|
||||
|
||||
|
||||
// write component HTML template
|
||||
var componentsHTML = '<center>' +
|
||||
|
|
@ -165,9 +171,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
'<button id="authButton">Auth</button>' +
|
||||
'<button id="computeButton" type="button">Compute</button>' +
|
||||
'<button id="jobsButton" type="button">Jobs</button>' +
|
||||
'<button id="dltButton" type="button">DLT</button>' +
|
||||
'<button id="odbcButton" type="button">ODBC/JDBC</button>' +
|
||||
'<button id="webappButton" type="button">Webapp</button>' +
|
||||
'<button id="sqlButton" type="button">SQL</button>' +
|
||||
'<button id="accountConsoleButton" type="button">Accounts</button>' +
|
||||
'</center></br></br>';
|
||||
|
||||
// regional functions
|
||||
|
|
@ -207,6 +215,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
var buttonRegions = ["westindia"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function swedencentralButtonClickAction(zEvent) {
|
||||
var buttonName = "swedencentralButton";
|
||||
var buttonRegions = ["swedencentral"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function switzerlandnorthButtonClickAction(zEvent) {
|
||||
var buttonName = "switzerlandnorthButton";
|
||||
var buttonRegions = ["switzerlandnorth"];
|
||||
|
|
@ -404,7 +417,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
};
|
||||
function stage1ButtonClickAction(zEvent) {
|
||||
var buttonName = "stage1Button";
|
||||
var buttonRegions = ["canadacentral", "canadaeast", "centralindia", "southindia", "westindia", "switzerlandnorth", "switzerlandwest", "norwayeast", "germanywestcentral"];
|
||||
var buttonRegions = ["canadacentral", "canadaeast", "centralindia", "southindia", "westindia", "swedencentral", "switzerlandnorth", "switzerlandwest", "norwayeast", "germanywestcentral"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function stage1point5ButtonClickAction(zEvent) {
|
||||
|
|
@ -455,6 +468,10 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
toggleComponent("jobs");
|
||||
toggleButtonColor("jobsButton");
|
||||
};
|
||||
function dltButtonClickAction(zEvent) {
|
||||
toggleComponent("dlt");
|
||||
toggleButtonColor("dltButton");
|
||||
};
|
||||
function odbcButtonClickAction(zEvent) {
|
||||
toggleComponent("odbc");
|
||||
toggleButtonColor("odbcButton");
|
||||
|
|
@ -467,6 +484,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
toggleComponent("sql");
|
||||
toggleButtonColor("sqlButton");
|
||||
};
|
||||
function accountConsoleButtonClickAction(zEvent) {
|
||||
toggleComponent("accountConsole");
|
||||
toggleButtonColor("accountConsoleButton");
|
||||
};
|
||||
|
||||
|
||||
// profile management functions
|
||||
function loadDataplanes() {
|
||||
|
|
@ -480,8 +502,9 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
'<button id="southindiaButton" style="width:156px" type="button">South India</button>' +
|
||||
'<button id="westindiaButton" style="width:156px" type="button">West India</button>' +
|
||||
'</br>' +
|
||||
'<button id="switzerlandnorthButton" style="width:234px" type="button">Switzerland North</button>' +
|
||||
'<button id="switzerlandwestButton" style="width:234px" type="button">Switzerland West</button>' +
|
||||
'<button id="swedencentralButton" style="width:156px" type="button">Sweden Central</button>' +
|
||||
'<button id="switzerlandnorthButton" style="width:156px" type="button">Switzerland North</button>' +
|
||||
'<button id="switzerlandwestButton" style="width:156px" type="button">Switzerland West</button>' +
|
||||
'</br>' +
|
||||
'<button id="norwayeastButton" style="width:234px" type="button">Norway East</button>' +
|
||||
'<button id="germanywestcentralButton" style="width:234px" type="button">Germany West Central</button>' +
|
||||
|
|
@ -558,6 +581,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
"southcentralus",
|
||||
"southeastasia",
|
||||
"southindia",
|
||||
"swedencentral",
|
||||
"switzerlandnorth",
|
||||
"switzerlandwest",
|
||||
"uaenorth",
|
||||
|
|
@ -579,6 +603,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
document.getElementById("centralindiaButton").addEventListener("click", centralindiaButtonClickAction, false);
|
||||
document.getElementById("southindiaButton").addEventListener("click", southindiaButtonClickAction, false);
|
||||
document.getElementById("westindiaButton").addEventListener("click", westindiaButtonClickAction, false);
|
||||
document.getElementById("swedencentralButton").addEventListener("click", swedencentralButtonClickAction, false);
|
||||
document.getElementById("switzerlandnorthButton").addEventListener("click", switzerlandnorthButtonClickAction, false);
|
||||
document.getElementById("switzerlandwestButton").addEventListener("click", switzerlandwestButtonClickAction, false);
|
||||
document.getElementById("norwayeastButton").addEventListener("click", norwayeastButtonClickAction, false);
|
||||
|
|
@ -624,9 +649,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -640,8 +667,9 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
'<button id="canadacentralButton" style="width:234px" type="button">Canada Central</button>' +
|
||||
'<button id="centralindiaButton" style="width:234px" type="button">Central India</button>' +
|
||||
'</br>' +
|
||||
'<button id="switzerlandnorthButton" style="width:234px" type="button">Switzerland North</button>' +
|
||||
'<button id="switzerlandwestButton" style="width:234px" type="button">Switzerland West</button>' +
|
||||
'<button id="swedencentralButton" style="width:156px" type="button">Sweden Central</button>' +
|
||||
'<button id="switzerlandnorthButton" style="width:156px" type="button">Switzerland North</button>' +
|
||||
'<button id="switzerlandwestButton" style="width:156px" type="button">Switzerland West</button>' +
|
||||
'</br>' +
|
||||
'<button id="norwayeastButton" style="width:234px" type="button">Norway East</button>' +
|
||||
'<button id="germanywestcentralButton" style="width:234px" type="button">Germany West Central</button>' +
|
||||
|
|
@ -690,6 +718,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
"norwayeast",
|
||||
"southafricanorth",
|
||||
"southeastasia",
|
||||
"swedencentral",
|
||||
"switzerlandnorth",
|
||||
"switzerlandwest",
|
||||
"uaenorth",
|
||||
|
|
@ -705,6 +734,7 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
|
||||
// regional listeners
|
||||
document.getElementById("canadacentralButton").addEventListener("click", canadacentralCPButtonClickAction, false);
|
||||
document.getElementById("swedencentralButton").addEventListener("click", swedencentralButtonClickAction, false);
|
||||
document.getElementById("switzerlandnorthButton").addEventListener("click", switzerlandnorthButtonClickAction, false);
|
||||
document.getElementById("switzerlandwestButton").addEventListener("click", switzerlandwestButtonClickAction, false);
|
||||
document.getElementById("centralindiaButton").addEventListener("click", centralindiaCPButtonClickAction, false);
|
||||
|
|
@ -739,9 +769,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -801,9 +833,11 @@ if (window.location.href.indexOf("5d49ec10226b9e13cb6a422e") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -856,12 +890,15 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
"auth",
|
||||
"compute",
|
||||
"jobs",
|
||||
"dlt",
|
||||
"odbc",
|
||||
"sql",
|
||||
"webapp"
|
||||
"webapp",
|
||||
"accountConsole"
|
||||
];
|
||||
var regionArray = [
|
||||
"ap-northeast-1",
|
||||
"ap-northeast-2",
|
||||
"ap-south-1",
|
||||
"ap-southeast-1",
|
||||
"ap-southeast-2",
|
||||
|
|
@ -892,9 +929,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
var authGroup = $("div.form-group").filter(":contains('Authentication')");
|
||||
var computeGroup = $("div.form-group").filter(":contains('Compute Service')");
|
||||
var jobsGroup = $("div.form-group").filter(":contains('Jobs Service')");
|
||||
var dltGroup = $("div.form-group").filter(":contains('Delta Live Tables')");
|
||||
var odbcGroup = $("div.form-group").filter(":contains('ODBC/JDBC Service')");
|
||||
var webappGroup = $("div.form-group").filter(":contains('User Interface')");
|
||||
var sqlGroup = $("div.form-group").filter(":contains('Databricks SQL')");
|
||||
var accountConsoleGroup = $("div.form-group").filter(":contains('Account Console')");
|
||||
var ceGroup = $("div.form-group").filter(":contains('Community Edition')");
|
||||
|
||||
// write component HTML template
|
||||
|
|
@ -905,9 +944,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
'<button id="authButton">Auth</button>' +
|
||||
'<button id="computeButton" type="button">Compute</button>' +
|
||||
'<button id="jobsButton" type="button">Jobs</button>' +
|
||||
'<button id="dltButton" type="button">DLT</button>' +
|
||||
'<button id="odbcButton" type="button">ODBC/JDBC</button>' +
|
||||
'<button id="webappButton" type="button">Webapp</button>' +
|
||||
'<button id="sqlButton" type="button">SQL</button>' +
|
||||
'<button id="accountConsoleButton" type="button">Accounts</button>' +
|
||||
'</center></br>';
|
||||
|
||||
// regional functions
|
||||
|
|
@ -971,6 +1012,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
var buttonRegions = ["ap-northeast-1"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function apnortheast2ButtonClickAction(zEvent) {
|
||||
var buttonName = "apnortheast2Button";
|
||||
var buttonRegions = ["ap-northeast-2"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function euwest1ButtonClickAction(zEvent) {
|
||||
var buttonName = "euwest1Button";
|
||||
var buttonRegions = ["eu-west-1"];
|
||||
|
|
@ -993,7 +1039,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
};
|
||||
function stage3amButtonClickAction(zEvent) {
|
||||
var buttonName = "stage3amButton";
|
||||
var buttonRegions = ["ap-south-1", "ap-southeast-2", "ap-northeast-1"];
|
||||
var buttonRegions = ["ap-south-1", "ap-southeast-2", "ap-northeast-1", "ap-northeast-2"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function stage3pmButtonClickAction(zEvent) {
|
||||
|
|
@ -1019,6 +1065,10 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
toggleComponent("jobs");
|
||||
toggleButtonColor("jobsButton");
|
||||
};
|
||||
function dltButtonClickAction(zEvent) {
|
||||
toggleComponent("dlt");
|
||||
toggleButtonColor("dltButton");
|
||||
};
|
||||
function odbcButtonClickAction(zEvent) {
|
||||
toggleComponent("odbc");
|
||||
toggleButtonColor("odbcButton");
|
||||
|
|
@ -1031,6 +1081,10 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
toggleComponent("sql");
|
||||
toggleButtonColor("sqlButton");
|
||||
};
|
||||
function accountConsoleButtonClickAction(zEvent) {
|
||||
toggleComponent("accountConsole");
|
||||
toggleButtonColor("accountConsoleButton");
|
||||
};
|
||||
|
||||
// profile management functions
|
||||
function loadDataplanes() {
|
||||
|
|
@ -1050,9 +1104,10 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
'</br>' +
|
||||
'<button id="apsoutheast1Button" style="width:468px" type="button">ap-southeast-1</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="apsouth1Button" style="width:156px" type="button">ap-south-1</button>' +
|
||||
'<button id="apsoutheast2Button" style="width:156px" type="button">ap-southeast-2</button>' +
|
||||
'<button id="apnortheast1Button" style="width:156px" type="button">ap-northeast-1</button>' +
|
||||
'<button id="apsouth1Button" style="width:117px" type="button">ap-south-1</button>' +
|
||||
'<button id="apsoutheast2Button" style="width:117px" type="button">ap-southeast-2</button>' +
|
||||
'<button id="apnortheast1Button" style="width:117px" type="button">ap-northeast-1</button>' +
|
||||
'<button id="apnortheast2Button" style="width:117px" type="button">ap-northeast-2</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="euwest1Button" style="width:468px" type="button">eu-west-1</button>' +
|
||||
'</center>';
|
||||
|
|
@ -1065,6 +1120,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
// array of active buttons
|
||||
buttonArray = [
|
||||
"apnortheast1",
|
||||
"apnortheast2",
|
||||
"apsouth1",
|
||||
"apsoutheast1",
|
||||
"apsoutheast2",
|
||||
|
|
@ -1094,6 +1150,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("apsoutheast1Button").addEventListener("click", apsoutheast1ButtonClickAction, false);
|
||||
document.getElementById("apsoutheast2Button").addEventListener("click", apsoutheast2ButtonClickAction, false);
|
||||
document.getElementById("apnortheast1Button").addEventListener("click", apnortheast1ButtonClickAction, false);
|
||||
document.getElementById("apnortheast2Button").addEventListener("click", apnortheast2ButtonClickAction, false);
|
||||
document.getElementById("euwest1Button").addEventListener("click", euwest1ButtonClickAction, false);
|
||||
document.getElementById("ceButton").addEventListener("click", ceButtonClickAction, false);
|
||||
|
||||
|
|
@ -1109,9 +1166,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1132,9 +1191,10 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
'<button id="useast2Button" style="width:117px" type="button">us-east-2</button>' +
|
||||
'<button id="apsoutheast1Button" style="width:117px" type="button">ap-southeast-1</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="apsouth1Button" style="width:156px" type="button">ap-south-1</button>' +
|
||||
'<button id="apsoutheast2Button" style="width:156px" type="button">ap-southeast-2</button>' +
|
||||
'<button id="apnortheast1Button" style="width:156px" type="button">ap-northeast-1</button>' +
|
||||
'<button id="apsouth1Button" style="width:117px" type="button">ap-south-1</button>' +
|
||||
'<button id="apsoutheast2Button" style="width:117px" type="button">ap-southeast-2</button>' +
|
||||
'<button id="apnortheast1Button" style="width:117px" type="button">ap-northeast-1</button>' +
|
||||
'<button id="apnortheast2Button" style="width:117px" type="button">ap-northeast-2</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="euwest1Button" style="width:468px" type="button">eu-west-1</button>' +
|
||||
'</center>';
|
||||
|
|
@ -1147,6 +1207,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
// array of active buttons
|
||||
buttonArray = [
|
||||
"apnortheast1",
|
||||
"apnortheast2",
|
||||
"apsouth1",
|
||||
"apsoutheast1",
|
||||
"apsoutheast2",
|
||||
|
|
@ -1174,6 +1235,7 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("apsoutheast1Button").addEventListener("click", apsoutheast1ButtonClickAction, false);
|
||||
document.getElementById("apsoutheast2Button").addEventListener("click", apsoutheast2ButtonClickAction, false);
|
||||
document.getElementById("apnortheast1Button").addEventListener("click", apnortheast1ButtonClickAction, false);
|
||||
document.getElementById("apnortheast2Button").addEventListener("click", apnortheast2ButtonClickAction, false);
|
||||
document.getElementById("euwest1Button").addEventListener("click", euwest1ButtonClickAction, false);
|
||||
document.getElementById("ceButton").addEventListener("click", ceButtonClickAction, false);
|
||||
|
||||
|
|
@ -1189,9 +1251,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1241,9 +1305,11 @@ if (window.location.href.indexOf("5cf02dde58a00904bda41926") > -1) {
|
|||
document.getElementById("authButton").addEventListener("click", authButtonClickAction, false);
|
||||
document.getElementById("computeButton").addEventListener("click", computeButtonClickAction, false);
|
||||
document.getElementById("jobsButton").addEventListener("click", jobsButtonClickAction, false);
|
||||
document.getElementById("dltButton").addEventListener("click", dltButtonClickAction, false);
|
||||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1295,7 +1361,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
"jobs",
|
||||
"odbc",
|
||||
"sql",
|
||||
"webapp"
|
||||
"webapp",
|
||||
"accountConsole"
|
||||
];
|
||||
var regionArray = [
|
||||
"australia-southeast1",
|
||||
|
|
@ -1306,7 +1373,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
"us-east1",
|
||||
"us-east4",
|
||||
"us-west1",
|
||||
"us-west4"
|
||||
"us-west4",
|
||||
"europe-west3"
|
||||
];
|
||||
var buttonArray = [];
|
||||
|
||||
|
|
@ -1327,6 +1395,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
var odbcGroup = $("div.form-group").filter(":contains('ODBC/JDBC Service')");
|
||||
var webappGroup = $("div.form-group").filter(":contains('User Interface')");
|
||||
var sqlGroup = $("div.form-group").filter(":contains('Databricks SQL')");
|
||||
var accountConsoleGroup = $("div.form-group").filter(":contains('Account Console')");
|
||||
|
||||
|
||||
// write component HTML template
|
||||
var componentsHTML = '<center>' +
|
||||
|
|
@ -1339,6 +1409,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
'<button id="odbcButton" type="button">ODBC/JDBC</button>' +
|
||||
'<button id="webappButton" type="button">Webapp</button>' +
|
||||
'<button id="sqlButton" type="button">SQL</button>' +
|
||||
'<button id="accountConsoleButton" type="button">Accounts</button>' +
|
||||
'</center></br></br>';
|
||||
|
||||
// regional functions
|
||||
|
|
@ -1387,6 +1458,11 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
var buttonRegions = ["us-west4"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function europewest3ButtonClickAction(zEvent) {
|
||||
var buttonName = "europewest3Button";
|
||||
var buttonRegions = ["europe-west3"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
function stage1ButtonClickAction(zEvent) {
|
||||
var buttonName = "stage1Button";
|
||||
var buttonRegions = ["europe-west1"];
|
||||
|
|
@ -1404,7 +1480,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
};
|
||||
function stage3pmButtonClickAction(zEvent) {
|
||||
var buttonName = "stage3pmButton";
|
||||
var buttonRegions = ["us-west4"];
|
||||
var buttonRegions = ["us-west4", "europe-west3"];
|
||||
toggleRegion(buttonName, buttonRegions);
|
||||
};
|
||||
|
||||
|
|
@ -1437,6 +1513,10 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
toggleComponent("sql");
|
||||
toggleButtonColor("sqlButton");
|
||||
};
|
||||
function sqlButtonClickAction(zEvent) {
|
||||
toggleComponent("accountConsole");
|
||||
toggleButtonColor("accountConsoleButton");
|
||||
};
|
||||
|
||||
function loadControlplanes() {
|
||||
currentMode = "controlplane";
|
||||
|
|
@ -1454,7 +1534,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
'<button id="australiasoutheast1Button" style="width:234px" type="button">Australia-Southeast1</button>' +
|
||||
'<button id="asiasoutheast1Button" style="width:234px" type="button">Asia-Southeast1</button>' +
|
||||
'</br></br>' +
|
||||
'<button id="uswest4Button" style="width:468px" type="button">US-West4</button>' +
|
||||
'<button id="uswest4Button" style="width:234px" type="button">US-West4</button>' +
|
||||
'<button id="europewest3Button" style="width:234px" type="button">EU-West3</button>' +
|
||||
'</br></center>'
|
||||
;
|
||||
zNode.innerHTML = profilesHTML + '<hr class="solid">' + controlplaneHTML + '<hr class="solid">' + componentsHTML + auxHTML;
|
||||
|
|
@ -1472,7 +1553,8 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
"useast1",
|
||||
"useast4",
|
||||
"uswest1",
|
||||
"uswest4"
|
||||
"uswest4",
|
||||
"europewest3"
|
||||
];
|
||||
if (debugFlag == true) {
|
||||
console.log("buttonArray: " + buttonArray);
|
||||
|
|
@ -1491,6 +1573,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
document.getElementById("useast4Button").addEventListener("click", useast4ButtonClickAction, false);
|
||||
document.getElementById("uswest1Button").addEventListener("click", uswest1ButtonClickAction, false);
|
||||
document.getElementById("uswest4Button").addEventListener("click", uswest4ButtonClickAction, false);
|
||||
document.getElementById("europewest3Button").addEventListener("click", europewest3ButtonClickAction, false);
|
||||
|
||||
// profile listeners
|
||||
document.getElementById("controlplanesButton").addEventListener("click", controlplanesButtonClickAction, false);
|
||||
|
|
@ -1506,6 +1589,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1558,6 +1642,7 @@ if (window.location.href.indexOf("60087ab5608daf0535dc8e23") > -1) {
|
|||
document.getElementById("odbcButton").addEventListener("click", odbcButtonClickAction, false);
|
||||
document.getElementById("webappButton").addEventListener("click", webappButtonClickAction, false);
|
||||
document.getElementById("sqlButton").addEventListener("click", sqlButtonClickAction, false);
|
||||
document.getElementById("accountConsoleButton").addEventListener("click", accountConsoleButtonClickAction, false);
|
||||
document.getElementById("allComponentsButton").addEventListener("click", allComponentsButtonClickAction, false);
|
||||
|
||||
// aux listeners
|
||||
|
|
@ -1719,12 +1804,22 @@ function checkButtonColor(buttonName) {
|
|||
return color;
|
||||
};
|
||||
function selectCheckbox(box) {
|
||||
try {
|
||||
box.filter("A")[0].classList.add("checked");
|
||||
box.filter("INPUT")[0].checked = true;
|
||||
} catch (e) {
|
||||
console.log(box + " does not appear to exist");
|
||||
}
|
||||
|
||||
};
|
||||
function deselectCheckbox(box) {
|
||||
try {
|
||||
box.filter("A")[0].classList.remove("checked");
|
||||
box.filter("INPUT")[0].checked = false;
|
||||
} catch (e) {
|
||||
console.log(box + " does not appear to exist");
|
||||
}
|
||||
|
||||
};
|
||||
function apply() {
|
||||
if (debugFlag == true) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue