ethinfo: add lan
This commit is contained in:
parent
ba3ebf0b74
commit
c02b47b4b9
@ -7,7 +7,7 @@ local jsonc = require "luci.jsonc"
|
|||||||
local eth_info = {}
|
local eth_info = {}
|
||||||
local ifname, stat
|
local ifname, stat
|
||||||
for ifname, stat in pairs(util.ubus("network.device", "status")) do
|
for ifname, stat in pairs(util.ubus("network.device", "status")) do
|
||||||
if ifname:match("^(eth%d+)$") == ifname or ifname:match("^(usb%d+)$") == ifname then
|
if ifname:match("^(eth%d+)$") == ifname or ifname:match("^(usb%d+)$") or ifname:match("^(lan%d+)$") == ifname then
|
||||||
local status, speed, duplex
|
local status, speed, duplex
|
||||||
|
|
||||||
status = stat.carrier and "yes" or "no"
|
status = stat.carrier and "yes" or "no"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user