讲师管理bug

This commit is contained in:
zhangsir
2024-12-02 15:57:24 +08:00
parent 1ffe96bc90
commit f887d740f4
5 changed files with 144 additions and 45 deletions

View File

@@ -62,7 +62,9 @@ export const getAffiliationCode = () => http.get('/admin/affiliation/getAffiliat
//查看或编辑回显培训发生组织
export const getAffiliationById = (id) => http.get(`/admin/affiliation/queryById?id=${id}`)
//审核记录
export const getByBusinessIdList = (obj) => http.post(`/admin/approval/getByBusinessIdList?businessId=${obj.businessId}&businessType=${obj.businessType}&pageNo=${obj.pageNo}&pageSize=${obj.pageSize}`)
export const getByBusinessIdList = (obj) => http.post(`/admin/approval/getByBusinessIdListPage?businessId=${obj.businessId}&businessType=${obj.businessType}&pageNo=${obj.pageNo}&pageSize=${obj.pageSize}`)
//审批中心查看详情
export const getApprovalResultByBusinessIdList = (obj) => http.post(`/admin/approval/getApprovalResultByBusinessIdList?businessId=${obj.businessId}&businessType=${obj.businessType}`)
//审核记录查看操作
export const getApprovalResultByApprovalIdList = (approvalId) => http.post(`/admin/approval/getApprovalResultByApprovalIdList?approvalId=${approvalId}`)
//恢复培训发生组织的数据

View File

@@ -415,14 +415,14 @@
<router-link to="/teacheropinion">意见</router-link>
</a-menu-item>
</a-sub-menu>
<a-sub-menu key="sub24" @titleClick="titleClick" v-if="checkMenu('instructorcertification')">
<a-sub-menu key="sub24" @titleClick="titleClick" v-if="checkMenu('lecturer')">
<template #icon>
<div class="imgBox">
<img style="width: 15px; height: 15px" src="../assets/images/navleft/project.png" />
</div>
</template>
<template #title>讲师管理</template>
<a-menu-item key="sub24-1" v-if="checkMenu('instructorcertification')">
<a-menu-item key="sub24-1" v-if="checkMenu('lecturer')">
<span
:class="{
circleActive: selectedKeys[0] === 'sub24-1' ? true : false,

View File

@@ -68,7 +68,7 @@
</a-table>
</div>
<div style="margin-bottom: 100px">
<a-table v-if="threeList" :columns="columnsThree" :data-source="formData?.tableDataThree" :pagination="false"/>
<a-table v-if="threeList" :columns="columnsThree" :loading="formData?.loadingThree" :data-source="formData?.tableDataThree" :pagination="false"/>
</div>
</a-tab-pane>
</a-tabs>
@@ -246,18 +246,28 @@ const columnsTwo = ref([
slots: { customRender: "action" },
}
])
const approvalData = ref(null)
const threeList = ref(false)
const lookList = (record) => {
console.log(record,'resssssss')
if(!threeList.value||record.approvalId!=approvalData.value){
threeList.value = true
approvalData.value = record.approvalId
formData.value.loadingThree = true
api.getApprovalResultByApprovalIdList(record.approvalId).then(res=>{
if(res.data.code == 200){
formData.value.tableDataThree = res.data.data
}
formData.value.loadingThree = false
}).catch(err=>{
message.destroy()
formData.value.loadingThree = false
message.error(err.data.msg)
})
}else{
threeList.value = false
approvalData.value = null
}
}
const visible = ref(false);
watch(visible, (val)=>{
@@ -288,7 +298,6 @@ const getTwoData = () => {
params.total = res.data.data.total
}
formData.value.loadingTwo = false
console.log(formData.value.tableDataTwo,'xixixi')
}).catch(err=>{
message.destroy()
message.error(err.data.msg)
@@ -358,7 +367,8 @@ function openDrawer() {
.impotergroupleader {
.drawerMain {
min-width: 600px;
margin: 0px 32px 0px 32px;
margin:0;
padding: 0px 32px 0px 32px;
overflow-x: auto;
display: flex;
flex-direction: column;
@@ -379,6 +389,7 @@ function openDrawer() {
color: #333333;
line-height: 25px;
// margin-left: 24px;
margin: 0;
}
}
.content{

View File

@@ -131,7 +131,7 @@
/>
</div>
<span class="line"></span>
<span>讲师费用详情</span>
<span style="font-weight:600;">讲师费用详情</span>
<a-descriptions style="margin-top:16px" bordered :column="2" :contentStyle="rowCenter" :labelStyle="rowCenter">
<a-descriptions-item label="审批编号">{{formParam?.approvalNumber||'-'}}</a-descriptions-item>
<a-descriptions-item label="培训发生组织">{{formParam?.trainOrgName||'-'}}</a-descriptions-item>
@@ -141,8 +141,8 @@
<a-descriptions-item label="状态">{{{0:'待确认' ,1:'待提交' ,2:'审核中', 3:'已完成', 4:'审核拒绝',5:'待提交'}[formParam?.status]}}</a-descriptions-item>
</a-descriptions>
<!-- <span>审批详情</span> -->
<span class="line" style="margin-top:12px;"></span>
<a-tabs v-model:activeKey="activeKey">
<span class="line" style="margin-top:15px;"></span>
<a-tabs v-model:activeKey="activeKey" @change="tabsChange">
<a-tab-pane key="1" tab="讲师费列表">
<div style="padding: 10px 0;">
<div style="display: flex;margin-bottom: 20px;">
@@ -167,7 +167,7 @@
<a-tab-pane key="2" tab="讲师费审批记录" force-render>
<div style="padding-bottom:70px">
<a-table :header-cell-style="{ 'text-align': 'center' }" style="border: 1px solid #f2f6fe" :columns="columnsExamineTwo"
:data-source="tableDataExamineTwo" :loading="examinetableLoading" @expand="expandTable" :pagination="pagination">
:data-source="tableDataExamineTwo" :loading="tableDataExamineLoading" @expand="expandTable" :pagination="false">
</a-table>
</div>
</a-tab-pane>
@@ -242,7 +242,7 @@
} from '@ant-design/icons-vue';
import ProjectManager from "@/components/project/ProjectManagerNew";
import {expenseBillList,queryById,queryExpnseByBillId ,updateTeacherFee,updateStatusSubmit,approveTeacherFee,getTrainOrg,isConfirm} from "../../api/lecturerFeeManagement";
import { getTeacherSystemList } from "../../api/Lecturer";
import { getTeacherSystemList,getApprovalResultByBusinessIdList } from "../../api/Lecturer";
// lecturerFeeManagement
// import {getProjSt} from "../../api/indexProjStu";
// import AddTeacher from "../../components/drawers/project/AddTeacher"
@@ -270,6 +270,8 @@
})
const router = useRouter()
const state = reactive({
tableDataExamineLoading: false,
tableDataExamineTwo: [],
tableDataParams:{
pageNo: 1,
pageSize: 10,
@@ -632,11 +634,54 @@
}
//表格内查看数据操作
const handleLook = (record) => {
state.activeKey = '1'
state.teachingdialog = true;
state.id= record.id
TeacherSystem()
gettableDataExamine()
}
const params = reactive({
pageNo: 1,
pageSize: 10,
total: 0,
businessType: 1,
businessId: '366'
})
const paginations = computed(() => ({
total: params.total,
showSizeChanger: true,
showQuickJumper:true,
current: params.pageNo,
pageSize: params.pageSize,
onChange: paginationChanges,
}));
const paginationChanges = (e,pageSize) => {
params.pageNo = e;
params.pageSize = pageSize
// getListData()
};
const tabsChange = (val) => {
if(val == 2){
getListData()
}
}
const getListData = () => {
state.tableDataExamineLoading = true
getApprovalResultByBusinessIdList({
businessType: 1,
businessId: state.id
}).then(res=>{
if(res.data.code == 200){
state.tableDataExamineTwo = res.data.data
// params.total = res.data.data.total
}
state.tableDataExamineLoading = false
}).catch(err=>{
message.destroy()
state.tableDataExamineLoading = false
message.error(err.data.msg)
})
}
const submit = (record) => {
console.log(record,'record')
dialog({
@@ -712,7 +757,6 @@
}
}
const tableDataExamine = ref([])
const tableDataExamineTwo = ref([])
const gettableDataExamine = () => {
state.examinetableLoading = true
queryExpnseByBillId({
@@ -747,51 +791,66 @@
const columnsExamineTwo = ref([
{
title: '审批层级 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'levelName',
key: 'levelName',
ellipsis: true,
align: "center",
width: 120,
},
{
title: '层级审批人 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'employeeNames',
key: 'employeeNames',
ellipsis: true,
align: "center",
width: 120,
},
{
title: '操作 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'approvalStatus',
key: 'approvalStatus',
ellipsis: true,
align: "center",
width: 120,
customRender: ({text})=>{
switch (text) {
case -1:
return <span>未处理</span>;
case 3:
return <span>通过</span>;
case 4:
return <span>拒绝</span>;
default:
return <span>-</span>;
}
}
},
{
title: '审批人 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'employeeName',
key: 'employeeName',
ellipsis: true,
align: "center",
width: 120,
},
{
title: '审批时间 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'approvalTime',
key: 'approvalTime',
ellipsis: true,
align: "center",
width: 120,
},
{
title: '审批建议 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'approvalMsg',
key: 'approvalMsg',
ellipsis: true,
align: "center",
width: 120,
customRender: ({text}) => {
return text||'-'
}
},
])
//二级页面
@@ -978,13 +1037,14 @@
columnsExamineTwo,
tableData,
tableDataExamine,
tableDataExamineTwo,
seeDateChange,
changePagination,
addTeacher,
cancelTeachingDialog,
handleLook,
submit,
getListData,
tabsChange,
withdraw,
goDdit,
cancel,
@@ -1000,6 +1060,8 @@
paginationChange,
searchTeacherFeeApprovalList,
resetSearch,
paginations,
paginationChanges,
}
},
};
@@ -1322,10 +1384,11 @@
.line {
float: left;
width: 3px;
height: 25px;
height: 17px;
background: #4ea6ff;
border-radius: 30%;
margin-right: 5px;
margin-top: 3px;
}
//抽屉功能

View File

@@ -701,38 +701,61 @@ getAllLevelList().then((res) => {
const columnSee = ref([
{
title: '审批层级',
dataIndex: 'name',
key: 'name',
dataIndex: 'levelName',
key: 'levelName',
ellipsis: true,
align: "center",
},
{
title: '审批人 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'employeeNames',
key: 'employeeNames',
ellipsis: true,
align: "center",
},
{
title: '审批状态 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'approvalStatus',
key: 'approvalStatus',
ellipsis: true,
align: "center",
customRender: ({text})=>{
switch (text) {
case 0:
return <span>待提交</span>;
case 1:
return <span>待审核</span>;
case 2:
return <span>审核中</span>;
case 3:
return <span>审核通过</span>;
case 4:
return <span>拒绝</span>;
case 5:
return <span>撤销中</span>;
case 6:
return <span>已撤销</span>;
default:
return <span>-</span>;
}
}
},
{
title: '审批时间 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'approvalTime',
key: 'approvalTime',
ellipsis: true,
align: "center",
},
{
title: '备注 ',
dataIndex: 'name',
key: 'name',
dataIndex: 'approvalMsg',
key: 'approvalMsg',
ellipsis: true,
align: "center",
customRender:({text})=>{
return text||'-'
}
},
])
const columns = ref([