From 60384e8241fa855b5780260633ee9b9f8904847a Mon Sep 17 00:00:00 2001 From: baoshiwei <baoshiwei@shlanbao.cn> Date: 星期五, 20 六月 2025 14:24:19 +0800 Subject: [PATCH] feat(eims-ui-mobile): 为多个页面添加搜索功能 - 在 equ-list、insp-st、maint-st、req-list 和 res-list 页面中添加设备名称和资产编号的模糊搜索 --- eims-ui-mobile/src/store/user.ts | 11 +++++------ 1 files changed, 5 insertions(+), 6 deletions(-) diff --git a/eims-ui-mobile/src/store/user.ts b/eims-ui-mobile/src/store/user.ts index 82bd873..73058d3 100644 --- a/eims-ui-mobile/src/store/user.ts +++ b/eims-ui-mobile/src/store/user.ts @@ -1,14 +1,15 @@ import { defineStore } from 'pinia' import { ref } from 'vue' +import type { UserInfoResp, UserInfo } from '@/service/login.d' -const initState = { nickname: '', avatar: '' } +const initState = null export const useUserStore = defineStore( - 'user', + 'userInfo', () => { - const userInfo = ref<IUserInfo>({ ...initState }) + const userInfo = ref<UserInfo>({ ...initState }) - const setUserInfo = (val: IUserInfo) => { + const setUserInfo = (val: UserInfo) => { userInfo.value = val } @@ -19,13 +20,11 @@ const reset = () => { userInfo.value = { ...initState } } - const isLogined = computed(() => !!userInfo.value.token) return { userInfo, setUserInfo, clearUserInfo, - isLogined, reset, } }, -- Gitblit v1.9.3