|
|
@@ -1,20 +1,48 @@
|
|
|
<template>
|
|
|
<a-card :bordered="false">
|
|
|
<!-- 搜索和操作区域 -->
|
|
|
- <a-row :gutter="60" style="margin-bottom: 16px">
|
|
|
- <a-col>
|
|
|
- <span>试卷名称:</span>
|
|
|
- <a-input v-model:value="formState.name" placeholder="请输入试卷名称" style="width: 150px;" />
|
|
|
- </a-col>
|
|
|
- <a-col>
|
|
|
- <span>学科名称:</span>
|
|
|
- <a-input v-model:value="formState.fileName" placeholder="请输入学科名称" style="width: 150px" />
|
|
|
- </a-col>
|
|
|
- <a-col>
|
|
|
- <a-button type="primary" style="margin-left: 8px" @click="handleSearch">查询</a-button>
|
|
|
- <a-button style="margin-left: 8px" @click="handleReset">重置</a-button>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
+
|
|
|
+ <a-card :bordered="false" style="margin-bottom: 10px">
|
|
|
+ <a-form ref="searchFormRef" name="advanced_search" class="ant-advanced-search-form" :model="formState">
|
|
|
+ <a-row :gutter="24">
|
|
|
+ <a-col :span="4">
|
|
|
+ <a-form-item name="name" label="ID:">
|
|
|
+ <a-input v-model:value="formState.id" placeholder="请输入试卷ID" style="width: 70%;"/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :span="4">
|
|
|
+ <a-form-item label="学科名称:" name="subjectId">
|
|
|
+ <a-select
|
|
|
+ v-model:value="formState.subjectId"
|
|
|
+ :options="susbjectOptions"
|
|
|
+ style="width: 70%"
|
|
|
+ placeholder="请选择学科"
|
|
|
+ >
|
|
|
+ </a-select>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :span="4">
|
|
|
+ <a-form-item name="name" label="试卷名称:">
|
|
|
+ <a-input v-model:value="formState.name" placeholder="请输入试卷名称" style="width: 70%;"/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :span="4">
|
|
|
+ <a-button type="primary" @click="table.refresh(true)" style="margin-right: 10px">
|
|
|
+ <template #icon><SearchOutlined /></template>
|
|
|
+ 查询
|
|
|
+ </a-button>
|
|
|
+ <a-button class="snowy-buttom-left" @click="reset">
|
|
|
+ <template #icon><redo-outlined /></template>
|
|
|
+ 重置
|
|
|
+ </a-button>
|
|
|
+ </a-col>
|
|
|
+ </a-row>
|
|
|
+ </a-form>
|
|
|
+ </a-card>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
|
|
|
<s-table
|
|
|
ref="table"
|
|
|
@@ -58,11 +86,17 @@
|
|
|
<script setup name="exampaper">
|
|
|
import Form from './form.vue'
|
|
|
import tExamPaperApi from '@/api/paper/examPaperApi'
|
|
|
- const formState = reactive({
|
|
|
+ import tool from "@/utils/tool";
|
|
|
+ const formState = ref({
|
|
|
id: null,
|
|
|
- verifyStatus: '0',
|
|
|
- resourcesId: null,
|
|
|
+ name: null,
|
|
|
+ subjectId: null,
|
|
|
})
|
|
|
+ const gradeLevelOptions = tool.dictList('SEMESTER')
|
|
|
+ const susbjectOptions = tool.dictList('SUBJECT')
|
|
|
+ const paperTypeOptions = tool.dictList('PAPER_TYPE')
|
|
|
+
|
|
|
+ const searchFormRef = ref()
|
|
|
const table = ref()
|
|
|
const formRef = ref()
|
|
|
const toolConfig = { refresh: true, height: true, columnSetting: true, striped: false }
|
|
|
@@ -110,7 +144,7 @@
|
|
|
}
|
|
|
}
|
|
|
const loadData = (parameter) => {
|
|
|
- return tExamPaperApi.tExamPaperPage(parameter).then((data) => {
|
|
|
+ return tExamPaperApi.tExamPaperPage(Object.assign(parameter, formState.value)).then((data) => {
|
|
|
return data
|
|
|
})
|
|
|
}
|
|
|
@@ -136,4 +170,24 @@
|
|
|
table.value.clearRefreshSelected()
|
|
|
})
|
|
|
}
|
|
|
+
|
|
|
+ // 方法
|
|
|
+ const handleSearch = () => {
|
|
|
+ loadData()
|
|
|
+ }
|
|
|
+
|
|
|
+ const handleReset = () => {
|
|
|
+ searchValue.value = null
|
|
|
+ majorIdName.value = null
|
|
|
+ resourceName.value = null
|
|
|
+ formState.fileName = null
|
|
|
+ formState.resourceType = null
|
|
|
+ formState.resourceTwoType = null
|
|
|
+ formState.suffix = null
|
|
|
+ formState.collegeTwoId = null
|
|
|
+ // formState.majorId = null
|
|
|
+ formState.collegeId = null
|
|
|
+ formState.collegeThreeId = null
|
|
|
+ loadData()
|
|
|
+ }
|
|
|
</script>
|