mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-12 04:16:45 +08:00
还有一个教师组织回显问题
This commit is contained in:
@@ -34,7 +34,7 @@
|
|||||||
<el-button icon="el-icon-folder-opened" type="primary" @click="exportsExcel">导出</el-button>
|
<el-button icon="el-icon-folder-opened" type="primary" @click="exportsExcel">导出</el-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<el-table ref="teacherTable" style="100%" :data="tableData" border stripe @selection-change="handleSelectionChange">
|
<el-table ref="teacherTable" style="100%" :data="tableData" @filter-change="filterChange" border stripe @selection-change="handleSelectionChange">
|
||||||
<el-table-column type="selection"></el-table-column>
|
<el-table-column type="selection"></el-table-column>
|
||||||
<el-table-column label="姓名" prop="name" fixed>
|
<el-table-column label="姓名" prop="name" fixed>
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -49,19 +49,19 @@
|
|||||||
<el-table-column label="教师体系" prop="tsystemName"></el-table-column>
|
<el-table-column label="教师体系" prop="tsystemName"></el-table-column>
|
||||||
<el-table-column label="教师级别" prop="tlevelName"></el-table-column>
|
<el-table-column label="教师级别" prop="tlevelName"></el-table-column>
|
||||||
<el-table-column label="发薪地" prop="salaryName"></el-table-column>
|
<el-table-column label="发薪地" prop="salaryName"></el-table-column>
|
||||||
<el-table-column label="在职状态" width="90" :filters="[{ text: '在职', value: '0'}, { text: '离职', value: '1' }]"
|
<el-table-column label="在职状态" column-key="waitStatus" width="90" :filters="[{ text: '在职', value: '0'}, { text: '离职', value: '1' }]"
|
||||||
:filter-method="filterWork">
|
:filter-method="filterWork">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{scope.row.waitStatus=='0'?'在职': scope.row.waitStatus=='1' ? '离职' :''}}
|
{{scope.row.waitStatus=='0'?'在职': scope.row.waitStatus=='1' ? '离职' :''}}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="认证状态" width="90" :filters="[{ text: '未认证', value: 0}, { text: '已认证', value: 1 }]"
|
<el-table-column label="认证状态" column-key="certStatus" width="90" :filters="[{ text: '未认证', value: 0}, { text: '已认证', value: 1 }]"
|
||||||
:filter-method="filterCertification">
|
:filter-method="filterCertification">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
{{scope.row.certStatus==0 ?'未认证': scope.row.certStatus==1 ? '已认证' :''}}
|
{{scope.row.certStatus==0 ?'未认证': scope.row.certStatus==1 ? '已认证' :''}}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="账号状态" width="90"
|
<el-table-column label="账号状态" column-key="status" width="90"
|
||||||
:filters="[{ text: '停用', value: 2}, { text: '启用', value: 1 }]"
|
:filters="[{ text: '停用', value: 2}, { text: '启用', value: 1 }]"
|
||||||
:filter-method="filterStatus">
|
:filter-method="filterStatus">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -194,6 +194,9 @@
|
|||||||
tlevelId:'',
|
tlevelId:'',
|
||||||
name:'',
|
name:'',
|
||||||
salaryId:'',
|
salaryId:'',
|
||||||
|
waitStatus:'',
|
||||||
|
status:'',
|
||||||
|
certStatus:'',
|
||||||
pageIndex: 1,
|
pageIndex: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
},
|
},
|
||||||
@@ -301,10 +304,11 @@
|
|||||||
// this.teacherDetailsId = '13BEBDBD-3D28-244D-648D-0CBD6796717C'
|
// this.teacherDetailsId = '13BEBDBD-3D28-244D-648D-0CBD6796717C'
|
||||||
},
|
},
|
||||||
getTeachersystem() {
|
getTeachersystem() {
|
||||||
|
this.systemData=[];
|
||||||
teacherBoeApi.teacherSystem(this.userInfo.sysId).then(res=>{
|
teacherBoeApi.teacherSystem(this.userInfo.sysId).then(res=>{
|
||||||
if(res.status == 200) {
|
if(res.status == 200) {
|
||||||
this.systemLevelTree=res.result;
|
this.systemLevelTree=res.result;
|
||||||
this.systemData=[];
|
|
||||||
res.result.forEach(item => {
|
res.result.forEach(item => {
|
||||||
this.teacherSystemids.push(item.teacher_system_id);
|
this.teacherSystemids.push(item.teacher_system_id);
|
||||||
this.systemData.push({
|
this.systemData.push({
|
||||||
@@ -312,6 +316,7 @@
|
|||||||
name:item.system_name
|
name:item.system_name
|
||||||
})
|
})
|
||||||
});
|
});
|
||||||
|
|
||||||
this.loadData(1);
|
this.loadData(1);
|
||||||
} else {
|
} else {
|
||||||
this.$message.error('教师体系数据获取失败!')
|
this.$message.error('教师体系数据获取失败!')
|
||||||
@@ -320,7 +325,7 @@
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
queryChangeSystem(val) {
|
queryChangeSystem(val) {
|
||||||
this.query.tLevelId = '';
|
this.query.tlevelId = '';
|
||||||
let array=[];
|
let array=[];
|
||||||
this.systemLevelTree.forEach(sl=>{
|
this.systemLevelTree.forEach(sl=>{
|
||||||
if(sl.teacher_system_id==val){
|
if(sl.teacher_system_id==val){
|
||||||
@@ -358,6 +363,9 @@
|
|||||||
this.query.salaryId='',
|
this.query.salaryId='',
|
||||||
this.query.pageIndex= 1,
|
this.query.pageIndex= 1,
|
||||||
this.query.pageSize= 10,
|
this.query.pageSize= 10,
|
||||||
|
this.query.waitStatus='';
|
||||||
|
this.query.certStatus='';
|
||||||
|
this.query.status='';
|
||||||
this.$refs.teacherTable.clearFilter();
|
this.$refs.teacherTable.clearFilter();
|
||||||
this.loadData(1);
|
this.loadData(1);
|
||||||
},
|
},
|
||||||
@@ -380,15 +388,39 @@
|
|||||||
this.coverImage = '';
|
this.coverImage = '';
|
||||||
this.dialogVisible=true
|
this.dialogVisible=true
|
||||||
},
|
},
|
||||||
|
filterChange(e){
|
||||||
|
console.log(e,e.key,"测试");
|
||||||
|
if(e.waitStatus){
|
||||||
|
if(e.waitStatus.length==0 || e.waitStatus.length==2){
|
||||||
|
this.query.waitStatus='';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(e.certStatus){
|
||||||
|
if(e.certStatus.length==0 || e.certStatus.length==2){
|
||||||
|
this.query.certStatus='';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(e.status){
|
||||||
|
if(e.status.length==0 || e.status.length==2){
|
||||||
|
this.query.status='';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
this.loadData(1);
|
||||||
|
},
|
||||||
filterWork(value,row){
|
filterWork(value,row){
|
||||||
|
this.query.waitStatus=value;
|
||||||
|
console.log(value,row.waitStatus,'waitStatus');
|
||||||
|
//this.loadData(1);
|
||||||
return row.waitStatus==value
|
return row.waitStatus==value
|
||||||
},
|
},
|
||||||
filterCertification(value,row){
|
filterCertification(value,row){
|
||||||
// console.log(row.certificationStatus,value)
|
console.log(row.certificationStatus,value,"certStatus")
|
||||||
|
this.query.certStatus=value;
|
||||||
return row.certStatus==value
|
return row.certStatus==value
|
||||||
},
|
},
|
||||||
filterStatus(value,row){
|
filterStatus(value,row){
|
||||||
//console.log(row.status,value,"qwerqw");
|
console.log(row.status,value,"status");
|
||||||
|
this.query.status=value;
|
||||||
return row.status==value
|
return row.status==value
|
||||||
},
|
},
|
||||||
shareItem(item){
|
shareItem(item){
|
||||||
@@ -589,6 +621,10 @@
|
|||||||
this.levelData=array;
|
this.levelData=array;
|
||||||
},
|
},
|
||||||
loadData(pageIndex) {
|
loadData(pageIndex) {
|
||||||
|
if(this.systemData.length==0){
|
||||||
|
this.$message({ type: "error", message: "您当前没有可管理的教师"});
|
||||||
|
return;
|
||||||
|
}
|
||||||
this.query.pageIndex = pageIndex;
|
this.query.pageIndex = pageIndex;
|
||||||
this.query.tsystemIds = this.query.tsystemId || this.teacherSystemids.join();
|
this.query.tsystemIds = this.query.tsystemId || this.teacherSystemids.join();
|
||||||
teacherApi.page(this.query).then((res) => {
|
teacherApi.page(this.query).then((res) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user