@cryptotaxi247 / netdata-1 / commits / 39d35a0e7

set qos submenu based on fireqos interface name

Costa Tsaousis (ktsaou) committed Jan 29, 2017 at 09:54 UTC 39d35a0e742be50d223c9a3b0e059ce2bebc3adb
1 file changed +3 -1
web/index.html
+3 -1
@@ -1094,7 +1094,7 @@
1094
1095 // find a name for this device from fireqos info
1096 // we strip '_(in|out)' or '(in|out)_'
1097 - if(typeof options.submenu_names[chart.family] === 'undefined' || options.submenu_names[chart.family] === chart.family) {
1097 + if(chart.context === 'tc.qos' && (typeof options.submenu_names[chart.family] === 'undefined' || options.submenu_names[chart.family] === chart.family)) {
1098 var n = chart.name.split('.')[1];
1099 if(n.endsWith('_in'))
1100 options.submenu_names[chart.family] = n.slice(0, n.lastIndexOf('_in'));
@@ -1104,6 +1104,8 @@
1104 options.submenu_names[chart.family] = n.slice(3, n.length);
1105 else if(n.startsWith('out_'))
1106 options.submenu_names[chart.family] = n.slice(4, n.length);
1107 + else
1108 + options.submenu_names[chart.family] = n;
1109 }
1110
1111 // increase the priority of IFB devices