讲师管理bug

This commit is contained in:
zhangsir
2024-11-14 20:44:26 +08:00
parent 28bb396a6b
commit 51b0e75fe3
5 changed files with 35 additions and 28 deletions

View File

@@ -12,7 +12,7 @@
</a-form-item>
<a-form-item class="select">
<a-select style="width: 276px" placeholder="请选择讲师体系" v-model:value="searchParam.tSystemId" allowClear
:options="LecturerSystemList" @change="changetlevel">
:options="LecturerSystemList">
</a-select>
</a-form-item>
<!-- <div @click="handlesearchlevel"> -->
@@ -53,7 +53,7 @@
</a-select>
</a-form-item>
<a-form-item v-if="moreid == 2" class="select">
<a-input style="width: 276px;height: 40px; border-radius:8px; " v-model:value="searchParam.expertiseNames"
<a-input style="width: 276px;height: 40px; border-radius:8px; " v-model:value="searchParam.courses"
placeholder="擅长课程" allowClear @pressEnter="searchSubmit">
</a-input>
</a-form-item>
@@ -87,7 +87,7 @@
</template>
<template v-if="column.key === 'operation'">
<a-space>
<a-button v-if="record.isPermission==='true'||record.isSuperPermission==='true'" type="link" @click="() => handleLook(record, String(record.courseform))">查看</a-button>
<a-button type="link" @click="() => handleLook(record, String(record.courseform))">查看</a-button>
<a-button v-if="record.isPermission==='true'||record.isSuperPermission==='true'" type="link" @click="() => handleModify(record, String(record.courseform))">编辑</a-button>
<a-button v-if="record.status == '1'&&(record.isPermission==='true'||record.isSuperPermission==='true')" type="link"
@@ -254,6 +254,7 @@
closable="false"
style="margin-top: 400px"
@cancel="cancelupdialog"
:maskClosable="false"
>
<div class="selectonlineface" style="width: 660px;" :style="{ display: updialog ? 'block' : 'none' }">
<div class="bg_headers"></div>
@@ -375,7 +376,7 @@ import ProjectManager from "@/components/project/ProjectManagerNew";
import SearchTeacher from "@/components/project/SearchTeacher";
import { message } from "ant-design-vue";
import { useRouter,useRoute } from "vue-router";
import { getTeacherSystemList, getTeacherList, getPayRollPlace, getLevel, insertTeacher, deleteInTeacher, updateInTeacher, getTeacherById, updateTeacherState } from "../../api/Lecturer";
import { getTeacherSystemList, getTeacherList, getPayRollPlace, getAllLevelList, insertTeacher, deleteInTeacher, updateInTeacher, getTeacherById, updateTeacherState } from "../../api/Lecturer";
import { fileUp } from "../../api/indexEval";
import { teacherUpload } from "../../api/Teaching";
import { getCookieForName } from "@/api/method";
@@ -462,7 +463,7 @@ export default {
tLevelId: null,
waitStatus: null,
certStatus: null,
expertiseNames: null,
courses: null,
pageNo: "1",
pageSize: "10"
},
@@ -540,7 +541,6 @@ export default {
const changeUpload = (newValue) => {
if (newValue[0].status == 'done' && newValue[0]?.response?.status == 200) {
const { id, name, path } = newValue[0].response.result
console.log(id,name,path)
state.formParam.certification = path
state.formParam.certificationName = name
}
@@ -576,11 +576,14 @@ export default {
state.updialog = true
}
const cancelupdialog = () => {
state.formParam.certification = null
state.formParam.certificationName = null
uploadRef.value.removeUpload()
state.updialog = false
}
const createupdialog = () => {
cancelupdialog()
uploadRef.value.removeUpload()
state.updialog = false
}
const LecturerSystemList = ref([
]);
@@ -622,9 +625,9 @@ export default {
LecturerSystemLista()
//获取内部讲师级别
const getLevelList = ref([])
const changetlevel = (val) => {
console.log("讲师体系id" + val);
getLevel({ id: val }).then((res) => {
const changetlevel = () => {
// console.log("讲师体系id" + val);
getAllLevelList().then((res) => {
if (res.data.code === 200) {
let arr = res.data.data;
let array = [];
@@ -689,7 +692,7 @@ export default {
state.moreid = 1
state.searchParam.waitStatus = null
state.searchParam.certStatus = null
state.searchParam.expertiseNames = null
state.searchParam.courses = null
}
}
const columns = ref([
@@ -949,6 +952,9 @@ export default {
return message.error(rules[formItemNames[i]][0].log)
}
}
if(state.formParam.certStatus&&!state.formParam.certificationName){
return message.error('请上传认证凭证')
}
if(state.formParam.name){
const nameNo = state.formParam?.name?.split('/')
state.formParam.name = nameNo[0]