llj
2026-01-27 373a695602d097ebfeab50ed14dc0bbf96c691a1
src/permission.js
@@ -7,10 +7,12 @@
import { isPathMatch } from "@/utils/validate";
import { isRelogin } from "@/utils/request";
NProgress.configure({ showSpinner: false });
const whiteList = [
  "/login",
  "/loginTMS",
  "/register",
  "/printList",
  "/hBarPlanPrint",
@@ -22,6 +24,9 @@
  "/gyMaterial",
  "/FbStepFoldinBillList",
  "/FbStepFoldOutBillList",
  "/warehouse/barcodeMaster/Gy_BarCodeBill_JinLong",
  "/warehouse/barcodeMaster/Gy_BarCodeBill_JinLong_AutoLogin",
  "/warehouse/barcodeMaster/Gy_BarCodeBillList_JinLong_AutoLogin"
]; // no redirect whitelist
const isWhiteList = (path) => {
@@ -48,6 +53,7 @@
        // 判断当前用户是否已拉取完user_info信息
        store .dispatch("GetInfo").then(() => {
            isRelogin.show = false;
            store.dispatch("GenerateRoutes").then((accessRoutes) => {
              // 根据roles权限生成可访问的路由表
              router.addRoutes(accessRoutes); // 动态添加可访问路由表