|
@@ -18,7 +18,7 @@
|
|
|
:columns="taskColumns"
|
|
:columns="taskColumns"
|
|
|
:data-source="taskList"
|
|
:data-source="taskList"
|
|
|
:expand-row-by-click="true"
|
|
:expand-row-by-click="true"
|
|
|
- :pagination="queryParam"
|
|
|
|
|
|
|
+ :pagination="pagination"
|
|
|
>
|
|
>
|
|
|
<template #bodyCell="{ column, record }">
|
|
<template #bodyCell="{ column, record }">
|
|
|
<div v-if="examType != 4">
|
|
<div v-if="examType != 4">
|
|
@@ -176,8 +176,8 @@
|
|
|
try {
|
|
try {
|
|
|
let res = []
|
|
let res = []
|
|
|
const params = {
|
|
const params = {
|
|
|
- ...queryParam.value,
|
|
|
|
|
- size: queryParam.value.pageSize,
|
|
|
|
|
|
|
+ current:pagination.value.current,
|
|
|
|
|
+ size: pagination.value.pageSize,
|
|
|
courseId: route.query.id,
|
|
courseId: route.query.id,
|
|
|
paperType: paperType.value,
|
|
paperType: paperType.value,
|
|
|
examType: examType.value
|
|
examType: examType.value
|
|
@@ -189,15 +189,20 @@
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
taskList.value = res?.records || []
|
|
taskList.value = res?.records || []
|
|
|
|
|
+ pagination.value.total = res.total
|
|
|
} catch (e) {
|
|
} catch (e) {
|
|
|
taskList.value = []
|
|
taskList.value = []
|
|
|
}
|
|
}
|
|
|
taskLoading.value = false
|
|
taskLoading.value = false
|
|
|
}
|
|
}
|
|
|
// 学科分类
|
|
// 学科分类
|
|
|
- const queryParam = ref({
|
|
|
|
|
|
|
+ const pagination = ref({
|
|
|
current: 1,
|
|
current: 1,
|
|
|
- pageSize: 10
|
|
|
|
|
|
|
+ pageSize: 10,
|
|
|
|
|
+ onChange: (current) => {
|
|
|
|
|
+ pagination.value.current = current
|
|
|
|
|
+ getTaskList()
|
|
|
|
|
+ }
|
|
|
})
|
|
})
|
|
|
const tabId = ref('')
|
|
const tabId = ref('')
|
|
|
const subjectList = ref([])
|
|
const subjectList = ref([])
|
|
@@ -211,7 +216,7 @@
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
const handleChange = (value) => {
|
|
const handleChange = (value) => {
|
|
|
- queryParam.value.subjectId = value
|
|
|
|
|
|
|
+ pagination.value.subjectId = value
|
|
|
getTaskList()
|
|
getTaskList()
|
|
|
}
|
|
}
|
|
|
// lifecycle
|
|
// lifecycle
|