|
@@ -2,15 +2,15 @@
|
|
|
<div class="mark-param-group">
|
|
|
<div class="box-justify part-box part-box-pad">
|
|
|
<div>
|
|
|
- <p v-if="unsetQuestionNos.length" class="tips-info tips-error">
|
|
|
+ <p v-if="unsetQuestionNos" class="tips-info tips-error">
|
|
|
试题{{
|
|
|
- unsetQuestionNos.join(",")
|
|
|
+ unsetQuestionNos
|
|
|
}}未设置评卷员,请点击列表里设置评卷员选择评卷员
|
|
|
</p>
|
|
|
</div>
|
|
|
<div>
|
|
|
- <el-button type="primary" @click="toPrev">上一步</el-button>
|
|
|
- <el-button type="primary" @click="toNext">下一步</el-button>
|
|
|
+ <el-button type="primary" @click="toPrev(1)">上一步</el-button>
|
|
|
+ <el-button type="primary" @click="toNext(1)">下一步</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
@@ -21,13 +21,15 @@
|
|
|
:span-method="openMergeMarker ? objectSpanMethod : undefined"
|
|
|
>
|
|
|
<el-table-column label="大题名称" prop="mainTitle"> </el-table-column>
|
|
|
- <el-table-column label="大题号" prop="mainNumber"> </el-table-column>
|
|
|
- <el-table-column label="小题号" prop="subNumber"> </el-table-column>
|
|
|
- <el-table-column label="评卷员">
|
|
|
+ <el-table-column label="大题号" prop="mainNumber" width="80">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="小题号" prop="subNumber" width="80">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column label="评卷员" min-width="200">
|
|
|
<template slot-scope="scope">
|
|
|
<el-tag
|
|
|
v-for="user in scope.row.markers"
|
|
|
- :key="user.id"
|
|
|
+ :key="user.markUserQuestionId"
|
|
|
class="tag-spin tag-wrap"
|
|
|
size="medium"
|
|
|
effect="dark"
|
|
@@ -36,7 +38,11 @@
|
|
|
>
|
|
|
{{ user.name }}({{ user.loginName }})
|
|
|
</el-tag>
|
|
|
- <el-button type="text" @click="toSetMarker(scope.row)">
|
|
|
+ <el-button
|
|
|
+ type="text"
|
|
|
+ class="btn-primary"
|
|
|
+ @click="toSetMarker(scope.row)"
|
|
|
+ >
|
|
|
设置评卷员
|
|
|
</el-button>
|
|
|
</template>
|
|
@@ -64,7 +70,7 @@
|
|
|
<el-table-column label="评卷区" width="80" align="center">
|
|
|
<template slot-scope="scope">
|
|
|
<i
|
|
|
- v-if="scope.row.pictureConfigs.length"
|
|
|
+ v-if="scope.row.pictureConfigs?.length"
|
|
|
class="el-icon-success color-success"
|
|
|
></i>
|
|
|
</template>
|
|
@@ -89,7 +95,7 @@
|
|
|
</el-table>
|
|
|
|
|
|
<!-- subjective answer -->
|
|
|
- <el-form>
|
|
|
+ <el-form class="mt-2" label-width="150px">
|
|
|
<el-form-item label="请上传标答PDF文档:">
|
|
|
<mark-param-subjective-answer></mark-param-subjective-answer>
|
|
|
</el-form-item>
|
|
@@ -132,6 +138,7 @@ import {
|
|
|
markSubjectiveBindMarker,
|
|
|
markSubjectiveUpdateMarkType,
|
|
|
markSubjectiveUpdateMarkArea,
|
|
|
+ markSubjectiveUnbindMarker,
|
|
|
} from "../../api";
|
|
|
import { cardDetail } from "../../../card/api";
|
|
|
import { SCORE_POLICY_TYPE } from "@/constants/enumerate";
|
|
@@ -166,6 +173,12 @@ export default {
|
|
|
"openMergeMarker",
|
|
|
"subjectiveTaskList",
|
|
|
]),
|
|
|
+ unsetQuestionNos() {
|
|
|
+ return this.subjectiveTaskList
|
|
|
+ .filter((item) => !item.markers.length)
|
|
|
+ .map((item) => `${item.mainNumber}-${item.subNumber}`)
|
|
|
+ .join(",");
|
|
|
+ },
|
|
|
},
|
|
|
mounted() {
|
|
|
this.initFillQuestionRanges();
|
|
@@ -241,7 +254,7 @@ export default {
|
|
|
if (this.openMergeMarker && row.questionType === 3) {
|
|
|
// 填空题按大题批量处理
|
|
|
const pos = this.subjectiveTaskList.findIndex(
|
|
|
- (item) => item.questionId === row.questionId
|
|
|
+ (item) => item.id === row.id
|
|
|
);
|
|
|
if (pos === -1) return;
|
|
|
const range = this.fillQuestionRanges.find((item) =>
|
|
@@ -251,7 +264,7 @@ export default {
|
|
|
this.curRowQuestions = range.map((index) => {
|
|
|
const item = this.subjectiveTaskList[index];
|
|
|
return {
|
|
|
- questionId: item.questionId,
|
|
|
+ id: item.id,
|
|
|
mainNumber: item.mainNumber,
|
|
|
subNumber: item.subNumber,
|
|
|
};
|
|
@@ -260,7 +273,7 @@ export default {
|
|
|
// 非填空题按单题处理
|
|
|
this.curRowQuestions = [
|
|
|
{
|
|
|
- questionId: row.questionId,
|
|
|
+ id: row.id,
|
|
|
mainNumber: row.mainNumber,
|
|
|
subNumber: row.subNumber,
|
|
|
},
|
|
@@ -273,13 +286,13 @@ export default {
|
|
|
await markSubjectiveBindMarker({
|
|
|
examId: this.basicInfo.examId,
|
|
|
paperNumber: this.basicInfo.paperNumber,
|
|
|
- questionIds: this.curRowQuestions.map((item) => item.questionId),
|
|
|
+ questionIds: this.curRowQuestions.map((item) => item.id),
|
|
|
markers: row.markers,
|
|
|
});
|
|
|
|
|
|
this.curRowQuestions.forEach((item) => {
|
|
|
this.updateSubjectiveTaskItem({
|
|
|
- questionId: item.questionId,
|
|
|
+ id: item.id,
|
|
|
markers: row.markers,
|
|
|
});
|
|
|
});
|
|
@@ -290,15 +303,18 @@ export default {
|
|
|
},
|
|
|
async areaModified(row) {
|
|
|
const pos = this.subjectiveTaskList.findIndex(
|
|
|
- (item) => item.questionId === row.questionId
|
|
|
+ (item) => item.id === row.id
|
|
|
);
|
|
|
if (pos === -1) return;
|
|
|
const datas = {
|
|
|
- questionId: row.questionId,
|
|
|
+ questionId: row.id,
|
|
|
pictureConfigs: row.pictureConfigs,
|
|
|
};
|
|
|
await markSubjectiveUpdateMarkArea(datas);
|
|
|
- this.updateSubjectiveTaskItem(datas);
|
|
|
+ this.updateSubjectiveTaskItem({
|
|
|
+ id: row.id,
|
|
|
+ pictureConfigs: row.pictureConfigs,
|
|
|
+ });
|
|
|
},
|
|
|
async toDeleteMarker(row, marker) {
|
|
|
const confirm = await this.$confirm(`确定要删除当前评卷员吗?`, "提示", {
|
|
@@ -306,17 +322,14 @@ export default {
|
|
|
}).catch(() => {});
|
|
|
if (confirm !== "confirm") return;
|
|
|
|
|
|
- const markers = row.markers.filter((item) => item.id !== marker.id);
|
|
|
- const datas = {
|
|
|
- questionId: row.questionId,
|
|
|
+ const markers = row.markers.filter(
|
|
|
+ (item) => item.markUserQuestionId !== marker.markUserQuestionId
|
|
|
+ );
|
|
|
+ await markSubjectiveUnbindMarker(marker.markUserQuestionId);
|
|
|
+ this.updateSubjectiveTaskItem({
|
|
|
+ id: row.id,
|
|
|
markers,
|
|
|
- };
|
|
|
- await markSubjectiveBindMarker({
|
|
|
- examId: this.basicInfo.examId,
|
|
|
- paperNumber: this.basicInfo.paperNumber,
|
|
|
- ...datas,
|
|
|
});
|
|
|
- this.updateSubjectiveTaskItem(datas);
|
|
|
},
|
|
|
toSetMarkType(row) {
|
|
|
this.curRow = row;
|
|
@@ -324,11 +337,11 @@ export default {
|
|
|
},
|
|
|
async markTypeModified(row) {
|
|
|
const pos = this.subjectiveTaskList.findIndex(
|
|
|
- (item) => item.questionId === row.questionId
|
|
|
+ (item) => item.id === row.id
|
|
|
);
|
|
|
if (pos === -1) return;
|
|
|
const datas = {
|
|
|
- id: row.questionId,
|
|
|
+ id: row.id,
|
|
|
doubleEnable: row.doubleEnable,
|
|
|
doubleRate: row.doubleRate,
|
|
|
arbitrateThreshold: row.arbitrateThreshold,
|