更新配置

This commit is contained in:
ling 2023-12-02 23:31:46 +08:00
parent a8eab8bc23
commit 9e80d5f77d
2 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,7 @@ mp = Map("hypermodem")
mp.title = translate("Hyper Modem Server") mp.title = translate("Hyper Modem Server")
mp.description = translate("Modem Server For OpenWrt") mp.description = translate("Modem Server For OpenWrt")
s = mp:section(TypedSection, "service", "Base Setting") s = mp:section(TypedSection, "service", translate("Base Setting"))
s.anonymous = true s.anonymous = true
enabled = s:option(Flag, "enabled", translate("Enable")) enabled = s:option(Flag, "enabled", translate("Enable"))

View File

@ -7,7 +7,7 @@ USE_PROCD=1
pre_set() pre_set()
{ {
[ "$(uci get network.wan.ifname)" != "$1" ] && { [ "$(uci get network.wwan_5g.ifname)" != "$1" ] && {
uci set network.wwan_5g='interface' uci set network.wwan_5g='interface'
uci set network.wwan_5g.ifname="$1" uci set network.wwan_5g.ifname="$1"
uci set network.wwan_5g.proto='dhcp' uci set network.wwan_5g.proto='dhcp'
@ -38,8 +38,8 @@ pre_set()
fi fi
} }
[ "$(uci get network.wan6.ifname)" == "$1" ] && { [ "$(uci get network.wwan6_5g.ifname)" == "$1" ] && {
uci set network.wan6.extendprefix='1' uci set network.wwan6_5g.extendprefix='1'
uci commit network uci commit network
} }
} }