diff --git a/api/keyboardPwd.js b/api/keyboardPwd.js
index 59afe24..cf869c0 100644
--- a/api/keyboardPwd.js
+++ b/api/keyboardPwd.js
@@ -37,3 +37,30 @@ export function deletePsaawordRequest(data) {
data
})
}
+
+// 创建自定义密码
+export function addCustomPasswordRequest(data) {
+ return request({
+ url: '/keyboardPwd/add',
+ method: 'POST',
+ data
+ })
+}
+
+// 更新密码
+export function updatePasswordRequest(data) {
+ return request({
+ url: '/keyboardPwd/update',
+ method: 'POST',
+ data
+ })
+}
+
+// 获取密码详情
+export function getPasswordRequest(data) {
+ return request({
+ url: '/keyboardPwd/detail',
+ method: 'POST',
+ data
+ })
+}
diff --git a/components/LockInput/LockInput.vue b/components/LockInput/LockInput.vue
index b68df6b..cf9d376 100644
--- a/components/LockInput/LockInput.vue
+++ b/components/LockInput/LockInput.vue
@@ -4,10 +4,11 @@
{{ title }}
@@ -20,7 +21,15 @@
props: {
title: String,
placeholder: String,
- value: String
+ value: String,
+ maxlength: {
+ type: Number,
+ default: 50
+ },
+ type: {
+ type: String,
+ default: 'text'
+ }
},
methods: {
changeInput(e) {
diff --git a/components/ModalInput/ModalInput.vue b/components/ModalInput/ModalInput.vue
index e9a7938..bdbc21a 100644
--- a/components/ModalInput/ModalInput.vue
+++ b/components/ModalInput/ModalInput.vue
@@ -10,6 +10,8 @@
:focus="show"
:placeholder="placeholder"
:value="text"
+ :maxlength="maxlength"
+ :type="type"
@change="change"
/>
@@ -38,7 +40,9 @@
title: { type: String, default: '请输入' },
placeholder: { type: String, default: '请输入' },
value: { type: String, default: '' },
- autoClose: { type: Boolean, default: true }
+ autoClose: { type: Boolean, default: true },
+ maxlength: { type: Number, default: 50 },
+ type: { type: String, default: 'text' }
})
const emits = defineEmits(['confirm'])
diff --git a/pages/createAdmin/createAdmin.vue b/pages/createAdmin/createAdmin.vue
index e6b594b..ba08013 100644
--- a/pages/createAdmin/createAdmin.vue
+++ b/pages/createAdmin/createAdmin.vue
@@ -196,7 +196,7 @@
return
}
- if (type === 'temporary' && temporaryStartTime.value > temporaryEndTime.value) {
+ if (type === 'temporary' && temporaryStartTime.value >= temporaryEndTime.value) {
uni.showToast({
title: '失效时间要大于生效时间',
icon: 'none'
diff --git a/pages/createCard/createCard.vue b/pages/createCard/createCard.vue
index b1ad0cc..8bef323 100644
--- a/pages/createCard/createCard.vue
+++ b/pages/createCard/createCard.vue
@@ -228,7 +228,7 @@
return
}
- if (type === 'temporary' && temporaryStartTime.value > temporaryEndTime.value) {
+ if (type === 'temporary' && temporaryStartTime.value >= temporaryEndTime.value) {
uni.showToast({
title: '失效时间要大于生效时间',
icon: 'none'
diff --git a/pages/createFace/createFace.vue b/pages/createFace/createFace.vue
index 7f9427d..91b57b5 100644
--- a/pages/createFace/createFace.vue
+++ b/pages/createFace/createFace.vue
@@ -200,7 +200,7 @@
return
}
- if (type === 'temporary' && temporaryStartTime.value > temporaryEndTime.value) {
+ if (type === 'temporary' && temporaryStartTime.value >= temporaryEndTime.value) {
uni.showToast({
title: '失效时间要大于生效时间',
icon: 'none'
diff --git a/pages/createFingerprint/createFingerprint.vue b/pages/createFingerprint/createFingerprint.vue
index 1122f1a..d96abe0 100644
--- a/pages/createFingerprint/createFingerprint.vue
+++ b/pages/createFingerprint/createFingerprint.vue
@@ -228,7 +228,7 @@
return
}
- if (type === 'temporary' && temporaryStartTime.value > temporaryEndTime.value) {
+ if (type === 'temporary' && temporaryStartTime.value >= temporaryEndTime.value) {
uni.showToast({
title: '失效时间要大于生效时间',
icon: 'none'
diff --git a/pages/createPalmVein/createPalmVein.vue b/pages/createPalmVein/createPalmVein.vue
index 1717ca7..fa7e295 100644
--- a/pages/createPalmVein/createPalmVein.vue
+++ b/pages/createPalmVein/createPalmVein.vue
@@ -229,7 +229,7 @@
return
}
- if (type === 'temporary' && temporaryStartTime.value > temporaryEndTime.value) {
+ if (type === 'temporary' && temporaryStartTime.value >= temporaryEndTime.value) {
uni.showToast({
title: '失效时间要大于生效时间',
icon: 'none'
diff --git a/pages/createPassword/createPassword.vue b/pages/createPassword/createPassword.vue
index 0eb10a0..121dceb 100644
--- a/pages/createPassword/createPassword.vue
+++ b/pages/createPassword/createPassword.vue
@@ -5,7 +5,7 @@
:list="tabs"
lineWidth="40rpx"
lineHeight="5rpx"
- :current="currnetIndex"
+ :current="currentIndex"
lineColor="#63b8af"
@click="clickTab"
:inactiveStyle="{ color: '#a3a3a3', fontSize: '32rpx', fontWeight: 'bold' }"
@@ -19,7 +19,7 @@
:list="tabs"
:autoplay="false"
:circular="true"
- :current="currnetIndex"
+ :current="currentIndex"
@change="changeSwiper"
>
@@ -27,17 +27,17 @@
:value="permanentName"
title="姓名"
placeholder="请给密码命名"
- @change-input="changePermanentInput"
+ @change-input="changeName('permanent', $event)"
>
{{ text }}
获取密码
-
+
{{ text }}
获取密码
+
+
+ 密码有效期为6个小时,只能使用一次
+ 获取密码
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 手动输入6-9位数字作为密码。可在锁旁边通过手机蓝牙添加,也可通过网关远程添加
+
+ 获取密码
+
+
+
+
+
+ 有效日
+
+ {{ cycleOptions[0][defaultIndex].name }}
+
+
+
+
+
+
+
+ 生效时间
+
+ {{ hoursStart }}:00
+
+
+
+
+
+
+
+ 失效时间
+
+
+ {{ hoursEnd }}:00
+
+
+
+
+ {{ text }}
+ 获取密码
+
+
+
+
+ 清空密码当日23:59前有效
+
+ 清空内容1:当日0点前生成的所有密码(当日0点后生成的密码,不受清空密码影响,可继续使用)
+
+ 清空内容2:清空密码使用后,立即清除所有自定义密码(含使用过和未使用过的)
+ 如需彻底清除所有密码,请使用重置所有密码功能
+ 获取密码
+
+
+
+
-
diff --git a/pages/createRemote/createRemote.vue b/pages/createRemote/createRemote.vue
index 037ce89..90f6cdd 100644
--- a/pages/createRemote/createRemote.vue
+++ b/pages/createRemote/createRemote.vue
@@ -176,7 +176,7 @@
return
}
- if (type === 'temporary' && temporaryStartTime.value > temporaryEndTime.value) {
+ if (type === 'temporary' && temporaryStartTime.value >= temporaryEndTime.value) {
uni.showToast({
title: '失效时间要大于生效时间',
icon: 'none'
diff --git a/pages/passwordDetail/passwordDetail.vue b/pages/passwordDetail/passwordDetail.vue
index 734e9eb..b91af60 100644
--- a/pages/passwordDetail/passwordDetail.vue
+++ b/pages/passwordDetail/passwordDetail.vue
@@ -1,141 +1,360 @@
-
+
+ 密码号
+ {{ $lock.currentPasswordInfo.pwdUserNo }}
+
+ $lock.currentPasswordInfo.isCustom === 1 && $refs.modalPassword.open()"
+ >
密码
- {{ currentPasswordInfo.keyboardPwd }}
-
-
- 姓名
- {{ currentPasswordInfo.keyboardPwdName }}
-
-
- 有效期
- 永久
-
- {{
- timeFormat(currentPasswordInfo.startDate, 'yyyy-mm-dd h:M')
- }}
- {{
- timeFormat(currentPasswordInfo.endDate, 'yyyy-mm-dd h:M')
- }}
+
+ {{ $lock.currentPasswordInfo.keyboardPwd }}
+
-
- {{ currentPasswordInfo.timeText.slice(0, -3) }}
+
+ $refs.modalInput.open()">
+ 姓名
+
+ {{ $lock.currentPasswordInfo.keyboardPwdName }}
+
+
+
+
+ 有效期
+
+
+ 永久
+
+ {{
+ timeFormat($lock.currentPasswordInfo.startDate, 'yyyy-mm-dd h:M')
+ }}
+ {{
+ timeFormat($lock.currentPasswordInfo.endDate, 'yyyy-mm-dd h:M')
+ }}
+
+
+ {{ $lock.currentPasswordInfo.timeText.slice(0, -3) }}
+
+
+
发送人
- {{ currentPasswordInfo.senderUsername }}
+ {{ $lock.currentPasswordInfo.senderUsername }}
发送时间
{{
- timeFormat(currentPasswordInfo.sendDate, 'yyyy-mm-dd h:M')
+ timeFormat($lock.currentPasswordInfo.sendDate, 'yyyy-mm-dd h:M')
}}
+
+ 是否为管理员
+
+
操作记录
删除
+
+
-