fix: 解决发现的兼容问题
This commit is contained in:
parent
4c7c1af3f5
commit
d9158dcc99
2
App.vue
2
App.vue
@ -19,6 +19,7 @@
|
||||
sn: '',
|
||||
// 获取环境配置
|
||||
getEnvConfig() {
|
||||
// #ifdef MP-WEIXIN
|
||||
const envVersionStorage = getStorage('envVersion')
|
||||
if (envVersionStorage) {
|
||||
return envVersionStorage
|
||||
@ -29,6 +30,7 @@
|
||||
if (this.envVersion === 'trial') {
|
||||
return 'XHJ'
|
||||
}
|
||||
// #endif
|
||||
return 'DEV'
|
||||
}
|
||||
},
|
||||
|
||||
@ -275,7 +275,9 @@
|
||||
}
|
||||
const { code, data, message } = await createKeyRequest(params)
|
||||
if (code === 0) {
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.reportEvent('create_key', {})
|
||||
// #endif
|
||||
this.updateKeySearch({
|
||||
...this.keySearch,
|
||||
pageNo: 1
|
||||
|
||||
@ -455,7 +455,9 @@
|
||||
})
|
||||
uni.hideLoading()
|
||||
if (requestCode === 0) {
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.reportEvent('create_password', {})
|
||||
// #endif
|
||||
$lock.updatePasswordSearch({
|
||||
...$lock.passwordSearch,
|
||||
pageNo: 1
|
||||
@ -562,7 +564,10 @@
|
||||
}
|
||||
const { code, data, message } = await createPsaawordRequest(params)
|
||||
if (code === 0) {
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.reportEvent('create_password', {})
|
||||
// #endif
|
||||
|
||||
$lock.updatePasswordSearch({
|
||||
...$lock.passwordSearch,
|
||||
pageNo: 1
|
||||
@ -638,23 +643,23 @@
|
||||
}
|
||||
|
||||
.text {
|
||||
padding: 0 32rpx;
|
||||
margin-top: 40rpx;
|
||||
margin-bottom: 50rpx;
|
||||
color: #262626;
|
||||
font-size: 26rpx;
|
||||
padding: 0 32rpx;
|
||||
color: #262626;
|
||||
}
|
||||
|
||||
.button {
|
||||
border-radius: 64rpx;
|
||||
width: 686rpx;
|
||||
margin-left: 32rpx;
|
||||
height: 100rpx;
|
||||
line-height: 100rpx;
|
||||
text-align: center;
|
||||
background-color: #63b8af;
|
||||
color: #fff;
|
||||
margin-left: 32rpx;
|
||||
font-size: 32rpx;
|
||||
font-weight: bold;
|
||||
line-height: 100rpx;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
background-color: #63b8af;
|
||||
border-radius: 64rpx;
|
||||
}
|
||||
</style>
|
||||
|
||||
@ -129,10 +129,12 @@
|
||||
$bluetooth.closeBluetoothConnection()
|
||||
})
|
||||
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.reportEvent('open_door', {
|
||||
result: code,
|
||||
duration: new Date().getTime() - timestamp
|
||||
})
|
||||
// #endif
|
||||
|
||||
if (code === 0) {
|
||||
uni.showToast({
|
||||
|
||||
@ -363,15 +363,19 @@
|
||||
onlineToken: onlineToken.value
|
||||
})
|
||||
if (type === 'open') {
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.reportEvent('open_door', {
|
||||
result: code,
|
||||
duration: new Date().getTime() - timestamp
|
||||
})
|
||||
// #endif
|
||||
} else if (type === 'close') {
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.reportEvent('close_door', {
|
||||
result: code,
|
||||
duration: new Date().getTime() - timestamp
|
||||
})
|
||||
// #endif
|
||||
}
|
||||
if (code === 0) {
|
||||
$bluetooth
|
||||
|
||||
@ -129,6 +129,7 @@
|
||||
this.buttonInfo = await this.getButtonInfo()
|
||||
this.env = await env[await getApp().globalData.getEnvConfig()]
|
||||
this.envVersion = getApp().globalData.envVersion
|
||||
|
||||
// eslint-disable-next-line guard-for-in,no-restricted-syntax
|
||||
for (let key in env) {
|
||||
this.envList.push({
|
||||
@ -136,7 +137,6 @@
|
||||
key
|
||||
})
|
||||
}
|
||||
console.log(this.envList)
|
||||
},
|
||||
methods: {
|
||||
...mapActions(useBasicStore, ['getButtonInfo', 'routeJump']),
|
||||
|
||||
@ -322,18 +322,18 @@
|
||||
}
|
||||
|
||||
.u-swipe-action {
|
||||
overflow: inherit !important;
|
||||
width: 700rpx;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
width: 700rpx;
|
||||
padding-bottom: 140rpx !important;
|
||||
overflow: inherit !important;
|
||||
}
|
||||
|
||||
.u-swipe-action-item {
|
||||
overflow: inherit !important;
|
||||
border-radius: 32rpx !important;
|
||||
background: transparent !important;
|
||||
border-radius: 32rpx !important;
|
||||
}
|
||||
|
||||
.u-swipe-action-item__right {
|
||||
@ -342,8 +342,8 @@
|
||||
}
|
||||
|
||||
.u-swipe-action-item__content {
|
||||
border-radius: 32rpx !important;
|
||||
margin-left: 25rpx;
|
||||
border-radius: 32rpx !important;
|
||||
}
|
||||
|
||||
.u-swipe-action-item__right__button {
|
||||
@ -357,14 +357,14 @@
|
||||
}
|
||||
|
||||
.notification {
|
||||
border-radius: 32rpx;
|
||||
margin-top: 32rpx;
|
||||
position: relative;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
width: 636rpx;
|
||||
padding: 32rpx;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
position: relative;
|
||||
margin-top: 32rpx;
|
||||
border-radius: 32rpx;
|
||||
box-shadow: 2rpx 2rpx 10rpx rgba(0, 0, 0, 0.3);
|
||||
|
||||
.icon {
|
||||
@ -373,44 +373,44 @@
|
||||
}
|
||||
|
||||
.point {
|
||||
position: absolute;
|
||||
top: 41rpx;
|
||||
left: 72rpx;
|
||||
width: 16rpx;
|
||||
height: 16rpx;
|
||||
background-color: #ff0000;
|
||||
border-radius: 50%;
|
||||
position: absolute;
|
||||
top: 41rpx;
|
||||
left: 72rpx;
|
||||
}
|
||||
|
||||
.content {
|
||||
width: 550rpx;
|
||||
font-size: 28rpx;
|
||||
color: #6c6c6c;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
font-size: 28rpx;
|
||||
font-weight: bold;
|
||||
color: #6c6c6c;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.time {
|
||||
font-size: 24rpx;
|
||||
color: #6c6c6c;
|
||||
margin-top: 5rpx;
|
||||
font-size: 24rpx;
|
||||
font-weight: bold;
|
||||
color: #6c6c6c;
|
||||
}
|
||||
}
|
||||
|
||||
.delete {
|
||||
position: fixed;
|
||||
right: 30rpx;
|
||||
bottom: 80rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 100rpx;
|
||||
height: 100rpx;
|
||||
border-radius: 50%;
|
||||
background-color: #5db5aa;
|
||||
position: fixed;
|
||||
bottom: 80rpx;
|
||||
right: 30rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
border-radius: 50%;
|
||||
|
||||
.delete-image {
|
||||
width: 45rpx;
|
||||
@ -426,29 +426,29 @@
|
||||
}
|
||||
|
||||
.empty-list-text {
|
||||
text-align: center;
|
||||
font-size: 32rpx;
|
||||
color: #999999;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.tips {
|
||||
margin-top: 40vh;
|
||||
padding: 32rpx 0;
|
||||
text-align: center;
|
||||
margin-top: 40vh;
|
||||
font-size: 28rpx;
|
||||
color: #999999;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.button-login {
|
||||
border-radius: 46rpx;
|
||||
width: 650rpx;
|
||||
height: 120rpx;
|
||||
line-height: 120rpx;
|
||||
text-align: center;
|
||||
margin-left: 50rpx;
|
||||
background: #63b8af;
|
||||
color: #ffffff;
|
||||
font-size: 48rpx;
|
||||
font-weight: bold;
|
||||
line-height: 120rpx;
|
||||
color: #ffffff;
|
||||
text-align: center;
|
||||
background: #63b8af;
|
||||
border-radius: 46rpx;
|
||||
}
|
||||
</style>
|
||||
|
||||
@ -286,10 +286,12 @@
|
||||
$bluetooth.closeBluetoothConnection()
|
||||
})
|
||||
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.reportEvent('open_door', {
|
||||
result: code,
|
||||
duration: new Date().getTime() - timestamp
|
||||
})
|
||||
// #endif
|
||||
|
||||
if (code === 0) {
|
||||
uni.showToast({
|
||||
|
||||
@ -440,7 +440,7 @@ export const useBasicStore = defineStore('basic', {
|
||||
// 设备信息
|
||||
deviceInfo: null,
|
||||
// 胶囊按钮的位置信息
|
||||
buttonInfo: null,
|
||||
buttonInfo: {},
|
||||
// 分享配置
|
||||
shareConfig: {}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user