forked from dragonhuntr/Lotus-AIO
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.js
82 lines (75 loc) · 2.75 KB
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
function start_all(){
elems = document.getElementsByName('start');
for (let elem of elems) {
if (typeof elem.onclick == "function") {
elem.onclick.apply(elem);
}
}
}
function delete_all(){
elems = document.getElementsByName('delete');
for (let elem of elems) {
if (typeof elem.onclick == "function") {
elem.onclick.apply(elem);
}
}
}
function stop_all(){
elems = document.getElementsByName('stop');
for (let elem of elems) {
if (typeof elem.onclick == "function") {
elem.onclick.apply(elem);
}
}
}
const async = require('async')
async function stopTask(taskid){
if (tasks[taskid].stopped == false){
tasks[taskid].stopped = true;
changeStatus(taskid, "primary", "Stopped");
}
}
function showProfiles(){
document.getElementById("contentDashboard").style.display = "none";
document.getElementById("contentProxies").style.display = "none";
document.getElementById("contentNewTask").style.display = "none";
document.getElementById("contentProfile").style.display = "";
document.querySelectorAll('li.botSelection').forEach(e => {
e.style="";
});
document.getElementById('profNav').style="background-color: #2c4384";
window.scrollTo(0, 0);
}
function showNewTask(){
document.getElementById("contentDashboard").style.display = "none";
document.getElementById("contentProfile").style.display = "none";
document.getElementById("contentProxies").style.display = "none";
document.getElementById("contentNewTask").style.display = "";
document.querySelectorAll('li.botSelection').forEach(e => {
e.style="";
});
document.getElementById('taskNav').style="background-color: #2c4384";
window.scrollTo(0, 0);
}
function showProxies(){
document.getElementById("contentDashboard").style.display = "none";
document.getElementById("contentProfile").style.display = "none";
document.getElementById("contentNewTask").style.display = "none";
document.getElementById("contentProxies").style.display = "";
document.querySelectorAll('li.botSelection').forEach(e => {
e.style="";
});
document.getElementById('proxyNav').style="background-color: #2c4384";
window.scrollTo(0, 0);
}
function showDashboard(){
document.getElementById("contentProfile").style.display = "none";
document.getElementById("contentNewTask").style.display = "none";
document.getElementById("contentProxies").style.display = "none";
document.getElementById("contentDashboard").style.display = "";
document.querySelectorAll('li.botSelection').forEach(e => {
e.style="";
});
document.getElementById('dashNav').style="background-color: #2c4384";
window.scrollTo(0, 0);
}