diff --git a/luasrc/model/cbi/easymesh.lua b/luasrc/model/cbi/easymesh.lua index 597cda4..2af730a 100755 --- a/luasrc/model/cbi/easymesh.lua +++ b/luasrc/model/cbi/easymesh.lua @@ -191,7 +191,7 @@ low_rssi_val:depends("kvr", 1) -- s.anonymous = true ---- ap_mode -o = s:taboption("apmode", Value, "gateway", translate("Node Hostname")) +o = s:taboption("apmode", Value, "hostname", translate("Node Hostname")) o.default = "node2" o:value("node2", "node2") o:value("node3", "node3") @@ -206,7 +206,7 @@ o:depends("role", "off") btnAPMode = s:taboption("apmode", Button, "_btn_apmode", translate("Join Mesh Network"), translate("WARNING: THIS WILL CHANGE THIS NODE'S IP ADDRESS, YOU WILL LOOSE ACCESS TO THIS UI")) function btnAPMode.write() - luci.sys.call("/easymesh/easymesh.sh apmode") + luci.sys.call("bash /easymesh/dumbap.sh") end btnAPMode:depends("role", "off") ---- ip address @@ -234,9 +234,9 @@ ctrl.addremove = false function m.on_after_commit(self) local enabled = m:formvalue("cbid.easymesh.easymesh.enabled") if enabled and enabled == "1" then - luci.sys.call("/easymesh/easymesh.sh start &") + luci.sys.call("bash /easymesh/easymesh.sh start &") else - luci.sys.call("/easymesh/easymesh.sh stop &") + luci.sys.call("bash /easymesh/easymesh.sh stop &") end end diff --git a/root/easymesh/dumbap.sh b/root/easymesh/dumbap.sh index 3d3480e..e70f3cf 100755 --- a/root/easymesh/dumbap.sh +++ b/root/easymesh/dumbap.sh @@ -102,4 +102,6 @@ set_apmode() { reload_config /etc/init.d/network reload fi -} \ No newline at end of file +} + +set_apmode \ No newline at end of file