-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
136 lines (124 loc) · 5.59 KB
/
index.html
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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<link rel="stylesheet" type="text/css" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/css/master.css"/>
<script src="https://code.jquery.com/jquery-3.3.1.min.js" type="text/javascript"></script>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/jquery-ui.js"></script>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/jquery.layout_and_plugins.min.js"></script>
<script type="text/javascript" src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/api.js"></script>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/modals/iziToast.min.js"></script>
<link rel="stylesheet" type="text/css" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/modals/iziToast.css"/>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/modals/iziModal.min.js"></script>
<link rel="stylesheet" type="text/css" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/modals/iziModal.min.css"/>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/modals/jquery-resizable.js"></script>
<link rel="stylesheet" type="text/css" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/datatables.min.css"/>
<link rel="stylesheet" type="text/css" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/jquery-ui.css"/>
<link rel="stylesheet" type="text/css" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/css/hamburgers.css"/>
<link rel="stylesheet" type="text/css" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/jquery-ui-timepicker-addon.css"/>
<link rel="stylesheet" type="text/css" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/layout-default.css"/>
<script type="text/javascript" src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/datatables.min.js"></script>
<script type="text/javascript" src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/moment.js"></script>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/dataTables.scrollResize.min.js"></script>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/dataTables.pageResize.min.js"></script>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/jquery.popupoverlay.js"></script>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/build/pdf.js"></script>
<script src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/easyPDF.js"></script>
<script type="text/javascript" src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/jquery-ui-timepicker-addon.js"></script>
<script type="text/javascript" src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/datetime-moment.js"></script>
<link rel="stylesheet" href="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/diffstyle.css"/>
<script type="text/javascript" src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/diff.js"></script>
<script type="text/javascript" src="https://hieadmin-cert.gl-hc.org/csp/gridclient/js/hl7.js"></script>
<title>Home</title>
</head>
<body>
<div class="wrap">
<div class="header">
<div class="nav">
<button href="changepassword.csp" class="button-primary">Profile</button>
<button href="routes.html" class="button-primary">Routes</button>
<button href="search.html" class="button-primary" id="default_page">Message Search</button>
</div>
<div class="logo">
<img src="https://hieadmin-cert.gl-hc.org/csp/gridclient/images/GLHC_Final Logo W_Digital_10.23.png" alt="GLHC Logo" height="56px">
</div>
<button href="login.html" class="button-primary button-red" id="logout">Logout</button>
</div>
<div class="content"></div>
</div>
</body>
</html>
<script>
idleMax = 10;// Logout after < 10 minutes of IDLE
idleTime = 0;
var idleQueue = false;
$(document).ready(function () {
// Idle pool, checks on interval
setInterval(checkIdle, 10000);
$('#default_page').addClass('selected_page')
var idleInterval = setInterval("timerIncrement()", 60000);
$(this).mousemove(function (e) {
idleTime = 0;
updateIdle();
});
$(this).keypress(function (e) {
idleTime = 0;
updateIdle();
/*
iziToast.success({
title: '⍟ Test Notifications',
message: "They're working!",
});
*/
});
});
// Checks bool value, and tickles the server if not idle, reseting the bool
function checkIdle() {
if (!idleQueue) return
$.ajax({
url:serverURL+"refresh",
type: "GET",
contentType: "application/json",
dataType: "text",
success: function(response) {
idleQueue = !idleQueue
}
});
}
// Updates the idle bool
function updateIdle() {
idleQueue = true;
}
// Updates our idle timer that controls the logout notification
function timerIncrement() {
idleTime += 1;
if (idleTime > idleMax) {
window.location.href = '?CacheLogout=1';
setCookie("page", "", 0);
} else if (idleTime >= 8) {
iziToast.question({
timeout: 10000,
close: false,
overlay: true,
pauseOnHover: false,
toastOnce: true,
id: 'question',
zindex: 999,
title: 'Hey',
message: "You're about to be logged out",
position: 'center',
buttons: [[
'<button><b>Keep me in!</b></button>', function (instance, toast) {
instance.hide({ transitionOut: 'fadeOut' }, toast, 'button');
}, true]
],
onClosing: function(instance, toast, closedBy){
if(closedBy == "timeout") {
window.location.href = '?CacheLogout=1';
setCookie("page", "", 0);
}
},
});
}
}
</script>