diff --git a/luci-base/luasrc/model/cbi/admin_network/proto_static.lua b/luci-base/luasrc/model/cbi/admin_network/proto_static.lua index e5aa6b193..1c70f85af 100644 --- a/luci-base/luasrc/model/cbi/admin_network/proto_static.lua +++ b/luci-base/luasrc/model/cbi/admin_network/proto_static.lua @@ -83,15 +83,14 @@ mtu.placeholder = "1500" mtu.datatype = "max(9200)" -metric = section:taboption("advanced", Value, "metric", - translate("Use gateway metric")) +--metric = section:taboption("advanced", Value, "metric", +-- translate("Use gateway metric")) +--metric.default = "1" +--metric.datatype = "uinteger" -metric.default = "1" -metric.datatype = "uinteger" - -local nw = require "luci.model.network".init() -for _, network in ipairs(nw:get_networks()) do - if network:proto() == "static" and network:type() == "macvlan" and tonumber(network:metric()) >= tonumber(metric.default) then - metric.default = network:metric() + 1 - end -end +--local nw = require "luci.model.network".init() +--for _, network in ipairs(nw:get_networks()) do +-- if network:proto() == "static" and network:type() == "macvlan" and tonumber(network:metric()) >= tonumber(metric.default) then +-- metric.default = network:metric() + 1 +-- end +--end