--demand 添加权限

This commit is contained in:
yuping
2023-02-01 23:25:21 +08:00
parent 0f498f55c6
commit e15cabe750

View File

@@ -1125,6 +1125,7 @@ export default {
pubtime: value.publishTime ? value.publishTime : "-", pubtime: value.publishTime ? value.publishTime : "-",
cretime: value.createTime ? value.createTime : "-", cretime: value.createTime ? value.createTime : "-",
remark: value.remark ? value.remark : "-", remark: value.remark ? value.remark : "-",
permissions: value.permissions,
}; };
array.push(obj); array.push(obj);
}); });
@@ -1553,6 +1554,45 @@ export default {
storage.set("routerId", id); storage.set("routerId", id);
} }
const getLearnPathInfo = (id) => {
// console.log("编辑学习路径图id", id);
//获取学习路径详情
api
.getRouterDetail(id)
.then((res) => {
if (res.data.code === 200) {
console.log("获取学习路径详情成功", res.data.data);
let detail = res.data.data.routerInfo;
state.pathName = detail.name;
state.pathBg = detail.picUrl;
state.pathBgId = "";
state.organizationSelectName = detail.organizationName;
state.organizationSelectId = detail.organizationId;
state.pathIntro = detail.remark;
state.editPathId = id;
let arr = imgData.value;
arr.forEach((item) => {
if (item.dictValue === state.pathBg) {
state.pathBgId = item.dictCode;
}
});
//for (let i = 0; i < arr.length; i++) {
// console.log("arr[i].dictValue", arr[i].dictValue, state.pathBg);
// if (arr[i].dictValue === state.pathBg) {
// state.pathBgId = arr[i].dictCode;
// }
// }
}
})
.catch((err) => {
console.log("获取详情失败", err);
});
state.out1 = true;
};
return { return {
...toRefs(state), ...toRefs(state),
imgData, imgData,
@@ -1595,7 +1635,8 @@ export default {
resetLearnPath, resetLearnPath,
showLearnBgMore, showLearnBgMore,
closeLearnBgMore, closeLearnBgMore,
checkPer checkPer,
getLearnPathInfo
}; };
}, },
}; };