个人中心添加-牌位管理页面-全部开启暂时regionId=1
This commit is contained in:
parent
8cf6372b6e
commit
89136edf66
|
|
@ -147,7 +147,8 @@ export default {
|
|||
return {
|
||||
// 兼容字段:同时传 floorId 与后端现用的 regionId
|
||||
|
||||
regionId: String(floorId),
|
||||
// regionId: String(floorId),
|
||||
regionId: 1,
|
||||
command, // open | close
|
||||
mac: "FFFFFFFFFFFF",
|
||||
timeout: "11",
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@
|
|||
@click="handleMenuClick(item)"
|
||||
>
|
||||
<view class="menu-icon">
|
||||
<image :src="item.icon" mode="aspectFit" />
|
||||
<image v-if="item.icon" :src="item.icon" mode="aspectFit" />
|
||||
</view>
|
||||
<text class="menu-text">{{ item.title }}</text>
|
||||
<view class="menu-arrow">
|
||||
|
|
@ -51,6 +51,7 @@ export default {
|
|||
backgroundColor: "#F5F0E7",
|
||||
},
|
||||
CommonEnum,
|
||||
SysAdmin: false,
|
||||
// 加载状态
|
||||
loading: false,
|
||||
// 用户信息
|
||||
|
|
@ -86,6 +87,11 @@ export default {
|
|||
icon: CommonEnum.MY_ACTIVITY,
|
||||
path: "/page_user/luru/index",
|
||||
},
|
||||
{
|
||||
title: "牌位管理",
|
||||
// 无图标,仅管理员可见
|
||||
path: "/pages/memorial/adminMemorial",
|
||||
},
|
||||
{
|
||||
title: "退出登录",
|
||||
path: "/pages/login/login",
|
||||
|
|
@ -166,9 +172,11 @@ export default {
|
|||
},
|
||||
toFilteredMenuItems() {
|
||||
console.log("filteredMenuItems触发了:", this.SysAdmin);
|
||||
return this.SysAdmin
|
||||
? this.menuItems
|
||||
: this.menuItems.filter((item) => item.title !== "牌位录入");
|
||||
// 非管理员隐藏:牌位录入、牌位管理
|
||||
if (this.SysAdmin) return this.menuItems;
|
||||
return this.menuItems.filter(
|
||||
(item) => item.title !== "牌位录入" && item.title !== "牌位管理",
|
||||
);
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
// 统一请求工具
|
||||
import { getAppId, getTempToken, shouldUseTempToken } from "@/config/dev.js";
|
||||
import { getAppId, getTempToken } from "@/config/dev.js";
|
||||
import debounce from "uview-ui/libs/function/debounce";
|
||||
|
||||
// 环境配置
|
||||
|
|
@ -52,7 +52,7 @@ function getRequestHeaders(customHeader = {}) {
|
|||
let token = uni.getStorageSync("token");
|
||||
|
||||
// 开发环境使用临时token
|
||||
if (shouldUseTempToken() && !token) {
|
||||
if (!token) {
|
||||
token = getTempToken();
|
||||
}
|
||||
|
||||
|
|
@ -147,7 +147,7 @@ export function request(options = {}) {
|
|||
let token = uni.getStorageSync("token");
|
||||
|
||||
// 如果本地没有token且启用了临时token,则使用临时token
|
||||
if (!token && shouldUseTempToken() && !options.noToken) {
|
||||
if (!token && !options.noToken) {
|
||||
token = getTempToken();
|
||||
console.log("使用临时token进行开发测试");
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user