Merge pull request #525 from UAb5eSMn/web-network-config

web: Change ip, netmask and gw network settings at the same time
This commit is contained in:
logicog authored and GitHub committed 2026-09-27 17:42:21 +02:00
commit e4f3315af3
1 file changed
+1 -1
+1 -1
View File
@@ -1766,7 +1766,7 @@ $("sy-apply").addEventListener("click",function(){
if(!/^[\x21-\x7e]{1,23}$/.test(hn)||/["\\]/.test(hn)){toast(t("sy_host_err"),"err");return;} if(!/^[\x21-\x7e]{1,23}$/.test(hn)||/["\\]/.test(hn)){toast(t("sy_host_err"),"err");return;}
cmds.push("hostname "+hn); cmds.push("hostname "+hn);
} }
cmds.push("ip "+ip,"netmask "+mask,"gw "+gw); cmds.push("ip "+ip+"\nnetmask "+mask+"\ngw "+gw);
var changingIp=ip!==S.info.ip_address; var changingIp=ip!==S.info.ip_address;
confirmModal(t("sy_net_q"),changingIp?t("sy_net_d",{ip:ip}):"",function(){ confirmModal(t("sy_net_q"),changingIp?t("sy_net_d",{ip:ip}):"",function(){
postCmds(cmds).then(function(){ postCmds(cmds).then(function(){