mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-12 20:36:43 +08:00
Merge branch 'dev'
# Conflicts: # src/components/Course/auditCourse2.vue
This commit is contained in:
@@ -26,14 +26,10 @@
|
|||||||
<span>{{item.name}}{{(item.orgInfo)}}</span> -->
|
<span>{{item.name}}{{(item.orgInfo)}}</span> -->
|
||||||
<!-- <el-tag v-if="status === 0" type="success">已发布</el-tag>
|
<!-- <el-tag v-if="status === 0" type="success">已发布</el-tag>
|
||||||
<el-tag type="warning" v-else>未发布</el-tag> -->
|
<el-tag type="warning" v-else>未发布</el-tag> -->
|
||||||
<span class="problem">
|
<span class="article-time">
|
||||||
|
|
||||||
<span> 时间:{{item.sysCreateTime|sysCreateTimeFilter}}</span>
|
<span> 时间:{{item.sysCreateTime|sysCreateTimeFilter}}</span>
|
||||||
</span>
|
</span>
|
||||||
<span v-if="!item.enabled">
|
<span v-if="!item.enabled">已下架</span>
|
||||||
已下架
|
|
||||||
</span>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="article-info-tools-btns" v-if="item.status == 9">
|
<div class="article-info-tools-btns" v-if="item.status == 9">
|
||||||
<!-- <interactBar :data="item" :type="2" :shares="false" :views="false"></interactBar> -->
|
<!-- <interactBar :data="item" :type="2" :shares="false" :views="false"></interactBar> -->
|
||||||
@@ -312,8 +308,9 @@ width: 100%;
|
|||||||
color: #7b7b7b;
|
color: #7b7b7b;
|
||||||
margin-left:5px;
|
margin-left:5px;
|
||||||
}
|
}
|
||||||
.problem{
|
.article-time{
|
||||||
margin-left: -5px;
|
margin-left: -5px;
|
||||||
|
border:0px;
|
||||||
span{
|
span{
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -162,11 +162,11 @@
|
|||||||
</audio> -->
|
</audio> -->
|
||||||
</div>
|
</div>
|
||||||
<div v-if="coursewareInfo.content.contentType == 40">
|
<div v-if="coursewareInfo.content.contentType == 40">
|
||||||
<div style="padding: 10px;color: #767676;text-align: center;line-height: 40px; " v-if="converStatus < 2">
|
<div style="padding: 10px;color: #767676;text-align: center;line-height: 40px; " v-if="converStatus < 2 && !coursewareInfo.content.content">
|
||||||
<div>文档文件转化中,还未转化完成,</div>
|
<div>文档文件转化中,还未转化完成,</div>
|
||||||
<div >上传时间:{{curCFile.sysCreateTime}}</div>
|
<div >上传时间:{{curCFile.sysCreateTime}}</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="padding: 10px;color: #767676;color: #ff0000;text-align: center;" v-if="converStatus == 3">
|
<div style="padding: 10px;color: #767676;color: #ff0000;text-align: center;" v-if="converStatus == 3 && !coursewareInfo.content.content">
|
||||||
文件转化失败,请重新上传(不要上传加密的文件)或联系管理员
|
文件转化失败,请重新上传(不要上传加密的文件)或联系管理员
|
||||||
</div>
|
</div>
|
||||||
<pdfPreview :filePath="fileBaseUrl+coursewareInfo.content.content"></pdfPreview>
|
<pdfPreview :filePath="fileBaseUrl+coursewareInfo.content.content"></pdfPreview>
|
||||||
@@ -593,24 +593,25 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if($this.coursewareInfo.content.contentType == 40) {
|
if($this.coursewareInfo.content.contentType == 40) {
|
||||||
//console.log(con.content,'con.content');
|
|
||||||
// if(con.content != '' && con.content.indexOf('.pdf') > -1) {
|
|
||||||
// $this.coursewareInfo.content.content = con.content;
|
|
||||||
// }else {
|
|
||||||
apiCourseFile.detail(con.contentRefId).then(cfrs => {
|
apiCourseFile.detail(con.contentRefId).then(cfrs => {
|
||||||
if (cfrs.status == 200) {
|
if (cfrs.status == 200) {
|
||||||
$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.curCFile=cfrs.result;
|
||||||
$this.converStatus = cfrs.result.converStatus;
|
$this.converStatus = cfrs.result.converStatus;
|
||||||
|
//以下是为了兼容老数据
|
||||||
|
if(cfrs.result.previewFilePath == '' && cfrs.result.filePath.indexOf('.pdf') > -1) {
|
||||||
|
$this.coursewareInfo.content.content = cfrs.result.filePath;
|
||||||
|
}
|
||||||
|
//设置状态值
|
||||||
|
if($this.coursewareInfo.content.content && $this.coursewareInfo.content.content.indexOf('.pdf') > -1){
|
||||||
|
if(!cfrs.result.converStatus || cfrs.result.converStatus<2){
|
||||||
|
$this.converStatus=2;//转化完成
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} 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;
|
||||||
|
|||||||
@@ -175,11 +175,11 @@
|
|||||||
</audio> -->
|
</audio> -->
|
||||||
</div>
|
</div>
|
||||||
<div v-if="contentData.contentType == 40">
|
<div v-if="contentData.contentType == 40">
|
||||||
<div style="padding: 10px;color: #767676; " v-if="converStatus < 2">
|
<div style="padding: 10px;color: #767676; " v-if="converStatus < 2 && !contentData.content">
|
||||||
<div>文档文件转化中,还未转化完成,</div>
|
<div>文档文件转化中,还未转化完成,</div>
|
||||||
<div>上传时间:{{curCFile.sysCreateTime}}</div>
|
<div>上传时间:{{curCFile.sysCreateTime}}</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="padding: 10px;color: #767676;color: #ff0000;" v-if="converStatus == 3">
|
<div style="padding: 10px;color: #767676;color: #ff0000;" v-if="converStatus == 3 && !contentData.content">
|
||||||
文件转化失败,请重新上传(不要上传加密的文件)或联系管理员
|
文件转化失败,请重新上传(不要上传加密的文件)或联系管理员
|
||||||
</div>
|
</div>
|
||||||
<pdfPreview v-if="contentData.content" :filePath="fileBaseUrl+contentData.content"></pdfPreview>
|
<pdfPreview v-if="contentData.content" :filePath="fileBaseUrl+contentData.content"></pdfPreview>
|
||||||
@@ -654,11 +654,16 @@ export default {
|
|||||||
if (cfrs.status == 200) {
|
if (cfrs.status == 200) {
|
||||||
this.curCFile=cfrs.result;
|
this.curCFile=cfrs.result;
|
||||||
this.contentData.content = cfrs.result.previewFilePath;
|
this.contentData.content = cfrs.result.previewFilePath;
|
||||||
|
this.converStatus = cfrs.result.converStatus;
|
||||||
//下面是为了兼容老数据
|
//下面是为了兼容老数据
|
||||||
if(cfrs.result.previewFilePath == '' && cfrs.result.filePath.indexOf('pdf') > -1) {
|
if(cfrs.result.previewFilePath == '' && cfrs.result.filePath.indexOf('pdf') > -1) {
|
||||||
this.contentData.content = cfrs.result.filePath;
|
this.contentData.content = cfrs.result.filePath;
|
||||||
} else {
|
}
|
||||||
this.converStatus = cfrs.result.converStatus;
|
//设置状态
|
||||||
|
if(this.contentData.content && this.contentData.content.indexOf('pdf') > -1){
|
||||||
|
if(!this.converStatus || this.converStatus<2){
|
||||||
|
this.converStatus=2;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
//console.log(r.content);
|
//console.log(r.content);
|
||||||
}else {
|
}else {
|
||||||
|
|||||||
@@ -368,37 +368,21 @@ export default {
|
|||||||
device:1,
|
device:1,
|
||||||
orderField: orderType == 1 ? '' : 'studys',
|
orderField: orderType == 1 ? '' : 'studys',
|
||||||
orderAsc: false,
|
orderAsc: false,
|
||||||
// topOrder:true,
|
topOrder:true,
|
||||||
pageIndex: pageIndex
|
pageIndex: pageIndex
|
||||||
};
|
};
|
||||||
let isTopList = [];
|
|
||||||
let data = [];
|
|
||||||
this.courseList.list = [];
|
|
||||||
apiCoursePortal.pageList(course).then(res => {
|
apiCoursePortal.pageList(course).then(res => {
|
||||||
|
|
||||||
if (res.status == 200 && res.result.list.length > 0) {
|
if (res.status == 200 && res.result.list.length > 0) {
|
||||||
|
|
||||||
let courseIds = [];
|
let courseIds = [];
|
||||||
res.result.list.forEach(item => {
|
res.result.list.forEach(item => {
|
||||||
item.authorInfo = { aid: '', name: '', orgInfo: '', avatar: '', code: '' ,sex:null};
|
item.authorInfo = { aid: '', name: '', orgInfo: '', avatar: '', code: '' ,sex:null};
|
||||||
courseIds.push(item.id);
|
courseIds.push(item.id);
|
||||||
console.log(item.isTop)
|
|
||||||
if(item.isTop) {
|
|
||||||
isTopList.push(item);
|
|
||||||
console.log(isTopList)
|
|
||||||
|
|
||||||
}else{
|
|
||||||
data.push(item);
|
|
||||||
// console.log(data)
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
this.loadCouserTeacher(res.result.list, courseIds);
|
this.loadCouserTeacher(res.result.list, courseIds);
|
||||||
this.courseList.list.push(...isTopList,...data);
|
this.courseList.list=res.result.list;
|
||||||
this.couname = res.result.list.name;
|
this.couname = res.result.list.name;
|
||||||
|
if(res.result.count - pageIndex * num < 8) {
|
||||||
|
|
||||||
|
|
||||||
if (res.result.count - pageIndex * num < 8) {
|
|
||||||
this.pageIndex = 0;
|
this.pageIndex = 0;
|
||||||
}
|
}
|
||||||
this.isNext = true;
|
this.isNext = true;
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
<<<<<<< HEAD
|
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<portal-header current="course" :goSearch="1"></portal-header>
|
<portal-header current="course" :goSearch="1"></portal-header>
|
||||||
@@ -78,10 +77,10 @@
|
|||||||
<img :src="fileBaseUrl+coursewareInfo.content.content" alt="图片">
|
<img :src="fileBaseUrl+coursewareInfo.content.content" alt="图片">
|
||||||
</div>
|
</div>
|
||||||
<div v-if="coursewareInfo.content.contentType == 40">
|
<div v-if="coursewareInfo.content.contentType == 40">
|
||||||
<div style="padding: 10px;color: #ed0000; " v-if="curCFile.converStatus < 2">
|
<div style="padding: 10px;color: #ed0000; " v-if="curCFile.converStatus < 2 && !coursewareInfo.content.content">
|
||||||
<div>此课程内容无法预览,请联系管理员</div>
|
<div>此课程内容无法预览,请联系管理员</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="padding: 10px;color: #ed0000; " v-if="curCFile.converStatus == 3">
|
<div style="padding: 10px;color: #ed0000; " v-if="curCFile.converStatus == 3 && !coursewareInfo.content.content">
|
||||||
此课程内容无法预览,请联系管理员
|
此课程内容无法预览,请联系管理员
|
||||||
</div>
|
</div>
|
||||||
<pdfPreview :autoScroll="true" v-if="coursewareInfo.content.contentType == 40" :filePath="fileBaseUrl+coursewareInfo.content.content"></pdfPreview>
|
<pdfPreview :autoScroll="true" v-if="coursewareInfo.content.contentType == 40" :filePath="fileBaseUrl+coursewareInfo.content.content"></pdfPreview>
|
||||||
@@ -450,8 +449,10 @@ export default {
|
|||||||
$this.curCFile = cfrs.result;
|
$this.curCFile = cfrs.result;
|
||||||
if(cfrs.result.previewFilePath){
|
if(cfrs.result.previewFilePath){
|
||||||
$this.coursewareInfo.content.content=cfrs.result.previewFilePath;
|
$this.coursewareInfo.content.content=cfrs.result.previewFilePath;
|
||||||
|
$this.curCFile=2;
|
||||||
}else if(cfrs.result.filePath.indexOf('.pdf')>-1){
|
}else if(cfrs.result.filePath.indexOf('.pdf')>-1){
|
||||||
$this.coursewareInfo.content.content=cfrs.result.filePath;
|
$this.coursewareInfo.content.content=cfrs.result.filePath;
|
||||||
|
$this.curCFile=2;
|
||||||
}
|
}
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
|
|||||||
@@ -83,10 +83,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="resType == 40">
|
<div v-if="resType == 40">
|
||||||
<div style="padding: 10px;color: #ed0000; " v-if="curCFile.converStatus < 2">
|
<div style="padding: 10px;color: #ed0000; " v-if="curCFile.converStatus < 2 && !contentData.content">
|
||||||
<div>此课程内容无法预览,请联系管理员</div>
|
<div>此课程内容无法预览,请联系管理员</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="padding: 10px;color: #ed0000;" v-if="curCFile.converStatus == 3">
|
<div style="padding: 10px;color: #ed0000;" v-if="curCFile.converStatus == 3 && !contentData.content">
|
||||||
此课程内容无法预览,请联系管理员
|
此课程内容无法预览,请联系管理员
|
||||||
</div>
|
</div>
|
||||||
<pdfPreview :autoScroll="true" v-if="resType == 40" :filePath="fileBaseUrl + contentData.content"></pdfPreview>
|
<pdfPreview :autoScroll="true" v-if="resType == 40" :filePath="fileBaseUrl + contentData.content"></pdfPreview>
|
||||||
@@ -822,10 +822,13 @@ 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.converStatus=2;
|
||||||
this.curCFile = cfrs.result;
|
}
|
||||||
|
if(r.content && r.content.indexOf('.pdf')>-1){
|
||||||
|
this.curCFile.converStatus=2;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this.$message.error('加载pdf课件文件失败');
|
$this.$message.error('加载pdf课件文件失败');
|
||||||
|
|||||||
Reference in New Issue
Block a user