|
|
@@ -1,17 +1,17 @@
|
|
|
<template>
|
|
|
<view>
|
|
|
<view class="w-full flex mb-30 justify-between">
|
|
|
- <view class="">
|
|
|
- <ie-picker ref="pickerRef" v-model="queryForm.buildStatus" :list="buildTypeList" placeholder="类型" title="类型"
|
|
|
+ <view class="max-w-180">
|
|
|
+ <ie-picker ref="pickerRef" v-model="queryForm.buildType" :list="buildTypeList" placeholder="类型" title="类型"
|
|
|
icon="arrow-down" key-label="name" key-value="value" :fontSize="28"
|
|
|
:placeholder-style="placeholderStyle"></ie-picker>
|
|
|
</view>
|
|
|
- <view class="">
|
|
|
+ <view class="max-w-180">
|
|
|
<ie-picker ref="pickerRef" v-model="queryForm.batchId" :list="batchList" placeholder="批次" title="批次"
|
|
|
icon="arrow-down" key-label="name" key-value="batchId" :fontSize="28"
|
|
|
:placeholder-style="placeholderStyle"></ie-picker>
|
|
|
</view>
|
|
|
- <view class="">
|
|
|
+ <view class="max-w-180">
|
|
|
<ie-picker ref="pickerRef" v-model="queryForm.classId" :list="classList" placeholder="班级" title="班级"
|
|
|
icon="arrow-down" key-label="name" key-value="classId" :fontSize="28"
|
|
|
:placeholder-style="placeholderStyle"></ie-picker>
|
|
|
@@ -56,12 +56,31 @@
|
|
|
import { Study, TableColumnConfig } from '@/types';
|
|
|
import { CSSProperties } from 'vue';
|
|
|
import { getBatchList, getTeachClassList, getTeacherSubjectList, getTeacherTestRecord, getTeacherTestRecordDetail, getTeacherTestRecordCondition } from '@/api/modules/study';
|
|
|
+import { EnumPaperBuildType, EnumPaperWorkState } from '@/common/enum';
|
|
|
|
|
|
const cellStyle: CSSProperties = {
|
|
|
padding: '30rpx 20rpx'
|
|
|
}
|
|
|
const queryForm = ref<Partial<Study.PaperWorkRecordQuery>>({});
|
|
|
const buildTypeList = ref([
|
|
|
+ {
|
|
|
+ name: '定向智能',
|
|
|
+ value: EnumPaperBuildType.EXACT_INTELLIGENT
|
|
|
+ },
|
|
|
+ {
|
|
|
+ name: '全量智能',
|
|
|
+ value: EnumPaperBuildType.FULL_INTELLIGENT
|
|
|
+ },
|
|
|
+ {
|
|
|
+ name: '定向手动',
|
|
|
+ value: EnumPaperBuildType.EXACT_HAND
|
|
|
+ },
|
|
|
+ {
|
|
|
+ name: '全量手动',
|
|
|
+ value: EnumPaperBuildType.FULL_HAND
|
|
|
+ }
|
|
|
+]);
|
|
|
+const buildStatusList = ref([
|
|
|
{
|
|
|
name: '未定向未组卷',
|
|
|
value: 10
|
|
|
@@ -145,6 +164,7 @@ const getStatusText = (status: number | null) => {
|
|
|
}
|
|
|
return statusMap[status as keyof typeof statusMap];
|
|
|
}
|
|
|
+
|
|
|
const popupRef = ref();
|
|
|
const handleRowClick = async (row: Study.PaperWorkRecord) => {
|
|
|
uni.$ie.showLoading();
|
|
|
@@ -179,9 +199,10 @@ const loadData = async () => {
|
|
|
});
|
|
|
await Promise.all([queryBatch, queryClass, querySubject]);
|
|
|
const queryCondition = getTeacherTestRecordCondition({}).then(res => {
|
|
|
- const { buildStatus, batchId, classId, subjectId } = res.data;
|
|
|
+ const { buildType, buildStatus, batchId, classId, subjectId } = res.data;
|
|
|
queryForm.value = {
|
|
|
- buildStatus: buildStatus || buildTypeList.value[0].value,
|
|
|
+ buildType: buildType || buildTypeList.value[0].value,
|
|
|
+ buildStatus: buildStatus || buildStatusList.value[0].value,
|
|
|
batchId: batchId || batchList.value[0].batchId,
|
|
|
classId: classId || classList.value[0].classId,
|
|
|
subjectId: subjectId || subjectList.value[0].subjectId,
|
|
|
@@ -207,12 +228,7 @@ const loadTestRecord = () => {
|
|
|
}
|
|
|
uni.$ie.showLoading();
|
|
|
getTeacherTestRecord(params).then(res => {
|
|
|
- // 根据类型过滤,保留总人数和指定类型的,没有类型时,显示所有类型
|
|
|
- if (!queryForm.value.buildStatus) {
|
|
|
- tableData.value = res.data;
|
|
|
- } else {
|
|
|
- tableData.value = res.data.filter(item => item.buildStatus === null || Number(item.buildStatus) === Number(queryForm.value.buildStatus));
|
|
|
- }
|
|
|
+ tableData.value = res.data;
|
|
|
}).finally(() => {
|
|
|
uni.$ie.hideLoading();
|
|
|
});
|