diff --git a/src/views/recruit/newstucheckin/index.vue b/src/views/recruit/newstucheckin/index.vue index 6a903c6..1251f98 100644 --- a/src/views/recruit/newstucheckin/index.vue +++ b/src/views/recruit/newstucheckin/index.vue @@ -2,14 +2,86 @@
- - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 查询 重置 @@ -74,7 +146,11 @@ - + + + @@ -119,6 +195,8 @@ import { getDictsByTypes } from '/@/api/admin/dict' import { useDict } from '/@/hooks/dict' import request from '/@/utils/request' import { getStatusConfig } from '/@/config/global' +import { getDeptList, getClassListByRole } from '/@/api/basic/basicclass' +import { getList } from '/@/api/recruit/recruitstudentplangroup' const StuCheckIn = defineAsyncComponent(() => import('./stu-check-in.vue')) const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue')) @@ -148,13 +226,24 @@ const eduList = ref([]) // 表格引用 const tableRef = ref() +const searchFormRef = ref() const stuCheckInRef = ref() // 导出加载状态 const exportLoading = ref(false) +// 数据列表 +const deptList = ref([]) +const planList = ref([]) +const classList = ref([]) + // 查询表单 const queryForm = reactive({ + deptCode: '', + grade: '', + classCode: '', + checkInStatus: '', + isDormApply: '', searchTotal: '' }) @@ -167,6 +256,11 @@ const state: BasicTableProps = reactive({ pageList: async (params: any) => { const response = await fetchList({ ...params, + deptCode: queryForm.deptCode, + grade: queryForm.grade, + classCode: queryForm.classCode, + checkInStatus: queryForm.checkInStatus, + isDormApply: queryForm.isDormApply, searchTotal: queryForm.searchTotal }) return { @@ -189,6 +283,12 @@ const getCheckInStatusLabel = (value: string) => { // 重置查询 const resetQuery = () => { + searchFormRef.value?.resetFields() + queryForm.deptCode = '' + queryForm.grade = '' + queryForm.classCode = '' + queryForm.checkInStatus = '' + queryForm.isDormApply = '' queryForm.searchTotal = '' getDataList() } @@ -257,9 +357,32 @@ const getCheckInStatusData = async () => { } } +// 初始化数据 +const init = async () => { + try { + // 获取学院列表 + const deptData = await getDeptList() + deptList.value = deptData.data || [] + + // 获取入学年份列表(招生计划) + const planData = await getList() + planList.value = planData.data || [] + + // 获取班级列表 + const classData = await getClassListByRole() + classList.value = classData.data || [] + + // 获取字典数据 + await getCheckInStatusData() + + getDataList() + } catch (error) { + message.error('初始化失败') + } +} + onMounted(() => { - getCheckInStatusData() - getDataList() + init() }) diff --git a/src/views/recruit/newstucheckin/stu-check-in.vue b/src/views/recruit/newstucheckin/stu-check-in.vue index 1f24649..0d6ff4f 100644 --- a/src/views/recruit/newstucheckin/stu-check-in.vue +++ b/src/views/recruit/newstucheckin/stu-check-in.vue @@ -1,30 +1,24 @@ @@ -92,10 +85,12 @@