Merge remote-tracking branch 'zcwy/zcwy-teacher-manage' into zcwy-teacher-manage

# Conflicts:
#	src/views/lecturer/LecturerFeeStatistics.vue
#	src/views/lecturer/MonthlyStatistics.vue
This commit is contained in:
zhangsir
2024-10-30 14:43:04 +08:00
12 changed files with 155 additions and 114 deletions

View File

@@ -15,21 +15,30 @@
<div class="filter" style="min-width: 1380px;">
<a-form layout="inline" >
<a-form-item class="select">
<div style="width: 276px; height: 40px; border-radius: 8px" >
<ProjectManager v-model:value="searchParam.managerId"
v-model:name="searchParam.manager"
placeholder="请输入工号/讲师姓名进行检索"
@onChange="managerChange" mode="multiple"></ProjectManager>
</div>
<a-input v-model:value="searchParam.name" style="width: 276px; height: 40px; border-radius: 8px"
placeholder="请输入工号/讲师姓名进行检索" allowClear showSearch>
</a-input>
</a-form-item>
<a-form-item class="select">
<a-select style="width: 230px" v-model:value="searchParam.payrollPlaceId" placeholder="发薪地"
:options="PlaceOfPayList" allowClear showSearch/>
</a-form-item>
<a-form-item class="select " >
<a-select style="width: 276px" v-model:value="searchParam.trainorgId" placeholder="培训发生组织"
:options="trainOrglist" allowClear showSearch>
</a-select>
<a-tree-select style="width: 230px"
:fieldNames="{
children: 'children',
label: 'name',
value: 'code',
}"
allow-clear
:getPopupContainer="triggerNode => triggerNode.parentNode || document.body"
v-model:value="searchParam.courseTypeId"
show-search
:dropdown-style="{ maxHeight: '400px', overflow: 'auto' }"
placeholder="请选择内容分类"
tree-default-expand-all
:tree-data="sysTypeOptions">
</a-tree-select>
</a-form-item>
<div style="display: flex; margin-bottom: 20px">
<a-button @click="searchSubmit()" type="primary" class="resetbtn">查询 </a-button>
@@ -71,8 +80,8 @@
<div style="float: right;">
<a-pagination
v-if="tableDataTotal > 10"
:showSizeChanger="false"
:showQuickJumper="true"
:showSizeChanger="true"
:showQuickJumper="false"
:hideOnSinglePage="true"
:pageSize="searchParam.pageSize"
:current="searchParam.pageNo"
@@ -124,18 +133,18 @@
</div>
</template>
<script lang="jsx">
import { reactive, toRefs, ref, watch } from "vue";
import {useRouter, useRoute} from "vue-router";
import { reactive, toRefs, ref, watch,computed } from "vue";
import { useStore } from "vuex";
import { useRouter,useRoute } from "vue-router";
import {
UploadOutlined,
} from '@ant-design/icons-vue';
import { getPayRollPlace } from "../../api/Lecturer";
import { getOrganization } from "../../api/Teaching";
import ProjectManager from "@/components/project/ProjectManagerNew";
import {getTrainOrg} from "../../api/lecturerFeeManagement";
import { queryTeacherFeeTotalList, queryTeacherFeeMonthly, getTeacherFeeDetailListByTeacherNo, getTeacherFeeListByTeacherNo ,getPreviousTeacherfee} from "../../api/lecturerFeeStatistics";
import {queryTeacherFeeMonthly} from "../../api/lecturerFeeStatistics";
import {CostDetails} from "../lecturer/CostDetails.vue"
import * as api from '@/api/Lecturer'
// import * as api from '@/api/Lecturer'
export default {
name: "MonthlyStatistics",
components: {
@@ -165,7 +174,7 @@ export default {
searchParam: {
pageNo: "1",
pageSize: "10",
teacherNo: null,
name: null,
payrollPlaceId: null,
departId: null,
summaryDate:null,
@@ -173,7 +182,7 @@ export default {
name: '',
trainOrgId: '',
},
teacherNo:null,
name:null,
drawer: {
name: null,
drawersearchdate: null,
@@ -183,6 +192,9 @@ export default {
})
watch(
)
//获取内容分类
const store = useStore();
const sysTypeOptions = computed(() => store.state.content_type);
const columns = ref([
{
title: '讲师姓名 ',
@@ -266,25 +278,7 @@ export default {
const searchSubmit = () => {
getTableDate();
};
const trainOrglist=ref([])
//获取培训发生组织
const trainOrglista =() => {
getTrainOrg().then((res)=>{
if (res.data.code === 200) {
let arr = res.data.data;
let array = [];
arr.map((value) => {
let obj = {
value: value.trainorgId,
label: value.trainOrg,
};
array.push(obj);
});
trainOrglist.value = array;
}
})
}
trainOrglista()
const PlaceOfPayList = ref([
])
//获取讲师发薪地列表
@@ -309,7 +303,7 @@ export default {
// List接口数据
const getTableDate = (obj) => {
state.tableLoading = true
api.expenseSummaryById(state.searchParam)
queryTeacherFeeMonthly(state.searchParam)
.then((res) => {
console.log(res,'resssss')
tableData.value = res.data.data.records
@@ -348,23 +342,23 @@ export default {
}
const changePagination = (page, pageSize) => {
state.searchParam.pageNo = page;
// state.pageNo = page;
state.searchParam.pageSize = pageSize;
getTableDate();
};
// 导出
const handleFeeMonthly = () => {
window.open(
`${process.env.VUE_APP_BASE_API}/teacher/fee/exportTeacherMonthlyFee?pageNo=${state.searchParam.currentPage
}&pageSize=${state.searchParam.pageSize}
&userNo=${state.searchParam.payrollPlaceId ? state.searchParam.payrollPlaceId : ""}
&teacherNo=${state.searchParam.teacherNo ? state.searchParam.teacherNo : ""}
&departId=${state.searchParam.trainorgId ? state.searchParam.trainorgId : ""}`)
`${process.env.VUE_APP_BASE_API}/admin/export/exportTeacherSummary?pageNo=${state.searchParam.pageNo}&pageSize=${state.searchParam.pageSize}
&name=${state.searchParam.name ? state.searchParam.name : ""}
&payrollPlaceId=${state.searchParam.payrollPlaceId ? state.searchParam.payrollPlaceId : ""}`)
}
//重置
const searchReset = () => {
state.searchParam = {
pageNo: "1",
pageSize: "10",
teacherNo: null,
name : null,
payrollPlaceId: null,
departId: null,
summaryDate:null,
@@ -499,13 +493,11 @@ export default {
state.opendrawer = false
};
return {
...toRefs(state),
trainOrglist,
...toRefs(state),
tableDatas,
column,
cancelTeachingDialog,
searchReset,
trainOrglista,
handleFeeMonthly,
handleLook,
changePagination,
@@ -517,7 +509,8 @@ export default {
PlaceOfPayLista,
getOrganizationList,
getOrganizationLista,
searchResetdrawer
searchResetdrawer,
sysTypeOptions,
}
},
};
@@ -900,5 +893,23 @@ export default {
font-size: 14px;
}
}
tableBox {
padding-bottom: 20px;
margin: 20px 38px 30px;
::v-deep .ant-select-dropdown{
display: inline-block;
}
::v-deep .ant-select-selection-item{
margin-left: 3px;
}
::v-deep .ant-pagination-options-size-changer.ant-select{
width: 84px;
}
.pa {
width: 100%;
display: flex;
justify-content: right;
}
}
</style>