mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-11 20:06:47 +08:00
--demand 权限列表
This commit is contained in:
@@ -28,6 +28,8 @@ import BreadCrumb from "@/components/BreadCrumb";
|
||||
import zhCN from "ant-design-vue/es/locale/zh_CN";
|
||||
import * as api1 from "@/api/index1";
|
||||
import * as api2 from "@/api/index";
|
||||
import {boeRequest} from "@/api/request";
|
||||
import {USER_PERMISSION} from "@/api/ThirdApi";
|
||||
|
||||
const store = useStore();
|
||||
const isLogin = ref(false);
|
||||
@@ -60,6 +62,7 @@ function init() {
|
||||
initDict("projectPic");
|
||||
initDict("sysType");
|
||||
getMemberInfo();
|
||||
getUserPermission();
|
||||
}
|
||||
|
||||
function unloadHandler() {
|
||||
@@ -102,6 +105,12 @@ async function initDict(key, localStory = false) {
|
||||
store.commit("SET_DICT", {key, data: list});
|
||||
}
|
||||
|
||||
function getUserPermission(){
|
||||
boeRequest(USER_PERMISSION,{permissionType:'PAGE'}).then(res=>{
|
||||
store.commit("SET_PERMISSION", res.result.flatMap(t=>t?.permissionPageList.map(s=>s.url)));
|
||||
})
|
||||
}
|
||||
|
||||
const getDictList = (param) => api1.getDictTree({setCode: param,}).then((res) => res.data.data);
|
||||
</script>
|
||||
<style lang="scss">
|
||||
|
||||
Reference in New Issue
Block a user