处理问题

This commit is contained in:
2026-01-17 02:33:39 +08:00
parent 9ea4f0e999
commit 32993ff52c
10 changed files with 54 additions and 28 deletions

View File

@@ -1,6 +1,7 @@
"use strict";
const common_vendor = require("../../common/vendor.js");
const utils_helper = require("../../utils/helper.js");
const api_index = require("../../api/index.js");
if (!Array) {
const _easycom_nut_avatar2 = common_vendor.resolveComponent("nut-avatar");
const _easycom_nut_icon2 = common_vendor.resolveComponent("nut-icon");
@@ -27,17 +28,24 @@ const _sfc_main = {
init();
});
const init = () => {
api_index.fetchUserInfo().then((res) => {
common_vendor.index.__f__("log", "at pages/mine/index.vue:72", res);
common_vendor.index.setStorageSync("uid", res.user_id);
common_vendor.index.setStorageSync("user_name", res.user_name);
common_vendor.index.setStorageSync("role", res.role.value);
common_vendor.index.setStorageSync("staff_name", res.staff_name);
});
common_vendor.index.getStorageSync("user_name");
let staff_name = common_vendor.index.getStorageSync("staff_name");
let role = common_vendor.index.getStorageSync("role");
let user_id = common_vendor.index.getStorageSync("uid");
common_vendor.index.__f__("log", "at pages/mine/index.vue:70", "staff_name", staff_name);
common_vendor.index.__f__("log", "at pages/mine/index.vue:82", "staff_name", staff_name);
uid.value = user_id;
staffName.value = staff_name;
staffRole.value = role;
};
common_vendor.onShow(() => {
common_vendor.index.__f__("log", "at pages/mine/index.vue:81", "init");
common_vendor.index.__f__("log", "at pages/mine/index.vue:92", "init");
init();
});
return (_ctx, _cache) => {