仅内网可见-管理员端

This commit is contained in:
670788339
2025-07-20 15:39:37 +08:00
parent 3bb4b519f1
commit 206f0e825d

View File

@@ -491,6 +491,7 @@ export default {
}, },
visibleShow:false, visibleShow:false,
isPermission:false, isPermission:false,
dicts:[],
extendRefId:'', extendRefId:'',
extendRefType:'', extendRefType:'',
courseTeachers: [], //课程的老师 courseTeachers: [], //课程的老师
@@ -558,6 +559,7 @@ export default {
handler(newVal) { handler(newVal) {
//需要保存 //需要保存
this.requireSaveCourse = true; this.requireSaveCourse = true;
this.checkOrgPermission(newVal.orgId);
}, },
deep: true deep: true
} }
@@ -584,6 +586,14 @@ export default {
this.loadUserGroup(); this.loadUserGroup();
}, },
methods: { methods: {
// 检查机构权限
checkOrgPermission(orgId) {
if (!orgId) {
this.isPermission = false;
return;
}
this.isPermission = this.dicts.includes(orgId);
},
// 关键字的更改 // 关键字的更改
changeKeywords(option){ changeKeywords(option){
if(option.target.value){ if(option.target.value){
@@ -892,7 +902,8 @@ export default {
async getDetail(id) { async getDetail(id) {
this.curCourseId = id; this.curCourseId = id;
this.orgName=''; this.orgName='';
let $this = this; this.isPermission = false;
let $this = this;
try { try {
const { result, status } = await apiCourse.detail(id); const { result, status } = await apiCourse.detail(id);
if (status === 200) { if (status === 200) {
@@ -910,6 +921,7 @@ export default {
this.sectionInfo.list = result.sections; this.sectionInfo.list = result.sections;
this.courseTeachers = result.teachers; //课程的老师信息 this.courseTeachers = result.teachers; //课程的老师信息
this.isPermission = result.teachers; //课程的老师信息 this.isPermission = result.teachers; //课程的老师信息
this.dicts = result.dicts; //课程的老师信息
if(!this.courseInfo.orgId){ if(!this.courseInfo.orgId){
//根据课程创建者获取机构id //根据课程创建者获取机构id