mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-15 22:06:43 +08:00
修改课程编辑资源归属为空的情况的处理,适应老课程的处理
This commit is contained in:
@@ -387,6 +387,7 @@ import apiTag from '../../api/modules/tag.js';
|
||||
import apiHRBP from '../../api/boe/HRBP.js';
|
||||
import apiCourse from '../../api/modules/course.js';
|
||||
import apiOrg from '../../api/system/organiza.js';
|
||||
import apiUser from '../../api/system/user.js';
|
||||
import WxEditor from '@/components/Editor/index.vue';
|
||||
import catalogSort from '@/components/Course/catalogSort.vue';
|
||||
import { courseType, getType } from '../../utils/tools.js';
|
||||
@@ -777,20 +778,32 @@ export default {
|
||||
this.contentInfo.list = result.contents;
|
||||
this.sectionInfo.list = result.sections;
|
||||
this.courseTeachers = result.teachers; //课程的老师信息
|
||||
|
||||
|
||||
if(!this.courseInfo.orgId){
|
||||
this.courseInfo.orgId=this.userInfo.departId;
|
||||
}
|
||||
//$this.orgKid='';
|
||||
if($this.courseInfo.orgId){
|
||||
apiOrg.getSimple($this.courseInfo.orgId).then(rrs=>{
|
||||
//根据课程创建者获取机构id
|
||||
apiUser.getOrgSimpleByUserId(result.course.sysCreateAid).then(ors=>{
|
||||
if(ors.status==200){
|
||||
$this.courseInfo.orgId=ors.result.id;
|
||||
apiOrg.getSimple(ors.result.id).then(rrs=>{
|
||||
if(rrs.status==200){
|
||||
$this.orgName=rrs.result.name;
|
||||
$this.orgKid=rrs.result.kid;
|
||||
}
|
||||
})
|
||||
}else{
|
||||
//
|
||||
}
|
||||
})
|
||||
|
||||
}else{
|
||||
apiOrg.getSimple(this.courseInfo.orgId).then(rrs=>{
|
||||
if(rrs.status==200){
|
||||
$this.orgName=rrs.result.name;
|
||||
$this.orgKid=rrs.result.kid;
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
this.resOwnerArray=[];
|
||||
if (result.course.resOwner1 == '') {
|
||||
this.resOwnerArray.push(result.course.resOwner1);
|
||||
|
||||
Reference in New Issue
Block a user