mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-14 05:16:43 +08:00
提交我的修改
This commit is contained in:
@@ -594,19 +594,23 @@ export default {
|
|||||||
}
|
}
|
||||||
if($this.coursewareInfo.content.contentType == 40) {
|
if($this.coursewareInfo.content.contentType == 40) {
|
||||||
//console.log(con.content,'con.content');
|
//console.log(con.content,'con.content');
|
||||||
if(con.content != '' && con.content.indexOf('.pdf') > -1) {
|
// if(con.content != '' && con.content.indexOf('.pdf') > -1) {
|
||||||
$this.coursewareInfo.content.content = con.content;
|
// $this.coursewareInfo.content.content = con.content;
|
||||||
}else {
|
// }else {
|
||||||
apiCourseFile.detail(con.contentRefId).then(cfrs => {
|
apiCourseFile.detail(con.contentRefId).then(cfrs => {
|
||||||
if (cfrs.status == 200) {
|
if (cfrs.status == 200) {
|
||||||
$this.curCFile=cfrs.result;
|
|
||||||
$this.converStatus = cfrs.result.converStatus;
|
|
||||||
$this.coursewareInfo.content.content = cfrs.result.previewFilePath;
|
$this.coursewareInfo.content.content = cfrs.result.previewFilePath;
|
||||||
|
if(cfrs.result.previewFilePath == '' && cfrs.result.filePath.indexOf('pdf') > -1) {
|
||||||
|
$this.coursewareInfo.content.content = cfrs.result.filePath;
|
||||||
|
} else {
|
||||||
|
$this.curCFile=cfrs.result;
|
||||||
|
$this.converStatus = cfrs.result.converStatus;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
$this.$message.error('加载pdf课件文件失败');
|
$this.$message.error('加载pdf课件文件失败');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
} else if (con.sortIndex == 2) {
|
} else if (con.sortIndex == 2) {
|
||||||
$this.homeworkInfo = con;
|
$this.homeworkInfo = con;
|
||||||
|
|||||||
@@ -650,21 +650,25 @@ export default {
|
|||||||
}
|
}
|
||||||
} else if(r.contentType == 40) {
|
} else if(r.contentType == 40) {
|
||||||
this.contentData.content="";
|
this.contentData.content="";
|
||||||
if (r.content != '' && r.content.indexOf('.pdf') > -1) {
|
// if (r.content != '' && r.content.indexOf('.pdf') > -1) {
|
||||||
this.contentData.content = cfrs.result.previewFilePath;
|
// // this.contentData.content = cfrs.result.previewFilePath;
|
||||||
}else{
|
// }else{
|
||||||
apiCourseFile.detail(r.contentRefId).then(cfrs => {
|
apiCourseFile.detail(r.contentRefId).then(cfrs => {
|
||||||
if (cfrs.status == 200) {
|
if (cfrs.status == 200) {
|
||||||
this.curCFile=cfrs.result;
|
|
||||||
this.converStatus = cfrs.result.converStatus;
|
|
||||||
this.contentData.content = cfrs.result.previewFilePath;
|
this.contentData.content = cfrs.result.previewFilePath;
|
||||||
|
if(cfrs.result.previewFilePath == '' && cfrs.result.filePath.indexOf('pdf') > -1) {
|
||||||
|
this.contentData.content = cfrs.result.filePath;
|
||||||
|
} else {
|
||||||
|
this.converStatus = cfrs.result.converStatus;
|
||||||
|
this.curCFile=cfrs.result;
|
||||||
|
}
|
||||||
//console.log(r.content);
|
//console.log(r.content);
|
||||||
}else {
|
}else {
|
||||||
this.contentData.content="";
|
this.contentData.content="";
|
||||||
this.$message.error('加载pdf课件文件失败');
|
this.$message.error('加载pdf课件文件失败');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
this.type = 0;
|
this.type = 0;
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -738,12 +738,17 @@
|
|||||||
}else{
|
}else{
|
||||||
apiCourseFile.detail(this.cware.content.contentRefId).then(rs=>{
|
apiCourseFile.detail(this.cware.content.contentRefId).then(rs=>{
|
||||||
if(rs.status==200){
|
if(rs.status==200){
|
||||||
this.curCFile=rs.result;
|
|
||||||
this.converStatus = rs.result.converStatus;
|
|
||||||
this.courseFileShow = false;
|
this.courseFileShow = false;
|
||||||
this.cware.content.pdfPath=rs.result.previewFilePath;
|
this.cware.content.pdfPath=rs.result.previewFilePath;
|
||||||
this.cware.content.content=rs.result.previewFilePath;
|
this.cware.content.content=rs.result.previewFilePath;
|
||||||
|
if(rs.result.previewFilePath == '' && rs.result.filePath.indexOf('pdf') > -1) {
|
||||||
this.$forceUpdate();
|
this.$forceUpdate();
|
||||||
|
this.cware.content.pdfPath = rs.result.filePath;
|
||||||
|
} else {
|
||||||
|
this.curCFile=rs.result;
|
||||||
|
this.converStatus = rs.result.converStatus;
|
||||||
|
}
|
||||||
|
this.$forceUpdate();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -823,6 +828,9 @@
|
|||||||
this.cware.content.duration=row.duration;//时长
|
this.cware.content.duration=row.duration;//时长
|
||||||
this.cware.findShow=false;
|
this.cware.findShow=false;
|
||||||
if(this.cware.content.contentType==40){
|
if(this.cware.content.contentType==40){
|
||||||
|
if(row.filePath.indexOf('.pdf')==-1){
|
||||||
|
this.cware.content.content=row.previewFilePath;
|
||||||
|
}
|
||||||
this.loadPdfFile();
|
this.loadPdfFile();
|
||||||
}
|
}
|
||||||
this.saveContent(1);
|
this.saveContent(1);
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
<<<<<<< HEAD
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<portal-header current="course" :goSearch="1"></portal-header>
|
<portal-header current="course" :goSearch="1"></portal-header>
|
||||||
@@ -444,16 +445,20 @@ export default {
|
|||||||
|
|
||||||
} else if (con.contentType == 40) {
|
} else if (con.contentType == 40) {
|
||||||
//需要读取pdf的路径
|
//需要读取pdf的路径
|
||||||
if($this.coursewareInfo.content.content!='' && $this.coursewareInfo.content.content.indexOf('.pdf')==-1){
|
apiCourseFile.detail($this.coursewareInfo.content.contentRefId).then(cfrs=>{
|
||||||
apiCourseFile.detail($this.coursewareInfo.content.contentRefId).then(cfrs=>{
|
if(cfrs.status==200){
|
||||||
if(cfrs.status==200){
|
$this.curCFile = cfrs.result;
|
||||||
this.curCFile = cfrs.result;
|
if(cfrs.result.previewFilePath){
|
||||||
$this.coursewareInfo.content.content=cfrs.result.previewFilePath;
|
$this.coursewareInfo.content.content=cfrs.result.previewFilePath;
|
||||||
}else{
|
}else if(cfrs.result.filePath.indexOf('.pdf')>-1){
|
||||||
$this.$message.error('加载pdf课件文件失败');
|
$this.coursewareInfo.content.content=cfrs.result.filePath;
|
||||||
}
|
}
|
||||||
});
|
|
||||||
}
|
}else{
|
||||||
|
$this.$message.error('加载pdf课件文件失败');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
//let url = this.fileBaseUrl + r.content;
|
//let url = this.fileBaseUrl + r.content;
|
||||||
}else if(con.contentType ==52){
|
}else if(con.contentType ==52){
|
||||||
if(con.content.startsWith('\{')){
|
if(con.content.startsWith('\{')){
|
||||||
@@ -1671,17 +1676,5 @@ export default {
|
|||||||
padding-left: 36px;
|
padding-left: 36px;
|
||||||
padding-right: 36px;
|
padding-right: 36px;
|
||||||
}
|
}
|
||||||
/* ::v-deep .el-tab-pane-boxContent{
|
|
||||||
.el-tabs__nav{
|
|
||||||
.el-tabs{
|
|
||||||
.el-tabs__header{
|
|
||||||
.el-tabs__nav{
|
|
||||||
.is-active{
|
|
||||||
font-size: 25px!important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} */
|
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -263,7 +263,9 @@ export default {
|
|||||||
components: { courseImage, portalHeader, portalFooter, hyperLink, comments, homework, exam, interactBar, assess, pdfPreview, audioPlayer, videoPlayer },
|
components: { courseImage, portalHeader, portalFooter, hyperLink, comments, homework, exam, interactBar, assess, pdfPreview, audioPlayer, videoPlayer },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
curCFile:{},
|
curCFile:{
|
||||||
|
converStatus:4,
|
||||||
|
},
|
||||||
interactRuning:false,
|
interactRuning:false,
|
||||||
playerBoxShow:false,
|
playerBoxShow:false,
|
||||||
userAvatarText,
|
userAvatarText,
|
||||||
@@ -820,9 +822,10 @@ export default {
|
|||||||
apiCourseFile.detail(r.contentRefId).then(cfrs => {
|
apiCourseFile.detail(r.contentRefId).then(cfrs => {
|
||||||
if (cfrs.status == 200) {
|
if (cfrs.status == 200) {
|
||||||
r.content = cfrs.result.previewFilePath;
|
r.content = cfrs.result.previewFilePath;
|
||||||
this.curCFile = cfrs.result;
|
|
||||||
if(cfrs.result.previewFilePath == '' && cfrs.result.filePath.indexOf('pdf') > -1) {
|
if(cfrs.result.previewFilePath == '' && cfrs.result.filePath.indexOf('pdf') > -1) {
|
||||||
r.content = cfrs.result.filePath;
|
r.content = cfrs.result.filePath;
|
||||||
|
} else {
|
||||||
|
this.curCFile = cfrs.result;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this.$message.error('加载pdf课件文件失败');
|
$this.$message.error('加载pdf课件文件失败');
|
||||||
|
|||||||
Reference in New Issue
Block a user