1. 添加密码不同状态的显示
This commit is contained in:
parent
2329997e8e
commit
ab960f8edd
@ -277,6 +277,9 @@ page {
|
|||||||
font-size: 32rpx;
|
font-size: 32rpx;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
padding-bottom: 6rpx;
|
padding-bottom: 6rpx;
|
||||||
|
white-space: nowrap;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
}
|
}
|
||||||
|
|
||||||
.key-right-bottom {
|
.key-right-bottom {
|
||||||
|
|||||||
@ -20,7 +20,12 @@
|
|||||||
<view class="password" @click="toPasswordDetail(password)">
|
<view class="password" @click="toPasswordDetail(password)">
|
||||||
<image class="password-left" src="/static/images/icon_lock_transparent.png" mode="aspectFill"></image>
|
<image class="password-left" src="/static/images/icon_lock_transparent.png" mode="aspectFill"></image>
|
||||||
<view class="password-right">
|
<view class="password-right">
|
||||||
<view class="password-right-top">{{ password.keyboardPwdName }}</view>
|
<view style="display: flex; align-items: center">
|
||||||
|
<view class="password-right-top">{{ password.keyboardPwdName }}</view>
|
||||||
|
<view class="key-status">
|
||||||
|
{{ getPasswordStatus(password.keyboardPwdStatus) }}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
<view class="password-right-bottom">{{ password.timeText }}</view>
|
<view class="password-right-bottom">{{ password.timeText }}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -81,7 +86,7 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
...mapActions(useBasicStore, ['routeJump', 'getDeviceInfo']),
|
...mapActions(useBasicStore, ['routeJump', 'getDeviceInfo']),
|
||||||
...mapActions(useLockStore, ['getPasswordList', 'updateCurrentPasswordInfo', 'updatePasswordSearch']),
|
...mapActions(useLockStore, ['getPasswordList', 'updateCurrentPasswordInfo', 'updatePasswordSearch', 'getPasswordStatus']),
|
||||||
...mapActions(useBluetoothStore, ['resetLockPassword', 'setLockPassword']),
|
...mapActions(useBluetoothStore, ['resetLockPassword', 'setLockPassword']),
|
||||||
toPasswordDetail(password) {
|
toPasswordDetail(password) {
|
||||||
this.updateCurrentPasswordInfo(password)
|
this.updateCurrentPasswordInfo(password)
|
||||||
@ -299,12 +304,13 @@ page {
|
|||||||
|
|
||||||
.password-right {
|
.password-right {
|
||||||
margin-right: 32rpx;
|
margin-right: 32rpx;
|
||||||
|
margin-left: 32rpx;
|
||||||
|
width: 574rpx;
|
||||||
|
|
||||||
.password-right-top {
|
.password-right-top {
|
||||||
font-size: 32rpx;
|
font-size: 32rpx;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
padding-bottom: 10rpx;
|
padding-bottom: 6rpx;
|
||||||
width: 600rpx;
|
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
@ -335,4 +341,10 @@ page {
|
|||||||
font-size: 32rpx;
|
font-size: 32rpx;
|
||||||
color: #999999;
|
color: #999999;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.key-status {
|
||||||
|
margin-left: auto;
|
||||||
|
font-size: 26rpx;
|
||||||
|
color: #df282d;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@ -101,6 +101,15 @@ export const useLockStore = defineStore('lock', {
|
|||||||
return ''
|
return ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
getPasswordStatus(passwordStatus) {
|
||||||
|
if(passwordStatus === 2) {
|
||||||
|
return '已过期'
|
||||||
|
} else if(passwordStatus === 3) {
|
||||||
|
return '未生效'
|
||||||
|
} else {
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
},
|
||||||
getTimeLimit(keyType) {
|
getTimeLimit(keyType) {
|
||||||
if(keyType === 1) {
|
if(keyType === 1) {
|
||||||
return '永久'
|
return '永久'
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user