From c8a6aa3210cfc6c377afe7ec7300c665159414bd Mon Sep 17 00:00:00 2001
From: TsMask <340112800@qq.com>
Date: Tue, 14 May 2024 14:58:35 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E9=94=81=E5=B1=8F=E9=81=AE=E7=BD=A9?=
=?UTF-8?q?=E6=B7=BB=E5=8A=A0=E7=B3=BB=E7=BB=9F=E9=87=8D=E7=BD=AE=E7=AD=89?=
=?UTF-8?q?=E5=BE=85?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/components/LockScreen/index.vue | 11 +++++++++++
src/i18n/locales/en-US.ts | 4 +++-
src/i18n/locales/zh-CN.ts | 2 ++
src/store/modules/locked.ts | 6 +++---
4 files changed, 19 insertions(+), 4 deletions(-)
diff --git a/src/components/LockScreen/index.vue b/src/components/LockScreen/index.vue
index 9960b21d..078b01a5 100644
--- a/src/components/LockScreen/index.vue
+++ b/src/components/LockScreen/index.vue
@@ -143,6 +143,17 @@ onUnmounted(() => {
{{ t('components.LockScreen.backReload2') }}
+
+
+
+
+
+ {{ t('components.LockScreen.systemReset') }}
+
+
+ {{ t('components.LockScreen.systemReset2') }}
+
+
diff --git a/src/i18n/locales/en-US.ts b/src/i18n/locales/en-US.ts
index eb65dbf3..7819755e 100644
--- a/src/i18n/locales/en-US.ts
+++ b/src/i18n/locales/en-US.ts
@@ -129,7 +129,9 @@ export default {
validError:'Validation Failure',
backLogin:'Logout to Relogin',
backReload:'Restarting now, please wait...',
- backReload2:'When ready, your browser will automatically refresh.',
+ backReload2:'When ready, Your browser will automatically refresh.',
+ systemReset:'Resetting now, please wait...',
+ systemReset2:'Data information is being reset.',
},
},
diff --git a/src/i18n/locales/zh-CN.ts b/src/i18n/locales/zh-CN.ts
index 78d0235b..2e84564f 100644
--- a/src/i18n/locales/zh-CN.ts
+++ b/src/i18n/locales/zh-CN.ts
@@ -130,6 +130,8 @@ export default {
backLogin:'退出并重新登录',
backReload:'正在重启,请稍等...',
backReload2:'当准备就绪的时候,你的浏览器会自动刷新。',
+ systemReset:'正在重置,请稍等...',
+ systemReset2:'数据信息正在重置',
},
},
diff --git a/src/store/modules/locked.ts b/src/store/modules/locked.ts
index c33e5036..1f7ef276 100644
--- a/src/store/modules/locked.ts
+++ b/src/store/modules/locked.ts
@@ -7,14 +7,14 @@ import { defineStore } from 'pinia';
/**锁屏信息类型 */
type Locked = {
/**锁屏类型 */
- type: 'none' | 'lock' | 'reload' | string;
+ type: 'none' | 'lock' | 'reload' | 'reset' ;
/**lock 超时锁屏时间,秒*/
lockTimeout: number;
};
const useLockedStore = defineStore('locked', {
state: (): Locked => ({
- type: localGet(CACHE_LOCAL_LOCK) || 'none',
+ type: (localGet(CACHE_LOCAL_LOCK) || 'none') as Locked['type'],
lockTimeout: 0,
}),
getters: {},
@@ -38,7 +38,7 @@ const useLockedStore = defineStore('locked', {
}
},
// 设置锁定
- async fnLock(type: 'none' | 'lock' | 'reload' | string) {
+ async fnLock(type: Locked['type'] ) {
this.type = type;
localSet(CACHE_LOCAL_LOCK, type);
if (type === 'reload') {