summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2008-11-30 19:15:16 +0000
committerJo-Philipp Wich <jow@openwrt.org>2008-11-30 19:15:16 +0000
commitc1d9107be88df75406e9fbc9ccbec9fbe6e907c2 (patch)
tree7f0a23c5aa86b4d90d04948e84139cbab2f8e756 /modules
parent3ec8d04c66a9054279c935cae0b376e45f6a8945 (diff)
luci-0.8: merge r3851
Diffstat (limited to 'modules')
-rw-r--r--modules/admin-full/luasrc/model/cbi/admin_network/routes.lua13
1 files changed, 8 insertions, 5 deletions
diff --git a/modules/admin-full/luasrc/model/cbi/admin_network/routes.lua b/modules/admin-full/luasrc/model/cbi/admin_network/routes.lua
index 0d20d67223..be6629774f 100644
--- a/modules/admin-full/luasrc/model/cbi/admin_network/routes.lua
+++ b/modules/admin-full/luasrc/model/cbi/admin_network/routes.lua
@@ -42,7 +42,10 @@ if not arg or not arg[1] then
return routes[section].gateway:string()
end
- metric = v:option(DummyValue, "Metric", translate("metric"))
+ metric = v:option(DummyValue, "metric", translate("metric"))
+ function metric.cfgvalue(self, section)
+ return routes[section].metric
+ end
if routes6 then
v = m:section(Table, routes6, translate("a_n_routes_kernel6"))
@@ -63,10 +66,10 @@ if not arg or not arg[1] then
return routes6[section].source:string()
end
- metric = v:option(DummyValue, "Metric", translate("metric"))
- function metric.cfgvalue(self, section)
- return string.format( "%08X", routes6[section].metric )
- end
+ metric = v:option(DummyValue, "metric", translate("metric"))
+ function metric.cfgvalue(self, section)
+ return string.format( "%08X", routes6[section].metric )
+ end
end
end