You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

getIsShowRegionTree.7b64ce60.js 821B

1
  1. import{B as u}from"./index.a2494fc2.js";const r=u.userStore.userInfo||{},n=r.userRoleInfoList.map(e=>e.code),c=(e,o="or")=>{var i=o==="and";return e.forEach(s=>{n.includes(s)&&o==="or"?i=!0:!n.includes(s)&&o==="and"&&(i=!1)}),i},t=e=>n.includes("SUPER_ADMIN")&&Object.keys(e).includes("SUPER_ADMIN")?{regionCode:330500,regionLevel:2}:n.includes("VISITOR")&&Object.keys(e).includes("VISITOR")?{regionCode:330500,regionLevel:2}:n.includes("REGION_MANAGER")&&Object.keys(e).includes("REGION_MANAGER")?{regionCode:Number(r.regionCode),regionLevel:r.regionCode==="330500"&&!e.REGION_MANAGER?2:3}:n.includes("EXPERT_ADMIN")&&Object.keys(e).includes("EXPERT_ADMIN")?{regionCode:Number(r.regionCode),regionLevel:r.regionCode==="330500"&&!e.EXPERT_ADMIN?2:3}:{regionCode:Number(r.regionCode),regionLevel:3};export{t as a,c as g};