diff --git a/src/components/Course/weikeContent.vue b/src/components/Course/weikeContent.vue index 554d801c..2b2f640c 100644 --- a/src/components/Course/weikeContent.vue +++ b/src/components/Course/weikeContent.vue @@ -778,6 +778,12 @@ if(con.contentType==40){ //console.log('加载pdf文件内容'); $this.loadPdfFile(); + }else if(con.contentType==50){ + //console.log('加载pdf文件内容'); + if(!this.scormUrl){ + $this.loadScormFile(); + } + } if(con.contentType==52){ if(con.content.startsWith('\{')){ @@ -836,7 +842,10 @@ }, loadScormFile(){ //对于scorm课件内容,需要再查一下 - this.scormUrl=''; + //this.scormUrl=''; + if(this.scormUrl){ + return; + } apiCourseFile.detail(this.cware.content.contentRefId).then(rs=>{ if(rs.status==200){ this.curCFile=rs.result; @@ -952,6 +961,7 @@ resetContent(index){ if(index==1){ this.cware.content.id=''; + this.scormUrl=''; this.cware.content.contentRefId=''; this.cware.content.contentName=''; this.cware.content.content=''; @@ -1030,6 +1040,7 @@ }); if(!pass){ this.$message.error("试卷试题请填写完整,每个试题必须要有答案"); + this.loading=false; return; } this.exam.info.paperContent=JSON.stringify(this.exam.paperJson); @@ -1139,11 +1150,11 @@ if(this.cware.content.contentType==40){ setTimeout(function(){ $this.loadPdfFile(); - },2000); + },1000); }else if(this.cware.content.contentType==50){ setTimeout(function(){ $this.loadScormFile(); - },2000); + },500); } }, getCoursewareList() { diff --git a/src/views/study/coursenew.vue b/src/views/study/coursenew.vue index 889b987f..ac123ce7 100644 --- a/src/views/study/coursenew.vue +++ b/src/views/study/coursenew.vue @@ -85,6 +85,9 @@
+
+ +