1. 修改断开设备连接位置
2. ios添加未打开微信定位权限引导
This commit is contained in:
parent
855068a3f9
commit
f39916214b
@ -180,8 +180,8 @@ export default {
|
|||||||
openTime: parseInt(new Date().getTime() / 1000) + this.time,
|
openTime: parseInt(new Date().getTime() / 1000) + this.time,
|
||||||
onlineToken: this.onlineToken
|
onlineToken: this.onlineToken
|
||||||
})
|
})
|
||||||
|
this.closeBluetoothConnection()
|
||||||
if(code === 0) {
|
if(code === 0) {
|
||||||
this.closeBluetoothConnection()
|
|
||||||
this.show = true
|
this.show = true
|
||||||
this.type = type
|
this.type = type
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
|
|||||||
@ -78,8 +78,8 @@ export default {
|
|||||||
startTime: timestamp,
|
startTime: timestamp,
|
||||||
endTime: timestamp
|
endTime: timestamp
|
||||||
})
|
})
|
||||||
|
that.closeBluetoothConnection()
|
||||||
if(code === 0) {
|
if(code === 0) {
|
||||||
that.closeBluetoothConnection()
|
|
||||||
const { code: requestCode, message } = await deletePsaawordRequest({
|
const { code: requestCode, message } = await deletePsaawordRequest({
|
||||||
lockId: that.currentLockInfo.lockId,
|
lockId: that.currentLockInfo.lockId,
|
||||||
keyboardPwdId: that.currentPasswordInfo.keyboardPwdId,
|
keyboardPwdId: that.currentPasswordInfo.keyboardPwdId,
|
||||||
|
|||||||
@ -120,8 +120,8 @@ export default {
|
|||||||
startTime: timestamp,
|
startTime: timestamp,
|
||||||
endTime: timestamp
|
endTime: timestamp
|
||||||
})
|
})
|
||||||
|
that.closeBluetoothConnection()
|
||||||
if(code === 0) {
|
if(code === 0) {
|
||||||
that.closeBluetoothConnection()
|
|
||||||
const { code: requestCode, message } = await deletePsaawordRequest({
|
const { code: requestCode, message } = await deletePsaawordRequest({
|
||||||
lockId: that.currentLockInfo.lockId,
|
lockId: that.currentLockInfo.lockId,
|
||||||
keyboardPwdId: password.keyboardPwdId,
|
keyboardPwdId: password.keyboardPwdId,
|
||||||
@ -180,8 +180,8 @@ export default {
|
|||||||
uid: that.userInfo.uid.toString(),
|
uid: that.userInfo.uid.toString(),
|
||||||
keyId: that.currentLockInfo.keyId.toString()
|
keyId: that.currentLockInfo.keyId.toString()
|
||||||
})
|
})
|
||||||
|
that.closeBluetoothConnection()
|
||||||
if(code === 0) {
|
if(code === 0) {
|
||||||
that.closeBluetoothConnection()
|
|
||||||
const { code: requestCode, message } = await resetPsaawordListRequest({
|
const { code: requestCode, message } = await resetPsaawordListRequest({
|
||||||
lockId: that.currentLockInfo.lockId,
|
lockId: that.currentLockInfo.lockId,
|
||||||
passwordKey: that.currentLockInfo.bluetooth.passwordKey
|
passwordKey: that.currentLockInfo.bluetooth.passwordKey
|
||||||
|
|||||||
@ -137,6 +137,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
fail (res) {
|
fail (res) {
|
||||||
|
console.log('获取地理位置信息失败', res)
|
||||||
if(res.errMsg === 'getLocation:fail auth deny') {
|
if(res.errMsg === 'getLocation:fail auth deny') {
|
||||||
uni.showModal({
|
uni.showModal({
|
||||||
title: '提示',
|
title: '提示',
|
||||||
@ -154,6 +155,23 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
} else if(res.errMsg === 'getLocation:fail system permission denied') {
|
||||||
|
uni.showModal({
|
||||||
|
title: '提示',
|
||||||
|
content: '定位失败,请打开微信的位置权限',
|
||||||
|
confirmText: '去打开',
|
||||||
|
cancelText: '跳过',
|
||||||
|
success (res) {
|
||||||
|
if (res.confirm) {
|
||||||
|
uni.openAppAuthorizeSetting()
|
||||||
|
} else {
|
||||||
|
that.routeJump({
|
||||||
|
type: 'redirectTo',
|
||||||
|
name: 'bindLock'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
uni.showModal({
|
uni.showModal({
|
||||||
title: '提示',
|
title: '提示',
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user