-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathkiosk.html
421 lines (364 loc) · 15.8 KB
/
kiosk.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
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
<!DOCTYPE html>
<html class="no-js" lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>Evidence Library 4 Web</title>
<link href="css/app.css" type="text/css" rel="stylesheet" media="screen"/>
<link href="css/font-awesome.css" type="text/css" rel="stylesheet" media="all" />
<link href="http://fonts.googleapis.com/css?family=Libre+Baskerville:400italic" type="text/css" rel="stylesheet" media="all" />
<link href="css/jquery.qtip.css" rel="stylesheet" />
<link rel="stylesheet" href="css/test.css" />
<link href="css/print.css" type="text/css" rel="stylesheet" media="print" />
<link rel="shortcut icon" href="images/favicon.ico" type="image/x-icon"/>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="mobile-web-app-capable" content="yes">
<script src="js/modernizr.js"></script>
<!--[if gte IE 9]>
<style type="text/css">
.gradient {filter: none;}
</style>
<![endif]-->
</head>
<body class="kiosk">
<section class="main-section clearfix">
<header id="kiosk-header" class="">
<img src="images/kiosk-logo.png" id="kiosk-logo" alt="" />
</header><!-- end header #kiosk-header. -->
<div class="row">
<div class="small-12 medium-12 large-12 columns">
<h2 class="select-officer text-centered"><i class="fa fa-user"></i> Select an Officer</h2>
<div id="officername-wrapper">
<input id="officername" name="officername" type="text" value="" placeholder="Enter an Officer Name" tabindex="1"/>
<a href="javascript:void(0);" class="toggle"><i class="fa fa-chevron-down"></i></a>
</div><!-- end div#input-wrapper -->
<button id="change-config" tabindex="2">
<span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-cogs fa-stack-1x fa-inverse"></i>
</span>
Change Officer Preferences / Device Settings</button>
</div><!-- end columns -->
</div><!-- end row -->
<div id="checkout-config-outer-wrapper">
<div id="checkout-config-wrapper">
<div class="row">
<div class="small-12 medium-12 large-12 columns">
<h5>Officer Preferences</h5>
</div><!-- end columns -->
</div><!-- end row -->
<div class="row">
<div class="small-12 medium-6 large-6 columns">
<label for="" class=""><i class="fa fa-sun-o"></i> LED Brightness</label>
<select class="select" tabindex="3">
<option value="">Dim</option>
<option value="" selected>Normal</option>
<option value="">Bright</option>
</select>
<label for="auto-reduce">
<input type="checkbox" name="auto-reduce" id="auto-reduce" tabindex="4"/>
<small>Auto reduce LED brightness between 8pm - 8am</small>
</label>
<br/>
</div><!-- end columns -->
<div class="small-12 medium-6 large-6 columns">
<label for="" class=""><i class="fa fa-volume-up"></i> Alert Notifications</label>
<select class="select" tabindex="5">
<option value="">Audio & Vibration</option>
<option value="">Audio Only</option>
<option value="">Vibration Only</option>
</select>
</div><!-- end columns -->
</div><!-- end row -->
<div class="row">
<div class="small-12 medium-6 large-6 columns">
<label for="" class=""><i class="fa fa-signal"></i> Audio Alert Levels</label>
<select class="select" tabindex="6">
<option value="">Low</option>
<option value="" selected>Normal</option>
<option value="">High</option>
</select>
</div><!-- end columns -->
<div class="small-12 medium-6 large-6 columns">
<label for="" class=""><i class="fa fa-wrench"></i> Select A Configuration</label>
<select class="select" id="rapid-config" tabindex="7">
<option value="">Config. 1</option>
<option value="">Config. 2</option>
<option value="">Config. 3</option>
</select>
</div><!-- end columns -->
</div><!-- end row -->
</div><!-- end div#checkout-config-wrapper -->
</div><!-- end div#checkout-config-outer-wrapper -->
<button id="kiosk-submit" tabindex="8">
<div class="circle">
<i class="fa fa-angle-double-right fa-stack-1x fa-inverse"></i>
</div>
<img src="images/vista-button-text.png" class="button-img" alt="" />
<span class="">Checkout</span>
</button>
<div id="assigned-devices-wrapper">
<div id="assigned-devices">
<!-- Officers appended here -->
</div><!-- end div#assigned-devices -->
<a href="javascript:void(0);" id="toggle-history" class=""><span>Show History <i class="fa fa-angle-double-down"></i></span></a>
</div><!-- end div#assigned-devices-wrapper -->
<a href="javascript:void(0);" id="fullscreen-toggle" class="has-tip" title="Show Kiosk in Full Screen">Fullscreen</a>
<a href="javascript:void(0);" id="kiosk-options" class="button radius has-tip" title="Kiosk Mode Settings" data-reveal-id="kiosk-options-modal"><i class="fa fa-cog"></i></a>
<a href="javascript:void(0);" id="kiosk-logout" class="button radius has-tip" title="Logout of Kiosk Mode"><i class="fa fa-power-off"></i></a>
</section>
<!-- end main section -->
<script type="text/javascript" src="js/jquery.min.js"></script>
<script type="text/javascript" src="js/foundation.min.js"></script>
<script type="text/javascript" src="js/chosen.jquery.js"></script>
<script type="text/javascript" src="js/jquery.qtip.js"></script>
<script type="text/javascript" src="js/app.js"></script>
<script type="text/javascript" charset="utf-8">
// mozfullscreenerror event handler
function errorHandler() {
alert('mozfullscreenerror');
}
document.documentElement.addEventListener('mozfullscreenerror', errorHandler, false);
// toggle full screen
function toggleFullScreen() {
if (!document.fullscreenElement && // alternative standard method
!document.mozFullScreenElement && !document.webkitFullscreenElement) { // current working methods
if (document.documentElement.requestFullscreen) {
document.documentElement.requestFullscreen();
} else if (document.documentElement.mozRequestFullScreen) {
document.documentElement.mozRequestFullScreen();
} else if (document.documentElement.webkitRequestFullscreen) {
document.documentElement.webkitRequestFullscreen(Element.ALLOW_KEYBOARD_INPUT);
}
$('html').addClass('fullscreen');
} else {
if (document.cancelFullScreen) {
document.cancelFullScreen();
} else if (document.mozCancelFullScreen) {
document.mozCancelFullScreen();
} else if (document.webkitCancelFullScreen) {
document.webkitCancelFullScreen();
}
$('html').removeClass('fullscreen');
}
}
$(document).ready(function(){
// toggle Fullscreen funtion
$('#fullscreen-toggle').on('click', function(){
toggleFullScreen();
});
// show change config options
$('#change-config').on('click', function(){
$(this).toggleClass('change');
if($(this).hasClass('change')){
$('#checkout-config-outer-wrapper').slideDown();
} else {
$('#checkout-config-outer-wrapper').slideUp();
}
});
$('#officername').val('').focus();
var items = 1;
// Submit device assignment
$('#kiosk-submit').click(function(){
// collapse the history list, if shown
$('#assigned-devices').removeClass('expand');
// show the assigned device info (officer, location)
$('#assigned-devices-wrapper').fadeIn();
setTimeout(function() {
$('#assigned-devices-wrapper').removeClass('pressed');
}, 1000);
// hide the config options and prep for another officer
$('#change-config').removeClass('change');
$('#checkout-config-outer-wrapper').slideUp();
// focus cursor in Officer Name field
// we need to reset the options in the config form to default
$('#checkout-config-outer-wrapper .select').each(function(){
$(this)[0].selectedIndex = 0;
$(this).trigger('chosen:updated');
});
// show the check mark for a second or so, then reset button
$(this).addClass('pressed');
setTimeout(function() {
$('#kiosk-submit').removeClass('pressed');
}, 1000);
var officername = $('#officername').val() !=='' ? 'Officer '+$('#officername').val() : 'Officer LastName, FirstName',
station = Math.ceil(Math.random() * 12),
slot = Math.ceil(Math.random() * 8);
$('#assigned-devices').append('<div class="assigned-device">'+
'<div class="name">'+officername+'</div>'+
'<div class="location">'+
'Transfer Station '+station+'A, Slot '+slot+
'</div><!-- end span.location -->'+
'</div><!-- end div.assigned-device -->');
$('#officername').val('').focus();
items++;
if(items > 2){
$('#toggle-history').show();
} else {
$('#toggle-history').hide();
}
});
// toggle class on Show/Hide Assigned History
$('#toggle-history').hide();
var active;
$('#toggle-history').on('click', function(){
if(active === true){
$(this).html('<span>Show History <i class="fa fa-angle-double-down"></i></span>');
active = false;
} else {
$(this).html('<span>Hide History <i class="fa fa-angle-double-up"></i></span>');
active = true;
}
// expands the height of the Device History div
$('#assigned-devices').toggleClass('expand');
});
// pop print report modal on submit of selected option in #select-checkout-report,
// reset the #select-checkout-report to first option
$('#submit-checkout-report').on('click', function(){
$('#checkout-report-modal').foundation('reveal', 'open');
$('#select-checkout-report')[0].selectedIndex = 0;
$('#select-checkout-report').trigger('chosen:updated');
});
// display the selected print report in new window
$('.checkout-report').on('click', function(){
openWindowReport();
});
}); // end docready
var windowReport = null; // global variable
function openWindowReport() {
if(windowReport == null || windowReport.closed) {
windowReport = window.open('checkout-report.html', '_blank', 'toolbar=0,titlebar=0,status=0,location=0,menubar=0,height=640,width=1024');
} else {
windowReport.focus();
};
}
document.addEventListener('keydown', function(e) {
if (e.altKey && e.keyCode == 70 ) { // ALT + F ---------- and/or ------ e.keyCode == 13 (ENTER KEY)
toggleFullScreen();
}
}, false);
</script>
<div id="rapid-checkout-modal" class="reveal-modal fixed-modal small show-footer" data-reveal>
<div class="modal-header">
<div class="modal-title">Checkout Complete</div>
</div>
<div class="modal-body">
<div class="row">
<div class="small-12 medium-12 large-12 columns">
<strong> Officer Pitcher, Matthew</strong><br/>
Transfer Station <strong>B21, Slot 3</strong><br/>
</div>
<!-- end row -->
</div>
<div class="modal-footer shaded-footer">
<button class="button secondary close-modal">Close</button>
<button class="button success modalsave close-modal">Done</button>
</div>
<a class="close-reveal-modal">×</a>
</div>
<div id="checkout-report-modal" class="reveal-modal fixed-modal xlarge show-footer" data-reveal>
<div class="modal-header">
<div class="modal-title">Checkout Report</div>
</div>
<div class="modal-body">
<div class="row" id="checkout-report-wrapper">
<div class="small-12 medium-12 large-12 columns">
<div id="checkout-report-details">
<div class="checkout-report-detail checkout-report-detail-header">
<div class="checkout-assignee">Officer Name</div>
<div class="checkout-device-config">Config.</div>
<div class="checkout-device-location">Location</div>
<div class="checkout-device-station">Station/Slot</div>
<div class="checkout-device-name">Device Name</div>
</div>
<div class="checkout-report-detail">
<div class="checkout-assignee">Johnny B. Good</div>
<div class="checkout-device-config">Config. 1</div>
<div class="checkout-device-location">Building 1</div>
<div class="checkout-device-station">Station #/slot</div>
<div class="checkout-device-name">Vista VL-167</div>
</div>
<div class="checkout-report-detail">
<div class="checkout-assignee">Johnny B. Good</div>
<div class="checkout-device-config">Config. 1</div>
<div class="checkout-device-location">Building 1</div>
<div class="checkout-device-station">Station #/slot</div>
<div class="checkout-device-name">Vista VL-169</div>
</div>
<div class="checkout-report-detail">
<div class="checkout-assignee">Johnny B. Good</div>
<div class="checkout-device-config">Config. 1</div>
<div class="checkout-device-location">Building 1</div>
<div class="checkout-device-station">Station #/slot</div>
<div class="checkout-device-name">Vista VL-185</div>
</div>
<div class="checkout-report-detail">
<div class="checkout-assignee">Johnny B. Good</div>
<div class="checkout-device-config">Config. 1</div>
<div class="checkout-device-location">Building 1</div>
<div class="checkout-device-station">Station #/slot</div>
<div class="checkout-device-name">Vista VL-144</div>
</div>
<div class="checkout-report-detail">
<div class="checkout-assignee">Johnny B. Good</div>
<div class="checkout-device-config">Config. 1</div>
<div class="checkout-device-location">Building 1</div>
<div class="checkout-device-station">Station #/slot</div>
<div class="checkout-device-name">Vista VL-201</div>
</div>
</div><!-- #checkout-report-details -->
</div><!-- end div#report-checkout-list -->
</div><!-- end row -->
</div><!-- /modal-body -->
<div class="modal-footer shaded-footer">
<button class="button secondary close-modal" >Close</button>
<button class="button success modalsave checkout-report" >Print Checkout Report</button>
</div>
<a class="close-reveal-modal">×</a>
</div>
<div id="kiosk-options-modal" class="reveal-modal fixed-modal small show-footer" data-reveal>
<div class="modal-header">
<div class="modal-title">Kiosk Options</div>
</div>
<div class="modal-body">
<div class="panel radius">
<div class="row">
<div class="small-12 medium-12 large-12 columns">
<form action="" method="POST" accept-charset="utf-8" >
<label for="select-location">Kiosk Service Location</label>
<select class="select" id="select-location">
<option value="">Select A Location</option>
<option value="">Building 1</option>
<option value="">Building 2</option>
<option value="">Annex 3</option>
</select>
</form>
<button class="button success close-modal no-margin">Save Location</button>
</div><!-- end columns -->
</div><!-- end row -->
</div><!-- end div.panel radius -->
<div class="panel radius">
<div class="row">
<div class="small-12 medium-12 large-12 columns">
<label for="select-checkout-report">Print Checkout Report</label>
<select class="select" id="select-checkout-report">
<option value="">- Select Reporting Period -</option>
<option value="">Print Last 1 Hours</option>
<option value="">Print Last 3 Hours</option>
<option value="">Print Last 5 Hours</option>
<option value="">Print Last 7 Hours</option>
<option value="">Print Last 12 Hours</option>
</select>
<button class="button success no-margin" id="submit-checkout-report">Print Checkout Report</button>
</div><!-- end columns -->
</div><!-- end row -->
</div><!-- end div.panel radius -->
</div><!-- / modal-body -->
<div class="modal-footer shaded-footer">
<button class="button secondary close-modal">Close</button>
</div>
<a class="close-reveal-modal">×</a>
</div>
</body>
</html>