mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-09 10:56:44 +08:00
Merge branch 'teacher' of https://codeup.aliyun.com/6265f483e4166464dc2f9c14/boeu/portal into dev
# Conflicts: # .gitignore # src/components/Course/weikeContent.vue
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1 +1,2 @@
|
||||
node_modules
|
||||
node_modules
|
||||
|
||||
@@ -41,8 +41,8 @@ const teacherSystem = function(id) {
|
||||
teacher_id 教师id
|
||||
* } data 查询条件
|
||||
*/
|
||||
const teacherInfo = function(data) {
|
||||
return ajax.get('/b1/system/teacher/teacher-info',data);
|
||||
const teacherInfo = function(sysId) {
|
||||
return ajax.get('/b1/system/teacher/teacher-info?teacher_id='+sysId);
|
||||
}
|
||||
/**
|
||||
* 教师删除接口
|
||||
@@ -56,18 +56,90 @@ const teacherSystem = function(id) {
|
||||
/**
|
||||
* 教师启用禁用接口
|
||||
* @param {
|
||||
teacher_id
|
||||
teacher_id
|
||||
status 状态;0:临时;1:正式;2:停用
|
||||
* } 查询条件
|
||||
*/
|
||||
const updateStatus = function(data) {
|
||||
return ajax.postJson('/b1/system/teacher/update-status',data);
|
||||
}
|
||||
/**
|
||||
* 教师授课记录查询接口
|
||||
* @param {
|
||||
```json
|
||||
id // 教师id
|
||||
courseType // 课程类型:‘1,2’:面授,训练班;‘0’:在线班
|
||||
pageSize // 每页数据条数
|
||||
page // 返回第几页数据
|
||||
isPage // 是否分页:0分页返回,1:不分页直接返回全部
|
||||
```
|
||||
*/
|
||||
const getCourseScore = function(data) {
|
||||
return ajax.get(`/b1/system/teacher/course-score?id=${data.id}&courseType=${data.courseType}&pageSize=${data.pageSize}&page=${data.page}&isPage=${data.isPage}`);
|
||||
}
|
||||
/**
|
||||
* 内部讲师-授课资格 查询接口
|
||||
* @param {
|
||||
id // 教师id
|
||||
pageSize // 每页数据条数
|
||||
page // 返回第几页数据
|
||||
```}
|
||||
*/
|
||||
const getTeachingQualify = function(data) {
|
||||
return ajax.get(`/b1/system/teacher/teaching-qualify?id=${data.id}&pageSize=${data.pageSize}&page=${data.page}`);
|
||||
}
|
||||
/**
|
||||
* 内部讲师-未开班资源查询接口
|
||||
* @param {
|
||||
id // 教师id
|
||||
```
|
||||
*/
|
||||
const getCourseInfo = function(id) {
|
||||
return ajax.get('/b1/system/teacher/course-info?id='+id);
|
||||
}
|
||||
/**
|
||||
* 内部讲师-晋级过程查询接口
|
||||
* @param {
|
||||
id // 教师id
|
||||
```
|
||||
*/
|
||||
const teacherUpgradePrecess = function(id) {
|
||||
return ajax.get('/b1/system/teacher/teacher-upgrade-precess?id='+id);
|
||||
}
|
||||
/**
|
||||
* 内部讲师-修改模块讲师信息
|
||||
* @param {
|
||||
courseId // 课程id
|
||||
modId // 模块id
|
||||
teacherId // 教师id
|
||||
teachingTime // 授课时间
|
||||
*/
|
||||
const editModelTeacher = function(data) {
|
||||
return ajax.postJson('/b1/system/teacher/edit-model-teacher',data);
|
||||
}
|
||||
/**
|
||||
* 内部讲师-删除模块讲师接口
|
||||
* @param {
|
||||
courseId // 课程id
|
||||
modId // 模块id
|
||||
teacherId // 教师id
|
||||
remark // 备注
|
||||
*/
|
||||
const deleteModelTeacher = function(data) {
|
||||
return ajax.postJson('/b1/system/teacher/delete-model-teacher',data);
|
||||
}
|
||||
|
||||
|
||||
export default {
|
||||
editTeacher,
|
||||
teacherSystem,
|
||||
teacherInfo,
|
||||
deleteTeacher,
|
||||
updateStatus
|
||||
}
|
||||
updateStatus,
|
||||
getCourseScore,
|
||||
getTeachingQualify,
|
||||
getCourseInfo,
|
||||
teacherUpgradePrecess,
|
||||
deleteModelTeacher,
|
||||
editModelTeacher
|
||||
}
|
||||
|
||||
@@ -173,6 +173,17 @@ const end=function(id){
|
||||
const exports=function(query){
|
||||
return ajax.post('/xboe/teacher/export',query);
|
||||
}
|
||||
|
||||
/**
|
||||
* courseType // 课程类型:‘1,2’:面授,训练班;‘0’:在线班
|
||||
* sysId:教师的sysId
|
||||
* tid: 教师的id
|
||||
* @param {tid,sysId,countType,pageSize:100,pageIndex} query
|
||||
*/
|
||||
const findAllCourses=function(query){
|
||||
return ajax.post('/xboe/teacher/compose/find/courses',query);
|
||||
}
|
||||
|
||||
export default {
|
||||
findByName,
|
||||
getInfoById,
|
||||
|
||||
@@ -134,7 +134,7 @@ export default {
|
||||
<style lang="scss" scoped>
|
||||
.one-line-ellipsis{
|
||||
display: -webkit-box;
|
||||
// white-space:pre-wrap;
|
||||
white-space:pre-wrap;
|
||||
word-wrap: break-word;
|
||||
word-break:break-all;
|
||||
overflow: hidden;
|
||||
|
||||
@@ -593,6 +593,7 @@
|
||||
setupTage:0,
|
||||
},
|
||||
},
|
||||
pdfTip:'',//pdf文件的提示
|
||||
hasCWare:{ keyword:'', count: 0, pageSize: 10, pageIndex: 1, list:[]},
|
||||
homework:{
|
||||
show:1,
|
||||
|
||||
@@ -73,10 +73,11 @@
|
||||
<span slot="title" class="textl">考试管理</span>
|
||||
</el-menu-item>
|
||||
</el-submenu>
|
||||
<!-- <el-menu-item index="/manage/teachers" v-show="curIdentity == 3">
|
||||
<!--增加一个说明-->
|
||||
<el-menu-item index="/manage/teachers" v-show="curIdentity == 3">
|
||||
<svg-icon icon-class="teather"></svg-icon>
|
||||
<span slot="title">教师管理</span>
|
||||
</el-menu-item> -->
|
||||
</el-menu-item>
|
||||
<!-- <el-menu-item index="/case/manage" v-show="curIdentity == 3">
|
||||
<svg-icon icon-class="case"></svg-icon>
|
||||
<span slot="title">案例管理</span>
|
||||
@@ -426,7 +427,7 @@ export default {
|
||||
height: 36px;
|
||||
}
|
||||
.oneheight{
|
||||
|
||||
|
||||
height: 36px;
|
||||
line-height: 36px;
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<el-select v-model="tSystemData" value-key="id" clearable @change="changeSystem" placeholder="请选择教师体系">
|
||||
<el-option v-for="item in systemData" :key="item.id" :label="item.name" :value="item"></el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 要在换一个变量与新建区别开 -->
|
||||
<div style="padding: 0px 5px;">
|
||||
<el-select v-model="tLevelData" clearable value-key="id" placeholder="请选择教师级别">
|
||||
@@ -31,10 +31,10 @@
|
||||
<el-table-column type="selection"></el-table-column>
|
||||
<el-table-column label="姓名" prop="name" fixed>
|
||||
<template slot-scope="scope">
|
||||
<span @click="handleName(scope.row)">{{scope.row.name}}</span>
|
||||
<span class="previewStyle" @click="handleName(scope.row)">{{scope.row.name}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
|
||||
<el-table-column label="部门" prop="departName"></el-table-column>
|
||||
<!-- <el-table-column label="创建时间" sortable prop="sysCreateTime"></el-table-column> -->
|
||||
<el-table-column label="修改时间" sortable width="155" prop="sysUpdateTime"></el-table-column>
|
||||
@@ -159,9 +159,9 @@
|
||||
:close-on-click-modal="false"
|
||||
:visible.sync="showTeacherDetails"
|
||||
width="800px">
|
||||
<teacher-details v-if="teacherDetailsId != ''" :id="teacherDetailsId"></teacher-details>
|
||||
<teacher-details v-if="teacherDetailsId != ''" :id="teacherDetailsId" :newId="teacherDetailId"></teacher-details>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="handleClose">取 消</el-button>
|
||||
<el-button @click="handleCloseOne()">取 消</el-button>
|
||||
<!-- <el-button type="primary" @click="showTeacherDetails = false">确 定</el-button> -->
|
||||
</span>
|
||||
</el-dialog>
|
||||
@@ -180,7 +180,8 @@
|
||||
components:{imageUpload,teacherDetails},
|
||||
data(){
|
||||
return {
|
||||
teacherDetailsId: '',
|
||||
teacherDetailId:'',//新数据id
|
||||
teacherDetailsId: '',// sid
|
||||
showTeacherDetails:false,
|
||||
tSystemData:{},
|
||||
tLevelData:{},
|
||||
@@ -255,14 +256,15 @@
|
||||
...mapGetters(['userInfo'])
|
||||
},
|
||||
methods:{
|
||||
handleClose() {
|
||||
console.log("1111");
|
||||
handleCloseOne() {
|
||||
// this.teacherDetailsId = '';
|
||||
this.showTeacherDetails = false;
|
||||
},
|
||||
handleName(row) {
|
||||
this.showTeacherDetails = true;
|
||||
this.teacherDetailsId = row.id;
|
||||
this.teacherDetailsId = row.sysId;
|
||||
this.teacherDetailId = row.id;
|
||||
// this.teacherDetailsId = '13BEBDBD-3D28-244D-648D-0CBD6796717C'
|
||||
},
|
||||
getTeachersystem() {
|
||||
teacherBoeApi.teacherSystem(this.userInfo.sysId).then(res=>{
|
||||
@@ -585,7 +587,7 @@
|
||||
eleForm.style="display:none;";
|
||||
eleForm.method='post';
|
||||
eleForm.action=`${process.env.VUE_APP_BASE_API}/xboe/teacher/export?name=${this.queryName}`;
|
||||
|
||||
|
||||
var hdnFilePath = document.createElement('input');
|
||||
hdnFilePath.type = 'hidden';
|
||||
hdnFilePath.name = 'ids';
|
||||
@@ -600,7 +602,7 @@
|
||||
eleLink.download = '教师授课信息';
|
||||
eleLink.style.display = 'none';
|
||||
eleLink.setAttribute('target', '_blank');
|
||||
eleLink.href = `${process.env.VUE_APP_BASE_API}/xboe/m/course/manage/export-teacher-course?teacherId=${row.id}`;
|
||||
eleLink.href = `${process.env.VUE_APP_BASE_API}/xboe/teacher/compose/export/courses?tid=${row.id}&sysId=${row.sysId}&courseType=0,1,2`;
|
||||
document.body.appendChild(eleLink);
|
||||
eleLink.click();
|
||||
document.body.removeChild(eleLink);
|
||||
|
||||
@@ -7,60 +7,62 @@
|
||||
<el-col :span="24">
|
||||
<el-form label-width="120px" size="mini">
|
||||
<el-form-item label="头像:">
|
||||
<div style="width: 90px;height: 90px" v-if="form.account.avatar == ''">
|
||||
<img style="width:100%;height:100%" v-if="form.gender == 1" :src="webBaseUrl + '/images/Avatarman.png'" alt="" srcset="">
|
||||
<div style="width: 90px;height: 90px" v-if="newForm && newForm.account && newForm.account.avatar == ''">
|
||||
<img style="width:100%;height:100%" v-if="newForm.gender == 1" :src="webBaseUrl + '/images/Avatarman.png'" alt="" srcset="">
|
||||
<img style="width:100%;height:100%" v-else :src="webBaseUrl + '/images/Avatarwoman.png'" alt="" srcset="">
|
||||
</div>
|
||||
<div style="width: 90px;height: 90px" v-else>
|
||||
<img style="width:100%;height:100%" :src="form.account.avatar" alt="" srcset="">
|
||||
<img style="width:100%;height:100%" :src="newForm && newForm.account && newForm.account.avatar" alt="" srcset="">
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item label="讲师账号:">
|
||||
<el-col :span="12">{{form.user.userNo}}</el-col>
|
||||
<el-col :span="12">{{newForm.user.userNo}}</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="讲师姓名:">{{form.user.name}}</el-form-item>
|
||||
<el-form-item label="讲师姓名:">{{newForm.user.name}}</el-form-item>
|
||||
</el-col>
|
||||
</el-form-item>
|
||||
<el-form-item label="讲师组织:" >
|
||||
<el-col :span="12">--</el-col>
|
||||
<el-col :span="12">{{form.company_name}}</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="初始授课时长:">12分账</el-form-item></el-col>
|
||||
<el-form-item label="初始授课时长:">{{formatSeconds(form.default_teaching_time)}}</el-form-item></el-col>
|
||||
</el-form-item>
|
||||
|
||||
|
||||
<el-form-item label="讲师体系:">
|
||||
<el-col :span="12">波ue</el-col>
|
||||
<el-col :span="12">{{form.system_name}}</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="讲师级别:">
|
||||
2级
|
||||
{{form.level_name}}
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form-item>
|
||||
<el-form-item label="总计授课时长:">
|
||||
<el-col :span="12">12分账</el-col>
|
||||
<el-col :span="12">{{formatSeconds(form.teaching_time)}}</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="认证状态:">
|
||||
未认证
|
||||
{{form.is_certify == 1? '已认证':'未认证'}}
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form-item>
|
||||
<el-form-item label="认证时间:">
|
||||
<el-col :span="12">--</el-col>
|
||||
<el-col :span="12">{{formatsec(form.certify_at *1000)}}</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="认证资料:"> --</el-form-item>
|
||||
<el-form-item label="认证资料:">
|
||||
<!-- <a href="http://" target="_blank" rel="noopener noreferrer"></a> -->
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-form-item>
|
||||
|
||||
|
||||
<el-form-item label="认证人:">
|
||||
<el-col :span="12">认证人</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="讲师介绍:">
|
||||
讲师介绍
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
|
||||
<!-- <el-form-item label="认证人:"> -->
|
||||
<!-- <el-col :span="12">--</el-col> -->
|
||||
<!-- <el-col :span="12"> -->
|
||||
<el-form-item label="讲师介绍:">
|
||||
<div v-html="form.description"></div>
|
||||
</el-form-item>
|
||||
<el-form-item label="讲师备注:">
|
||||
--
|
||||
<!-- </el-col>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="讲师备注:">
|
||||
{{form.remark}}
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-col>
|
||||
@@ -69,8 +71,8 @@
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="授课记录" name="second">
|
||||
<div style="display:flex">
|
||||
<div><el-button type="primary">导出授课记录</el-button></div>
|
||||
<div style="margin: 0 5px"><el-select v-model="value" placeholder="请选择" clearable >
|
||||
<!-- <div><el-button type="primary" @click="exportCourse()">导出授课记录</el-button></div> -->
|
||||
<div style="margin: 0 5px"><el-select v-model="records.courseType" placeholder="请选择" clearable @change="getCourseScore()">
|
||||
<el-option
|
||||
v-for="item in options"
|
||||
:key="item.value"
|
||||
@@ -79,143 +81,167 @@
|
||||
</el-option>
|
||||
</el-select></div>
|
||||
</div>
|
||||
<el-table
|
||||
:data="tableData"
|
||||
<el-table height="430"
|
||||
:data="records.list"
|
||||
style="width: 100%;margin-top:10px">
|
||||
<el-table-column
|
||||
prop="date"
|
||||
label="班级编号"
|
||||
width="180">
|
||||
prop="courseCode" width="120"
|
||||
label="班级编号">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="类型"
|
||||
width="180">
|
||||
prop="courseType"
|
||||
label="类型">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.courseType == '1'">面授班</span>
|
||||
<span v-if="scope.row.courseType == '2'">训练班</span>
|
||||
<span v-if="scope.row.courseType == '0'">在线班</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="班级名称">
|
||||
prop="courseName" show-overflow-tooltip
|
||||
label="班级名称" width="180">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="date"
|
||||
prop="modName" show-overflow-tooltip
|
||||
label="模块名称"
|
||||
width="180">
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="授课时长(min)"
|
||||
width="180">
|
||||
prop="teachingTime"
|
||||
label="授课时长(min)" width="120">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="开班时间">
|
||||
prop="openStartTime"
|
||||
label="开班时间" width="140">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
prop="courseStatus"
|
||||
label="班级状态"
|
||||
width="180">
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
prop="teacherScore"
|
||||
label="评分">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="操作"
|
||||
width="180">
|
||||
width="120">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" @click="update()">修改</el-button>
|
||||
<el-button type="text">删除</el-button>
|
||||
<el-button type="text" @click="recordsUpdate(scope.row)">修改</el-button>
|
||||
<el-button type="text" @click="recordsDel(scope.row)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- <div style="text-align:center;margin-top:20px">
|
||||
<el-pagination
|
||||
background
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
:current-page="records.page"
|
||||
:page-sizes="[10, 20, 30, 40]"
|
||||
:page-size="records.pageSize"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
:total="records.count">
|
||||
</el-pagination>
|
||||
</div> -->
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="授课资格" name="third">
|
||||
<el-table
|
||||
:data="tableData"
|
||||
<el-table height="430"
|
||||
:data="qualify.list"
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
prop="date"
|
||||
prop="courseCode"
|
||||
label="课程编号"
|
||||
width="180">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
prop="courseName" show-overflow-tooltip
|
||||
label="课程名称"
|
||||
width="180">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="班级名称">
|
||||
width="250">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="date"
|
||||
prop="dictionaryName"
|
||||
label="课程分类"
|
||||
width="180">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
prop="courseType"
|
||||
label="课程类型"
|
||||
width="180">
|
||||
width="100">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.courseType == '0'">在线班</span>
|
||||
<span v-if="scope.row.courseType == '1'">面授</span>
|
||||
<span v-if="scope.row.courseType == '2'">线下课</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!-- <div style="text-align:center;margin-top:20px">
|
||||
<el-pagination
|
||||
background
|
||||
@size-change="qualifySizeChange"
|
||||
@current-change="qualifyCurrentChange"
|
||||
:current-page="records.page"
|
||||
:page-sizes="[10, 20, 30, 40]"
|
||||
:page-size="records.pageSize"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
:total="records.count">
|
||||
</el-pagination>
|
||||
</div> -->
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="未开班资源" name="fourth">
|
||||
<el-table
|
||||
:data="tableData"
|
||||
<el-table height="430"
|
||||
:data="courseInfoList"
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
prop="date"
|
||||
prop="courseCode"
|
||||
label="班级编号"
|
||||
width="180">
|
||||
width="120">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
prop="courseName" show-overflow-tooltip
|
||||
label="班级名称"
|
||||
width="180">
|
||||
width="200">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
prop="modName" width="150" show-overflow-tooltip
|
||||
label="模块名称">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="date"
|
||||
prop="teachingTime"
|
||||
label="授课时长"
|
||||
width="180">
|
||||
width="100">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
prop="openStartTime"
|
||||
label="开班时间"
|
||||
width="180">
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="晋级过程" name="five">
|
||||
<el-table
|
||||
:data="tableData"
|
||||
<el-table height="370"
|
||||
:data="precessList"
|
||||
style="width: 100%">
|
||||
<el-table-column
|
||||
prop="date"
|
||||
prop="operatorTime"
|
||||
label="变更时间"
|
||||
width="180">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="变更方式"
|
||||
width="180">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="address"
|
||||
label="模块名称">
|
||||
prop="type"
|
||||
label="变更方式">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.type == '0'">手动</span>
|
||||
<span v-if="scope.row.type == '1'">自动</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="date"
|
||||
label="变更结果"
|
||||
width="180">
|
||||
prop="afterLevelName"
|
||||
label="变更结果">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="name"
|
||||
label="操作人"
|
||||
width="180">
|
||||
prop="operatorName"
|
||||
label="操作人">
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-tab-pane>
|
||||
@@ -225,22 +251,23 @@
|
||||
:visible.sync="dialogVisible"
|
||||
width="300px"
|
||||
top="20%"
|
||||
:modal="false"
|
||||
:before-close="handleClose">
|
||||
:modal="false">
|
||||
<div>请输入授课时长(分钟)</div>
|
||||
<div><el-input v-model="input" placeholder="请输入内容"></el-input></div>
|
||||
<div style="margin-top:20px"><el-input v-model="records.row.teachingTime" placeholder="请输入内容"></el-input></div>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogVisible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="dialogVisible = false">确 定</el-button>
|
||||
<el-button type="primary" @click="editModelTeacher()">确 定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import qs from 'qs'
|
||||
import teacherApi from "@/api/modules/teacher";
|
||||
import teacherBoeApi from "@/api/boe/teacher";
|
||||
import userApi from "@/api/system/user";
|
||||
import { formatSeconds,formatsec } from '@/utils/datetime.js'
|
||||
import imageUpload from "@/components/ImageUpload/index.vue";
|
||||
import { mapGetters } from "vuex";
|
||||
export default {
|
||||
@@ -249,14 +276,46 @@ export default {
|
||||
props: {
|
||||
id:{
|
||||
type: String,
|
||||
},
|
||||
newId:{
|
||||
type: String,
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
formatsec,
|
||||
formatSeconds,
|
||||
baseUrl: process.env.VUE_APP_BASE_API,
|
||||
newForm:{
|
||||
account:{},
|
||||
user:{},
|
||||
},
|
||||
dialogVisible:false,
|
||||
activeName: "first",
|
||||
value: "",
|
||||
options: [],
|
||||
options: [//‘1,2’:面授,训练班;‘0’:在线班
|
||||
{label:'录播',value:'0'},
|
||||
{label:'面授',value:'1'},
|
||||
{label:'线下课',value:'2'},
|
||||
],
|
||||
records:{// 授课记录
|
||||
courseType:'',
|
||||
// pageSize: 1,
|
||||
// page:5,
|
||||
count:0,
|
||||
list:[],
|
||||
row:{
|
||||
teachingTime:'',
|
||||
},
|
||||
},
|
||||
qualify:{//授课资格
|
||||
pageSize: 1,
|
||||
page:5,
|
||||
count:0,
|
||||
list:[]
|
||||
},
|
||||
courseInfoList: [],//未开班资源
|
||||
precessList:[],//晋级过程
|
||||
tableData: [],
|
||||
input:'',
|
||||
form:{
|
||||
@@ -266,26 +325,168 @@ export default {
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
console.log(this.id,'id');
|
||||
this.getDetail(this.id)
|
||||
this.getDetail(this.id);
|
||||
this.getAvatar();
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(["userInfo"])
|
||||
},
|
||||
methods: {
|
||||
update(row) {
|
||||
console.log(row,'row');
|
||||
getAvatar(){
|
||||
teacherApi.detail(this.newId).then(res => {
|
||||
if (res.status == 200) {
|
||||
// const result = res.result;
|
||||
this.newForm = res.result;
|
||||
if(res.result.account.avatar != '') {
|
||||
this.newForm.account.avatar = this.baseUrl + res.result.account.avatar;
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
exportCourse(row){
|
||||
var eleLink = document.createElement('a');
|
||||
eleLink.download = '教师授课信息';
|
||||
eleLink.style.display = 'none';
|
||||
eleLink.setAttribute('target', '_blank');
|
||||
eleLink.href = `${process.env.VUE_APP_BASE_API}/xboe/teacher/compose/export/courses?tid=${row.id}&sysId=${row.sysId}&courseType=0,1,3`;
|
||||
document.body.appendChild(eleLink);
|
||||
eleLink.click();
|
||||
document.body.removeChild(eleLink);
|
||||
},
|
||||
recordsDel(row) {
|
||||
this.$confirm('此操作将永久删除该记录, 是否继续?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
let data = {
|
||||
courseId:row.courseId, // 课程id
|
||||
modId:row.modId, // 模块id
|
||||
teacherId:row.teacherId, // 教师id
|
||||
remark:'', // 备注
|
||||
}
|
||||
teacherBoeApi.deleteModelTeacher(data).then(res=>{
|
||||
if(res.status == '200') {
|
||||
this.getCourseScore();
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '删除成功!'
|
||||
});
|
||||
} else {
|
||||
this.$message.error(res.message);
|
||||
}
|
||||
})
|
||||
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消删除'
|
||||
});
|
||||
});
|
||||
|
||||
},
|
||||
recordsUpdate(row) {
|
||||
this.records.row = row;
|
||||
this.dialogVisible = true;
|
||||
},
|
||||
handleClick() {},
|
||||
getDetail(id) {
|
||||
this.saveLoading = false;
|
||||
this.newOrEdit = "编辑教师";
|
||||
this.allowInput = true;
|
||||
teacherApi.detail(id).then(res => {
|
||||
handleClick(tab, event) {
|
||||
if(tab.name == 'second') {// 授课记录
|
||||
this.getCourseScore();
|
||||
} else if(tab.name == 'third') {// 授课资格
|
||||
this.getTeachingQualify();
|
||||
}else if(tab.name == 'fourth') {// 为开班资源
|
||||
this.getCourseInfo();
|
||||
}if(tab.name == 'five') {// 晋级过程
|
||||
this.teacherUpgradePrecess();
|
||||
}
|
||||
},
|
||||
// 晋级过程
|
||||
teacherUpgradePrecess() {
|
||||
teacherBoeApi.teacherUpgradePrecess(this.id).then(res=>{
|
||||
if(res.status == '200') {
|
||||
this.precessList = res.result.data;
|
||||
}
|
||||
})
|
||||
},
|
||||
// 未开班资源
|
||||
getCourseInfo() {
|
||||
teacherBoeApi.getCourseInfo(this.id).then(res=>{
|
||||
if(res.status == '200') {
|
||||
this.courseInfoList = res.result.data;
|
||||
}
|
||||
})
|
||||
},
|
||||
// 授课资格
|
||||
getTeachingQualify() {
|
||||
let data = {
|
||||
id:this.id, // 教师id
|
||||
pageSize:this.qualify.pageSize, // 每页数据条数
|
||||
page:this.qualify.page, // 返回第几页数据
|
||||
}
|
||||
teacherBoeApi.getTeachingQualify(data).then(res=>{
|
||||
if(res.status == '200') {
|
||||
this.qualify.list = res.result.data;
|
||||
}
|
||||
})
|
||||
},
|
||||
qualifySizeChange(val) {
|
||||
this.qualify.pageSize = val
|
||||
this.qualify.page = 1
|
||||
this.getTeachingQualify()
|
||||
},
|
||||
qualifyCurrentChange(val) {
|
||||
this.qualify.page = val
|
||||
this.getTeachingQualify()
|
||||
},
|
||||
editModelTeacher() {
|
||||
let data = {
|
||||
courseId:this.records.row.courseId, // 课程id
|
||||
modId:this.records.row.modId, // 模块id
|
||||
teacherId:this.records.row.teacherId, // 教师id
|
||||
teachingTime:this.records.row.teachingTime, // 授课时间
|
||||
}
|
||||
teacherBoeApi.editModelTeacher(data).then(res=>{
|
||||
if(res.status == '200') {
|
||||
this.$message.success('修改成功');
|
||||
this.dialogVisible = false;
|
||||
this.getCourseScore();
|
||||
} else {
|
||||
this.$message.error(res.message);
|
||||
}
|
||||
})
|
||||
},
|
||||
// 授课记录
|
||||
getCourseScore() {
|
||||
let data = {
|
||||
id:this.id,// 教师id
|
||||
courseType:this.records.courseType || '0,1,2', // 课程类型:‘1,2’:面授,训练班;‘0’:在线班
|
||||
// pageSize:this.records.pageSize, // 每页数据条数
|
||||
// page:this.records.page, // 返回第几页数据
|
||||
isPage:1, // 是否分页:0分页返回,1:不分页直接返回全部
|
||||
}
|
||||
teacherBoeApi.getCourseScore(data).then(res=>{
|
||||
if(res.status === '200') {
|
||||
this.records.list = res.result.data;
|
||||
|
||||
}
|
||||
})
|
||||
},
|
||||
handleSizeChange(val) {
|
||||
this.records.pageSize = val
|
||||
this.records.page = 1
|
||||
this.getCourseScore()
|
||||
},
|
||||
handleCurrentChange(val) {
|
||||
this.records.page = val
|
||||
this.getCourseScore()
|
||||
},
|
||||
getDetail() {
|
||||
teacherBoeApi.teacherInfo(this.id).then(res => {
|
||||
if (res.status == 200) {
|
||||
const result = res.result;
|
||||
this.form = result;
|
||||
} else {
|
||||
this.$message.error(res.message);
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -297,6 +498,8 @@ export default {
|
||||
.teacher-details {
|
||||
height: 500px;
|
||||
.one{
|
||||
height: 460px;
|
||||
overflow-y: auto;
|
||||
.el-form-item{
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
@@ -33,11 +33,11 @@
|
||||
:class="{ actice: articleList.order == 1 }">
|
||||
最新
|
||||
</el-button>
|
||||
|
||||
|
||||
</div>
|
||||
<span class="more"></span>
|
||||
</el-row>
|
||||
<div class="data-content">
|
||||
<div class="data-content" v-if="articleList.list.length > 0">
|
||||
<div :span="24" v-for="(article, aidx) in articleList.list" :key="aidx" class="article-list">
|
||||
<div class="article-info">
|
||||
<!--title-->
|
||||
@@ -77,7 +77,11 @@
|
||||
<div class="pagination-div">
|
||||
<span class="pag-text" @click="loadMore()" v-if="moreState == 1">加载更多</span>
|
||||
<span class="pag-text-msg" v-else-if="moreState == 2">数据加载中</span>
|
||||
<span class="pag-text-msg" v-else-if="moreState == 3">没有更多数据了</span>
|
||||
<span class="pag-text-msg" v-else-if="moreState == 3 && !isSeach">没有更多数据了</span>
|
||||
<span class="pag-text-msg" v-else-if="isSeach">没有查询到相关内容</span>
|
||||
</div>
|
||||
<div v-if="isSeach" style="height:382px">
|
||||
|
||||
</div>
|
||||
</el-card>
|
||||
</el-row>
|
||||
@@ -128,9 +132,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<el-row :gutter="10">
|
||||
|
||||
|
||||
<el-col :span="6" class="right-box" >
|
||||
|
||||
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
@@ -193,6 +197,7 @@ export default {
|
||||
ankingFixed:false,
|
||||
diagSync:false,//控制弹窗
|
||||
// articleList: []
|
||||
isSeach:false,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
@@ -200,7 +205,9 @@ export default {
|
||||
// this.ankingWidth=el_anking.clientWidth;
|
||||
//console.log(el_anking.clientWidth,'clientWidth');
|
||||
this.articleList.keyword = this.$route.query.keyword;
|
||||
|
||||
if(this.articleList.keyword != '') {
|
||||
this.isSeach = true;
|
||||
}
|
||||
this.getArticleList();
|
||||
this.getAnkingData();
|
||||
this.searchterm();
|
||||
@@ -217,6 +224,7 @@ export default {
|
||||
methods: {
|
||||
emitInput(val){
|
||||
this.articleList.keyword = val;
|
||||
this.isSeach =true;
|
||||
this.searchData();
|
||||
},
|
||||
saveSuccess(data){
|
||||
@@ -329,6 +337,7 @@ export default {
|
||||
// portalPageList接口换了,这是原来的
|
||||
apiArticle.findPortal(query).then(res => {
|
||||
if (res.status == 200 && res.result.list.length > 0) {
|
||||
this.isSeach =false;
|
||||
let ids = [];
|
||||
res.result.list.forEach(item => {
|
||||
item.authorInfo = { name: '', avatar: '', orgInfo: '' ,sex:null};
|
||||
@@ -583,7 +592,7 @@ export default {
|
||||
width: 100%;
|
||||
padding: 15px 0;
|
||||
}
|
||||
|
||||
|
||||
.ranking-data {
|
||||
margin: 10px 0;
|
||||
color: #999999;
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
</el-radio-group> -->
|
||||
</span>
|
||||
</el-row>
|
||||
<div class="data-content">
|
||||
<div class="data-content" v-if="qaList.length > 0">
|
||||
<div :span="24" v-for="(qa, qaidx) in qaList" :key="qaidx" class="qa-list">
|
||||
<div class="qa-info-box">
|
||||
<div class="qa-info">
|
||||
@@ -85,7 +85,11 @@
|
||||
<div class="pagination-div">
|
||||
<span class="pag-text" @click="loadMore()" v-if="moreState == 1">加载更多</span>
|
||||
<span class="pag-text-msg" v-else-if="moreState == 2">数据加载中</span>
|
||||
<span class="pag-text-msg" v-else-if="moreState == 3">没有更多数据了</span>
|
||||
<span class="pag-text-msg" v-else-if="moreState == 3 && !isSeach">没有更多数据了</span>
|
||||
<span class="pag-text-msg" v-else-if="isSeach">没有查询到相关内容</span>
|
||||
</div>
|
||||
<div v-if="isSeach" style="height:382px">
|
||||
|
||||
</div>
|
||||
</el-card>
|
||||
</el-row>
|
||||
@@ -215,12 +219,16 @@ export default {
|
||||
//以上是整理后的数据
|
||||
anking: 2, //排行榜
|
||||
ankingList: [],
|
||||
styleControl:2
|
||||
styleControl:2,
|
||||
isSeach:false,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
this.queryKeyWord = this.$route.query.keyword;
|
||||
this.queryConditions.keyword = this.queryKeyWord;
|
||||
if(this.queryConditions.keyword != '') {
|
||||
this.isSeach = true;
|
||||
}
|
||||
this.getQaData(true);
|
||||
this.getAnkingData();
|
||||
window.addEventListener("scroll", this.handleScroll);
|
||||
@@ -232,6 +240,7 @@ export default {
|
||||
methods: {
|
||||
emitInput(val){
|
||||
this.queryKeyWord = val;
|
||||
this.isSeach =true;
|
||||
this.search();
|
||||
},
|
||||
//发布回答
|
||||
@@ -373,6 +382,7 @@ export default {
|
||||
.potallist(this.queryConditions)
|
||||
.then(res => {
|
||||
if (res.status == 200 && res.result.list.length > 0) {
|
||||
this.isSeach = false;
|
||||
res.result.list.forEach(item => {
|
||||
item.authorInfo = { aid: '', name: '', orgInfo: '', avatar: '',sex:null, };
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user