mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-11 03:46:44 +08:00
课程状态、在线课权限
This commit is contained in:
@@ -135,13 +135,14 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" width="180px" fixed="right">
|
||||
<template slot-scope="scope" class="btn-gl">
|
||||
<el-button type="text" size="mini" v-if="scope.row.status == 5 && !scope.row.published" @click="releaseData(scope.row)">发布</el-button>
|
||||
<el-button v-if="pageManage && scope.row.published" @click="showStudent(scope.row)" type="text" size="mini">学员</el-button>
|
||||
<el-button v-if="!forChoose && scope.row.published" @click="showManageStudy(scope.row)" type="text" size="mini">管理</el-button>
|
||||
<el-button v-if="!forChoose && scope.row.status == 2" @click="withdraw(scope.row)" type="text" size="mini">撤回</el-button>
|
||||
<el-button v-if="scope.row.status != 2" type="text" size="mini" @click="editCurriculum(scope.row)">编辑</el-button>
|
||||
<el-button v-if="(scope.row.status != 2 && !scope.row.published) || !scope.row.enabled" type="text" size="mini" @click="delItem(scope.row)">删除</el-button>
|
||||
<el-dropdown v-if="scope.row.published" type="text" size="mini" style="margin-left:10px">
|
||||
<!-- 20240621 修改scope.row.isPermission = fasle 时不展示操作按钮-->
|
||||
<el-button type="text" size="mini" v-if="scope.row.isPermission && scope.row.status == 5 && !scope.row.published" @click="releaseData(scope.row)">发布</el-button>
|
||||
<el-button v-if="scope.row.isPermission && pageManage && scope.row.published" @click="showStudent(scope.row)" type="text" size="mini">学员</el-button>
|
||||
<el-button v-if="scope.row.isPermission && !forChoose && scope.row.published" @click="showManageStudy(scope.row)" type="text" size="mini">管理</el-button>
|
||||
<el-button v-if="scope.row.isPermission && !forChoose && scope.row.status == 2" @click="withdraw(scope.row)" type="text" size="mini">撤回</el-button>
|
||||
<el-button v-if="scope.row.isPermission && scope.row.status != 2" type="text" size="mini" @click="editCurriculum(scope.row)">编辑</el-button>
|
||||
<el-button v-if="scope.row.isPermission && (scope.row.status != 2 && !scope.row.published) || scope.row.isPermission &&!scope.row.enabled" type="text" size="mini" @click="delItem(scope.row)">删除</el-button>
|
||||
<el-dropdown v-if="scope.row.isPermission && scope.row.published" type="text" size="mini" style="margin-left:10px">
|
||||
<el-button type="text" size="mini">更多<i class="el-icon-arrow-down el-icon--right"></i></el-button>
|
||||
<el-dropdown-menu slot="dropdown">
|
||||
<el-dropdown-item @click.native="copyCourse(scope.row)">复制</el-dropdown-item>
|
||||
@@ -294,6 +295,7 @@ import {courseType} from '../../utils/tools.js';
|
||||
import apiCourse from '../../api/modules/course.js';
|
||||
// import {resOwnerIndexName,sysTypeIndexName} from '@/utils/type.js';
|
||||
import { mapGetters,mapActions } from 'vuex';
|
||||
import apiUserbasic from "@/api/boe/userbasic.js"
|
||||
export default {
|
||||
name: 'manageCourse',
|
||||
components: {courseForm, manager, auditCourse1, auditCourse2,adminPage},
|
||||
@@ -302,6 +304,7 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
audiences: [],
|
||||
forChoose:false,
|
||||
pageManage:false,
|
||||
showDetails: false,
|
||||
@@ -384,6 +387,7 @@ export default {
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
this.getAudiences()
|
||||
let chooseFlag=this.$route.query.f;
|
||||
this.extendRefId=this.$route.query.refId;
|
||||
this.extendRefType=this.$route.query.refType;
|
||||
@@ -400,7 +404,7 @@ export default {
|
||||
}
|
||||
// this.getTree();
|
||||
// this.getTypeData();
|
||||
this.searchData();
|
||||
// this.searchData();
|
||||
this.getResOwnerTree().then(rs=>{
|
||||
this.resOwnerListMap=rs;
|
||||
});
|
||||
@@ -414,6 +418,14 @@ export default {
|
||||
|
||||
},
|
||||
methods: {
|
||||
getAudiences(){
|
||||
apiUserbasic.getInAudienceIds().then(res=>{
|
||||
if (res.status == 200) {
|
||||
this.audiences = res.result;
|
||||
}
|
||||
this.searchData();
|
||||
})
|
||||
},
|
||||
showStudent(row){
|
||||
//出现学员管理
|
||||
window.parent.openSelectStu(row);
|
||||
@@ -644,6 +656,16 @@ export default {
|
||||
this.params.sysType1 = this.sysTypeList[0];
|
||||
this.params.sysType2 = this.sysTypeList[1];
|
||||
this.params.sysType3 = this.sysTypeList[2];
|
||||
if(this.$route.query.courseIds) this.params.courseIds = this.$route.query.courseIds.split(',');
|
||||
if(this.$route.query.projectId) this.params.projectId = this.$route.query.projectId;
|
||||
if(this.audiences && this.audiences.length > 0){
|
||||
this.params.audiences = this.audiences.join(',');
|
||||
}
|
||||
if(this.pageManage){
|
||||
this.params.isCreateCourse = false
|
||||
}else{
|
||||
this.params.isCreateCourse = true
|
||||
}
|
||||
apiCourse.pageList(this.params).then(rs=>{
|
||||
if(rs.status==200){
|
||||
this.pageData = rs.result.list;
|
||||
|
||||
Reference in New Issue
Block a user