diff options
Diffstat (limited to 'modules/admin-mini/luasrc/model/cbi/mini/dhcp.lua')
-rw-r--r-- | modules/admin-mini/luasrc/model/cbi/mini/dhcp.lua | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/modules/admin-mini/luasrc/model/cbi/mini/dhcp.lua b/modules/admin-mini/luasrc/model/cbi/mini/dhcp.lua index 05334049da..3d26d6a9d6 100644 --- a/modules/admin-mini/luasrc/model/cbi/mini/dhcp.lua +++ b/modules/admin-mini/luasrc/model/cbi/mini/dhcp.lua @@ -59,7 +59,12 @@ s.addremove = true s.anonymous = true s.template = "cbi/tblsection" -s:option(Value, "macaddr", translate("macaddress")) -s:option(Value, "ipaddr", translate("ipaddress")) +mac = s:option(Value, "macaddr", translate("macaddress")) +ip = s:option(Value, "ipaddr", translate("ipaddress")) +for i, dataset in ipairs(luci.sys.net.arptable()) do + ip:value(dataset["IP address"]) + mac:value(dataset["HW address"], + dataset["HW address"] .. " (" .. dataset["IP address"] .. ")") +end return m, m2
\ No newline at end of file |