|
@@ -66,7 +66,7 @@
|
|
|
|
|
|
<script setup lang="ts" name="MarkingMark">
|
|
<script setup lang="ts" name="MarkingMark">
|
|
/** 阅卷-正式评卷 */
|
|
/** 阅卷-正式评卷 */
|
|
-import { computed, nextTick, ref, watch, onBeforeUnmount } from 'vue'
|
|
|
|
|
|
+import { computed, nextTick, ref, watch, onBeforeUnmount, unref } from 'vue'
|
|
import { useRouter } from 'vue-router'
|
|
import { useRouter } from 'vue-router'
|
|
import { ElButton, ElRadioGroup, ElRadioButton, ElRadio, ElMessage } from 'element-plus'
|
|
import { ElButton, ElRadioGroup, ElRadioButton, ElRadio, ElMessage } from 'element-plus'
|
|
import { minus } from '@/utils/common'
|
|
import { minus } from '@/utils/common'
|
|
@@ -134,7 +134,8 @@ type FormalTaskType = ExtractArrayValue<ExtractApiResponse<'getMarkingTask'>>
|
|
|
|
|
|
type TaskInfoType = FormalTaskType | HistoryTaskType
|
|
type TaskInfoType = FormalTaskType | HistoryTaskType
|
|
|
|
|
|
-let currentTaskPool: ExtractApiResponse<'getMarkingTask'> = []
|
|
|
|
|
|
+// let currentTaskPool: ExtractApiResponse<'getMarkingTask'> = []
|
|
|
|
+let currentTaskPool: any = []
|
|
|
|
|
|
const currentTask = ref<TaskInfoType>()
|
|
const currentTask = ref<TaskInfoType>()
|
|
|
|
|
|
@@ -145,7 +146,8 @@ const excludeOperations = computed<excludeOperationTypes>(() => {
|
|
return ['delete', 'bookmark']
|
|
return ['delete', 'bookmark']
|
|
}
|
|
}
|
|
const isSampleType = ['SAMPLE_A', 'SAMPLE_B'].includes(currentTask.value.taskType)
|
|
const isSampleType = ['SAMPLE_A', 'SAMPLE_B'].includes(currentTask.value.taskType)
|
|
- return ['delete', 'bookmark'].concat(isSampleType ? ['problem'] : []) as excludeOperationTypes
|
|
|
|
|
|
+ // return ['delete', 'bookmark'].concat(isSampleType ? ['problem'] : []) as excludeOperationTypes
|
|
|
|
+ return ['delete', 'bookmark']
|
|
})
|
|
})
|
|
|
|
|
|
const { fetch: getMarkingTask, loading } = useFetch('getMarkingTask')
|
|
const { fetch: getMarkingTask, loading } = useFetch('getMarkingTask')
|
|
@@ -153,6 +155,11 @@ const { fetch: submitMarkTask, loading: submitting } = useFetch('submitMarkTask'
|
|
const { fetch: getMarkStatus, result: markStatus } = useFetch('getMarkStatus')
|
|
const { fetch: getMarkStatus, result: markStatus } = useFetch('getMarkStatus')
|
|
|
|
|
|
const historyTaskChange = (task: HistoryTaskType) => {
|
|
const historyTaskChange = (task: HistoryTaskType) => {
|
|
|
|
+ let saveTargetTask = unref(currentTask)
|
|
|
|
+ console.log('saveTargetTask:', saveTargetTask)
|
|
|
|
+ if (currentTaskType.value != 'remarking') {
|
|
|
|
+ currentTaskPool.unshift(saveTargetTask)
|
|
|
|
+ }
|
|
currentTask.value = task
|
|
currentTask.value = task
|
|
currentTaskType.value = 'remarking'
|
|
currentTaskType.value = 'remarking'
|
|
nextTick(() => {
|
|
nextTick(() => {
|
|
@@ -302,6 +309,10 @@ const onConfirmSubmitProblem = async () => {
|
|
if (!currentTask.value) {
|
|
if (!currentTask.value) {
|
|
return
|
|
return
|
|
}
|
|
}
|
|
|
|
+ if (currentTask.value.taskType !== 'FORMAL') {
|
|
|
|
+ ElMessage.error('该试卷类型不能提交问题卷')
|
|
|
|
+ return
|
|
|
|
+ }
|
|
problemVisible.value = false
|
|
problemVisible.value = false
|
|
if (problemClass.value === 'similar') {
|
|
if (problemClass.value === 'similar') {
|
|
await onSubmitSimilar()
|
|
await onSubmitSimilar()
|