|
@@ -18,11 +18,10 @@
|
|
|
</a-form-item>
|
|
|
<a-form-item label="查找条件">
|
|
|
<a-select
|
|
|
- v-model:value="searchDataCheckType"
|
|
|
+ v-model:value="searchModel.examStatus"
|
|
|
placeholder="请选择"
|
|
|
:options="absentCheckOptions"
|
|
|
allow-clear
|
|
|
- @change="absentCheckTypeChange"
|
|
|
></a-select>
|
|
|
</a-form-item>
|
|
|
<a-form-item label="考号">
|
|
@@ -131,6 +130,7 @@ import {
|
|
|
RedoOutlined,
|
|
|
} from "@ant-design/icons-vue";
|
|
|
import { message } from "ant-design-vue";
|
|
|
+import type { DefaultOptionType } from "ant-design-vue/es/vc-select/Select";
|
|
|
|
|
|
import { useUserStore, useDataCheckStore } from "@/store";
|
|
|
import { AbsentCheckListFilter, ImportType } from "@/ap/types/absentCheck";
|
|
@@ -142,6 +142,7 @@ import {
|
|
|
absentCheckRoomExport,
|
|
|
examStatusSave,
|
|
|
} from "@/ap/absentCheck";
|
|
|
+import { examNumberFillCount } from "@/ap/base";
|
|
|
import useDictOption from "@/hooks/dictOption";
|
|
|
import useLoading from "@/hooks/useLoading";
|
|
|
|
|
@@ -161,10 +162,37 @@ const emit = defineEmits(["search"]);
|
|
|
const userStore = useUserStore();
|
|
|
const dataCheckStore = useDataCheckStore();
|
|
|
|
|
|
-const { optionList: absentCheckOptions } = useDictOption("ABSENT_CHECK_TYPE");
|
|
|
const { optionList: imageTypeOptions } = useDictOption("IMAGE_TYPE");
|
|
|
const panelKey = ref(["1", "2", "3", "4"]);
|
|
|
|
|
|
+const absentCheckOptions = ref([] as DefaultOptionType[]);
|
|
|
+async function getAbsentCheckOptions() {
|
|
|
+ const res = await examNumberFillCount(userStore.curExam.id);
|
|
|
+ absentCheckOptions.value = [
|
|
|
+ {
|
|
|
+ label: "缺考",
|
|
|
+ value: "ABSENT",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "正常",
|
|
|
+ value: "OK",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "客观题未作答+主观题有作答(待确认)",
|
|
|
+ value: "UNCHECK1",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: `客观题未作答+主观题未作答+填涂≥${res}+有卷型(待确认)`,
|
|
|
+ value: "UNCHECK2",
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: `交叉对比缺考不一致(待确认)`,
|
|
|
+ value: "UNCHECK3",
|
|
|
+ },
|
|
|
+ ];
|
|
|
+}
|
|
|
+getAbsentCheckOptions();
|
|
|
+
|
|
|
// search
|
|
|
const initSearchModel = {
|
|
|
examId: userStore.curExam.id,
|
|
@@ -172,10 +200,9 @@ const initSearchModel = {
|
|
|
studentCode: "",
|
|
|
name: "",
|
|
|
subjectCode: "",
|
|
|
- examStatus: [],
|
|
|
+ examStatus: "",
|
|
|
};
|
|
|
const searchModel = reactive<AbsentCheckListFilter>({ ...initSearchModel });
|
|
|
-const searchDataCheckType = ref();
|
|
|
const imageType = ref(dataCheckStore.imageType);
|
|
|
|
|
|
// imageType
|
|
@@ -198,23 +225,6 @@ function onExamNumberEdited(val: string) {
|
|
|
searchModel.examNumber = val;
|
|
|
}
|
|
|
|
|
|
-function absentCheckTypeChange() {
|
|
|
- switch (searchDataCheckType.value) {
|
|
|
- // 缺考
|
|
|
- case "1":
|
|
|
- searchModel.examStatus = ["ABSENT"];
|
|
|
- break;
|
|
|
- // 正常
|
|
|
- case "2":
|
|
|
- searchModel.examStatus = ["OK"];
|
|
|
- break;
|
|
|
-
|
|
|
- default:
|
|
|
- searchModel.examStatus = [];
|
|
|
- break;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
function onSearch() {
|
|
|
emit("search", searchModel);
|
|
|
}
|