|
@@ -7,7 +7,15 @@
|
|
|
@click="onOperationClick"
|
|
|
>
|
|
|
<!-- <el-button type="primary" size="small" class="m-l-base" @click="onEditScore">修改给分</el-button> -->
|
|
|
- <el-button type="primary" size="small" class="m-l-base m-r-auto" @click="onConfirm">提交确认</el-button>
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ size="small"
|
|
|
+ class="m-l-base m-r-auto"
|
|
|
+ :disabled="currentSubjectiveCheck"
|
|
|
+ :loading="confirmLoading"
|
|
|
+ @click="onConfirm"
|
|
|
+ >提交确认</el-button
|
|
|
+ >
|
|
|
</mark-header>
|
|
|
<div class="flex flex-1 overflow-hidden p-base mark-container">
|
|
|
<splitpanes class="default-theme" style="height: 100%" @resize="setPaneSize">
|
|
@@ -61,7 +69,9 @@
|
|
|
style="margin-top: 20px"
|
|
|
>
|
|
|
<template #form-item-search>
|
|
|
- <el-button :loading="loading" type="primary" @click="onSearch">查询</el-button>
|
|
|
+ <el-button :loading="loading" type="primary" :disabled="confirmLoading" @click="onSearch"
|
|
|
+ >查询</el-button
|
|
|
+ >
|
|
|
</template>
|
|
|
</base-form>
|
|
|
<div class="m-b-mini">
|
|
@@ -397,10 +407,22 @@ const onSubmit = async () => {
|
|
|
/** 确认 */
|
|
|
const { fetch: subjectiveCheckConfirm } = useFetch('subjectiveCheckConfirm')
|
|
|
|
|
|
+const confirmLoading = ref(false)
|
|
|
+const hideLoading = () => {
|
|
|
+ setTimeout(() => {
|
|
|
+ confirmLoading.value = false
|
|
|
+ })
|
|
|
+}
|
|
|
const onConfirm = async () => {
|
|
|
if (currentSubjectiveCheck.value) {
|
|
|
- await subjectiveCheckConfirm({ taskId: currentSubjectiveCheck.value.taskId })
|
|
|
- await onSearch()
|
|
|
+ confirmLoading.value = true
|
|
|
+ try {
|
|
|
+ await subjectiveCheckConfirm({ taskId: currentSubjectiveCheck.value.taskId })
|
|
|
+ await onSearch()
|
|
|
+ hideLoading()
|
|
|
+ } catch (e) {
|
|
|
+ hideLoading()
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
|