new-20250827 #40

Merged
liubiao merged 3 commits from liubiao/APP:new-20250827 into main 2026-03-24 15:59:45 +08:00
Showing only changes of commit 5613f0fb8a - Show all commits

View File

@ -700,12 +700,18 @@
}
},
bleStatuToggle() {
const mac = (this.device && this.device.deviceMac) || (this.deviceInfo && this.deviceInfo.deviceMac);
if (!mac) return;
const macNorm = (m) => (m || '').replace(/:/g, '').toUpperCase();
const targetMacNorm = macNorm(mac);
const last6 = targetMacNorm.slice(-6);
let f = bleTool.data.LinkedList.find((v) => {
return v.macAddress == this.device.deviceMac;
const m = macNorm(v.macAddress || '');
return m === targetMacNorm || (m.length >= 6 && m.slice(-6) === last6);
});
if (!f) {
this.tryConnect100JBle(this.device.deviceMac);
this.tryConnect100JBle(mac);
return;
}
if (this.formData.bleStatu === true) {
@ -757,8 +763,8 @@
// 关闭状态
that.formData.sta_LightType = '-1';
}
if (this.formData_VoiceType == 7) {
this.formData.sta_VoiceType = res.data.voiceStrobeAlarm ?? 0;
if (this.formData.sta_VoiceType === '7' || this.formData.sta_VoiceType === 7) {
this.formData.sta_VoiceType = (res.data.voiceStrobeAlarm ?? 0) + '';
} else {
this.formData.sta_VoiceType = res.data.alarmMode + ''
}