修复蓝牙连接锁未释放的问题
This commit is contained in:
@ -15,7 +15,7 @@
|
||||
|
||||
</block>
|
||||
</uni-nav-bar>
|
||||
<view class="eq">
|
||||
<view class="eq" :style="{marginTop:Status.navbar.height+'px'}">
|
||||
<view class="leftImg" @click.stop="previewImg(device.devicePic?device.devicePic:formData.img)">
|
||||
<image class="img" :src="device.devicePic?device.devicePic:formData.img" mode="aspectFit"></image>
|
||||
|
||||
@ -84,7 +84,7 @@
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="warnnig" v-show="formData.sta_ShakeBit!='' && formData.sta_ShakeBit!='0'"
|
||||
<view class="warnnig" v-show="formData.sta_ShakeBit==1 && formData.sta_ShakeBit==2"
|
||||
@click="showAction('map')">
|
||||
<view>{{ShakeBit}}</view>
|
||||
</view>
|
||||
@ -297,7 +297,10 @@
|
||||
permissions: []
|
||||
}
|
||||
},
|
||||
|
||||
created() {
|
||||
this.Status.navbar.height = uni.getSystemInfoSync().statusBarHeight + 44;
|
||||
console.log("this.Status.navbar.height=",this.Status.navbar.height);
|
||||
},
|
||||
onUnload() {
|
||||
console.log("页面卸载,释放资源");
|
||||
ble.removeAllCallback(pagePath);
|
||||
@ -355,7 +358,7 @@
|
||||
these.device.latitude = form.sta_latitude;
|
||||
these.formData.blename = f.name ? f.name : "Unname";
|
||||
these.formData.deviceName = device.deviceName;
|
||||
|
||||
|
||||
these.formData.bleStatu = false;
|
||||
these.formData.deviceId = f.deviceId;
|
||||
ble.LinkBlue(f.deviceId, f.writeServiceId, f.wirteCharactId, f.notifyCharactId).then(res => {
|
||||
@ -412,6 +415,7 @@
|
||||
let dic = {
|
||||
"1": "设备SOS求救中",
|
||||
"2": "设备静止报警中",
|
||||
"6":"设备遇水报警中"
|
||||
};
|
||||
let keys = Object.keys(dic);
|
||||
let f = keys.find(key => {
|
||||
|
||||
Reference in New Issue
Block a user