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

@@ -6,8 +6,8 @@ import ajax from '@/utils/xajax.js'
* orderField * orderField
* orderAsc * orderAsc
*/ */
const indexList = function(query) { const indexList = function (query) {
return ajax.post('/xboe/m/boe/cases/case-random', query); return ajax.post('/xboe/m/boe/cases/case-random', query);
} }
/* /*
*案例分页搜索查询 是否推荐 *案例分页搜索查询 是否推荐
@@ -19,9 +19,12 @@ const indexList = function(query) {
*@param(String) majorType 专业分类 *@param(String) majorType 专业分类
* @param(String) majorDomain 专业领域 * @param(String) majorDomain 专业领域
*/ */
const queryList = function(query) { const queryList = function (query) {
return ajax.post('/xboe/m/boe/cases/queryList', 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(String) keyWord 关键词
@param(Boolean) isTop 是否置顶 true或false @param(Boolean) isTop 是否置顶 true或false
@@ -29,76 +32,77 @@ const queryList = function(query) {
*@param(String) majorType 专业分类 *@param(String) majorType 专业分类
* @param(String) majorDomain 专业领域 * @param(String) majorDomain 专业领域
*/ */
const isTopList = function(query) { const isTopList = function (query) {
return ajax.post('/xboe/m/boe/cases/isTopList', query); return ajax.post('/xboe/m/boe/cases/isTopList', query);
} }
/* 设置置顶 取消置顶 /* 设置置顶 取消置顶
@param(String) id @param(String) id
@param(Integer) isTop 是否置顶 0未置顶1已置顶 @param(Integer) isTop 是否置顶 0未置顶1已置顶
*/ */
const updateTop = function(id, isTop) { const updateTop = function (id, isTop) {
return ajax.get(`/xboe/m/boe/cases/updateTop?id=${id}&isTop=${isTop}`); return ajax.get(`/xboe/m/boe/cases/updateTop?id=${id}&isTop=${isTop}`);
} }
/* 删除案例 /* 删除案例
*param(String) id 案例的id *param(String) id 案例的id
*/ */
const del = function(id) { const del = function (id) {
return ajax.get('/xboe/m/boe/cases/delete?id=' + id); return ajax.get('/xboe/m/boe/cases/delete?id=' + id);
} }
/*案例详情 /*案例详情
@param(String) id 案例的id @param(String) id 案例的id
@param(Boolean) addView 是否增加浏览量 @param(Boolean) addView 是否增加浏览量
*/ */
const detail = function(id,addView) { const detail = function (id, addView) {
let pars='id=' + id; let pars = 'id=' + id;
if(addView){ if (addView) {
pars+='&addView='+addView pars += '&addView=' + addView
} }
return ajax.get('/xboe/m/boe/cases/detail?'+pars); return ajax.get('/xboe/m/boe/cases/detail?' + pars);
} }
/*推荐 /*推荐
*@param (String) id 案例的id *@param (String) id 案例的id
*@param (String) title 案例的标题 *@param (String) title 案例的标题
*@param (String) acceptAid 受众id *@param (String) acceptAid 受众id
*@param (String) recommentThat 推荐说明 *@param (String) recommentThat 推荐说明
*/ */
const savaRecommend = function(data) { const savaRecommend = function (data) {
return ajax.post('/xboe/m/boe/recommend/save', data); return ajax.post('/xboe/m/boe/recommend/save', data);
} }
/* 推荐列表 /* 推荐列表
*没有参数 *没有参数
*/ */
const query = function() { const query = function () {
return ajax.get('/xboe/m/boe/recommend/query'); return ajax.get('/xboe/m/boe/recommend/query');
} }
/* /*
*作者排行榜 *作者排行榜
@param pageSize 长度 @param pageSize 长度
*/ */
const usernameList= function(pageSize){ const usernameList = function (pageSize) {
return ajax.get(`/xboe/m/boe/cases/usernamelist?pageSize=${pageSize}`); return ajax.get(`/xboe/m/boe/cases/usernamelist?pageSize=${pageSize}`);
} }
/* /*
人气榜 人气榜
@param pageSize 长度 @param pageSize 长度
*/ */
const queryPraises=function(pageSize){ const queryPraises = function (pageSize) {
return ajax.get(`/xboe/m/boe/cases/query-praises?pageSize=${pageSize}`); return ajax.get(`/xboe/m/boe/cases/query-praises?pageSize=${pageSize}`);
} }
/* /*
好评榜 好评榜
@param pageSize 长度 @param pageSize 长度
*/ */
const queryComments=function(pageSize){ const queryComments = function (pageSize) {
return ajax.get(`/xboe/m/boe/cases/query-comments?pageSize=${pageSize}`); return ajax.get(`/xboe/m/boe/cases/query-comments?pageSize=${pageSize}`);
} }
/** /**
* 专业分类 * 专业分类
* */ * */
const majorTypes=function (){ const majorTypes = function () {
return ajax.get('/xboe/m/boe/cases/majorTypes'); return ajax.get('/xboe/m/boe/cases/majorTypes');
} }
/** /**
* 详情新*/ * 详情新*/
const details = function (id, addView) { const details = function (id, addView) {
@@ -115,8 +119,8 @@ const details = function (id, addView) {
* ids * ids
* } * }
* */ * */
const ids=function (data){ const ids = function (data) {
return ajax.postJson('/xboe/m/boe/cases/ids',data); return ajax.postJson('/xboe/m/boe/cases/ids', data);
} }
/** /**
@@ -126,8 +130,8 @@ const ids=function (data){
* excellent true、设置 false 取消 * excellent true、设置 false 取消
* } * }
* */ * */
const excellent=function(data){ const excellent = function (data) {
return ajax.post('/xboe/m/boe/cases/excellent',data) return ajax.post('/xboe/m/boe/cases/excellent', data)
} }
@@ -138,8 +142,8 @@ const excellent=function(data){
* pageSize * pageSize
* } * }
* */ * */
const mylist=function (query){ const mylist = function (query) {
return ajax.post('/xboe/m/boe/cases/mylist',query); return ajax.post('/xboe/m/boe/cases/mylist', query);
} }
/** /**
@@ -149,26 +153,56 @@ const mylist=function (query){
* pageSize * pageSize
* } * }
* */ * */
const exportCases=function (query){ const exportCases = function (query) {
return ajax.post('/xboe/m/boe/cases/export',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 { export default {
indexList, indexList,
queryList, queryList,
isTopList, queryListV2,
updateTop, isTopList,
del, updateTop,
detail, del,
savaRecommend, detail,
query, savaRecommend,
usernameList, query,
queryPraises, usernameList,
queryComments, queryPraises,
queryComments,
majorTypes, majorTypes,
details, details,
ids, ids,
excellent, excellent,
mylist, mylist,
exportCases exportCases,
exports,
startReadTimer,
endReadTimer
} }

View File

@@ -40,8 +40,8 @@ const pageList = function(query) {
* 课程的详细信息 * 课程的详细信息
* @param {String} id * @param {String} id
*/ */
const detail = function(id,preview) { const detail = function(id,preview,course=false) {
return ajax.get(`/xboe/m/course/portal/detail?id=${id}&preview=${preview}`); 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 ajax from '@/utils/xajax.js'
import request from '../unionAjax.js';
/** /**
* 提取全量树形结构数据 * 提取全量树形结构数据
@@ -11,6 +12,16 @@ import ajax from '@/utils/xajax.js'
const tree = function(sysResType) { const tree = function(sysResType) {
return ajax.get(`/xboe/type/tree-list?sysResType=${sysResType}&status=1`); 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查询列表 * 按父ID查询列表
@@ -24,5 +35,6 @@ const list = function(sysResType, parentId) {
export default { export default {
tree, tree,
list list,
} treeList
}

View File

@@ -8,6 +8,12 @@ import ajax from '@/utils/xajax.js'
const cases=function (type){ const cases=function (type){
return ajax.get('/xboe/portal/index/cases?type='+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, articleViews,
qaAnswers, qaAnswers,
articlelist, 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; 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){ @media screen and (max-width: 1366px){
@@ -384,11 +432,18 @@ body {margin: 0px;padding: 0px;}
position: absolute; position: absolute;
right:20px; right:20px;
bottom: 78px; bottom: 78px;
} }
.course-image-box { .course-image-box {
width:218; width:218;
height: 122px; height: 122px;
} }
.course-img-box{
height: 122px;
}
.keywordInfo{
width: 40px !important;
margin-right: 2px;
}
} }
.course-tit{ .course-tit{
float: none !important; float: none !important;
@@ -401,6 +456,13 @@ body {margin: 0px;padding: 0px;}
height: 45px !important; height: 45px !important;
} }
// 课程导航
.nav{
width: 478px;
}
.upload{
width: 300px;
}
} }
@media screen and (max-width: 1680px) and (min-width:1367px){ @media screen and (max-width: 1680px) and (min-width:1367px){
@@ -429,7 +491,21 @@ body {margin: 0px;padding: 0px;}
width: 278px; width: 278px;
height: 156px; height: 156px;
} }
.course-img-box{
height: 156px;
}
.keywordInfo{
width: 45px !important;
margin-right: 13px;
}
} }
// 课程导航
.nav{
width: 654px;
}
.upload{
width: 350px;
}
} }
@media screen and (max-width: 1920px) and (min-width: 1681px){ @media screen and (max-width: 1920px) and (min-width: 1681px){
@@ -458,6 +534,19 @@ body {margin: 0px;padding: 0px;}
width: 346px; width: 346px;
height: 192px; 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; width: 340px;
height: 191px; height: 191px;
} }
.course-img-box{
height: 191px;
}
.keywordInfo{
margin-right: 33px;
}
}
// 课程导航
.nav{
width: 974px;
}
.upload{
width: 410px;
} }
} }

View File

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

View File

@@ -76,10 +76,11 @@
if(!data.id){ if(!data.id){
return; return;
} }
if(item.info.deleted){ if(data.deleted){
this.$message.warning("此问题已删除"); this.$message.warning("此问题已删除");
return; return;
} }
this.$router.push({ path: '/qa/answer', query: { id: data.id } }); 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 style="color: #333333;font-weight: 600;font-size: 16px;">{{userName}}</span>
<span class="author-text" v-if="userInfo && userInfo!=''"> {{userInfo}} </span> <span class="author-text" v-if="userInfo && userInfo!=''"> {{userInfo}} </span>
</div> </div>
<slot />
</div> </div>
</template> </template>
<script> <script>

View File

@@ -35,7 +35,7 @@
<span class="interact-bar-value"> {{ data.praises? data.praises:0}}</span> <span class="interact-bar-value"> {{ data.praises? data.praises:0}}</span>
</div> </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"> <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-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> <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"> <div class="person-action-item">
<el-badge class="person-action-index" :value="userMsg" :hidden="userMsg == 0"> <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-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"> -->
<svg-icon :style="{color:textColor}" style="margin-right: 0;font-size:22px;" icon-class="messfff"></svg-icon> <router-link to="/message/center/index">
</el-link> <svg-icon :style="{color:textColor}" style="margin-right: 0;font-size:22px;" icon-class="messfff"></svg-icon>
</router-link>
<!-- </el-link> -->
</el-tooltip> </el-tooltip>
</el-badge> </el-badge>
</div> </div>
@@ -216,21 +218,17 @@ export default {
// }); // });
}, },
handleCommand(val) { handleCommand(val) {
if (val === "four") { let urlPre=window.location.protocol+'//'+window.location.host;
this.$emit('showClass',true) // process.env.VUE_APP_BOE_WEB_URL
} else { let obj = {
let urlPre = window.location.protocol + "//" + window.location.host; one: urlPre+'/web/teacherLesson',
// process.env.VUE_APP_BOE_WEB_URL two: urlPre+'/grow180/login',
let obj = { three: this.webBaseUrl + '/study/index?study=1',
one: urlPre + "/web/teacherLesson", four: 'https://m.qingxuetang.com/x/?appId=qxtcorp306130',
two: urlPre + "/grow180/login", five: urlPre+'/boe/new-employee/index.html',
three: this.webBaseUrl + "/study/index?study=1", six: urlPre+'/web/contributor/index'
// four: 'https://m.qingxuetang.com/x/?appId=qxtcorp306130', };
five: urlPre + "/boe/new-employee/index.html", window.open(obj[val]);
six: urlPre + "/web/contributor/index",
};
window.open(obj[val]);
}
}, },
handleUcCommand(val) { handleUcCommand(val) {
if (val == 'uc') { if (val == 'uc') {
@@ -274,7 +272,8 @@ export default {
} else if (this.goSearch == 2) { } else if (this.goSearch == 2) {
if(this.keyword==''){return;} 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}`); //window.open(`${this.webBaseUrl}/case?keyword=${this.keyword}`);
} else if (this.goSearch == 3) { } else if (this.goSearch == 3) {
if(this.keyword==''){return;} if(this.keyword==''){return;}

View File

@@ -38,11 +38,11 @@
:biBarrageXml="biBarrageXml" :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"/> <img src="@/components/VideoPlayer/images/loading.svg" alt="loading"/>
</div> </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"> <div v-show="isShowVolumeHint" class="player-volumeHint">
<span class="player-volumeHint-text">当前音量:{{volumePercent}}%</span> <span class="player-volumeHint-text">当前音量:{{volumePercent}}%</span>
</div> </div>
@@ -264,6 +264,10 @@ export default {
isDrag:{ isDrag:{
type: Boolean, type: Boolean,
default: null, default: null,
},
isCrowd:{
type: Boolean,
default: true,
} }
}, },
data() { data() {

View File

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

View File

@@ -9,18 +9,27 @@
<div style="display: flex;justify-content:flex-start;"> <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-cascader placeholder="资源归属" clearable v-model="params.type" :options="typeList"></el-cascader></div> -->
<div style="padding: 0px 5px;"> <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="true"></el-option>
<el-option label="未置顶" :value="false"></el-option> <el-option label="未置顶" :value="false"></el-option>
</el-select> </el-select>
</div> </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;"> <div style="padding: 0px 5px;">
<el-button @click="getData(1)" icon="el-icon-search" type="primary" >搜索</el-button> <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 @click="showRecords()" icon="el-icon-tickets" type="info" >推荐记录</el-button> -->
<el-button icon="el-icon-refresh-right" type="primary" @click="reset">重置</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> </div>
</div> </div>
@@ -34,60 +43,61 @@
</el-table-column> --> </el-table-column> -->
<el-table-column label="作者" width="80px" prop="authorName"></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="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="sysCreateTime"></el-table-column>
<el-table-column label="设置优秀时间" prop="excellentTime"></el-table-column> <el-table-column label="设置优秀时间" prop="excellentTime"></el-table-column>
<el-table-column label="操作"> <el-table-column label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button-group> <el-button-group>
<!-- <el-button type="text" @click="shareItem(scope.row)" icon="el-icon-share" style="margin:0 5px">推荐</el-button> --> <!-- <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"
<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> @click="setTop(scope.row)" icon="el-icon-top">置顶</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"
<el-button style="margin:0 5px" type="text" @click="delItem(scope.row)" icon="el-icon-delete">删除</el-button> @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> </el-button-group>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div style="text-align: center;margin-top: 50px;"> <div style="text-align: center;margin-top: 50px;">
<el-pagination <el-pagination background @size-change="handleSizeChange" @current-change="handleCurrentChange"
background :current-page="queryObj.pageIndex" :page-sizes="[10, 20, 30, 40]" :page-size="queryObj.pageSize"
@size-change="handleSizeChange" layout="total, sizes, prev, pager, next, jumper" :total="count"></el-pagination>
@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>
<div style="height: 100px;"></div> <div style="height: 100px;"></div>
<el-dialog title="推荐案例" :visible.sync="shareShow" :close-on-click-modal="false" width="500px" custom-class="g-dialog"> <el-dialog title="推荐案例" :visible.sync="shareShow" :close-on-click-modal="false" width="500px" custom-class="g-dialog">
<div style="padding-right: 30px;"> <div style="padding-right: 30px;">
<el-form label-width="100px" @submit.native.prevent > <el-form label-width="100px" @submit.native.prevent>
<el-form-item label="推荐案例">{{shareItemData.title}}</el-form-item> <el-form-item label="推荐案例">{{ shareItemData.title }}</el-form-item>
<el-form-item label="姓名或工号"> <el-form-item label="姓名或工号">
<el-input v-model="shareInfo.name" maxlength="10" placeholder="您要分享的人的姓名搜索" @keyup.enter.native="keyupEnter"> <el-input v-model="shareInfo.name" maxlength="10" placeholder="您要分享的人的姓名搜索" @keyup.enter.native="keyupEnter">
<el-button @click="findUser" slot="append" icon="el-icon-search"></el-button> <el-button @click="findUser" slot="append" icon="el-icon-search"></el-button>
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-checkbox-group v-model="shareUsers"> <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-group> ')' }}</el-checkbox>
</el-form-item> </el-checkbox-group>
<!-- <div style="padding: 0 20px 20px 20px;"> </el-form-item>
<!-- <div style="padding: 0 20px 20px 20px;">
</div> --> </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"
</el-form> placeholder="备注说明"></el-input></el-form-item>
</el-form>
</div> </div>
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
<el-button @click="shareShow = false"> </el-button> <el-button @click="shareShow = false"> </el-button>
<el-button @click="submitWork" type="primary">提交推荐任务</el-button> <el-button @click="submitWork" type="primary">提交推荐任务</el-button>
</span> </span>
</el-dialog> </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> <div>
<el-table stripe style="width: 100%" :data="recommend.records"> <el-table stripe style="width: 100%" :data="recommend.records">
<el-table-column prop="caseName" label="案例名称"></el-table-column> <el-table-column prop="caseName" label="案例名称"></el-table-column>
@@ -121,27 +131,27 @@ export default {
name: 'articleItems', name: 'articleItems',
data() { data() {
return { return {
excellent:false, excellent: false,
queryObj: { queryObj: {
pageIndex:1, pageIndex: 1,
pageSize:10, pageSize: 10,
isTop:'', isTop: '',
excellent:'', excellent: '',
}, //查询对象 }, //查询对象
caseList: [], //案例列表 caseList: [], //案例列表
count:0, count: 0,
recommend: { recommend: {
dlgShow: false, dlgShow: false,
records: [] records: []
}, },
shareInfo:{ shareInfo: {
name:'', name: '',
load:false, load: false,
list:[] list: []
}, },
shareShow: false, shareShow: false,
shareUsers:[], shareUsers: [],
shareItemData:{}, shareItemData: {},
timeout: null, timeout: null,
params: { name: '', type: '' }, params: { name: '', type: '' },
typeList: [], typeList: [],
@@ -163,66 +173,81 @@ export default {
this.getData(); this.getData();
}, },
methods: { 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(){ // getSearch(){
// this.queryObj.excellent = !this.queryObj.excellent; // this.queryObj.excellent = !this.queryObj.excellent;
// this.getData(); // this.getData();
// }, // },
cancal(item){ cancal(item) {
this.$confirm('是否取消该案例为优秀案例?', '提示', { this.$confirm('确定要取消设置为最佳案例?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
this.excellent = false; this.excellent = false;
let data = { let data = {
id:item.id, id: item.id,
excellent:this.excellent excellent: this.excellent
}
console.log(data)
apiCase.excellent(data).then(res => {
if (res.status == 200) {
this.$message({
type: 'success',
message: '取消成功!'
});
this.getData()
} }
console.log(data) })
apiCase.excellent(data).then(res => { }).catch(() => {
if(res.status == 200){ this.$message({
this.$message({ type: 'info',
type: 'success', message: '已撤回取消推荐'
message: '取消成功!'
});
this.getData()
}
})
}).catch(() => {
this.$message({
type: 'info',
message: '已撤回取消推荐'
});
}); });
});
}, },
open(item) { open(item) {
this.$confirm('是否设置此案例为优秀案例吗?', '提示', { this.$confirm('你确认要设置为最佳案例吗?', '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
this.excellent = true; this.excellent = true;
let data = { let data = {
id:item.id, id: item.id,
excellent:this.excellent excellent: this.excellent
}
console.log(data)
apiCase.excellent(data).then(res => {
if (res.status == 200) {
this.$message({
type: 'success',
message: '设置最佳案例成功!'
});
this.getData()
} }
console.log(data) })
apiCase.excellent(data).then(res => { }).catch(() => {
if(res.status == 200){ this.$message({
this.$message({ type: 'info',
type: 'success', message: '已取消优秀案例设置'
message: '设置优秀案例成功!'
});
this.getData()
}
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消优秀案例设置'
});
}); });
}, });
},
inputOn() { inputOn() {
this.$forceUpdate(); this.$forceUpdate();
}, },
@@ -235,20 +260,20 @@ export default {
}, },
//获取案例列表数据 //获取案例列表数据
getData(num) { getData(num) {
if(num === 1) { if (num === 1) {
this.queryObj.pageIndex = 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 => { apiCase.isTopList(this.queryObj).then(res => {
if (res.status == 200) { if (res.status == 200) {
this.count=res.result.count this.count = res.result.count
this.caseList = res.result.list; this.caseList = res.result.list;
} else { } else {
this.$message({type: 'error', message: '查询数据失败'}); this.$message({ type: 'error', message: '查询数据失败' });
} }
}) })
.catch(err => { .catch(err => {
this.$message({ this.$message({
type: 'error', type: 'error',
@@ -257,54 +282,69 @@ export default {
}); });
}, },
handleSizeChange(val) { handleSizeChange(val) {
this.queryObj.pageSize=val; this.queryObj.pageSize = val;
this.getData(1); this.getData(1);
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
this.queryObj.pageIndex=val; this.queryObj.pageIndex = val;
this.getData(); this.getData();
}, },
//暂时因为没数据,先做添加 //暂时因为没数据,先做添加
showRecords() { showRecords() {
this.recommend.dlgShow = true; this.recommend.dlgShow = true;
apiCase.query().then(res=>{ apiCase.query().then(res => {
if(res.status==200){ if (res.status == 200) {
this.recommend.records=res.result this.recommend.records = res.result
} }
}).catch(err=>{ }).catch(err => {
this.$message({ this.$message({
type:'error', type: 'error',
message:'获取数据失败' message: '获取数据失败'
}) })
}) })
}, },
setTop(item) { setTop(item) {
let msg,isTop; let msg, isTop, btnMsg;
if (item.isTop==1) { if (item.isTop == 1) {
msg = '取消置顶'; msg = '确认要取消置顶此案例吗?';
isTop=0 btnMsg = "取消成功"
isTop = 0
} else { } else {
msg = '置顶成功'; msg = '你确认要置顶此案例吗?';
isTop=1 btnMsg = "设置置顶成功"
isTop = 1
} }
apiCase.updateTop(item.id,isTop).then(res=>{ this.$confirm(msg, '删除提示', {
if(res.status==200){
this.$message.success(msg);
this.getData()
}else{
this.$message.error("操作失败")
}
})
},
delItem(item) {
this.$confirm('您确定要删除所选内容吗?', '删除提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
type: 'warning' type: 'warning'
}) })
.then(() => { .then(() => {
apiCase.del(item.id).then(res=>{ apiCase.updateTop(item.id, isTop).then(res => {
if(res.status==200){ if (res.status == 200) {
this.$message({
type: 'success',
message: btnMsg
});
this.getData()
} else {
this.$message.error("操作失败")
}
})
})
.catch(() => {
this.$message({ type: 'info', message: '取消操作', offset: 50 });
});
},
delItem(item) {
this.$confirm('您确定要删除这条案例吗?', '删除提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
})
.then(() => {
apiCase.del(item.id).then(res => {
if (res.status == 200) {
this.$message.success("删除成功"); this.$message.success("删除成功");
this.getData() this.getData()
} }
@@ -316,67 +356,67 @@ export default {
}, },
//添加推荐 //添加推荐
shareItem(item) { shareItem(item) {
this.shareItemData={...item} this.shareItemData = { ...item }
this.shareShow = true; this.shareShow = true;
}, },
submitWork(){ submitWork() {
if(this.shareUsers.length==0){ if (this.shareUsers.length == 0) {
this.$message.error('请选择分享人'); this.$message.error('请选择分享人');
return; return;
} }
let {title,recommentThat,id}=this.shareItemData let { title, recommentThat, id } = this.shareItemData
let {aid:acceptAid}=this.shareInfo.list[0] let { aid: acceptAid } = this.shareInfo.list[0]
let queryData={ let queryData = {
title,recommentThat,acceptAid,id title, recommentThat, acceptAid, id
} }
//暂时只针对个人分享,所以暂时只传一条,没有传数组 //暂时只针对个人分享,所以暂时只传一条,没有传数组
apiCase.savaRecommend(queryData).then(res=>{ apiCase.savaRecommend(queryData).then(res => {
if(res.status==200){ if (res.status == 200) {
this.$message.success("分享成功") this.$message.success("分享成功")
this.shareShow = false; this.shareShow = false;
}else{ } else {
this.$message.error("分享失败") this.$message.error("分享失败")
} }
}).catch(err=>{ }).catch(err => {
this.$message.error("分享失败") this.$message.error("分享失败")
}) })
// let {id,title,acceptAid,recommentThat}=item // let {id,title,acceptAid,recommentThat}=item
// apiCase.savaRecommend() // apiCase.savaRecommend()
}, },
keyupEnter(){ keyupEnter() {
this.findUser(); this.findUser();
return false; return false;
}, },
findUser(){ findUser() {
this.shareInfo.load=false; this.shareInfo.load = false;
this.shareInfo.list=[]; this.shareInfo.list = [];
this.shareUsers=[]; this.shareUsers = [];
var name=this.shareInfo.name; var name = this.shareInfo.name;
var regPos = /^\d+(\.\d+)?$/; //非负浮点数 var regPos = /^\d+(\.\d+)?$/; //非负浮点数
if(regPos.test(name)){ if (regPos.test(name)) {
//console.log("数字"); //console.log("数字");
apiUser.getByLoginName(name).then(rs=>{ apiUser.getByLoginName(name).then(rs => {
if(rs.status==200){ if (rs.status == 200) {
//因为根据工号查询只会是一个人所有会有null情况而json会返回空字符串 //因为根据工号查询只会是一个人所有会有null情况而json会返回空字符串
if(rs.result!=''){ if (rs.result != '') {
this.shareInfo.list.push(rs.result); this.shareInfo.list.push(rs.result);
} }
this.shareInfo.load=true; this.shareInfo.load = true;
}else{ } else {
this.$message.error('查询用户失败'); this.$message.error('查询用户失败');
} }
}) })
}else{ } else {
// console.log("非数字"); // console.log("非数字");
apiUser.findByName(name).then(rs=>{ apiUser.findByName(name).then(rs => {
if(rs.status==200){ if (rs.status == 200) {
this.shareInfo.list=rs.result; this.shareInfo.list = rs.result;
this.shareInfo.load=true; this.shareInfo.load = true;
}else{ } else {
this.$message.error('查询用户失败'); this.$message.error('查询用户失败');
} }
}) })
} }
}, },
setEssence(item, idx) { setEssence(item, idx) {
@@ -415,12 +455,12 @@ export default {
}; };
}, },
viewTopic(data) { viewTopic(data) {
if(data.confidentialityLevel=='内部'){ if (data.confidentialityLevel == '内部') {
this.$router.push({path:'/case/detail',query:{id:data.id}}) this.$router.push({ path: '/case/detail', query: { id: data.id } })
}else{ } else {
this.$message.warning("非内部密级案例不能查看"); this.$message.warning("非内部密级案例不能查看");
} }
} }
} }
}; };
@@ -432,16 +472,19 @@ export default {
border: 1px dotted #1ea0fa; border: 1px dotted #1ea0fa;
color: #1ea0fa; color: #1ea0fa;
} }
.article-status2 { .article-status2 {
padding: 3px; padding: 3px;
border: 1px dotted #00aa00; border: 1px dotted #00aa00;
color: #00aa00; color: #00aa00;
} }
.article-status3 { .article-status3 {
padding: 3px; padding: 3px;
border: 1px dotted #ff0000; border: 1px dotted #ff0000;
color: #ff0000; color: #ff0000;
} }
.article-list { .article-list {
margin: 5px 0; margin: 5px 0;
border: 1px solid #dddddd; border: 1px solid #dddddd;
@@ -454,6 +497,7 @@ export default {
font-weight: 400; font-weight: 400;
height: 40px; height: 40px;
line-height: 40px; line-height: 40px;
.article-info-date { .article-info-date {
width: 150px; width: 150px;
height: 40px; height: 40px;
@@ -461,21 +505,26 @@ export default {
float: right; float: right;
font-weight: 200; font-weight: 200;
color: #999999; color: #999999;
i { i {
margin-right: 5px; margin-right: 5px;
} }
} }
} }
.article-info-summary { .article-info-summary {
height: 65px; height: 65px;
color: #999999; color: #999999;
} }
.article-info-tools { .article-info-tools {
height: 30px; height: 30px;
.article-info-tools-auth { .article-info-tools-auth {
float: left; float: left;
font-size: 13px; font-size: 13px;
color: #999999; color: #999999;
img { img {
margin-right: 10px; margin-right: 10px;
width: 30px; width: 30px;
@@ -484,14 +533,17 @@ export default {
vertical-align: middle; vertical-align: middle;
} }
} }
.article-info-tools-btns { .article-info-tools-btns {
float: right; float: right;
.article-info-tools-btn { .article-info-tools-btn {
margin: 0 0 0 15px; margin: 0 0 0 15px;
} }
} }
} }
} }
.case-row-btn { .case-row-btn {
line-height: 25px; line-height: 25px;
@@ -500,8 +552,9 @@ export default {
padding: 3px 20px; padding: 3px 20px;
} }
} }
.el-form{
.el-form-item{ .el-form {
.el-form-item {
margin-bottom: 10px; margin-bottom: 10px;
} }
} }

View File

@@ -90,6 +90,11 @@
<span v-if="scope.row.sysType3 !=''">/{{sysTypeName(scope.row.sysType3)}}</span> <span v-if="scope.row.sysType3 !=''">/{{sysTypeName(scope.row.sysType3)}}</span>
</template> </template>
</el-table-column> </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"> <!-- <el-table-column label="资源归属" sortable prop="author" width="240px">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{resOwnerName(scope.row.resOwner1)}}</span> <span>{{resOwnerName(scope.row.resOwner1)}}</span>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

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

File diff suppressed because it is too large Load Diff

View File

@@ -17,15 +17,16 @@
</el-radio-group> --> </el-radio-group> -->
</div> </div>
<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> <el-button class="navbut" type="text" @click="delChooseList">删除所选</el-button>
</div> </div>
</div> </div>
<div style="background-color: #FFFFFF;min-height: 600px;"> <div style="background-color: #FFFFFF;min-height: 600px;">
<p style="line-height:30px;text-align: center;">{{showMessage}}</p> <p style="line-height:30px;text-align: center;">{{ showMessage }}</p>
<!-- 临时增加上线一段时间后删除 开始 <!-- 临时增加上线一段时间后删除 开始
<div class="msg-list"> <div class="msg-list">
<a href="javascript:void(0);"> <a href="javascript:void(0);">
<div class="msg-top"> <div class="msg-top">
@@ -45,16 +46,16 @@
<div class="msg-list"> <div class="msg-list">
<a href="javascript:void(0);"> <a href="javascript:void(0);">
<div class="msg-top"> <div class="msg-top">
<div> <div>
<span style="padding-right: 10px;"><el-checkbox disabled></el-checkbox></span> <span style="padding-right: 10px;"><el-checkbox disabled></el-checkbox></span>
<span @click="showMsgDg()">系统消息</span> <span @click="showMsgDg()">系统消息</span>
</div>
</div> </div>
</div> <div class="msg-body" @click="dialogMsgVisible = true">
<div class="msg-body" @click="dialogMsgVisible=true"> <div class="msg-body-content">新功能说明</div>
<div class="msg-body-content">新功能说明</div> </div>
</div> <div class="msg-time">2022-12-30 11:23:33</div>
<div class="msg-time">2022-12-30 11:23:33</div>
</a> </a>
</div> </div>
@@ -78,40 +79,43 @@
<div class="msg-list" v-for="(item, index) in data" :key="index"> <div class="msg-list" v-for="(item, index) in data" :key="index">
<div class="msg-top"> <div class="msg-top">
<div> <div>
<span style="padding-right: 10px;"><el-checkbox v-model="item.checked" @change="setCheckAll(item)"></el-checkbox></span> <span style="padding-right: 10px;"><el-checkbox v-model="item.checked"
<span v-if="!item.isRead" style="font-size:12px;padding:5px 7px; border-radius: 2px;background: #FF6562;color: #fff;margin-right: 5px">未读</span> @change="setCheckAll(item)"></el-checkbox></span>
<span v-else style="font-size:14px;padding:5px 7px; background: #eee; border-radius: 2px; color: #666666;margin-right: 5px">已读</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)"> --> <!-- <a :href="returnRouter(item)"> -->
<span style="cursor: pointer;" @click="returnRouter(item)">{{ item.title }}</span> <span style="cursor: pointer;" @click="returnRouter(item)">{{ item.title }}</span>
</div> </div>
</div> </div>
<div class="msg-body"> <div class="msg-body">
<!-- <a :href="returnRouter(item)"> --> <!-- <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 v-if="item.refType !== '99'">
<div style="cursor: pointer;" @click="returnRouter(item)" class="msg-body-content" v-else>{{item.tip}}</div> <div style="cursor: pointer;" @click="returnRouter(item)" class="msg-body-content" v-if="item.content">
<!-- </a> --> {{ item.tip }}-{{ item.content }}</div>
<div class="msg-body-but"> <div style="cursor: pointer;" @click="returnRouter(item)" class="msg-body-content" v-else>{{ item.tip }}
<el-button type="danger" plain @click="delItem(item)">删除</el-button> </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 v-if="item.refType !== '99'" class="msg-body-but">
<el-button type="danger" plain @click="delItem(item)">删除</el-button>
</div> </div>
</div> </div>
<div class="msg-time">{{ item.msgTime }}</div> <div class="msg-time">{{ item.msgTime }}</div>
</div> </div>
</div> </div>
<div style="text-align: center;margin-top: 50px" v-if="total > queryData.pageSize"> <div style="text-align: center;margin-top: 50px" v-if="total > queryData.pageSize">
<el-pagination <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
@size-change="handleSizeChange" :current-page="queryData.pageIndex" :page-sizes="[2, 4, 6, 8]" :page-size="queryData.pageSize"
@current-change="handleCurrentChange" layout="total, sizes, prev, pager, next, jumper" :total="total"></el-pagination>
: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>
<!-- <div class="pagination-div" v-if="queryData.pageIndex < totalPages"><span class="pag-text" @click="loadMore()">加载更多</span></div> --> <!-- <div class="pagination-div" v-if="queryData.pageIndex < totalPages"><span class="pag-text" @click="loadMore()">加载更多</span></div> -->
</div> </div>
@@ -122,21 +126,21 @@
<!-- 对话框 --> <!-- 对话框 -->
<el-dialog :visible.sync="dialogMsgVisible" title="新功能说明" width="30%" append-to-body> <el-dialog :visible.sync="dialogMsgVisible" title="新功能说明" width="30%" append-to-body>
<div> <div>
教师端<br/> 教师端<br />
1支持个人授课记录/案例记录查询<br/> 1支持个人授课记录/案例记录查询<br />
2支持个人修改/完善教师介绍并在个人主页中展示<br/> 2支持个人修改/完善教师介绍并在个人主页中展示<br />
<br/> <br />
<br/> <br />
管理员端<br/> 管理员端<br />
1新增学习路径图功能<br/> 1新增学习路径图功能<br />
2新增学习项目功能<br/> 2新增学习项目功能<br />
3新增课程库功能<br/> 3新增课程库功能<br />
4升级案例管理设置优秀案例等<br/> 4升级案例管理设置优秀案例等<br />
5升级考试功能试题及提干支持图片修改已发布考试的部分信息等)<br/> 5升级考试功能试题及提干支持图片修改已发布考试的部分信息等)<br />
6课件支持 Scorm 格式<br/> 6课件支持 Scorm 格式<br />
及上述功能配套的学员端功能<br/> 及上述功能配套的学员端功能<br />
<br/> <br />
<br/> <br />
我们会在1月份提供线上操作培训及详细的使用手册便于大家熟悉和使用新增功能 我们会在1月份提供线上操作培训及详细的使用手册便于大家熟悉和使用新增功能
</div> </div>
<template #footer> <template #footer>
@@ -147,13 +151,6 @@
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
<script> <script>
@@ -162,6 +159,7 @@ import portalHeader from '@/components/PortalHeader.vue';
import portalFooter from '@/components/PortalFooter.vue'; import portalFooter from '@/components/PortalFooter.vue';
import GuideBox from '@/components/Portal/guideBox.vue' import GuideBox from '@/components/Portal/guideBox.vue'
import apiMessage from '@/api/system/message.js'; import apiMessage from '@/api/system/message.js';
import apiCase from '@/api/modules/cases.js';
export default { export default {
name: 'answer', name: 'answer',
components: { components: {
@@ -174,21 +172,21 @@ export default {
}, },
data() { data() {
return { return {
dialogMsgVisible:false, dialogMsgVisible: false,
queryData: { queryData: {
pageIndex: 1, pageIndex: 1,
pageSize: 6, pageSize: 6,
isRead: null isRead: null
}, },
disabledReadAll:false, disabledReadAll: false,
total: 0, total: 0,
checkAll: false, checkAll: false,
data: [], data: [],
totalPages: '', totalPages: '',
checkedIds:[], checkedIds: [],
isIndeterminate: false, isIndeterminate: false,
url: '', url: '',
showMessage:'暂无消息' showMessage: '暂无消息'
}; };
}, },
mounted() { mounted() {
@@ -209,10 +207,10 @@ export default {
this.isReadChooseList(); this.isReadChooseList();
}, },
methods: { methods: {
showMsgDg(){ showMsgDg() {
this.dialogMsgVisible = true; this.dialogMsgVisible = true;
}, },
jumResearch(){ jumResearch() {
this.$router.push('/user/research'); this.$router.push('/user/research');
// return this.webBaseUrl + '/src/views/user/myResearch.vue'; // return this.webBaseUrl + '/src/views/user/myResearch.vue';
}, },
@@ -223,27 +221,27 @@ export default {
this.checkAll = false; this.checkAll = false;
this.isIndeterminate = false; this.isIndeterminate = false;
} }
this.disabledReadAll=false; this.disabledReadAll = false;
apiMessage.list(this.queryData).then(res => { apiMessage.list(this.queryData).then(res => {
if (res.status == 200) { if (res.status == 200) {
this.totalPages = res.result.totalPages; this.totalPages = res.result.totalPages;
this.total = res.result.count; this.total = res.result.count;
let allRead=true; let allRead = true;
res.result.list.forEach(item => { res.result.list.forEach(item => {
let name = this.filterContent(item.content); let name = this.filterContent(item.content);
let num = name.slice(1,name.length); let num = name.slice(1, name.length);
item.tip = name[0]; item.tip = name[0];
item.content = num.join('-'); item.content = num.join('-');
item.checked = false; item.checked = false;
if(!item.isRead){ if (!item.isRead) {
allRead=false; allRead = false;
} }
this.data.push(item); this.data.push(item);
}); });
if(allRead){ if (allRead) {
this.disabledReadAll=true; this.disabledReadAll = true;
} }
if(this.total == 0){this.showMessage = '暂无消息';} if (this.total == 0) { this.showMessage = '暂无消息'; }
this.showMessage = this.total <= 0 ? '暂无消息' : ''; this.showMessage = this.total <= 0 ? '暂无消息' : '';
} else { } else {
this.$message.error('获取数据失败'); this.$message.error('获取数据失败');
@@ -275,9 +273,9 @@ export default {
// } // }
// }, // },
setCheckAll(item) { setCheckAll(item) {
if(item.checked){ if (item.checked) {
this.checkedIds.push(item.id); this.checkedIds.push(item.id);
}else{ } else {
let obj = this.checkedIds.indexOf(item.id); let obj = this.checkedIds.indexOf(item.id);
this.checkedIds.splice(obj, 1) this.checkedIds.splice(obj, 1)
} }
@@ -293,6 +291,7 @@ export default {
this.checkAll = item.checked; this.checkAll = item.checked;
} }
}, },
//改变已读状态的操作 //改变已读状态的操作
isReadChooseList() { isReadChooseList() {
if (this.data.length == 0) return; if (this.data.length == 0) return;
@@ -302,8 +301,8 @@ export default {
ids.push(this.data[i].id); ids.push(this.data[i].id);
} }
} }
if(this.checkedIds.length>0){ if (this.checkedIds.length > 0) {
apiMessage.updateIsRead(this.checkedIds).then(res => { apiMessage.updateIsRead(this.checkedIds).then(res => {
if (res.status == 200) { if (res.status == 200) {
this.$store.dispatch('refrashMsg'); this.$store.dispatch('refrashMsg');
this.queryMessage(true) this.queryMessage(true)
@@ -313,7 +312,7 @@ export default {
return; return;
} }
if(this.checkAll){ if (this.checkAll) {
apiMessage.updateIsRead(ids).then(res => { apiMessage.updateIsRead(ids).then(res => {
if (res.status == 200) { if (res.status == 200) {
this.$store.dispatch('refrashMsg'); this.$store.dispatch('refrashMsg');
@@ -324,11 +323,17 @@ export default {
} }
}, },
delChooseList() { 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); let list = this.data.filter(item => item.checked).map(v => v.id);
if (list.length == 0) { if (list.length == 0) {
this.$message.error('请先选择要删除的消息'); this.$message.error('请先选择要删除的消息');
return; return;
} }
this.$confirm('您确定要删除所选消息吗?', '删除提示', { this.$confirm('您确定要删除所选消息吗?', '删除提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
@@ -367,42 +372,59 @@ export default {
}, },
// 弹出新功能引导页弹窗事件(临时) // 弹出新功能引导页弹窗事件(临时)
showGuideDialog(){ showGuideDialog() {
this.$refs.guide.guideCollection = true; 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 // 跳转详情事件11
returnRouter(item) { returnRouter(item) {
apiMessage.updateIsRead([item.id]).then(res => { apiMessage.updateIsRead([item.id]).then(res => {
if (res.status == 200) { if (res.status == 200) {
this.$store.dispatch('refrashMsg'); this.$store.dispatch('refrashMsg');
// this.queryMessage(true) // this.queryMessage(true)
item.isRead = true; item.isRead = true;
} }
}); });
if(item.pageUrl && item.pageUrl.length>10){ if (item.pageUrl && item.pageUrl.length > 10) {
location.href = item.pageUrl; location.href = item.pageUrl;
}else{ } else {
if(item.pageType && item.pageParams){ if (item.pageType && item.pageParams) {
if(item.pageType==1){ if (item.pageType == 1) {
this.$router.push('/course/studyindex?id='+ item.pageParams); this.$router.push('/course/studyindex?id=' + item.pageParams);
}else if(item.pageType==2){ } else if (item.pageType == 2) {
this.$router.push('/article/detail?id='+ item.pageParams); this.$router.push('/article/detail?id=' + item.pageParams);
}else if(item.pageType==3){ } else if (item.pageType == 3) {
this.$router.push('/case/detail?id='+ item.pageParams); this.$router.push('/case/detail?id=' + item.pageParams);
}else if(item.pageType==4){ } else if (item.pageType == 4) {
this.$router.push('/qa/answer?id='+ item.pageParams); this.$router.push('/qa/answer?id=' + item.pageParams);
} }
}else{ } else {
if (item.refType == 2) { if (item.refType == 2) {
this.$router.push('/article/detail?id='+ item.refId); this.$router.push('/article/detail?id=' + item.refId);
}else if(item.refType==3){ } else if (item.refType == 3) {
this.$router.push('/case/detail?id='+ item.refId); this.$router.push('/case/detail?id=' + item.refId);
}else if (item.refType == 4||item.refType == 5) { } else if (item.refType == 4 || item.refType == 5) {
this.$router.push('/qa/answer?id='+ item.refId); this.$router.push('/qa/answer?id=' + item.refId);
} else if (item.refType == 1){ } else if (item.refType == 1) {
this.$router.push('/course/studyindex?id='+ item.refId); this.$router.push('/course/studyindex?id=' + item.refId);
} }
} }
} }
@@ -413,7 +435,11 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.navbut{ .infoActive {
color: #0078FC !important;
}
.navbut {
width: 110px; width: 110px;
height: 30px; height: 30px;
border-radius: 2px; border-radius: 2px;
@@ -421,8 +447,9 @@ export default {
text-align: center; text-align: center;
border: 1px solid #0078FC; border: 1px solid #0078FC;
padding: 0; padding: 0;
color: #0078FC ; color: #0078FC;
} }
.msg-nav { .msg-nav {
display: flex; display: flex;
// justify-content: space-between; // justify-content: space-between;
@@ -431,62 +458,72 @@ export default {
background-color: #ffffff; background-color: #ffffff;
padding: 5px 10px; padding: 5px 10px;
} }
.msg-list { .msg-list {
border-bottom: 1px solid rgb(237, 237, 237); border-bottom: 1px solid rgb(237, 237, 237);
margin-top: 10px; margin-top: 10px;
line-height: 26px; line-height: 26px;
background-color: #ffffff; background-color: #ffffff;
padding: 5px 10px; padding: 5px 10px;
&:first-of-type { &:first-of-type {
padding-top: 15px; padding-top: 15px;
} }
.msg-top { .msg-top {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
line-height: 30px; line-height: 30px;
} }
.msg-body { .msg-body {
padding: 10px 10px 10px 25px; padding: 10px 10px 10px 25px;
display: flex; display: flex;
width: 100%; width: 100%;
.msg-body-content{
.msg-body-content {
flex: 1; flex: 1;
word-break:break-all; word-break: break-all;
color: #727272; color: #727272;
a:hover { a:hover {
color: #409eff; color: #409eff;
} }
} }
.msg-body-but{
.msg-body-but {
margin-left: auto; margin-left: auto;
button{ button {
width: 88px; width: 88px;
height: 32px; height: 32px;
background-color: #fff; background-color: #fff;
border-radius: 16px; border-radius: 16px;
padding: 0; padding: 0;
color: #F52F3E; color: #F52F3E;
line-height: 32px; line-height: 32px;
text-align: center; text-align: center;
border: 1px solid #F52F3E; border: 1px solid #F52F3E;
} }
button:hover{
background-color: rgba(255,101,98,0.13); button:hover {
color: #F52F3E; background-color: rgba(255, 101, 98, 0.13);
color: #F52F3E;
} }
} }
} }
.msg-time { .msg-time {
color: #a5a5a5; color: #a5a5a5;
font-size: 14px; font-size: 14px;
padding-left: 25px; padding-left: 25px;
} }
} }
.messageList { .messageList {
> p { >p {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
border-bottom: 1px solid rgb(219, 219, 219); border-bottom: 1px solid rgb(219, 219, 219);
@@ -494,9 +531,11 @@ export default {
margin: 0; margin: 0;
align-items: center; align-items: center;
} }
.messageItem:not(:first-child) { .messageItem:not(:first-child) {
padding-top: 10px; padding-top: 10px;
} }
.messageItem { .messageItem {
// width: 100%; // width: 100%;
padding-bottom: 10px; padding-bottom: 10px;
@@ -504,12 +543,15 @@ export default {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
.el-checkbox { .el-checkbox {
margin-right: 5px; margin-right: 5px;
} }
.el-button { .el-button {
margin-left: auto; margin-left: auto;
} }
// margin-bottom: 10px; // margin-bottom: 10px;
p { p {
margin: 0; margin: 0;
@@ -517,24 +559,29 @@ export default {
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
} }
p:first-of-type { p:first-of-type {
> span { >span {
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
align-items: center; align-items: center;
span:first-of-type { span:first-of-type {
font-size: 12px; font-size: 12px;
} }
} }
> span:last-of-type {
>span:last-of-type {
font-size: 14px; font-size: 14px;
color: #b7b7b7; color: #b7b7b7;
margin-left: 5px; margin-left: 5px;
} }
} }
p:last-of-type { p:last-of-type {
font-size: 14px; font-size: 14px;
text-indent: 3em; text-indent: 3em;
span:last-of-type { span:last-of-type {
font-size: 14px; font-size: 14px;
color: #b7b7b7; color: #b7b7b7;
@@ -542,6 +589,7 @@ export default {
} }
} }
} }
.pagination-div { .pagination-div {
cursor: pointer; cursor: pointer;
} }

View File

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