|
@@ -1,13 +1,60 @@
|
|
<template>
|
|
<template>
|
|
<div class="marker-grading">
|
|
<div class="marker-grading">
|
|
<marker-header
|
|
<marker-header
|
|
- :data="workSubject"
|
|
|
|
|
|
+ :steps="steps"
|
|
@area-change="areaChange"
|
|
@area-change="areaChange"
|
|
|
|
+ @step-change="stepChange"
|
|
|
|
+ @page-set-change="pageSetChange"
|
|
@to-history="toHistory"
|
|
@to-history="toHistory"
|
|
@to-standard="toStandard"
|
|
@to-standard="toStandard"
|
|
></marker-header>
|
|
></marker-header>
|
|
|
|
|
|
- <div class="marker-action"></div>
|
|
|
|
|
|
+ <div
|
|
|
|
+ :class="[
|
|
|
|
+ 'marker-action',
|
|
|
|
+ { 'marker-action-fullscreen': isFullscreenMarking }
|
|
|
|
+ ]"
|
|
|
|
+ v-show="!multipleGradingList.length"
|
|
|
|
+ >
|
|
|
|
+ <grade-action
|
|
|
|
+ :cur-paper-or-task="curPaper"
|
|
|
|
+ :levels="levels"
|
|
|
|
+ :params-set="paramsSet"
|
|
|
|
+ @on-select-level="gradeCurPaper"
|
|
|
|
+ @on-pass="passCurPaper"
|
|
|
|
+ ref="GradeAction"
|
|
|
|
+ v-if="curPaper.id"
|
|
|
|
+ ></grade-action>
|
|
|
|
+ </div>
|
|
|
|
+ <!-- multiple grading action -->
|
|
|
|
+ <div class="marker-action" v-show="multipleGradingList.length">
|
|
|
|
+ <div class="grade-action">
|
|
|
|
+ <div class="action-paper-state">
|
|
|
|
+ <p class="paper-state-cont">批量分档</p>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="action-paper-info">
|
|
|
|
+ <p><span>任务密号:</span><span>--</span></p>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="action-grade-list">
|
|
|
|
+ <div
|
|
|
|
+ class="action-grade-item"
|
|
|
|
+ v-for="(level, index) in levels"
|
|
|
|
+ :key="index"
|
|
|
|
+ >
|
|
|
|
+ <div
|
|
|
|
+ :class="[
|
|
|
|
+ 'action-grade-item-content',
|
|
|
|
+ { 'action-item-content-disabled': multiplebtnClicked }
|
|
|
|
+ ]"
|
|
|
|
+ @click="multipleSelectLevel(level)"
|
|
|
|
+ >
|
|
|
|
+ <p>{{ level.name }}</p>
|
|
|
|
+ <p>{{ level.minScore }}~{{ level.maxScore }}</p>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
|
|
<div class="marker-body">
|
|
<div class="marker-body">
|
|
<div :class="markerImageListClasses" v-if="papers.length">
|
|
<div :class="markerImageListClasses" v-if="papers.length">
|
|
@@ -25,25 +72,55 @@
|
|
<marker-image-view
|
|
<marker-image-view
|
|
:data="paper"
|
|
:data="paper"
|
|
@to-review="toReview(index)"
|
|
@to-review="toReview(index)"
|
|
- @to-check="toCheck"
|
|
|
|
|
|
+ @to-select="selectMultiplePaper"
|
|
></marker-image-view>
|
|
></marker-image-view>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
+ <div v-else class="marker-image-none">暂无数据</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- MarkerHistory -->
|
|
<!-- MarkerHistory -->
|
|
<marker-history
|
|
<marker-history
|
|
:question-id="filter.questionId"
|
|
:question-id="filter.questionId"
|
|
|
|
+ @on-paper-click="
|
|
|
|
+ (index, papers) => {
|
|
|
|
+ toViewCarouselPaper(index, papers, 'history');
|
|
|
|
+ }
|
|
|
|
+ "
|
|
ref="MarkerHistory"
|
|
ref="MarkerHistory"
|
|
></marker-history>
|
|
></marker-history>
|
|
<!-- MarkerStandard -->
|
|
<!-- MarkerStandard -->
|
|
<marker-standard
|
|
<marker-standard
|
|
:question-id="filter.questionId"
|
|
:question-id="filter.questionId"
|
|
:levels="levels"
|
|
:levels="levels"
|
|
|
|
+ @on-paper-click="
|
|
|
|
+ (index, papers) => {
|
|
|
|
+ toViewCarouselPaper(index, papers, 'sample');
|
|
|
|
+ }
|
|
|
|
+ "
|
|
ref="MarkerStandard"
|
|
ref="MarkerStandard"
|
|
v-if="levels.length && filter.questionId && paramsSet.showSample"
|
|
v-if="levels.length && filter.questionId && paramsSet.showSample"
|
|
></marker-standard>
|
|
></marker-standard>
|
|
|
|
+ <!-- image-preview -->
|
|
|
|
+ <simple-image-preview
|
|
|
|
+ class="grading-operation-image-preview"
|
|
|
|
+ :cur-image="curPaper"
|
|
|
|
+ @on-prev="toPrevPaper"
|
|
|
|
+ @on-next="toNextPaper"
|
|
|
|
+ @on-close="isFullscreenMarking = false"
|
|
|
|
+ ref="SimpleImagePreview"
|
|
|
|
+ ></simple-image-preview>
|
|
|
|
+
|
|
|
|
+ <!-- carousel paper review -->
|
|
|
|
+ <simple-image-preview
|
|
|
|
+ class="grading-operation-image-preview"
|
|
|
|
+ :cur-image="curPaper"
|
|
|
|
+ @on-prev="toCarousePaper('prev')"
|
|
|
|
+ @on-next="toCarousePaper('next')"
|
|
|
|
+ @on-close="carouseImagePreviewClose"
|
|
|
|
+ ref="CarouselPapersPreview"
|
|
|
|
+ ></simple-image-preview>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
@@ -52,6 +129,9 @@ import MarkerHeader from "./MarkerHeader";
|
|
import MarkerImageView from "./MarkerImageView";
|
|
import MarkerImageView from "./MarkerImageView";
|
|
import MarkerHistory from "./MarkerHistory";
|
|
import MarkerHistory from "./MarkerHistory";
|
|
import MarkerStandard from "./MarkerStandard";
|
|
import MarkerStandard from "./MarkerStandard";
|
|
|
|
+import GradeAction from "../components/GradeAction";
|
|
|
|
+import SimpleImagePreview from "@/components/SimpleImagePreview";
|
|
|
|
+
|
|
import {
|
|
import {
|
|
markerTaskList,
|
|
markerTaskList,
|
|
markerLevelTotalStatData,
|
|
markerLevelTotalStatData,
|
|
@@ -64,7 +144,14 @@ import {
|
|
|
|
|
|
export default {
|
|
export default {
|
|
name: "marker-grading",
|
|
name: "marker-grading",
|
|
- components: { MarkerHeader, MarkerImageView, MarkerHistory, MarkerStandard },
|
|
|
|
|
|
+ components: {
|
|
|
|
+ MarkerHeader,
|
|
|
|
+ MarkerImageView,
|
|
|
|
+ MarkerHistory,
|
|
|
|
+ MarkerStandard,
|
|
|
|
+ GradeAction,
|
|
|
|
+ SimpleImagePreview
|
|
|
|
+ },
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
filter: {
|
|
filter: {
|
|
@@ -92,13 +179,21 @@ export default {
|
|
totalPage: 1,
|
|
totalPage: 1,
|
|
curStep: null,
|
|
curStep: null,
|
|
curStandardGradeId: "",
|
|
curStandardGradeId: "",
|
|
- steps: [],
|
|
|
|
|
|
+ steps: { levelStep: [], otherStep: [] },
|
|
levels: [],
|
|
levels: [],
|
|
curArea: {},
|
|
curArea: {},
|
|
papers: [],
|
|
papers: [],
|
|
curPaper: {},
|
|
curPaper: {},
|
|
curPaperIndex: 0,
|
|
curPaperIndex: 0,
|
|
- paramsSet: {}
|
|
|
|
|
|
+ paramsSet: {},
|
|
|
|
+ // multiple grading
|
|
|
|
+ multiplebtnClicked: false,
|
|
|
|
+ multipleGradingList: [],
|
|
|
|
+ // carousel paper review,
|
|
|
|
+ carouselType: "",
|
|
|
|
+ carouselPapers: [],
|
|
|
|
+ curCarouselPaperIndex: 0,
|
|
|
|
+ isFullscreenMarking: false
|
|
};
|
|
};
|
|
},
|
|
},
|
|
computed: {
|
|
computed: {
|
|
@@ -233,10 +328,11 @@ export default {
|
|
};
|
|
};
|
|
});
|
|
});
|
|
},
|
|
},
|
|
- pageSizeChange(size) {
|
|
|
|
- this.size = size;
|
|
|
|
- this.toPage(1);
|
|
|
|
- this.getStepLevels();
|
|
|
|
|
|
+ pageSetChange(page) {
|
|
|
|
+ this.size = page.pageSize;
|
|
|
|
+ this.current = page.current;
|
|
|
|
+ this.papers = [];
|
|
|
|
+ this.getList();
|
|
},
|
|
},
|
|
async stepChange(step) {
|
|
async stepChange(step) {
|
|
this.curStep = step;
|
|
this.curStep = step;
|
|
@@ -257,13 +353,14 @@ export default {
|
|
this.filter.questionId = curArea.id;
|
|
this.filter.questionId = curArea.id;
|
|
await this.getStepLevels();
|
|
await this.getStepLevels();
|
|
this.toPage(1);
|
|
this.toPage(1);
|
|
- // this.updateHistory();
|
|
|
|
},
|
|
},
|
|
// selectMultiplePaper
|
|
// selectMultiplePaper
|
|
selectMultiplePaper(paper) {
|
|
selectMultiplePaper(paper) {
|
|
if (paper.sample) return;
|
|
if (paper.sample) return;
|
|
- paper.selected = !paper.selected;
|
|
|
|
|
|
+ const curPaper = this.papers.find(p => p.id === paper.id);
|
|
|
|
+ curPaper.selected = paper.selected;
|
|
this.multipleGradingList = this.papers.filter(paper => paper.selected);
|
|
this.multipleGradingList = this.papers.filter(paper => paper.selected);
|
|
|
|
+ console.log(this.multipleGradingList);
|
|
},
|
|
},
|
|
async multipleSelectLevel(level) {
|
|
async multipleSelectLevel(level) {
|
|
if (!this.multipleGradingList.length) return;
|
|
if (!this.multipleGradingList.length) return;
|
|
@@ -272,7 +369,7 @@ export default {
|
|
const multipleGradingListCount = this.multipleGradingList.length;
|
|
const multipleGradingListCount = this.multipleGradingList.length;
|
|
|
|
|
|
let result = true;
|
|
let result = true;
|
|
- const papers = await paperSelectLevelBatch(
|
|
|
|
|
|
+ await paperSelectLevelBatch(
|
|
this.multipleGradingList.map(item => item.id).join(), // is taskId
|
|
this.multipleGradingList.map(item => item.id).join(), // is taskId
|
|
level.name,
|
|
level.name,
|
|
"LEVEL"
|
|
"LEVEL"
|
|
@@ -286,7 +383,6 @@ export default {
|
|
this.multipleGradingList = [];
|
|
this.multipleGradingList = [];
|
|
// this.getStepLevels();
|
|
// this.getStepLevels();
|
|
this.updateStepLevel(this.curStep, level.name, multipleGradingListCount);
|
|
this.updateStepLevel(this.curStep, level.name, multipleGradingListCount);
|
|
- this.updateHistory(papers);
|
|
|
|
|
|
|
|
// update paper list
|
|
// update paper list
|
|
if (
|
|
if (
|
|
@@ -300,9 +396,6 @@ export default {
|
|
await this.getList();
|
|
await this.getList();
|
|
this.selectPaper(this.curPaperIndex);
|
|
this.selectPaper(this.curPaperIndex);
|
|
},
|
|
},
|
|
- toCheck(paper) {
|
|
|
|
- console.log(paper);
|
|
|
|
- },
|
|
|
|
// paper view action
|
|
// paper view action
|
|
toReview(index) {
|
|
toReview(index) {
|
|
this.isFullscreenMarking = true;
|
|
this.isFullscreenMarking = true;
|
|
@@ -370,20 +463,14 @@ export default {
|
|
level.name,
|
|
level.name,
|
|
"LEVEL"
|
|
"LEVEL"
|
|
);
|
|
);
|
|
|
|
+ if (!paper) return;
|
|
this.updateStepLevel(this.curStep, level.name, 1);
|
|
this.updateStepLevel(this.curStep, level.name, 1);
|
|
- this.updateCacheHistory([paper]);
|
|
|
|
this.toActionNextPaper();
|
|
this.toActionNextPaper();
|
|
},
|
|
},
|
|
async passCurPaper() {
|
|
async passCurPaper() {
|
|
await paperTaskPass(this.curPaper.id);
|
|
await paperTaskPass(this.curPaper.id);
|
|
this.toActionNextPaper();
|
|
this.toActionNextPaper();
|
|
},
|
|
},
|
|
- updateHistory() {
|
|
|
|
- this.$refs.GradeHistoryPaper.updatePapers();
|
|
|
|
- },
|
|
|
|
- updateCacheHistory(papers) {
|
|
|
|
- this.$refs.GradeHistoryPaper.updateCachePapers(papers);
|
|
|
|
- },
|
|
|
|
// paper carousel
|
|
// paper carousel
|
|
toViewCarouselPaper(paperIndex, papers, type) {
|
|
toViewCarouselPaper(paperIndex, papers, type) {
|
|
this.carouselType = type;
|
|
this.carouselType = type;
|
|
@@ -399,10 +486,10 @@ export default {
|
|
this.curPaper = { ...this.carouselPapers[index] };
|
|
this.curPaper = { ...this.carouselPapers[index] };
|
|
},
|
|
},
|
|
toCarousePaper(type) {
|
|
toCarousePaper(type) {
|
|
- if (this.carouselType === "sample") {
|
|
|
|
- this.toSampleCarousePaper(type);
|
|
|
|
- return;
|
|
|
|
- }
|
|
|
|
|
|
+ // if (this.carouselType === "sample") {
|
|
|
|
+ // this.toSampleCarousePaper(type);
|
|
|
|
+ // return;
|
|
|
|
+ // }
|
|
if (type === "prev" && this.curCarouselPaperIndex > 0) {
|
|
if (type === "prev" && this.curCarouselPaperIndex > 0) {
|
|
this.curCarouselPaperIndex--;
|
|
this.curCarouselPaperIndex--;
|
|
} else if (
|
|
} else if (
|
|
@@ -425,10 +512,6 @@ export default {
|
|
this.carouselType = "";
|
|
this.carouselType = "";
|
|
this.selectPaper(this.curPaperIndex);
|
|
this.selectPaper(this.curPaperIndex);
|
|
},
|
|
},
|
|
- standardPaperChange(curPaper) {
|
|
|
|
- if (!this.isFullscreenMarking) return;
|
|
|
|
- this.curPaper = { ...curPaper };
|
|
|
|
- },
|
|
|
|
// header
|
|
// header
|
|
toHistory() {
|
|
toHistory() {
|
|
this.$refs.MarkerHistory.open();
|
|
this.$refs.MarkerHistory.open();
|