Merge remote-tracking branch 'boe/dev0731' into dev0731

This commit is contained in:
yujicun
2023-08-04 15:49:21 +08:00
23 changed files with 3561 additions and 2155 deletions

BIN
public/images/courseBg.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 67 KiB

View File

@@ -22,6 +22,9 @@ const indexList = function(query) {
const queryList = function (query) {
return ajax.post('/xboe/m/boe/cases/queryList', query);
}
const queryListV2 = function (query) {
return ajax.postJson('/xboe/m/boe/cases/queryListV2', query);
}
/* 案例分页搜索查询 是否置顶
*@param(String) keyWord 关键词
@param(Boolean) isTop 是否置顶 true或false
@@ -99,6 +102,7 @@ const queryComments=function(pageSize){
const majorTypes = function () {
return ajax.get('/xboe/m/boe/cases/majorTypes');
}
/**
* 详情新*/
const details = function (id, addView) {
@@ -153,9 +157,36 @@ const exportCases=function (query){
return ajax.post('/xboe/m/boe/cases/export', query);
}
/**
* 导出案例后加的
* */
const exports = function (query) {
return ajax.post('/xboe/m/boe/cases/exportCase', query, { responseType: 'blob' });
}
/**
* @param
* 记录查看开始时间
* caseRecommendId读取的案例的id
*/
const startReadTimer = (caseRecommendId) => ajax.get(`/xboe/m/boe/cases/recommend/startRead?caseRecommendId=${caseRecommendId}`);
/**
* @param
* 记录查看结束时间
* data{
* caseId [案例id]
* browseDuration [浏览时间秒]
* }
*/
const endReadTimer = (data)=> ajax.postJson('/xboe/m/boe/cases/recommend/recordBrowseDuration',data)
export default {
indexList,
queryList,
queryListV2,
isTopList,
updateTop,
del,
@@ -170,5 +201,8 @@ export default {
ids,
excellent,
mylist,
exportCases
exportCases,
exports,
startReadTimer,
endReadTimer
}

View File

@@ -40,8 +40,8 @@ const pageList = function(query) {
* 课程的详细信息
* @param {String} id
*/
const detail = function(id,preview) {
return ajax.get(`/xboe/m/course/portal/detail?id=${id}&preview=${preview}`);
const detail = function(id,preview,course=false) {
return ajax.get(`/xboe/m/course/portal/detail?id=${id}&preview=${preview}&course=${course}`);
}
/**

View File

@@ -2,6 +2,7 @@
* 分类
*/
import ajax from '@/utils/xajax.js'
import request from '../unionAjax.js';
/**
* 提取全量树形结构数据
@@ -11,6 +12,16 @@ import ajax from '@/utils/xajax.js'
const tree = function(sysResType) {
return ajax.get(`/xboe/type/tree-list?sysResType=${sysResType}&status=1`);
}
/**
*
* @param {*} sysResType [1]
* @param {*} pid [字典类别码]
* @param {*} current [1当前页码]
* @returns
*/
const treeList = function(sysResType,pid,current) {
return request.get('/infrasApi',`/dict/page?type=${sysResType}&pid=${pid}&current=${current}`);
}
/**
* 按父ID查询列表
@@ -24,5 +35,6 @@ const list = function(sysResType, parentId) {
export default {
tree,
list
list,
treeList
}

View File

@@ -8,6 +8,12 @@ import ajax from '@/utils/xajax.js'
const cases=function (type){
return ajax.get('/xboe/portal/index/cases?type='+type);
}
/**
* 首页新改的推荐案例
* */
const newCases=function (){
return ajax.get('/xboe/portal/index/casesV2');
}
/**
* 首页文章排行榜
@@ -45,5 +51,6 @@ export default {
articleViews,
qaAnswers,
articlelist,
courselist
courselist,
newCases
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 487 B

View File

@@ -341,6 +341,54 @@ body {margin: 0px;padding: 0px;}
width: 400px;
}
//课程三级弹窗popperClass的样式
.coursePopperClass{
padding: 0;
margin-left: 0 !important;
box-shadow: 1px 1px 35px 1px rgba(118,136,166,0.21);
border-radius: 4px;
.course-three-box{
min-height: 268px;
.course-three-box-title{
font-size: 16px;
font-weight: 600;
height: 68px;
line-height: 80px;
background: linear-gradient(180deg, rgba(78,166,255,0.2) 0%,
rgba(78,166,255,0) 100%);padding-left: 40px;
}
.course-three{
border-radius: 6px;
border: 1px solid #C7CBD2;display: inline-block;
height: 40px;
line-height: 40px;
padding: 0 20px;
margin-right: 20px;
cursor: pointer;
&:hover{
color: #387DF7;
border: 1px solid #387DF7 !important;
}
}
.threeActive{
color: #387DF7;
border: 1px solid #387DF7 !important;
}
}
}
// 标题提示
.keywordInfo-class{
background-color: #F2F5F7 !important;
min-width: 54px;
padding: 0 10px;
line-height: 26px;
text-align: center;
border: 1px solid #387DF7;
color: #387DF7 !important;
}
//以下是多分辨率的控制,注意,只是一些样式的高度,宽度,大小控制,非大小控制不要在这里写
@media screen and (max-width: 1366px){
@@ -389,6 +437,13 @@ body {margin: 0px;padding: 0px;}
width:218;
height: 122px;
}
.course-img-box{
height: 122px;
}
.keywordInfo{
width: 40px !important;
margin-right: 2px;
}
}
.course-tit{
float: none !important;
@@ -401,6 +456,13 @@ body {margin: 0px;padding: 0px;}
height: 45px !important;
}
// 课程导航
.nav{
width: 478px;
}
.upload{
width: 300px;
}
}
@media screen and (max-width: 1680px) and (min-width:1367px){
@@ -429,6 +491,20 @@ body {margin: 0px;padding: 0px;}
width: 278px;
height: 156px;
}
.course-img-box{
height: 156px;
}
.keywordInfo{
width: 45px !important;
margin-right: 13px;
}
}
// 课程导航
.nav{
width: 654px;
}
.upload{
width: 350px;
}
}
@@ -458,6 +534,19 @@ body {margin: 0px;padding: 0px;}
width: 346px;
height: 192px;
}
.course-img-box{
height: 191px;
}
.keywordInfo{
margin-right: 20px;
}
}
// 课程导航
.nav{
width: 828px;
}
.upload{
width: 400px;
}
}
@@ -488,6 +577,19 @@ body {margin: 0px;padding: 0px;}
width: 340px;
height: 191px;
}
.course-img-box{
height: 191px;
}
.keywordInfo{
margin-right: 33px;
}
}
// 课程导航
.nav{
width: 974px;
}
.upload{
width: 410px;
}
}

View File

@@ -133,7 +133,9 @@
</el-select>
</el-form-item> -->
<el-form-item v-if="!weike.onlyRequired" label="关键字">
<el-input v-model="courseInfo.keywords" maxlength="100" show-word-limit placeholder="请输入关键字(限100字以内)"></el-input>
<!-- <el-input v-model="courseInfo.keywords" maxlength="100" show-word-limit placeholder="请输入关键字(限100字以内)"></el-input> -->
<el-input v-model.trim="keywords" maxlength="100" @keyup.enter.native="changeKeywords" placeholder="请输入关键字"></el-input>
<el-tag v-for="(tag,index) in tips" size="small" :key="index" closable type="info" @close="closeKeywordsTag(tag,index)">{{ tag }}</el-tag>
</el-form-item>
<el-form-item v-if="!weike.onlyRequired" label="观看设置">
<el-radio style="margin-right: 10px;" v-model="courseInfo.device" :label="1">PC端可见</el-radio>
@@ -251,6 +253,12 @@
</el-select> -->
<choice :teacherValue="teacherValues" @getTeacherList="getTeacherList"></choice>
</el-form-item>
<el-form-item label="关键字">
<el-input v-model.trim="keywords" maxlength="100" @keyup.enter.native="changeKeywords" placeholder="请输入关键字"></el-input>
<el-tag v-for="(tag,index) in tips" size="small" :key="index" closable type="info" @close="closeKeywordsTag(tag,index)">
{{ tag }}
</el-tag>
</el-form-item>
</el-col>
</el-form-item>
<el-form-item label="资源归属" required>
@@ -421,6 +429,8 @@ export default {
components: { weikeContent, catalogCourseware, imageUpload, WxEditor, catalogSort,agreement,filecloud,choice,chooseOrg},
data() {
return {
keywords:'',//关键字的定义
tips:[],
addOrder:1,
checked:false,
courseInfoFormCheckedShow:false,
@@ -571,6 +581,17 @@ export default {
this.loadUserGroup();
},
methods: {
// 关键字的更改
changeKeywords(option){
if(option.target.value){
this.tips.push(option.target.value)
}
this.keywords = ''
},
//关闭关键字
closeKeywordsTag(item,index){
this.tips.splice(index, 1);
},
showChooseOrg(){
this.$refs.refChooseOrg.dlgShow = true;
},
@@ -744,6 +765,8 @@ export default {
this.teacherValues = [];
this.courseCrowds=[];
this.courseCoverurl = '';
// 关键字的清空
this.tips=[];
if (!editData) {
//console.log("新建课程?");
@@ -862,6 +885,7 @@ export default {
this.courseCoverurl = '';
this.courseInfo.coverImg = '';
},
//获取课程信息
async getDetail(id) {
this.curCourseId = id;
this.orgName='';
@@ -873,6 +897,10 @@ export default {
if(result.course.visible==''){
result.course.visible=true;
}
// 给关键字赋值
if(result.course.keywords){
this.tips = result.course.keywords.split(',') || []
}
this.courseInfo = result.course;
this.checked = false;
this.contentInfo.list = result.contents;
@@ -1156,6 +1184,7 @@ export default {
if (this.showTags.length > 0) {
this.courseInfo.tags = this.showTags.join();
}
this.courseInfo.keywords = this.tips.join(',') || ''
//检查输入是否合法
//if(!this.requireSaveCourse){
// this.curStepIndex=2;//转到第二步处理

View File

@@ -76,10 +76,11 @@
if(!data.id){
return;
}
if(item.info.deleted){
if(data.deleted){
this.$message.warning("此问题已删除");
return;
}
this.$router.push({ path: '/qa/answer', query: { id: data.id } });
},

View File

@@ -16,6 +16,7 @@
<span style="color: #333333;font-weight: 600;font-size: 16px;">{{userName}}</span>
<span class="author-text" v-if="userInfo && userInfo!=''"> {{userInfo}} </span>
</div>
<slot />
</div>
</template>
<script>

View File

@@ -35,7 +35,7 @@
<span class="interact-bar-value"> {{ data.praises? data.praises:0}}</span>
</div>
<div v-if="favorites" @click="addFavorite()" :style="`min-width: ${nodeWidth};`" class="interact-bar-btn" :class="{cursor:!readonly}">
<div v-if="favorites" @click.stop="addFavorite()" :style="`min-width: ${nodeWidth};`" class="interact-bar-btn" :class="{cursor:!readonly}">
<el-tooltip effect="light" content="收藏" placement="top" :visible-arrow="false" popper-class="text-tooltip">
<svg-icon v-if="courseExclusive" style="font-size: 32px;margin-right: 0;" :icon-class="isFavorite?'collectedCourse':'collectionCourse'"></svg-icon>
<svg-icon v-else style="margin-right: 0;" :style="{'font-size':(size+2)+'px'}" :icon-class="isFavorite?'scactive2':'xihuan'"></svg-icon>

View File

@@ -76,9 +76,11 @@
<div class="person-action-item">
<el-badge class="person-action-index" :value="userMsg" :hidden="userMsg == 0">
<el-tooltip content="消息" placement="bottom" effect="light" :visible-arrow="false" popper-class="text-tooltip">
<el-link type="primary" :href="`${webBaseUrl}/message/center/index`" :underline="false">
<!-- <el-link type="primary" :href="`${webBaseUrl}/message/center/index`" :underline="false"> -->
<router-link to="/message/center/index">
<svg-icon :style="{color:textColor}" style="margin-right: 0;font-size:22px;" icon-class="messfff"></svg-icon>
</el-link>
</router-link>
<!-- </el-link> -->
</el-tooltip>
</el-badge>
</div>
@@ -216,21 +218,17 @@ export default {
// });
},
handleCommand(val) {
if (val === "four") {
this.$emit('showClass',true)
} else {
let urlPre = window.location.protocol + "//" + window.location.host;
let urlPre=window.location.protocol+'//'+window.location.host;
// process.env.VUE_APP_BOE_WEB_URL
let obj = {
one: urlPre + "/web/teacherLesson",
two: urlPre + "/grow180/login",
three: this.webBaseUrl + "/study/index?study=1",
// four: 'https://m.qingxuetang.com/x/?appId=qxtcorp306130',
five: urlPre + "/boe/new-employee/index.html",
six: urlPre + "/web/contributor/index",
one: urlPre+'/web/teacherLesson',
two: urlPre+'/grow180/login',
three: this.webBaseUrl + '/study/index?study=1',
four: 'https://m.qingxuetang.com/x/?appId=qxtcorp306130',
five: urlPre+'/boe/new-employee/index.html',
six: urlPre+'/web/contributor/index'
};
window.open(obj[val]);
}
},
handleUcCommand(val) {
if (val == 'uc') {
@@ -274,7 +272,8 @@ export default {
} else if (this.goSearch == 2) {
if(this.keyword==''){return;}
// 案例
location.href=`${this.webBaseUrl}/case?keyword=${this.keyword}`;
// location.href=`${this.webBaseUrl}/case?keyword=${this.keyword}`;
this.$router.push(`/case?keyword=${this.keyword}`)
//window.open(`${this.webBaseUrl}/case?keyword=${this.keyword}`);
} else if (this.goSearch == 3) {
if(this.keyword==''){return;}

View File

@@ -38,11 +38,11 @@
:biBarrageXml="biBarrageXml"
/>
<!-- 加载动画 -->
<div v-show="isShowLoading" class="player-loading" @click="videoDom.focus({preventScroll: true})">
<div v-show="isShowLoading && isCrowd" class="player-loading" @click="videoDom.focus({preventScroll: true})">
<img src="@/components/VideoPlayer/images/loading.svg" alt="loading"/>
</div>
<!-- 控制栏 -->
<div v-show="!isShowLoading" class="player-controls-container" @click="videoDom.focus({preventScroll: true})">
<div v-show="!isShowLoading && isCrowd" class="player-controls-container" @click="videoDom.focus({preventScroll: true})">
<div v-show="isShowVolumeHint" class="player-volumeHint">
<span class="player-volumeHint-text">当前音量:{{volumePercent}}%</span>
</div>
@@ -264,6 +264,10 @@ export default {
isDrag:{
type: Boolean,
default: null,
},
isCrowd:{
type: Boolean,
default: true,
}
},
data() {

View File

@@ -324,7 +324,7 @@
<div class="xcontent2-main xindex-main">
<div class="modules-title">
<span class="modules-text">推荐案例</span>
<span class="quyer-tag">
<!-- <span class="quyer-tag">
<a
:class="caseList.orderType == 2 ? 'current' : ''"
@click="changeCaseOrder(2)"
@@ -335,7 +335,7 @@
@click="changeCaseOrder(1)"
>最新</a
>
</span>
</span> -->
<span class="more">
<router-link to="/case">查看更多>></router-link>
</span>
@@ -1337,12 +1337,15 @@ export default {
// }
// })
},
changeCaseOrder(val) {
this.caseList.orderType = val;
this.getCaseData();
},
// 去掉案例的推荐课程
// changeCaseOrder(val) {
// this.caseList.orderType = val;
// this.getCaseData();
// },
//案例的参数等着需要改
getCaseData() {
apiIndex.cases(this.caseList.orderType).then((res) => {
apiIndex.newCases().then((res) => {
if (res.status == 200) {
if (res.result.length > 0) {
let userIds = [];

View File

@@ -9,18 +9,27 @@
<div style="display: flex;justify-content:flex-start;">
<!-- <div style="padding: 0px 5px;"><el-cascader placeholder="资源归属" clearable v-model="params.type" :options="typeList"></el-cascader></div> -->
<div style="padding: 0px 5px;">
<el-select v-model="queryObj.isTop" style="width: 110px;" clearable placeholder="置顶">
<el-select v-model="queryObj.isTop" style="width: 110px;" clearable placeholder="全部">
<el-option label="已置顶" :value="true"></el-option>
<el-option label="未置顶" :value="false"></el-option>
</el-select>
</div>
<div style="padding: 0px 5px;"><el-input placeholder="关键词搜索" v-model="queryObj.keyWord" @input="inputOn($event)" clearable></el-input></div>
<div style="padding: 0px 5px;">
<el-select v-model="queryObj.excellent" style="width: 120px;" clearable placeholder="全部">
<el-option label="最佳案例" :value="true"></el-option>
<el-option label="非最佳案例" :value="false"></el-option>
</el-select>
</div>
<div style="padding: 0px 5px;"><el-input placeholder="关键词搜索" v-model="queryObj.keyWord" @input="inputOn($event)"
clearable></el-input></div>
<div style="padding: 0px 5px;flex: 1;display: flex;align-items: center;">
<el-button @click="getData(1)" icon="el-icon-search" type="primary">搜索</el-button>
<!-- <el-button @click="showRecords()" icon="el-icon-tickets" type="info" >推荐记录</el-button> -->
<el-button icon="el-icon-refresh-right" type="primary" @click="reset">重置</el-button>
<el-checkbox style="margin-left:10px" v-model="queryObj.excellent" @change="getData()">优秀案例</el-checkbox>
<!-- <el-checkbox style="margin-left:10px" v-model="queryObj.excellent" @change="getData()">优秀案例</el-checkbox> -->
<div style="flex: 1; display: flex; justify-content: flex-end;align-items:baseline;">
<el-button type="primary" icon="el-icon-document" @click="importList">导出</el-button>
</div>
</div>
</div>
</div>
@@ -34,31 +43,29 @@
</el-table-column> -->
<el-table-column label="作者" width="80px" prop="authorName"></el-table-column>
<el-table-column label="密级" width="80px" prop="confidentialityLevel"></el-table-column>
<el-table-column label="浏览次数" width="80px" prop="views"></el-table-column>
<el-table-column label="导入时间" prop="sysCreateTime"></el-table-column>
<el-table-column label="设置优秀时间" prop="excellentTime"></el-table-column>
<el-table-column label="操作">
<template slot-scope="scope">
<el-button-group>
<!-- <el-button type="text" @click="shareItem(scope.row)" icon="el-icon-share" style="margin:0 5px">推荐</el-button> -->
<el-button style="margin:0 5px" v-if="!scope.row.isTop && scope.row.confidentialityLevel=='内部'" type="text" @click="setTop(scope.row)" icon="el-icon-top">置顶</el-button>
<el-button style="margin:0 5px" v-if="scope.row.isTop && scope.row.confidentialityLevel=='内部'" type="text" @click="setTop(scope.row)" icon="el-icon-bottom">取消置顶</el-button>
<el-button type="text" icon="el-icon-medal" v-if="scope.row.filePath && scope.row.confidentialityLevel=='内部'" ><span @click="cancal(scope.row)" v-if="scope.row.excellent">取消优秀</span><span @click="open(scope.row)" v-else>设为优秀</span></el-button>
<el-button style="margin:0 5px" v-if="!scope.row.isTop && scope.row.confidentialityLevel == '内部'" type="text"
@click="setTop(scope.row)" icon="el-icon-top">置顶</el-button>
<el-button style="margin:0 5px" v-if="scope.row.isTop && scope.row.confidentialityLevel == '内部'" type="text"
@click="setTop(scope.row)" icon="el-icon-bottom">取消置顶</el-button>
<el-button type="text" icon="el-icon-medal"
v-if="scope.row.filePath && scope.row.confidentialityLevel == '内部'"><span @click="cancal(scope.row)"
v-if="scope.row.excellent">取消最佳</span><span @click="open(scope.row)" v-else>最佳案例</span></el-button>
<el-button style="margin:0 5px" type="text" @click="delItem(scope.row)" icon="el-icon-delete">删除</el-button>
</el-button-group>
</template>
</el-table-column>
</el-table>
<div style="text-align: center;margin-top: 50px;">
<el-pagination
background
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page="queryObj.pageIndex"
:page-sizes="[10, 20, 30, 40]"
:page-size="queryObj.pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="count"
></el-pagination>
<el-pagination background @size-change="handleSizeChange" @current-change="handleCurrentChange"
:current-page="queryObj.pageIndex" :page-sizes="[10, 20, 30, 40]" :page-size="queryObj.pageSize"
layout="total, sizes, prev, pager, next, jumper" :total="count"></el-pagination>
</div>
<div style="height: 100px;"></div>
@@ -73,13 +80,15 @@
</el-form-item>
<el-form-item>
<el-checkbox-group v-model="shareUsers">
<el-checkbox v-for="(u,uidx) in shareInfo.list" :key="uidx" :label="u.aid">{{u.name+'('+u.orgInfo+')'}}</el-checkbox>
<el-checkbox v-for="(u, uidx) in shareInfo.list" :key="uidx" :label="u.aid">{{ u.name + '(' + u.orgInfo +
')' }}</el-checkbox>
</el-checkbox-group>
</el-form-item>
<!-- <div style="padding: 0 20px 20px 20px;">
</div> -->
<el-form-item label="推荐说明"><el-input type="textarea" :rows="3" v-model="shareItemData.recommentThat" placeholder="备注说明"></el-input></el-form-item>
<el-form-item label="推荐说明"><el-input type="textarea" :rows="3" v-model="shareItemData.recommentThat"
placeholder="备注说明"></el-input></el-form-item>
</el-form>
</div>
<span slot="footer" class="dialog-footer">
@@ -87,7 +96,8 @@
<el-button @click="submitWork" type="primary">提交推荐任务</el-button>
</span>
</el-dialog>
<el-dialog title="推荐记录" :visible.sync="recommend.dlgShow" :close-on-click-modal="false" width="900px" custom-class="g-dialog">
<el-dialog title="推荐记录" :visible.sync="recommend.dlgShow" :close-on-click-modal="false" width="900px"
custom-class="g-dialog">
<div>
<el-table stripe style="width: 100%" :data="recommend.records">
<el-table-column prop="caseName" label="案例名称"></el-table-column>
@@ -163,12 +173,27 @@ export default {
this.getData();
},
methods: {
// 导出
importList() {
apiCase.exports(this.queryObj).then(res => {
const link = document.createElement('a');// 创建a标签
let blob = new Blob([res], { type: 'application/vnd.ms-excel;charset=UTF-8' }); // 设置文件类型
link.style.display = "none";
link.href = URL.createObjectURL(blob); // 创建URL
console.log(link.href);
link.setAttribute("download", "案例.xls");
document.body.appendChild(link);
link.click();
URL.revokeObjectURL(link.href)
document.body.removeChild(link);
})
},
// getSearch(){
// this.queryObj.excellent = !this.queryObj.excellent;
// this.getData();
// },
cancal(item) {
this.$confirm('是否取消该案例为优秀案例?', '提示', {
this.$confirm('确定要取消设置为最佳案例?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
@@ -196,7 +221,7 @@ export default {
});
},
open(item) {
this.$confirm('是否设置此案例为优秀案例吗?', '提示', {
this.$confirm('你确认要设置为最佳案例吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
@@ -211,7 +236,7 @@ export default {
if (res.status == 200) {
this.$message({
type: 'success',
message: '设置优秀案例成功!'
message: '设置最佳案例成功!'
});
this.getData()
}
@@ -238,9 +263,9 @@ export default {
if (num === 1) {
this.queryObj.pageIndex = 1;
}
if(!this.queryObj.excellent){
this.queryObj.excellent='';
}
// if (!this.queryObj.excellent) {
// this.queryObj.excellent = '';
// }
apiCase.isTopList(this.queryObj).then(res => {
if (res.status == 200) {
this.count = res.result.count
@@ -279,25 +304,40 @@ export default {
})
},
setTop(item) {
let msg,isTop;
let msg, isTop, btnMsg;
if (item.isTop == 1) {
msg = '取消置顶';
msg = '确认要取消置顶此案例吗?';
btnMsg = "取消成功"
isTop = 0
} else {
msg = '置顶成功';
msg = '你确认要置顶此案例吗?';
btnMsg = "设置置顶成功"
isTop = 1
}
this.$confirm(msg, '删除提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
})
.then(() => {
apiCase.updateTop(item.id, isTop).then(res => {
if (res.status == 200) {
this.$message.success(msg);
this.$message({
type: 'success',
message: btnMsg
});
this.getData()
} else {
this.$message.error("操作失败")
}
})
})
.catch(() => {
this.$message({ type: 'info', message: '取消操作', offset: 50 });
});
},
delItem(item) {
this.$confirm('您确定要删除所选内容吗?', '删除提示', {
this.$confirm('您确定要删除这条案例吗?', '删除提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
@@ -432,16 +472,19 @@ export default {
border: 1px dotted #1ea0fa;
color: #1ea0fa;
}
.article-status2 {
padding: 3px;
border: 1px dotted #00aa00;
color: #00aa00;
}
.article-status3 {
padding: 3px;
border: 1px dotted #ff0000;
color: #ff0000;
}
.article-list {
margin: 5px 0;
border: 1px solid #dddddd;
@@ -454,6 +497,7 @@ export default {
font-weight: 400;
height: 40px;
line-height: 40px;
.article-info-date {
width: 150px;
height: 40px;
@@ -461,21 +505,26 @@ export default {
float: right;
font-weight: 200;
color: #999999;
i {
margin-right: 5px;
}
}
}
.article-info-summary {
height: 65px;
color: #999999;
}
.article-info-tools {
height: 30px;
.article-info-tools-auth {
float: left;
font-size: 13px;
color: #999999;
img {
margin-right: 10px;
width: 30px;
@@ -484,14 +533,17 @@ export default {
vertical-align: middle;
}
}
.article-info-tools-btns {
float: right;
.article-info-tools-btn {
margin: 0 0 0 15px;
}
}
}
}
.case-row-btn {
line-height: 25px;
@@ -500,6 +552,7 @@ export default {
padding: 3px 20px;
}
}
.el-form {
.el-form-item {
margin-bottom: 10px;

View File

@@ -90,6 +90,11 @@
<span v-if="scope.row.sysType3 !=''">/{{sysTypeName(scope.row.sysType3)}}</span>
</template>
</el-table-column>
<el-table-column label="关键字" :show-overflow-tooltip="true" prop="name" width="200px">
<template slot-scope="scope">
{{ scope.row.keywords }}
</template>
</el-table-column>
<!-- <el-table-column label="资源归属" sortable prop="author" width="240px">
<template slot-scope="scope">
<span>{{resOwnerName(scope.row.resOwner1)}}</span>

View File

@@ -15,10 +15,12 @@
</div>
<div class="title">
<h5>{{ caseDetail.title }}</h5>
<span style="text-align: right;" v-if="caseDetail.sysCreateTime"> <i class="el-icon-time"></i> {{ caseDetail.sysCreateTime.substring(0,10) }}</span>
<span style="text-align: right;" v-if="caseDetail.sysCreateTime"> <i class="el-icon-time"></i> {{
caseDetail.sysCreateTime.substring(0, 10) }}</span>
</div>
<div class="label">
<author :aid="caseDetail.sysCreateAid" :onlyAvatar="true" :avatar="authorInfo.avatar" :sex="authorInfo.sex" ></author>
<author :aid="caseDetail.sysCreateAid" :onlyAvatar="true" :avatar="authorInfo.avatar"
:sex="authorInfo.sex"></author>
<span>案主{{ authorInfo.name }} ({{ authorInfo.orgInfo }})</span>
<!-- <span>案主{{ authorInfo.name }}</span>
<span>工号{{ authorInfo.code }}</span>
@@ -31,10 +33,14 @@
</div> -->
<!-- <div class="case-summary"><span>{{ caseDetail.summary }}</span></div> -->
<div class="btn-div clearfix">
<div style="color:#2974D6;font-weight: 450;" v-if="caseDetail.orgDomain" class="item">{{ orgDomainTranslate(caseDetail.orgDomain) }}</div>
<div style="color:#2974D6;font-weight: 450;" class="item" v-if="caseDetail.orgDomain == '' && caseDetail.orgDomainParent">{{ orgDomainTranslate(caseDetail.orgDomainParent) }}</div>
<div style="color:#2974D6;font-weight: 450;" v-if="caseDetail.orgDomain" class="item">{{
orgDomainTranslate(caseDetail.orgDomain) }}</div>
<div style="color:#2974D6;font-weight: 450;" class="item"
v-if="caseDetail.orgDomain == '' && caseDetail.orgDomainParent">{{
orgDomainTranslate(caseDetail.orgDomainParent) }}</div>
<!-- <div style="color:#2974D6;font-weight: 450;" v-if="caseDetail.majorType" class="item">{{ majorTypeTranslate(caseDetail.majorType) }}</div> -->
<div class="item" style="color:#2974D6;font-weight: 450;" v-for="item,idx in caseDetail.majorType" :key="idx" >{{ majorTypeTranslate(item) }}</div>
<div class="item" style="color:#2974D6;font-weight: 450;" v-for="item, idx in caseDetail.majorType"
:key="idx">{{ majorTypeTranslate(item) }}</div>
<div v-if="caseDetail.keyword1" class="item">{{ caseDetail.keyword1 }}</div>
<div v-if="caseDetail.keyword2" class="item">{{ caseDetail.keyword2 }}</div>
<div v-if="caseDetail.keyword3" class="item">{{ caseDetail.keyword3 }}</div>
@@ -72,13 +78,16 @@
<div style="display: flex;justify-content: space-between;">
<div style="margin-left:20px">
<div style="margin-top:3px">
<i style="font-size:22px;color:#a3b1cc" v-show="zoomShow" @click="zoomBox()" class="el-icon-zoom-in"></i>
<i style="font-size:22px;color:#a3b1cc" v-show="!zoomShow" @click="zoomBox()" class="el-icon-zoom-out"></i>
<i style="font-size:22px;color:#a3b1cc" v-show="zoomShow" @click="zoomBox()"
class="el-icon-zoom-in"></i>
<i style="font-size:22px;color:#a3b1cc" v-show="!zoomShow" @click="zoomBox()"
class="el-icon-zoom-out"></i>
</div>
</div>
<div>
<div style="display:inline-block;">
<interactBar v-if="caseDetail.id" :data="caseDetail" :type="3" :comments="false" :shares="true" :unicom="true"></interactBar>
<interactBar v-if="caseDetail.id" :data="caseDetail" :type="3" :comments="false" :shares="true"
:unicom="true"></interactBar>
</div>
<div style="display:inline-block;margin: 0 20px;">
<i style="font-size: 25px;color:#6E7B84;" @click="goTop()" class="el-icon-arrow-up"></i>
@@ -90,7 +99,8 @@
</div>
<!-- :authorId="articleDetailData.sysCreateAid" -->
<div id="comments-box">
<comments @success="success" v-if="resolveId != ''" :obj-type="3" :obj-id="resolveId" :authorId="caseDetail.authorId" :toUsers="toUsers"></comments>
<comments @success="success" v-if="resolveId != ''" :obj-type="3" :obj-id="resolveId"
:authorId="caseDetail.authorId" :toUsers="toUsers"></comments>
</div>
</div>
@@ -104,7 +114,8 @@
<div class="portal-ranking ranking-bg">
<p class="ranking-title">好评榜</p>
<ul class="ranking-data">
<li v-for="(item, index) in Positive" :key="index" class="title-line-ellipsis" style="cursor: pointer;margin-top:30px;line-height: 22px;" @click="jumpRouter(item)">
<li v-for="(item, index) in Positive" :key="index" class="title-line-ellipsis"
style="cursor: pointer;margin-top:30px;line-height: 22px;" @click="jumpRouter(item)">
<span class="portal-right-text blue-one" v-if="index == 0">
<img :src="`${webBaseUrl}/images/listblue01.png`" alt="">
</span>
@@ -127,7 +138,8 @@
<div style="margin-top:26px" class="portal-ranking ranking-bg1">
<p class="ranking-title">人气榜</p>
<ul class="ranking-data">
<li v-for="(item, index) in Popularity" :key="index" class="title-line-ellipsis" style="cursor: pointer;margin-top:30px;line-height: 22px;" @click="jumpRouter(item)">
<li v-for="(item, index) in Popularity" :key="index" class="title-line-ellipsis"
style="cursor: pointer;margin-top:30px;line-height: 22px;" @click="jumpRouter(item)">
<span class="portal-right-text orange-one" v-if="index == 0">
<img :src="`${webBaseUrl}/images/list-01.png`" alt="">
</span>
@@ -211,14 +223,68 @@ export default {
Profess: [],
orgData: [],
setTimeCase: null,
dataTime: sessionStorage.getItem('startTime') || 0
};
},
mounted() {
let $this = this;
console.log(this.dataTime);
this.allRequests()
},
beforeRouteEnter(to, from, next) {
console.log(from, '哈哈哈');
console.log(to, '嘿嘿');
let time = new Date().getTime()
sessionStorage.setItem('startTime', time)
next()
},
beforeRouteUpdate(to, from, next) {
if (to.query.id != from.query.id) {
window.removeEventListener("scroll", this.handleScroll);
clearInterval(this.setTimeCase);
// 结束时间
let recordEndTime = new Date().getTime()
this.endTimeRequst(from.query.id, recordEndTime)
//时间重新赋值
let time = new Date().getTime()
sessionStorage.setItem('startTime', time)
this.dataTime = time
this.allRequests(to.query.id)
}
next()
},
beforeRouteLeave(to, from, next) {
to.meta.keepAlive = true;
next();
},
beforeDestroy() {
console.log('销毁了');
// 结束时间
let recordEndTime = new Date().getTime()
this.endTimeRequst(this.resolveId, recordEndTime)
sessionStorage.removeItem('startTime')
window.removeEventListener("scroll", this.handleScroll);
clearInterval(this.setTimeCase);
},
methods: {
endTimeRequst(caseId, recordEndTime) {
console.log(this.dataTime);
let time = (recordEndTime - this.dataTime) / 1000 / 60
if (time > 10080) {
time = 0
}
//结束之前的查看取时间
apiCase.endReadTimer({
caseId,
browseDuration: Math.ceil(time)
})
},
allRequests(id = '') {
this.Intsucc();
this.retest();
this.resolveId = this.$route.query.id;
this.resolveId = id ? id : this.$route.query.id;
this.$watermark.set(this.userInfo.name + this.userInfo.loginName);
if (this.resolveId) {
this.getCaseData();
@@ -233,17 +299,7 @@ export default {
"scroll",
this.handleScroll
);
},
beforeRouteLeave(to, from, next){
to.meta.keepAlive=true;
next();
},
beforeDestroy(){
window.removeEventListener("scroll",this.handleScroll);
clearInterval(this.setTimeCase);
},
methods: {
banJump() {
if (this.resonimg.JumpUrl) {
window.open(this.resonimg.JumpUrl);
@@ -367,8 +423,17 @@ export default {
},
jumpRouter(item) {
// console.log(item)
location.href =`${this.webBaseUrl}/case/detail?id=${item.id}`
// location.href =`${this.webBaseUrl}/case/detail?id=${item.id}`
// this.$router.push(`/case/detail?id=${item.id}`);
const currentRoute = this.$router.currentRoute;
if (currentRoute.query.id !== item.id) {
this.$router.push('/case/detail?id=' + item.id);
} else {
// 结束时间
let recordEndTime = new Date().getTime()
this.endTimeRequst(item.id, recordEndTime)
location.href = `${this.webBaseUrl}/case/detail?id=${item.id}`
}
},
goTop() {
document.documentElement.scrollTop = 0;
@@ -554,20 +619,23 @@ export default {
</script>
<style scoped lang="scss">
.case-banner {
height: 240px;
background: url('../../../../public/images/case-banner.png');
}
.course-resources {
margin-top: 26px;
img {
width: 100%;
height: 100%;
border-radius: 8px;
}
}
.pdftext {
// padding: 0 20px;
span {
font-size: 22px;
@@ -576,23 +644,29 @@ export default {
line-height: 40px;
padding: 0 20px;
}
text-align: center;
}
.fixd-box-show {
display: none;
}
::v-deep .interact-bar .interact-bar-btns {
justify-content: flex-start !important;
}
::v-deep .interact-bar-btn {
margin-left: 0px !important;
margin-right: 15px !important;
}
.postfixt-bot {
height: 60px;
//margin-top: 10px;
line-height: 60px;
// background-color: #fff;
// border: 1px solid #eee;
// z-index: 999;
@@ -603,28 +677,35 @@ export default {
// border: 1px solid #eee;
}
}
.el-card {
border: none;
}
.case-summary {
font-size: 15px;
color: #454545;
word-break: break-all;
line-height: 25px;
}
::v-deep .el-card__body {
padding: 0;
}
::v-deep .bacolor:nth-child(odd) {
background-color: #f6f6f6;
padding: 0 5px;
}
::v-deep .bacolor:nth-child(even) {
background-color: #fff;
padding: 0 5px;
}
.ranking-title {
// line-height: 34px;
// font-size: 15px;
// color: #333333;
@@ -632,13 +713,16 @@ export default {
font-size: 15px;
color: #333333;
}
.center {
text-align: right;
}
img {
margin-top: 5px;
}
}
::v-deep .title-line-ellipsis {
// width: 100%;
display: -webkit-box;
@@ -649,15 +733,19 @@ export default {
box-sizing: border-box;
word-break: break-all;
}
.nav {
margin-bottom: 10px;
}
.detail {
background-color: #fff;
padding: 50px;
.title {
display: flex;
width: 100%;
h5 {
margin: 0;
font-size: 20px;
@@ -665,6 +753,7 @@ export default {
font-weight: 600;
flex: 1;
}
span {
margin-left: auto;
line-height: 45px;
@@ -672,19 +761,23 @@ export default {
font-size: 14px;
}
}
.label {
font-size: 15px;
color: #999999;
display: flex;
justify-content: flex-start;
align-items: center;
span {
margin-left: 10px;
&:last-of-type {
flex: 1;
}
}
}
.type {
color: #0079fe;
}
@@ -697,12 +790,14 @@ export default {
clear: both;
visibility: hidden;
}
.btn-div {
margin: 0px 0 5px 0;
padding-bottom: 5px;
padding-top: 5px;
height: 100%;
width: 100%;
.item {
float: left;
margin: 7px 10px 0px 0px;
@@ -716,58 +811,71 @@ export default {
box-sizing: border-box;
color: #2C68FF;
}
.item-right {
float: right;
}
}
}
.jianjie {
// margin: 15px 0;
margin-top: 30px;
background-color: #f5f7fa;
min-height: 300px;
padding: 0px 0px 0px 0px;
.content {
padding: 10px 0;
line-height: 25px;
}
.btn-div {
margin: 8px 0;
padding: 10px 0;
color: #666;
.item {
margin-right: 30px;
}
.item-right {
float: right;
}
}
}
.bottom-btn {
padding: 10px 50px;
.article-info-tools-btn {
padding: 5px 0px;
margin: 0 10px;
}
}
.bottom-div {
margin-top: 10px;
background-color: #fff;
padding: 5px 20px 10px 20px;
.title {
font-size: 16px;
font-weight: 600;
line-height: 50px;
border-bottom: 1px solid #dfdfdf;
.tip {
color: #666;
font-size: 12px;
margin: 0 10px;
}
}
.submit-div {
margin: 15px 0;
}
.bottom {
text-align: right;
}
@@ -776,42 +884,52 @@ export default {
margin-top: 10px;
background-color: #fff;
padding: 5px 20px 10px 20px;
.data-item {
border-bottom: 1px solid #dfdfdf;
margin-top: 10px;
.top {
font-size: 18px;
font-weight: 600;
span {
font-size: 14px;
color: #666;
font-weight: normal;
}
}
.text {
margin: 15px 0 5px 0;
padding-left: 40px;
line-height: 35px;
}
.huifu {
padding-left: 40px;
padding-bottom: 10px;
border-bottom: 1px solid #dfdfdf;
}
.result-div {
padding-left: 40px;
padding-top: 10px;
.top {
font-size: 16px;
}
}
.up-div {
padding: 0 15px;
.up-btn {
padding: 8px 20px;
color: #000;
}
}
img {
margin-right: 10px;
width: 30px;
@@ -822,24 +940,30 @@ export default {
}
}
}
.right-box {
line-height: 25px;
.ranking-card {
margin-bottom: 10px;
.el-col {
margin-bottom: 10px;
}
.center {
text-align: center;
}
}
.ranking-title {
}
.ranking-title {}
.aligh-title {
font-size: 14px;
color: #333333;
}
.ranking-data {
margin: 10px 0;
color: #999999;

File diff suppressed because it is too large Load Diff

View File

@@ -50,7 +50,7 @@
</div>
<div v-else class="score-no">未评分</div>
</div>
<div class="btn-div" style="height:30px;margin-top: 15px;">
<div class="btn-div" v-if="isCrowd" style="height:30px;margin-top: 15px;">
<el-button v-if="stuStusts == 0" type="primary" @click="startSigningUp()" >开始学习</el-button>
<el-button v-if="stuStusts == 1" type="primary" @click="jumpJearning">{{btnName}}</el-button>
</div>
@@ -69,14 +69,14 @@
<el-col :span="18">
<el-card :body-style="{ padding: '0px' }" class="info" style="margin-top: 10px;">
<el-tabs v-model="activeName">
<el-tab-pane label="课程简介" name="first">
<el-tab-pane label="内容简介" name="first">
<div>
<div class="content"><img src="@/assets/images/icon/remark-iocn.png" alt="" srcset="">目标人群<div class="content-text">{{courseInfo.forUsers}}</div></div>
<div class="content"><img src="@/assets/images/icon/remark-iocn.png" alt="" srcset="">课程价值<div class="content-text">{{courseInfo.value}}</div></div>
<div class="content"><img src="@/assets/images/icon/remark-iocn.png" alt="" srcset="">详细介绍<div class="content-text" v-html="courseInfo.summary"></div></div>
</div>
</el-tab-pane>
<el-tab-pane label="大纲" name="second" v-if="courseInfo.type==20">
<el-tab-pane label="课程速览" name="second" v-if="courseInfo.type==20">
<div class="category" v-for="(item) in catalogTree" :key="item.id">
<div class="node">
<div class="title">{{item.section.name}}</div>
@@ -92,7 +92,7 @@
</div>
<div style="height: 30px;"></div>
</el-tab-pane>
<el-tab-pane label="大纲" name="second" v-if="courseInfo.type==10">
<el-tab-pane label="课程速览" name="second" v-if="courseInfo.type==10">
<div class="category" v-for="(item) in contentList" :key="item.id">
<div class="node">
<div class="title">{{item.contentName}}</div>
@@ -120,7 +120,8 @@
</div>
<div class="teacher-info">
<div class="teacher-name">{{ item.teacherName }}</div>
<div class="teacher-remark" v-html="item.remark"></div>
<!-- <div class="teacher-remark" v-html="item.remark"></div> -->
<div class="teacher-remark">{{ cutOrgNamePath(item.orgInfo) }} </div>
</div>
</div>
</div>
@@ -144,7 +145,7 @@ import apiCourse from '@/api/modules/course.js';
import apiUser from '@/api/system/user.js';
import courseStudy from '@/api/modules/courseStudy.js';
import apiCoursePortal from '@/api/modules/coursePortal.js';
import { courseType,getType,toScore,userAvatarText} from '@/utils/tools.js';
import { courseType,getType,toScore,userAvatarText,cutOrgNamePath } from '@/utils/tools.js';
import courseImage from "@/components/Course/courseImage.vue"
export default {
name: "atticle",
@@ -154,6 +155,7 @@ export default {
},
data() {
return {
cutOrgNamePath,
userAvatarText,
getType,
showQrcode: false,
@@ -174,6 +176,7 @@ export default {
commentsTtoal:0,
toUsers:[],//可以@的用户列表
btnName:'开始学习',
isCrowd:false, //根据受众展示不展示
};
},
mounted() {
@@ -185,13 +188,17 @@ export default {
let $this=this;
//页面只支取一次,所以先直接写在这里面
apiCoursePortal.detail(id,false).then(rs=>{
apiCoursePortal.detail(id,false,true).then(rs=>{
if(rs.status==200){
if(!rs.result.course.enabled || rs.result.course.deleted){
$this.$message.error('十分抱歉,此课程已停用,如需使用,请联系管理员。');
return;
}
if(!rs.result.isCrowd){
$this.$message.error('您没有查看该课程的权限');
}
this.isCrowd = rs.result.isCrowd
if(rs.result.teachers && rs.result.teachers.length > 0){
let userIds=[];
@@ -347,6 +354,7 @@ export default {
item.avatar=this.fileBaseUrl + author.avatar;
}
item.sex = author.sex;
item.orgInfo = author.orgInfo
return true;
}else{
return false;
@@ -363,7 +371,7 @@ export default {
};
</script>
<style scoped lang="scss" scoped>
<style scoped lang="scss">
::v-deep .teacher .teacher-avator .teacher-text {
background: none;
border: none;
@@ -400,6 +408,7 @@ export default {
}
.course-title{
position: relative;
height: 90px;
display: flex;
justify-content: space-between;
@@ -411,7 +420,6 @@ export default {
margin-bottom: 10px;
word-break:break-all;
}
position: relative;
// .course-title-right{
// position: absolute;
// right: 0;

File diff suppressed because it is too large Load Diff

View File

@@ -17,7 +17,8 @@
</el-radio-group> -->
</div>
<div>
<el-button style="margin-left: 25px;" :disabled="disabledReadAll" :class="{navbut:!disabledReadAll}" type="text" @click="isReadChooseList">设置已读</el-button>
<el-button style="margin-left: 25px;" :disabled="disabledReadAll" :class="{ navbut: !disabledReadAll }"
type="text" @click="isReadChooseList">设置已读</el-button>
<el-button class="navbut" type="text" @click="delChooseList">删除所选</el-button>
</div>
</div>
@@ -82,36 +83,39 @@
<div class="msg-top">
<div>
<span style="padding-right: 10px;"><el-checkbox v-model="item.checked" @change="setCheckAll(item)"></el-checkbox></span>
<span v-if="!item.isRead" style="font-size:12px;padding:5px 7px; border-radius: 2px;background: #FF6562;color: #fff;margin-right: 5px">未读</span>
<span v-else style="font-size:14px;padding:5px 7px; background: #eee; border-radius: 2px; color: #666666;margin-right: 5px">已读</span>
<span style="padding-right: 10px;"><el-checkbox v-model="item.checked"
@change="setCheckAll(item)"></el-checkbox></span>
<span v-if="!item.isRead"
style="font-size:12px;padding:5px 7px; border-radius: 2px;background: #FF6562;color: #fff;margin-right: 5px">未读</span>
<span v-else
style="font-size:14px;padding:5px 7px; background: #eee; border-radius: 2px; color: #666666;margin-right: 5px">已读</span>
<!-- <a :href="returnRouter(item)"> -->
<span style="cursor: pointer;" @click="returnRouter(item)">{{ item.title }}</span>
</div>
</div>
<div class="msg-body">
<!-- <a :href="returnRouter(item)"> -->
<div style="cursor: pointer;" @click="returnRouter(item)" class="msg-body-content" v-if="item.content">{{item.tip}}-{{ item.content }}</div>
<div style="cursor: pointer;" @click="returnRouter(item)" class="msg-body-content" v-else>{{item.tip}}</div>
<div v-if="item.refType !== '99'">
<div style="cursor: pointer;" @click="returnRouter(item)" class="msg-body-content" v-if="item.content">
{{ item.tip }}-{{ item.content }}</div>
<div style="cursor: pointer;" @click="returnRouter(item)" class="msg-body-content" v-else>{{ item.tip }}
</div>
</div>
<div v-else :class="!item.isRead ? 'infoActive' : ''" style="cursor: pointer;" @click="goRouter(item)"
class="msg-body-content">管理员{{ item.acceptName }}向您推荐了案例{{ item.content }}点击查看>>>
</div>
<!-- </a> -->
<div class="msg-body-but">
<div v-if="item.refType !== '99'" class="msg-body-but">
<el-button type="danger" plain @click="delItem(item)">删除</el-button>
</div>
</div>
<div class="msg-time">{{ item.msgTime }}</div>
</div>
</div>
<div style="text-align: center;margin-top: 50px" v-if="total > queryData.pageSize">
<el-pagination
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page="queryData.pageIndex"
:page-sizes="[2, 4, 6, 8]"
:page-size="queryData.pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="total"
></el-pagination>
<el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
:current-page="queryData.pageIndex" :page-sizes="[2, 4, 6, 8]" :page-size="queryData.pageSize"
layout="total, sizes, prev, pager, next, jumper" :total="total"></el-pagination>
</div>
<!-- <div class="pagination-div" v-if="queryData.pageIndex < totalPages"><span class="pag-text" @click="loadMore()">加载更多</span></div> -->
</div>
@@ -147,13 +151,6 @@
</el-dialog>
</div>
</template>
<script>
@@ -162,6 +159,7 @@ import portalHeader from '@/components/PortalHeader.vue';
import portalFooter from '@/components/PortalFooter.vue';
import GuideBox from '@/components/Portal/guideBox.vue'
import apiMessage from '@/api/system/message.js';
import apiCase from '@/api/modules/cases.js';
export default {
name: 'answer',
components: {
@@ -293,6 +291,7 @@ export default {
this.checkAll = item.checked;
}
},
//改变已读状态的操作
isReadChooseList() {
if (this.data.length == 0) return;
@@ -324,11 +323,17 @@ export default {
}
},
delChooseList() {
// 全选的时候不能删除案例
if (this.data.some((item) => item.refType == '99' && item.checked)) {
this.$message.error('推荐案例不能删除,请重新选择');
return;
}
let list = this.data.filter(item => item.checked).map(v => v.id);
if (list.length == 0) {
this.$message.error('请先选择要删除的消息');
return;
}
this.$confirm('您确定要删除所选消息吗?', '删除提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
@@ -371,6 +376,23 @@ export default {
this.$refs.guide.guideCollection = true;
},
// 点击案例
async goRouter(item) {
console.log(item);
apiMessage.updateIsRead([item.id]).then(res => {
if (res.status == 200) {
this.$store.dispatch('refrashMsg');
item.isRead = true;
}
});
//需要跳转
if (item.pageUrl && item.pageUrl.length > 10) {
await apiCase.startReadTimer(item.refId)
this.$router.push('/case/detail?id=' + item.pageParams);
} else {
this.$router.push('/case?recommendId=' + item.refId);
}
},
// 跳转详情事件11
returnRouter(item) {
apiMessage.updateIsRead([item.id]).then(res => {
@@ -413,6 +435,10 @@ export default {
</script>
<style lang="scss" scoped>
.infoActive {
color: #0078FC !important;
}
.navbut {
width: 110px;
height: 30px;
@@ -423,6 +449,7 @@ export default {
padding: 0;
color: #0078FC;
}
.msg-nav {
display: flex;
// justify-content: space-between;
@@ -431,32 +458,39 @@ export default {
background-color: #ffffff;
padding: 5px 10px;
}
.msg-list {
border-bottom: 1px solid rgb(237, 237, 237);
margin-top: 10px;
line-height: 26px;
background-color: #ffffff;
padding: 5px 10px;
&:first-of-type {
padding-top: 15px;
}
.msg-top {
display: flex;
justify-content: space-between;
line-height: 30px;
}
.msg-body {
padding: 10px 10px 10px 25px;
display: flex;
width: 100%;
.msg-body-content {
flex: 1;
word-break: break-all;
color: #727272;
a:hover {
color: #409eff;
}
}
.msg-body-but {
margin-left: auto;
@@ -471,6 +505,7 @@ export default {
text-align: center;
border: 1px solid #F52F3E;
}
button:hover {
background-color: rgba(255, 101, 98, 0.13);
color: #F52F3E;
@@ -479,12 +514,14 @@ export default {
}
}
}
.msg-time {
color: #a5a5a5;
font-size: 14px;
padding-left: 25px;
}
}
.messageList {
>p {
display: flex;
@@ -494,9 +531,11 @@ export default {
margin: 0;
align-items: center;
}
.messageItem:not(:first-child) {
padding-top: 10px;
}
.messageItem {
// width: 100%;
padding-bottom: 10px;
@@ -504,12 +543,15 @@ export default {
display: flex;
justify-content: space-between;
align-items: center;
.el-checkbox {
margin-right: 5px;
}
.el-button {
margin-left: auto;
}
// margin-bottom: 10px;
p {
margin: 0;
@@ -517,24 +559,29 @@ export default {
justify-content: space-between;
align-items: center;
}
p:first-of-type {
>span {
display: flex;
justify-content: flex-start;
align-items: center;
span:first-of-type {
font-size: 12px;
}
}
>span:last-of-type {
font-size: 14px;
color: #b7b7b7;
margin-left: 5px;
}
}
p:last-of-type {
font-size: 14px;
text-indent: 3em;
span:last-of-type {
font-size: 14px;
color: #b7b7b7;
@@ -542,6 +589,7 @@ export default {
}
}
}
.pagination-div {
cursor: pointer;
}

View File

@@ -30,7 +30,7 @@
<videoPlayer ref="myVideoPlayer" id="myVideoPlayer" :src="blobUrl" @onPlayerPlaying="onPlayerPlaying"
:initTime="contentData.lastStudyTime" :notePlay="notePlay" @onPlayerPlay="onPlayerPlay"
:isDrag="curriculumData.isDrag" @onFullscreen="onFullscreen" @onPlayerPause="onPlayerPause"
@onPlayerEnded="onPlayerEnded"></videoPlayer>
@onPlayerEnded="onPlayerEnded" :isCrowd="isCrowd"></videoPlayer>
<div class="player-box" v-if="playerBoxShow">
<div class="player-praise" style="cursor: pointer;">
<div @click="praiseContent">
@@ -200,7 +200,7 @@
<div class="course-info">
<div style="background-color: #fff;">
<div class="course-info-tab">
<div @click="coutab(1)" :class="courestab == 1? 'course-info-tab-active' : ''">课程介绍<span class=""></span> </div>
<div @click="coutab(1)" :class="courestab == 1? 'course-info-tab-active' : ''">内容简介<span class=""></span> </div>
<div @click="coutab(2)" :class="courestab == 2? 'course-info-tab-active' : ''">课程评论<span class=""></span> </div>
<div @click="coutab(3)" :class="courestab == 3? 'course-info-tab-active' : ''">课程笔记<span class=""></span> </div>
</div>
@@ -240,9 +240,10 @@
<div class="teacher-info">
<div class="teacher-name">
<span> {{ item.teacherName }}</span>
<span style="font-size: 12px; color:#666666 ;">( {{cutOrgNamePath(item.authorInfo.orgInfo)}} )</span>
<!-- <span style="font-size: 12px; color:#666666 ;">( {{cutOrgNamePath(item.authorInfo.orgInfo)}} )</span> -->
</div>
<div class="teacher-remark" v-html="item.authorInfo.sign"></div>
<!-- <div class="teacher-remark" v-html="item.authorInfo.sign"></div> -->
<div class="teacher-remark">{{cutOrgNamePath(item.authorInfo.orgInfo)}}</div>
</div>
<div style="padding-top:15px;width:70px;">
<followButton :auto="true" size="small" :aid="item.teacherId"></followButton>
@@ -319,6 +320,7 @@
},
data() {
return {
isCrowd:false,
cutOrgNamePath,
scormUrl:'',//当前播放的scormUrl
loading:false,
@@ -692,6 +694,10 @@
})
},
showRes(r, i, index) { //i:子节下标index:章下标
// 无权限查看不能点击
if(!this.isCrowd){
return
}
if (i != undefined && i!=-1 && index != undefined && r.status < 9) {
if (this.courseInfo.orderStudy) {
//判断上个是否学完
@@ -1132,6 +1138,7 @@
this.finishStudyItem();
}
},
// 获取数据信息
loadData() {
let $this=this;
apiStudy.studyIndex(this.courseId).then(rs => {
@@ -1149,6 +1156,11 @@
$this.tab=2;
//console.log('内容只有一个');
}
if(!rs.result.isCrowd){
$this.$message.error('您没有查看该课程的权限');
}
// 是否播放
this.isCrowd = rs.result.isCrowd
if (rs.result.course.type == 20) { //有目录课程
rs.result.sections.forEach(sec => {