diff options
author | Kristian Lyngstol <kristian@bohemians.org> | 2016-04-01 19:14:20 +0200 |
---|---|---|
committer | Kristian Lyngstol <kristian@bohemians.org> | 2016-04-01 19:14:20 +0200 |
commit | bc83b07e4aa4c68f63f4e1b9f6f00757388ea13c (patch) | |
tree | ccb9a45430645ea80bca1b3717e453e254229a0e /web/nms.gathering.org/js | |
parent | 1d2470a411e5eaac7e5a1c5d5b6b81e92c92f4a8 (diff) | |
parent | 3dc8afb739a03459393d3cda79bd16cefff15cae (diff) |
Merge branch 'master' of github.com:tech-server/tgmanage
Diffstat (limited to 'web/nms.gathering.org/js')
-rw-r--r-- | web/nms.gathering.org/js/nms-info-box.js | 10 | ||||
-rw-r--r-- | web/nms.gathering.org/js/nms-map-handlers.js | 3 |
2 files changed, 10 insertions, 3 deletions
diff --git a/web/nms.gathering.org/js/nms-info-box.js b/web/nms.gathering.org/js/nms-info-box.js index 01bac94..1742ac2 100644 --- a/web/nms.gathering.org/js/nms-info-box.js +++ b/web/nms.gathering.org/js/nms-info-box.js @@ -546,7 +546,7 @@ nmsInfoBox._windowTypes.inventoryListing = { activeView: '', activeFilter: '', getTitle: function() { - return '<h4>Inventory listing</h4><button type="button" class="distro-name btn btn-xs btn-default" onclick="nmsInfoBox.showWindow(\'inventoryListing\',\'distro_name\');">Distro name</button> <button type="button" class="distro-name btn btn-xs btn-default" onclick="nmsInfoBox.showWindow(\'inventoryListing\',\'sysDescr\');">System Description</button>'; + return '<h4>Inventory listing</h4><button type="button" class="distro-name btn btn-xs btn-default" onclick="nmsInfoBox.showWindow(\'inventoryListing\',\'distro_name\');">Distro name</button> <button type="button" class="distro-name btn btn-xs btn-default" onclick="nmsInfoBox.showWindow(\'inventoryListing\',\'sysDescr\');">System Description</button><button type="button" class="distro-name btn btn-xs btn-default" onclick="nmsInfoBox.showWindow(\'inventoryListing\',\'jnxBoxSerialNo\');">Serial Numbers</button>'; }, getContent: function() { return this.content; @@ -592,6 +592,11 @@ nmsInfoBox._windowTypes.inventoryListing = { listTitle = 'System description'; needSnmp = true; break; + case 'jnxBoxSerialNo': + if(hasSnmp) + listTitle = 'Serial Numbers'; + needSnmp = true; + break; default: listTitle = 'Distro names'; list = 'distro_name'; @@ -619,6 +624,9 @@ nmsInfoBox._windowTypes.inventoryListing = { case 'sysDescr': value = nmsData.snmp.snmp[sw]["misc"]["sysDescr"][0]; break; + case 'jnxBoxSerialNo': + value = nmsData.snmp.snmp[sw]["misc"]["jnxBoxSerialNo"][0]; + break; } } catch (e) { //console.log(e); diff --git a/web/nms.gathering.org/js/nms-map-handlers.js b/web/nms.gathering.org/js/nms-map-handlers.js index 474e8ef..a7672a3 100644 --- a/web/nms.gathering.org/js/nms-map-handlers.js +++ b/web/nms.gathering.org/js/nms-map-handlers.js @@ -373,14 +373,13 @@ function getDhcpColor(stop) function dhcpUpdater() { - var realnow = Date.now(); - var now = Math.floor(realnow / 1000); if (nmsData.dhcp == undefined || nmsData.dhcp.dhcp == undefined) { return } if (nmsData.switches == undefined || nmsData.switches.switches == undefined) { return; } + var now = nmsData.dhcp.time; try { for (var sw in nmsData.switches.switches) { var c = blue; |