/** * user_applicant --申请者 * user_manager --管理员 */ import tabBar from '../../utils/tabBar.js'; import { getUserProfile } from '@/utils/auth.js'; let temp = 'user_applicant'; if (uni.getStorageSync("userInfo")) { const userInfo = JSON.parse(uni.getStorageSync("userInfo")); if (userInfo.salt === "物业人员") { temp = 'user_manager'; } else { temp = 'user_applicant'; } } let type = temp; const state = { type: 'user_applicant', list: tabBar[type] } const mutations = { changeType(state, payload) { state.type = payload.type; } } export default { namespaced: true, state, mutations }