diff options
author | Hannu Nyman <hannu.nyman@iki.fi> | 2018-05-15 18:15:04 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-15 18:15:04 +0300 |
commit | 452c161ac0c42b196a22b62c8a482a7c9dd70d2e (patch) | |
tree | f31cdc8538d05007f23ba5917e94bb90a781b503 | |
parent | f3b30512361584c61c9daa51650ad833072aa919 (diff) | |
parent | 9a93359d42d6a16727e1198910cc440abce584ba (diff) |
Merge pull request #1796 from TDT-AG/pr/20180515-luci-app-mwan3-add-param
luci-app-mwan3: add new config options and fix
-rw-r--r-- | applications/luci-app-mwan3/luasrc/model/cbi/mwan/interfaceconfig.lua | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/applications/luci-app-mwan3/luasrc/model/cbi/mwan/interfaceconfig.lua b/applications/luci-app-mwan3/luasrc/model/cbi/mwan/interfaceconfig.lua index a439502671..a6570e341c 100644 --- a/applications/luci-app-mwan3/luasrc/model/cbi/mwan/interfaceconfig.lua +++ b/applications/luci-app-mwan3/luasrc/model/cbi/mwan/interfaceconfig.lua @@ -54,6 +54,7 @@ count:value("5") size = mwan_interface:option(Value, "size", translate("Ping size")) size.default = "56" +size:depends("track_method", "ping") size:value("8") size:value("24") size:value("56") @@ -67,6 +68,52 @@ size.datatype = "range(1, 65507)" size.rmempty = false size.optional = false +check_quality = mwan_interface:option(Flag, "check_quality", translate("Check link quality")) +check_quality:depends("track_method", "ping") +check_quality.default = false + +failure_latency = mwan_interface:option(Value, "failure_latency", translate("Max packet latency [ms]")) +failure_latency:depends("check_quality", 1) +failure_latency.default = "1000" +failure_latency:value("25") +failure_latency:value("50") +failure_latency:value("75") +failure_latency:value("100") +failure_latency:value("150") +failure_latency:value("200") +failure_latency:value("250") +failure_latency:value("300") + +failure_loss = mwan_interface:option(Value, "failure_loss", translate("Max packet loss [%]")) +failure_loss:depends("check_quality", 1) +failure_loss.default = "20" +failure_loss:value("2") +failure_loss:value("5") +failure_loss:value("10") +failure_loss:value("20") +failure_loss:value("25") + +recovery_latency = mwan_interface:option(Value, "recovery_latency", translate("Min packet latency [ms]")) +recovery_latency:depends("check_quality", 1) +recovery_latency.default = "500" +recovery_latency:value("25") +recovery_latency:value("50") +recovery_latency:value("75") +recovery_latency:value("100") +recovery_latency:value("150") +recovery_latency:value("200") +recovery_latency:value("250") +recovery_latency:value("300") + +recovery_loss = mwan_interface:option(Value, "recovery_loss", translate("Min packet loss [%]")) +recovery_loss:depends("check_quality", 1) +recovery_loss.default = "5" +recovery_loss:value("2") +recovery_loss:value("5") +recovery_loss:value("10") +recovery_loss:value("20") +recovery_loss:value("25") + timeout = mwan_interface:option(ListValue, "timeout", translate("Ping timeout")) timeout.default = "2" timeout:value("1", translatef("%d second", 1)) |