mirror of
https://github.com/caiwx86/small-packages.git
synced 2026-10-29 15:55:13 +08:00
update 2026-09-18 06:36:08
This commit is contained in:
1 parent
1f24c42f3b
commit
44c96ca486
1958 files changed
+2
-1523091
No files matched your search
@@ -56,13 +56,6 @@ return view.extend({
|
||||
o = s.taboption('netsetup', form.Value, 'lan_ipaddr', _('IPv4 address'));
|
||||
o.datatype = 'ip4addr';
|
||||
|
||||
o = s.taboption('netsetup', form.Value, 'lan_netmask', _('IPv4 netmask'));
|
||||
o.datatype = 'ip4addr';
|
||||
o.value('255.255.255.0');
|
||||
o.value('255.255.0.0');
|
||||
o.value('255.0.0.0');
|
||||
o.default = '255.255.255.0';
|
||||
|
||||
o = s.taboption('netsetup', form.DynamicList, 'lan_dns', _('Use custom DNS servers'), _('Leave empty to use ISP DNS'));
|
||||
o.datatype = 'ip4addr';
|
||||
o.cast = 'string';
|
||||
|
||||
@@ -11,7 +11,7 @@ boot() {
|
||||
add_wizard() {
|
||||
local cfg="$1"
|
||||
local wan_proto wan_pppoe_user wan_pppoe_pass
|
||||
local lan_ipaddr lan_netmask lan_dns lan_gateway dhcp
|
||||
local lan_ipaddr lan_dns lan_gateway dhcp
|
||||
local device ipv6 old_ipv6 wifi_ssid wifi_key old_wifi_ssid old_wifi_key
|
||||
|
||||
config_get wan_proto "$cfg" wan_proto
|
||||
@@ -43,10 +43,8 @@ add_wizard() {
|
||||
esac
|
||||
|
||||
config_get lan_ipaddr "$cfg" lan_ipaddr
|
||||
config_get lan_netmask "$cfg" lan_netmask
|
||||
test -n "${lan_ipaddr}" && test -n "${lan_netmask}" && {
|
||||
test -n "${lan_ipaddr}" && {
|
||||
uci set network.lan.ipaddr="${lan_ipaddr}"
|
||||
uci set network.lan.netmask="${lan_netmask}"
|
||||
}
|
||||
|
||||
config_get siderouter "$cfg" siderouter
|
||||
@@ -162,7 +160,6 @@ uci -q set wizard.default.wan_proto="$(uci -q get network.wan.proto)"
|
||||
uci -q set wizard.default.wan_pppoe_user="$(uci -q get network.wan.username)"
|
||||
uci -q set wizard.default.wan_pppoe_pass="$(uci -q get network.wan.password)"
|
||||
uci -q set wizard.default.lan_ipaddr="$(uci -q get network.lan.ipaddr)"
|
||||
uci -q set wizard.default.lan_netmask="$(uci -q get network.lan.netmask)"
|
||||
uci -q set wizard.default.lan_gateway="$(uci -q get network.lan.gateway)"
|
||||
uci -q set wizard.default.lan_dns="$(uci -q get network.lan.dns)"
|
||||
[ "$(uci -q get dhcp.lan.ignore)" ] && uci -q set wizard.default.dhcp="0" || uci -q del wizard.default.dhcp
|
||||
|
||||
Reference in new issue
Block a user