From a128d99df306bb1ab017b7069fb0441837b3917b Mon Sep 17 00:00:00 2001
From: zhanghua <314079846@qq.com>
Date: 星期一, 13 十月 2025 10:04:35 +0800
Subject: [PATCH] 导出加参数
---
src/views/login/index.vue | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index 2419b5a..ae5111e 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -95,10 +95,17 @@
isAdmin = true;
}
})
+
if (isAdmin) {
- findStaffByUserId(res.id).then(staffs => {
- localStorage.setItem("staffs", JSON.stringify(staffs));
- localStorage.setItem("selectStaff", JSON.stringify(staffs[0]));
+ findStaffByUserId(res.id).then(sres => {
+
+ if (sres.data && sres.data.findStaffByUserId) {
+ var staffs = sres.data.findStaffByUserId;
+ localStorage.setItem("staffs", JSON.stringify(staffs));
+ localStorage.setItem("selectStaff", JSON.stringify(staffs[0]));
+
+ this.$EventBus.$emit("updateStaffs", '123');
+ }
})
}
--
Gitblit v1.8.0