-
Notifications
You must be signed in to change notification settings - Fork 5
/
accounts.html
247 lines (188 loc) · 9.72 KB
/
accounts.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
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1.0, user-scalable=no">
<link rel="stylesheet" href="./css/bootstrap.min.css">
<script language="JavaScript" type="text/javascript" src="./js/jquery/jquery-3.6.0.min.js"></script>
<script language="JavaScript" type="text/javascript" src="./js/jquery/jquery-ui.min.js"></script>
<script language="JavaScript" type="text/javascript" src="./js/bootstrap.bundle.min.js"></script>
<link rel="stylesheet" type="text/css" href="./js/jquery/jquery-ui.min.css">
<link rel="stylesheet" type="text/css" href="./css/css_styles.css">
<link rel="stylesheet" type="text/css" href="./css/css_styles2.css">
<script language="JavaScript" type="text/javascript" src="./js/js_dictionary.js"></script>
<script language="JavaScript" type="text/javascript" src="./js/js_helpers.js"></script>
<script language="JavaScript" type="text/javascript" src="./siteConfig.js"></script>
<script language="JavaScript" type="text/javascript" src="./js/js_globals.js"></script>
<script language="JavaScript" type="text/javascript" src="./js/js_eventEmitter.js"></script>
<script language="JavaScript" type="text/javascript" src="./js/js_localStorage.js"></script>
<script language="JavaScript" type="text/javascript" src="./js/js_andruavAuth.js"></script>
<script language="JavaScript" type="text/javascript" src="./js/js_captcha.js"></script>
<script src="./js/react2/babel.js"></script>
<script src="./js/react2/react.development.js"></script>
<script src="./js/react2/react-dom.development.js"></script>
<script>
Babel.registerPreset("my-preset", {
presets: [
[Babel.availablePresets["es2015"], { "modules": false }],
[Babel.availablePresets["react"]]
],
plugins: [
[Babel.availablePlugins["transform-modules-umd"]]
],
moduleId: "main"
});
</script>
<script type="text/babel" data-plugins="transform-modules-umd" src="./js/components/jsc_cmp_login.jsx"></script>
</head>
<style>
</style>
<script type="text/javascript">
function gui_alert(title,message,level)
{
$('#alert #title').html(title);
$('#alert #title').html(title);
$('#alert #msg').html(message);
$('#alert').removeClass();
$('#alert').addClass('alert alert-' + level);
$('#alert').show();
}
function gui_alert_hide()
{
$('#alert').hide();
}
function fn_do_modal_confirmation (p_title,p_message,p_callback,p_yesCaption,p_style)
{
if (p_style == null)
{
p_style = "bg-success text-white";
}
$('#modal_saveConfirmation').children().find('h4#title').html(p_title);
$('#modal_saveConfirmation').children().find('h4#title').removeClass();
$('#modal_saveConfirmation').children().find('h4#title').addClass("modal-title " + p_style);
$('#modal_saveConfirmation').children().find('div.modal-body p#conf').html(p_message);
$('#modal_saveConfirmation').children().find('div.modal-body p#res').html("");
$('#modal_saveConfirmation').children().find('button#geo_btn_confirm').off('26492d902b1126492cb9'._fn_hexDecode() /*'click'*/);
$('#modal_saveConfirmation').children().find('button#geo_btn_confirm').unbind('26492d902b1126492cb9'._fn_hexDecode() /*'click'*/);
$('#modal_saveConfirmation').children().find('button#geo_btn_confirm').click(p_callback);
if (p_yesCaption!= null)
{
$('#modal_saveConfirmation').children().find('button#geo_btn_confirm').html(p_yesCaption);
}
$('#modal_saveConfirmation').modal('show');
}
function fn_clickRegenerate () {
window.AndruavLibs.LocalStorage.setEmail($('#txtEmail').val());
window.AndruavLibs.LocalStorage.setAccessCode($('#txtAccessCode').val());
window.AndruavLibs.AndruavPermissions.fn_regenerateLoginAfterLogin($('#txtEmail').val(),$('#txtAccessCode').val());
}
$(document).ready (function ()
{
//triggered when modal is about to be shown
$('#deletemodal').on('show.bs.modal', function(e) {
//get data-id attribute of the clicked element
var pwdid = $(e.relatedTarget).data('pwdid');
//populate the textbox
$(e.currentTarget).find('#Heading').text("Delete access code " + pwdid + "?" );
$(e.currentTarget).attr('pwdid',pwdid);
});
window.AndruavLibs.EventEmitter.fn_subscribe ( EE_Auth_Account_Created, this,
function (p_sender,p_msg)
{
var v_Message = "<p class='text-success'>Access Code Created Successfully.</p>";
if (p_msg.hasOwnProperty(CONST_ACCESS_CODE_PARAMETER.toString()) === true)
{
v_Message += "<p class='text-success'>Access Code: <span class='text-warning'><strong>" + p_msg[CONST_ACCESS_CODE_PARAMETER.toString()] + "</strong></span></p>"
}
$('#modal_saveConfirmation').children().find('div.modal-body p#res').html(v_Message);
});
window.AndruavLibs.EventEmitter.fn_subscribe ( EE_Auth_Account_Regenerated, this,
function (p_sender,p_msg)
{
var v_Message = "<p class='text-success'>New Access Code Created Successfully.";
if (p_msg.hasOwnProperty(CONST_ACCESS_CODE_PARAMETER.toString()) === true)
{
v_Message += "<p class='text-success'>Access Code: <span class='text-warning'><strong>" + p_msg[CONST_ACCESS_CODE_PARAMETER.toString()] + "</strong></span></p>"
}
$('#modal_saveConfirmation').children().find('div.modal-body p#res').html(v_Message);
});
window.AndruavLibs.EventEmitter.fn_subscribe ( EE_Auth_Account_BAD_Operation, this,
function (p_sender,p_msg)
{
if (p_msg != null)
{
var v_Message = "<p class='text-danger'>Operation Failed: <strong>" + p_msg[CONST_ERROR_MSG.toString()]+ "</strong></p>";
if (p_msg.hasOwnProperty(CONST_ACCESS_CODE_PARAMETER.toString()) === true)
{
v_Message += "<p class='text-success'>Access Code: <span class='text-warning'><strong>" + p_msg[CONST_ACCESS_CODE_PARAMETER.toString()] + "</strong></span></p>"
}
$('#modal_saveConfirmation').children().find('div.modal-body p#res').html(v_Message);
}
else
{
$('#modal_saveConfirmation').children().find('div.modal-body p#res').html("<p class='text-danger'>Operation Failed: <strong> Cannot Reach Server </strong></p>");
}
});
});
</script>
<body>
<div id="header"></div>
<div id="modal_saveConfirmation" class="modal fade" role="dialog">
<div class="modal-dialog">
<!-- Modal content-->
<div class="modal-content">
<div class="modal-header">
<button type="button" class="margin_zero btn-close" data-bs-dismiss="modal" aria-hidden="true">×</button>
<h4 id="title" class="modal-title bg-success text-white"><strong>Attention:</strong> Delete Operation.</h4>
</div>
<div class="modal-body">
<p id="conf">XAre you?</p>
<div class='row'>
<div class='col-sm-6'>
<div class="capbox">
<div id="CaptchaDiv"></div>
<div class="capbox-inner">
Type the above number:<br/>
<input type="hidden" id="txtCaptcha"/>
<input type="text" name="CaptchaInput" id="CaptchaInput" size="15"/><br/>
<br/><br/>
</div>
</div>
</div>
<div class='col-sm-6'>
<p id="res">XAre you?</p>
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-muted" data-bs-dismiss="modal">Cancel</button>
<button id="geo_btn_confirm" type="button" class="btn btn-danger" >Submit</button>
</div>
</div>
</div>
</div>
</div>
<div class="">
<div class="container">
<div class="row margin_zero container ">
<div id="loginCtrl" class=""></div>
</div>
<br>
<div class="row margin_zero container">
<div id="help" class="">
<h3 class="text-primary" >Quick Help</h3>
<ol>
<li> You can generate access code easily from this webpage. You can also regenerate your access code i.e. change it.</li>
<li> Make sure you use a valid email as access code is sent to your email.</li>
<li> If this is your first time to use the system then please select press "AccessCode".</li>
<li> "Regenerate" will create a new access code -password- or a secondary account with different permissions.</li>
<li> Secondary account will have the same email but different access code -password-.</li>
<li> Check this <a href="https://cloud.ardupilot.org/de-account-create.html" target="_blank">page</a> for simple installation instructions.</li>
<li> For Support please contribute to <a href="https://discuss.ardupilot.org/" target="_blank">https://discuss.ardupilot.org/</a></li>
</ol>
</div>
</div>
</div>
<div id="footer"></div>
</body>
<script src="./js/js_main_last.js"></script>
</html>