feat: 钱包样式
All checks were successful
构建并部署前端到生产环境 / build-and-deploy (push) Successful in 46s

This commit is contained in:
sexygoat
2026-04-24 14:36:34 +08:00
parent 8f4ecda7eb
commit 383e7b819b

View File

@@ -390,15 +390,24 @@
return; return;
} }
await new Promise((resolve) => { // #ifndef H5
const [err, res] = await uni.getConnectedWifi();
if (!err && res && res.wifi) {
const currentIP = res.wifi.localIp || '';
const lanIP = deviceInfo.lan_ip.replace('http://', '').replace('https://', '').split(':')[0];
const lanIPPrefix = lanIP.split('.').slice(0, 3).join('.');
const currentIPPrefix = currentIP.split('.').slice(0, 3).join('.');
if (currentIPPrefix !== lanIPPrefix && lanIPPrefix !== '0.0.0') {
uni.showModal({ uni.showModal({
title: '提示', title: '提示',
content: '请先连接设备WiFi否则无法访问后台管理', content: '请先连接设备WiFi否则无法访问后台管理',
showCancel: false, cancelText: '取消',
buttonText: '我知道了', confirmText: '我知道了'
success: () => resolve()
});
}); });
return;
}
}
// #endif
// 跳转到设备后台管理地址 // 跳转到设备后台管理地址
const url = deviceInfo.lan_ip.startsWith('http') ? deviceInfo.lan_ip : `http://${deviceInfo.lan_ip}`; const url = deviceInfo.lan_ip.startsWith('http') ? deviceInfo.lan_ip : `http://${deviceInfo.lan_ip}`;