download custom dashboard info from the API server; fix snapshot filename
Costa Tsaousis (ktsaou) committed
Nov 14, 2017 at 14:40 UTC
fc330a773667bfd92dc174da4ffcba8f08f7356f
1 file changed
+2
-2
web/index.html
+2
-2
@@ -2592,7 +2592,7 @@
2592
NETDATA.chartRegistry.downloadAll(netdata_url, function(data) {
2593
if(data !== null) {
2594
if(typeof data.custom_info !== 'undefined' && data.custom_info !== "") {
2595
- loadJs(data.custom_info, function () {
2595
+ loadJs(NETDATA.serverDefault + data.custom_info, function () {
2596
$.extend(true, netdataDashboard, customDashboard);
2597
initializeDynamicDashboardWithData(data);
2598
});
@@ -2938,7 +2938,7 @@
2938
}
2939
2940
var start_date = new Date(start_ms);
2941
- var yyyymmddhhssmm = start_date.getFullYear() + NETDATA.zeropad(start_date.getMonth() + 1) + NETDATA.zeropad(start_date.getDate()) + NETDATA.zeropad(start_date.getHours()) + NETDATA.zeropad(start_date.getMinutes()) + NETDATA.zeropad(start_date.getSeconds());
2941
+ var yyyymmddhhssmm = start_date.getFullYear() + NETDATA.zeropad(start_date.getMonth() + 1) + NETDATA.zeropad(start_date.getDate()) + '-' + NETDATA.zeropad(start_date.getHours()) + NETDATA.zeropad(start_date.getMinutes()) + NETDATA.zeropad(start_date.getSeconds());
2942
2943
document.getElementById('saveSnapshotFilename').value = 'netdata-' + options.hostname.toString() + '-' + yyyymmddhhssmm.toString() + '-' + view_duration.toString() + '.snapshot'
2944