mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
Fix and add huawei signal power
This commit is contained in:
parent
59f8161292
commit
1274791cc1
5 changed files with 53 additions and 14 deletions
|
@ -358,6 +358,7 @@
|
|||
ipaddr=replaceLastNChars(ipaddr,"x",6);
|
||||
}
|
||||
var whois = mArray.wans[i].whois;
|
||||
var signal = mArray.wans[i].signal;
|
||||
var multipath = mArray.wans[i].multipath;
|
||||
if(multipath == 'master')
|
||||
{
|
||||
|
@ -412,23 +413,36 @@
|
|||
{
|
||||
content += String.format('%s %s<br />',_('mtu:'), mtu);
|
||||
}
|
||||
if(signal !== '')
|
||||
{
|
||||
if (signal <= 0)
|
||||
title += ' <img src="/luci-static/resources/icons/signal-0.png" />';
|
||||
else if (signal < 25)
|
||||
title += ' <img src="/luci-static/resources/icons/signal-0-25.png" />';
|
||||
else if (signal < 50)
|
||||
title += ' <img src="/luci-static/resources/icons/signal-25-50.png" />';
|
||||
else if (signal < 75)
|
||||
title += ' <img src="/luci-static/resources/icons/signal-50-75.png" />';
|
||||
else
|
||||
title += ' <img src="/luci-static/resources/icons/signal-75-100.png" />';
|
||||
}
|
||||
if(ipaddr == '')
|
||||
{
|
||||
statusMessage += _('No IP defined') + '<br />'
|
||||
statusMessage += _('No IP defined') + '<br />';
|
||||
}
|
||||
if(gateway == '')
|
||||
{
|
||||
statusMessage += _('No gateway defined') + '<br />'
|
||||
statusMessage += _('No gateway defined') + '<br />';
|
||||
} else if(gw_ping == 'DOWN')
|
||||
{
|
||||
statusMessage += _('Gateway DOWN') + '<br />'
|
||||
statusMessage += _('Gateway DOWN') + '<br />';
|
||||
} else if(multipath_available == 'ERROR')
|
||||
{
|
||||
statusMessage += _('Multipath seems to be blocked on the connection') + '<br />'
|
||||
statusMessage += _('Multipath seems to be blocked on the connection') + '<br />';
|
||||
}
|
||||
if(server_ping == 'DOWN')
|
||||
{
|
||||
statusMessage += _('No Server ping response after 1 second') + '<br />'
|
||||
statusMessage += _('No Server ping response after 1 second') + '<br />';
|
||||
}
|
||||
if (stat == 'Offline' && ipaddr != '' && ipaddr == mArray.wans[i].gateway)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue