forked from Bendr0id/xmrigCC
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
executable file
·1524 lines (1347 loc) · 104 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
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
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html lang=\"en\" xmlns="http://www.w3.org/1999/html">
<head>
<meta charset=\"utf-8\">
<title>XMRigCC Dashboard</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.20/css/dataTables.bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/buttons/1.5.0/css/buttons.bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/select/1.2.5/css/select.dataTables.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-select/1.13.2/css/bootstrap-select.min.css">
<link rel="stylesheet" href="https://gitcdn.github.io/bootstrap-toggle/2.2.2/css/bootstrap-toggle.min.css">
<link rel="stylesheet" href="https://cdn.datatables.net/rowgroup/1.1.1/css/rowGroup.dataTables.min.css">
<link href="data:image/x-icon;base64,AAABAAEAMDAAAAEAIACoJQAAFgAAACgAAAAwAAAAYAAAAAEAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACYAAABQAAAAfQAAAKcAAADFAAAA3AAAAPEAAADwAAAA2wAAAMQAAAClAAAAfAAAAE8AAAAkAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABtAAAA7AAAAPoAAAD+AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP4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AAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAANsAAAD/AAAA/xYTDP/qx3z/9dCC//jShP8YFA3/AAAA/wMCAv//2Yf/9dCC/+XDev8YFQ3/AAAA/wAAAP8AAAD/kpKS////////////////////////////////////////////////////////////////////////////e3t7/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAPAAAAD/AAAA/xYTDP/qx3z/9dCC//jShP8YFQ3/AAAA/wMCAv//2Yf/9dCC/+XCev8YFQ3/AAAA/wAAAP8AAAD/aGho////////////////////////////////////////////////////////////////////////////VVVV/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAPEAAAD1AAAA/w8NCP/oxXv/9dCC//jSg/8jHRL/AAAA/wAAAP//2oj/9dCC/+rHfP8gGxH/AAAA/wAAAP8AAAD/AQEB/1NTU/+CgoL/wsLC////////////x8fH/39/f/+AgID/zs7O////////////ysrK/4KCgv9UVFT/AgIC/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAANwAAADcAAAA/wMCAf/mxHr/9dCC//fSg/86MR//AAAA/wAAAP/ZuHP/99GD//TQgv8vKRn/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/f39/////////////ioqK/wAAAP8AAAD/mJiY////////////kJCQ/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAMUAAAC2AAAA/wAAAP/Ssm//9tGD//bRgv9dTzL/AAAA/wAAAP+Qe03/+dSE//jSg/9yYD3/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/g4OD////////////jY2N/wAAAP8AAAD/m5ub////////////k5OT/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAKcAAACDAAAA/wAAAP+MeEv/+9WF//XQgv+Nd0v/AAAA/wAAAP8wKRn//NaG//bRgv/fvnb/AAAA/wAAAP8AAAD/AAAA/2NjY/98fHz/v7+/////////////jY2N/wAAAP8AAAD/m5ub////////////yMjI/3x8fP9fX1//AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAH0AAABEAAAA/wAAAP81LRz//9uJ//XQgv/KrGv/AAAA/wAAAP8LCQb/2rl0//XQgv/914b/Wkww/wAAAP8AAAD/aWlp////////////////////////////jY2N/wAAAP8AAAD/m5ub////////////////////////////UlJS/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/gAAAFAAAAAjAAAA9QAAAP8AAAD/6MV8//XQgv//2If/HxoR/wAAAP8AAAD/lH1P//fSg//10IL/2blz/wYFA/8AAAD/ZGRk////////////////////////////YWFh/wAAAP8AAAD/c3Nz////////////////////////////UFBQ/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA+gAAACYAAAAGAAAA4QAAAP8AAAD/kXtN//XQgv/504T/s5df/wAAAP8AAAD/CQgF//rUhP/10IL/+dSE/5F7Tf8AAAD/AAAA/2ZmZv+ZmZn/mZmZ/5mZmf9lZWX/AAAA/wAAAP8AAAD/AAAA/2tra/+ZmZn/mZmZ/5mZmf9lZWX/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8AAAD/AAAA/wAAAP8A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APAAAAAADwAA4AAAAAAHAADAAAAAAAMAAMAAAAAAAwAAwAAAAAADAACAAAAAAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAgAAAAAABAACAAAAAAAMAAMAAAAAAAwAAwAAAAAADAADgAAAAAAcAAPAAAAAADwAA8AAAAAAPAAD4AAAAAB8AAPwAAAAAPwAA/gAAAAB/AAD/AAAAAP8AAP+AAAAB/wAA/+AAAAf/AAD/8AAAD/8AAP/8AAB//wAA//8AAP//AAA="
rel="icon" type="image/x-icon">
<style>
.right {
text-align: right;
}
.left {
text-align: left;
}
.rowPadded {
padding-top: 15px;
}
.center {
text-align: center;
padding-bottom: 50pt
}
.center-tab {
text-align: center;
vertical-align: middle;
}
.online {
color: green
}
.offline {
color: red
}
.paused {
color: yellow
}
.toggle {
border-radius: 2px;
}
.toggle .toggle-handle {
border-radius: 2px;
}
form label {
display: block;
margin-bottom: 5px;
text-align: left;
}
form label span {
display: inline-block;
margin-left: .5rem;
text-align: left;
}
form label input {
vertical-align: top;
}
</style>
<script type="text/javascript" language="javascript" src="https://code.jquery.com/jquery-3.3.1.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdn.datatables.net/1.10.20/js/jquery.dataTables.min.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdn.datatables.net/1.10.20/js/dataTables.bootstrap.min.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdn.datatables.net/buttons/1.5.0/js/dataTables.buttons.min.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdn.datatables.net/buttons/1.5.0/js/buttons.bootstrap.min.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdn.datatables.net/select/1.2.4/js/dataTables.select.min.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdn.datatables.net/buttons/1.5.6/js/buttons.colVis.min.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdn.datatables.net/rowgroup/1.1.1/js/dataTables.rowGroup.min.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdnjs.cloudflare.com/ajax/libs/jquery-timeago/1.6.1/jquery.timeago.min.js"></script>
<script type="text/javascript" language="javascript"
src="https://cdnjs.cloudflare.com/ajax/libs/numeral.js/2.0.6/numeral.min.js"></script>
<script src="https://gitcdn.github.io/bootstrap-toggle/2.2.2/js/bootstrap-toggle.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-select/1.13.2/js/bootstrap-select.min.js"></script>
<script src="https://use.fontawesome.com/6b3cdfc597.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.22.2/moment.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.9.3/Chart.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/chartjs-plugin-colorschemes"></script>
<script type="text/javascript">
var TRESHOLD_IN_MS = 60 * 1000;
var RELOAD_INTERVAL_IN_MS = 10 * 1000;
var CHART_RELOAD_INTERVAL_IN_MS = 60 * 1000;
var latestRelease = "";
var currentServerTime = 0;
var clockDrift = 0;
var latestVersion = 0;
var currentVersion = 0;
$.fn.dataTable.ext.search.push(
function (settings, data, dataIndex) {
var hideOffline = $('#hideOffline').prop('checked');
var showNotification = $('#showOfflineNotification').prop('checked');
var clientId = settings.aoData[dataIndex]._aData.client_status.client_id;
var lastStatus = settings.aoData[dataIndex]._aData.client_status.last_status_update * 1000;
var online = isOnline(lastStatus);
if (!online) {
var threshold = currentServerTime - (TRESHOLD_IN_MS + RELOAD_INTERVAL_IN_MS);
if (lastStatus > threshold && showNotification) {
$("#notificationBar").after('<div class="alert alert-danger alert-dismissable fade in">' +
'<a href="#" class="close" data-dismiss="alert" aria-label="close">×</a>' +
'<strong>Miner ' + clientId + ' just went offline!</strong> Last update: ' + new Date(lastStatus) +
'</div>');
}
}
return (online || !hideOffline);
}
);
$(document).ready(function () {
var table = $('#clientStatusList').DataTable({
dom: "<'row'<'col-sm-12'B>><'row rowPadded'<'col-sm-9'l><'col-sm-3'f>><'row'<'col-sm-12't>><'row'<'col-sm-4'i><'col-sm-8'p>><'col-sm-13'<'#serverTime'>>",
lengthMenu: [ [10, 25, 50, 100, -1], [10, 25, 50, 100, "All"] ],
pageLength: -1,
bPpaginate: true,
pagingType: "full_numbers",
stateSave: true,
ajax: {
url: "/admin/getClientStatusList",
dataSrc: 'client_status_list'
},
orderFixed: [5, 'asc'],
rowGroup: {
dataSrc: "client_status.current_algo_name"
},
columns: [
{
data: null,
defaultContent: '',
className: 'select-checkbox',
orderable: false
},
{data: "client_status.client_id", render: clientInfo},
{data: "client_status.version", render: version},
{data: "client_status.current_pool"},
{data: "client_status.current_pool_user", visible: false},
{data: "client_status.current_pool_pass", visible: false},
{data: "client_status.current_status", render: clientStatus},
{data: "client_status.current_algo_name", render: algoAndPowVariantName},
{data: "client_status.cpu_brand", visible: false},
{data: "client_status.external_ip", visible: false},
{data: "client_status.hugepages_available", visible: false},
{data: "client_status.hugepages_enabled", visible: false},
{data: "client_status.cpu_is_x64", visible: false},
{data: "client_status.cpu_has_aes", visible: false},
{data: "client_status.cpu_is_vm", visible: false},
{data: "client_status.hash_factor", className: "right", visible: false},
{data: "client_status.total_pages", className: "right", visible: false},
{data: "client_status.total_hugepages", className: "right", visible: false},
{data: "client_status.free_memory", render: memory, className: "right", visible: false},
{data: "client_status.total_memory", render: memory, className: "right", visible: false},
{data: "client_status.current_threads", className: "right", visible: false},
{data: "client_status.cpu_sockets", className: "right", visible: false},
{data: "client_status.cpu_cores", className: "right", visible: false},
{data: "client_status.cpu_threads", className: "right", visible: false},
{data: "client_status.cpu_l2", render: cache, className: "right", visible: false},
{data: "client_status.cpu_l3", render: cache, className: "right", visible: false},
{data: "client_status.cpu_nodes", className: "right", visible: false},
{data: "client_status.max_cpu_usage", className: "right", visible: false},
{data: "client_status.hashrate_short", render: round, className: "right"},
{data: "client_status.hashrate_medium", render: round, className: "right"},
{data: "client_status.hashrate_long", render: round, className: "right"},
{data: "client_status.hashrate_highest", render: round, className: "right"},
{data: "client_status.hashes_total", className: "right"},
{data: "client_status.avg_time", className: "right"},
{data: "client_status.shares_good", className: "right"},
{data: "client_status.shares_total", className: "right"},
{data: "client_status.uptime", render: uptime, className: "right"},
{data: "client_status.last_status_update", render: laststatus},
{
data: null,
defaultContent:
"<td class='center-tab'><button type='button' id='LOG' class='btn btn-xs btn-info' data-toggle='tooltip' title='View miner log'><i class='fa fa-file-text-o'></i></button></td>",
orderable: false,
className: "center-tab"
},
{
data: null,
defaultContent:
"<td class='center-tab'><button type='button' id='EDIT' class='btn btn-xs btn-primary' data-toggle='tooltip' title='Edit miner config'><i class='fa fa-edit'></i></button></td>",
orderable: false,
className: "center-tab"
}
],
rowId: 'client_status.client_id',
select: {
style: "multi+shift"
},
order: [1, 'asc'],
buttons: [
'colvis',
{
text: '<i class="fa fa-upload"> Push miner config</i>',
className: 'btn-primary',
enabled: false,
action: function () {
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
sendAction("UPDATE_CONFIG", data.client_status.client_id);
});
}
},
{
text: '<i class="fa fa-download"> Pull miner config</i>',
className: 'btn-info',
enabled: false,
action: function () {
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
sendAction("PUBLISH_CONFIG", data.client_status.client_id);
});
}
},
{
text: '<i class="fa fa-play"> Start</i>',
className: 'btn-success',
enabled: false,
action: function () {
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
sendAction("START", data.client_status.client_id);
});
}
},
{
text: '<i class="fa fa-pause"> Pause</i>',
className: 'btn-warning',
enabled: false,
action: function () {
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
sendAction("STOP", data.client_status.client_id);
});
}
},
{
text: '<i class="fa fa-repeat"> Restart</i>',
className: 'btn-info',
enabled: false,
action: function () {
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
sendAction("RESTART", data.client_status.client_id);
});
}
},
{
text: '<i class="fa fa-sign-out"> Stop</i>',
className: 'btn-danger',
enabled: false,
action: function () {
$('#commandDialogStop').modal('show');
}
},
{
text: '<i class="fa fa-refresh"> Reboot</i>',
className: 'btn-warning',
enabled: false,
action: function () {
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
sendAction("REBOOT", data.client_status.client_id);
});
}
},
{
text: '<i class="fa fa-rocket"> Execute</i>',
className: 'btn-success',
enabled: false,
action: function () {
$('#commandExecuteDialog').modal('show');
}
},
{
text: '<i class="fa fa-table"> Assign template</i>',
className: 'btn-info',
enabled: false,
action: function () {
$.ajax({
type: "GET",
url: "/admin/getClientConfigTemplates",
dataType: "json",
success: function (data) {
var htmlContent = "";
var arrayLength = data["templates"].length;
for (var i = 0; i < arrayLength; i++) {
htmlContent += "<option>" + data["templates"][i] + "</option>";
}
if (arrayLength > 0) {
$('#assignTemplate').prop('disabled', false);
$('#assignTemplateSelector').html(htmlContent);
$('#assignTemplateSelector').selectpicker('refresh');
} else {
$('#assignTemplate').prop('disabled', true);
}
$('#assignTemplateEditor').modal('show');
},
error: function (data) {
setError('<strong>Unable to fetch templates</strong> - Please make they exist!');
}
});
}
},
{
text: '<i class="fa fa-edit"> Template Editor</i>',
className: 'btn-primary',
enabled: true,
action: function () {
$.ajax({
type: "GET",
url: "/admin/getClientConfigTemplates",
dataType: "json",
success: function (data) {
var htmlContent = "";
var arrayLength = data["templates"].length;
for (var i = 0; i < arrayLength; i++) {
htmlContent += "<option>" + data["templates"][i] + "</option>";
}
if (arrayLength > 0) {
$('#templateEditorSave').prop('disabled', false);
$('#templateEditorDeleteDialog').prop('disabled', false);
$('#templateSelector').html(htmlContent);
$('#templateSelector').selectpicker('refresh');
$('#templateSelector').trigger('change');
} else {
$('#templateEditorSave').prop('disabled', true);
$('#templateEditorDeleteDialog').prop('disabled', true);
}
$('#templateEditor').modal('show');
},
error: function (data) {
setError('<strong>Unable to fetch templates</strong> - Please make they exist!');
}
});
}
}
],
"footerCallback": function (row, data, start, end, display) {
var api = this.api();
var sumHashrateShort = 0;
var sumHashrateMedium = 0;
var sumHashrateLong = 0;
var sumHashrateHighest = 0;
var sumHashesTotal = 0;
var avgTimeTotal = 0;
var sumSharesGood = 0;
var sumSharedTotal = 0;
var colOffset = 28;
sumHashrateShort = api
.column(colOffset, {page: 'current'})
.data()
.reduce(function (a, b) {
return a + b;
}, 0);
sumHashrateMedium = api
.column(colOffset+1, {page: 'current'})
.data()
.reduce(function (a, b) {
return a + b;
}, 0);
sumHashrateLong = api
.column(colOffset+2, {page: 'current'})
.data()
.reduce(function (a, b) {
return a + b;
}, 0);
sumHashrateHighest = api
.column(colOffset+3, {page: 'current'})
.data()
.reduce(function (a, b) {
return a + b;
}, 0);
sumHashesTotal = api
.column(colOffset+4, {page: 'current'})
.data()
.reduce(function (a, b) {
return a + b;
}, 0);
avgTimeTotal = api
.column(colOffset+5, {page: 'current'})
.data()
.reduce(function (a, b) {
return (a + b);
}, 0) / api.column(26, {page: 'current'}).data().length;
sumSharesGood = api
.column(colOffset+6, {page: 'current'})
.data()
.reduce(function (a, b) {
return a + b;
}, 0);
sumSharedTotal = api
.column(colOffset+7, {page: 'current'})
.data()
.reduce(function (a, b) {
return a + b;
}, 0);
sumHashrateShort = round(sumHashrateShort);
sumHashrateMedium = round(sumHashrateMedium);
sumHashrateLong = round(sumHashrateLong);
sumHashrateHighest = round(sumHashrateHighest);
avgTimeTotal = round(avgTimeTotal);
// update footer
$(api.column(colOffset).footer()).html(sumHashrateShort);
$(api.column(colOffset+1).footer()).html(sumHashrateMedium);
$(api.column(colOffset+2).footer()).html(sumHashrateLong);
$(api.column(colOffset+3).footer()).html(sumHashrateHighest);
$(api.column(colOffset+4).footer()).html(sumHashesTotal);
$(api.column(colOffset+5).footer()).html(avgTimeTotal);
$(api.column(colOffset+6).footer()).html(sumSharesGood);
$(api.column(colOffset+7).footer()).html(sumSharedTotal);
}
});
table.on('xhr.dt', function (e, settings, json, xhr) {
// check version
if (latestRelease === "" && json !== undefined) {
$.ajax({
url: "https://api.github.com/repos/Bendr0id/xmrigCC/releases/latest",
type: 'GET',
dataType: "json",
success: function (release) {
latestRelease = release.tag_name
latestVersion = parseInt(release.tag_name.split('.').join(""));
currentVersion = parseInt(json.current_version.split('.').join(""));
if (currentVersion < 1000) {
currentVersion = currentVersion * 10;
}
if (latestVersion < 1000) {
latestVersion = latestVersion * 10;
}
if (latestVersion > currentVersion) {
$("#updateNotificationBar").html('<div class="alert alert-info alert-dismissable fade in">' +
'<a href="#" class="close" data-dismiss="alert" aria-label="close">×</a>' +
'<a href="https://github.com/Bendr0id/xmrigCC/releases/latest"><strong>Update!</strong> XMRigCC v' + latestRelease + ' is available for download\n</a>' +
'</div>');
}
}
});
}
currentServerTime = settings.json.current_server_time * 1000;
clockDrift = new Date().getTime() - currentServerTime;
$('#serverTime').html("<div class='dataTables_info text-right'>" + new Date(currentServerTime) + "</div>");
});
table.on('select', function () {
var selectedRows = table.rows({selected: true}).count();
table.button(1).enable(selectedRows > 0);
table.button(2).enable(selectedRows > 0);
table.button(3).enable(selectedRows > 0);
table.button(4).enable(selectedRows > 0);
table.button(5).enable(selectedRows > 0);
table.button(6).enable(selectedRows > 0);
table.button(7).enable(selectedRows > 0);
table.button(8).enable(selectedRows > 0);
table.button(9).enable(selectedRows > 0);
});
table.on('deselect', function () {
var selectedRows = table.rows({selected: true}).count();
table.button(1).enable(selectedRows > 0);
table.button(2).enable(selectedRows > 0);
table.button(3).enable(selectedRows > 0);
table.button(4).enable(selectedRows > 0);
table.button(5).enable(selectedRows > 0);
table.button(6).enable(selectedRows > 0);
table.button(7).enable(selectedRows > 0);
table.button(8).enable(selectedRows > 0);
table.button(9).enable(selectedRows > 0);
});
table.buttons().container().appendTo('#clientStatusList_wrapper .col-sm-6:eq(0)');
$('#hideOffline').change(function () {
table.draw();
});
$('#groupByAlgo').change(function () {
if ($('#groupByAlgo').prop('checked')) {
table.rowGroup().enable().draw();
table.order.fixed({
pre: [5, 'asc']
}).draw();
} else {
table.rowGroup().disable().draw();
table.order.fixed({
pre: []
}).draw();
}
});
$('#resetClientStatusList').click(function () {
resetClientStatusList();
});
$('#clientStatusList tbody ').on('click', 'button#EDIT', function () {
var data = table.row($(this).parents('tr')).data();
var clientId = data['client_status']['client_id'];
$.ajax({
type: "GET",
url: "/admin/getClientConfig?clientId=" + clientId,
dataType: "json",
success: function (jsonClientConfig) {
var htmlContent = "<div class='form-group' id='editor' data-value='" + clientId + "'>" +
"<label for='config'>Config for: " + clientId + "</label>" +
"<textarea class='form-control' rows='20' id='config'>" +
JSON.stringify(jsonClientConfig, undefined, 2) +
"</textarea>" +
"</div>";
$('#minerEditor').find('.modal-body').html(htmlContent);
$('#minerEditor').modal('show');
},
error: function (data) {
setError('<strong>Unable to fetch ' + clientId + '_config.json</strong> - Please make sure that you pulled the config before!');
}
});
});
$('#minerEditorSave').click(function (event) {
var clientId = $('#minerEditor').find('.form-group')["0"].dataset.value;
var clientConfig = $('#config').val();
setClientConfig(clientId, clientConfig);
});
$('#templateEditorSave').click(function (event) {
var templateId = $('#templateSelector').val();
var template = $('#template').val();
setTemplateConfig(templateId, template);
});
$('#templateEditorSaveAsDialog').click(function (event) {
$('#templateDialogSaveAs').modal('show');
});
$('#templateEditorDeleteDialog').click(function (event) {
$('#templateDialogDelete').modal('show');
});
$('#templateEditorSaveAs').click(function (event) {
var templateId = $('#templateName').val();
var template = $('#template').val();
setTemplateConfig(templateId, template);
$('#templateEditor').modal('hide');
});
$('#templateEditorDelete').click(function (event) {
var templateId = $('#templateSelector').val();
deleteTemplateConfig(templateId, template);
});
$('#commandStop').click(function (event) {
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
sendAction("SHUTDOWN", data.client_status.client_id);
});
});
$('#commandExecuteDialogExecute').click(function (event) {
var command = $('#executeCommand').val();
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
sendAction("EXECUTE", data.client_status.client_id, command);
});
});
$('#clientStatusList tbody').on('click', 'button#LOG', function () {
var data = table.row($(this).parents('tr')).data();
var clientId = data['client_status']['client_id'];
var clientIp = data['client_status']['external_ip'];
$.ajax({
type: "GET",
url: "/admin/getClientLog?clientId=" + clientId,
dataType: "json",
success: function (data) {
var htmlContent = "<div class='form-group' id='viewer' data-value='" + clientId + "'>" +
"<label for='config'>Log of: " + clientId + " (" + clientIp + ")</label>" +
"<textarea class='form-control' rows='20' id='log'>" + data.client_log + "</textarea>" +
"</div>";
$('#minerLog').find('.modal-body').html(htmlContent);
$('#minerLog').modal('show');
},
error: function (data) {
setError('<strong>Unable to fetch ' + clientId + ' log.</strong> - Please make sure it is enabled on the miner!');
}
});
});
$('#minerLogRefresh').click(function (event) {
var clientId = $('#minerLog').find('.form-group')["0"].dataset.value;
table.rows().eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
$.ajax({
type: "GET",
url: "/admin/getClientLog?clientId=" + clientId,
dataType: "json",
success: function (data) {
$('#log').val(data.client_log);
},
error: function (data) {
setError('<strong>Unable to fetch ' + clientId + ' log.</strong> - Please make sure it is enabled on the miner!');
}
});
});
});
$('#templateSelector').on('changed.bs.select', function (e, clickedIndex, newValue, oldValue) {
var selected = $(e.currentTarget).val();
$.ajax({
type: "GET",
url: "/admin/getClientConfig?clientId=template_" + selected,
dataType: "json",
success: function (jsonClientConfig) {
$('#template').val(JSON.stringify(jsonClientConfig, undefined, 2));
},
error: function (data) {
setError('<strong>Unable to fetch template ' + selected + '</strong> - Please make sure it readable!');
}
});
});
$('#assignTemplate').click(function (event) {
var template = $('#assignTemplateSelector').val();
$.ajax({
type: "GET",
url: "/admin/getClientConfig?clientId=template_" + template,
dataType: "json",
success: function (jsonTemplate) {
table.rows({selected: true}).eq(0).each(function (index) {
var row = table.row(index);
var data = row.data();
var clientId = data['client_status']['client_id'];
if ($('#mergeTemplate').prop('checked')) {
setMergedClientConfig(jsonTemplate, clientId);
} else {
jsonTemplate['cc-client']['worker-id'] = clientId
clientConfig = JSON.stringify(jsonTemplate, undefined, 2);
if ($('#replaceWorkerId').prop('checked')) {
clientConfig = clientConfig.replace(new RegExp("@WORKER-ID@", 'g'), clientId).trim();
}
setClientConfig(clientId, clientConfig);
}
});
},
error: function (data) {
setError('<strong>Unable to fetch template ' + template + '</strong> - Please make sure it readable!');
}
});
});
$('#selectAllTop,#selectAllBottom').click(function () {
if ($("#selectAllTop").hasClass("fa fa-square-o")) {
$("#selectAllTop").removeClass("fa fa-square-o").addClass("fa fa-check-square-o");
$("#selectAllBottom").removeClass("fa fa-square-o").addClass("fa fa-check-square-o");
table.rows().select();
} else {
$("#selectAllTop").removeClass("fa fa-check-square-o").addClass("fa fa-square-o");
$("#selectAllBottom").removeClass("fa fa-check-square-o").addClass("fa fa-square-o");
table.rows().deselect();
}
});
var hashrateChart = new Chart(document.getElementById("hashrateChart").getContext("2d"), {
type: "line",
data: {
datasets: []
},
options: {
title:{
display:true,
text:'Hashrates'
},
tooltips: {
mode: 'nearest',
intersect: false,
},
scales: {
yAxes: [
{
id: 'hashrate',
position: 'left',
scalePositionLeft: true,
stacked: false,
ticks: {
beginAtZero: true
},
scaleLabel: {
display: true,
labelString: 'Hashrate',
fontSize: 16
}
}
],
xAxes: [{
type: 'time',
distribution: 'series',
time: {
unit: 'minute',
displayFormats: {
minute: 'HH:mm'
}
},
ticks: {
stepSize: 10,
autoSkip: true,
maxTicksLimit: 60
}
}]
},
elements: {
point:{
radius: 0
}
},
responsive: true,
maintainAspectRatio: false
},
plugins: {
colorschemes: {
scheme: 'brewer.Paired12'
}
}
});
var minerChart = new Chart(document.getElementById("minerChart").getContext("2d"), {
type: "line",
data: {
datasets: []
},
options: {
title:{
display:true,
text:'Miners'
},
tooltips: {
mode: 'nearest',
intersect: false,
},
scales: {
yAxes: [
{
id: 'miner',
position: 'left',
scalePositionLeft: true,
stacked: false,
ticks: {
beginAtZero: true,
callback: function(value) {if (value % 1 === 0) {return value;}}
},
scaleLabel: {
display: true,
labelString: 'Miner',
fontSize: 16
}
}
],
xAxes: [{
type: 'time',
distribution: 'series',
time: {
unit: 'minute',
displayFormats: {
minute: 'HH:mm'
}
},
ticks: {
stepSize: 10,
autoSkip: true,
maxTicksLimit: 60
}
}]
},
elements: {
point:{
radius: 0
}
},
responsive: true,
maintainAspectRatio: false
},
plugins: {
colorschemes: {
scheme: 'brewer.Paired12'
}
}
});
Chart.plugins.register({
afterDraw: function(chart) {
if (chart.data.datasets.length === 0) {
// No data is present
var ctx = chart.chart.ctx;
var width = chart.chart.width;
var height = chart.chart.height
ctx.save();
ctx.textAlign = 'center';
ctx.textBaseline = 'middle';
ctx.font = "16px normal 'Helvetica Nueue'";
ctx.fillText('No data to display', width / 2, height / 2);
ctx.restore();
}
}
});
updateCharts(hashrateChart, minerChart);
setInterval(function () {
table.ajax.reload(null, false);
}, RELOAD_INTERVAL_IN_MS);
setInterval(function () {
updateCharts(hashrateChart, minerChart);
}, CHART_RELOAD_INTERVAL_IN_MS);
});
function sendAction(action, clientId, payload) {
$.ajax({
type: "POST",
url: "/admin/setClientCommand?clientId=" + clientId,
dataType: "text",
data: '{"control_command":{"command": "' + action + '", "payload": "' + payload + '"}}',
success: function (data) {
setSuccess('<strong>Successfully send ' + action + ' to ' + clientId + ' [payload=\'' + payload +'\']</strong> - It can take up to 30s until the command is processed.');
},
error: function (data) {
setError('<strong>Failed to send ' + action + ' to ' + clientId + ' [payload=\'' + payload +'\']</strong> \nError: ' + JSON.stringify(data, undefined, 2));
}
});
}
function resetClientStatusList() {
$.ajax({
type: "POST",
url: "/admin/resetClientStatusList",
dataType: "text",
data: '{}',
success: function (data) {
setSuccess('<strong>Successfully send the reset client status list request to the Server.</strong> - Now just wait for the next refresh.');
},
error: function (data) {
setError('<strong>Failed to send the reset client status list request to the Server.</strong> \nError: ' + JSON.stringify(data, undefined, 2));
}
});
}
function uptime(data, type, row) {
if (type !== 'sort') {
var lastStatus = row.client_status.last_status_update * 1000;
if (isOnline(lastStatus)) {
return numeral(data / 1000).format('00:00:00:00');
} else {
return "";
}
}
return data;
}
function setMergedClientConfig(template, clientId) {
$.ajax({
type: "GET",
url: "/admin/getClientConfig?clientId=" + clientId,
dataType: "json",
success: function (clientConfig) {
$.extend(true, clientConfig, template);
clientConfig = JSON.stringify(clientConfig, undefined, 2)
if ($('#replaceWorkerId').prop('checked')) {
clientConfig = clientConfig.replace(new RegExp("@WORKER-ID@", 'g'), clientId).trim();
}
setClientConfig(clientId, clientConfig);
},
error: function (data) {
setError('<strong>Unable to fetch client config ' + clientId + ' for template merge</strong> - Please make sure it readable!');
}
});
}
function laststatus(data, type, row) {
if (type !== 'sort') {
var date = new Date(data * 1000 - clockDrift);
return '<span data-toggle="tooltip" title="' + date + '">' + jQuery.timeago(date) + '</span>';
}
return data;
}
function algoAndPowVariantName(data, type, row) {
var algo = row.client_status.current_algo_name;
var powVariant = row.client_status.current_pow_variant_name;
if (powVariant !== "") {
return algo + " / " + powVariant
} else {
return algo;
}
}