|
@@ -9,6 +9,8 @@
|
|
|
@to-progress="toProgress"
|
|
|
@to-history="toHistory"
|
|
|
@to-statistics="toStatistics"
|
|
|
+ @on-code-search="serachPaperByCode"
|
|
|
+ @on-mark-search="serachMarkPaper"
|
|
|
></marker-header>
|
|
|
|
|
|
<div
|
|
@@ -23,8 +25,6 @@
|
|
|
:levels="levels"
|
|
|
:key="curPaper.key"
|
|
|
@on-leader-level="leaderSelectLevel"
|
|
|
- @on-code-search="serachPaperByCode"
|
|
|
- @on-grade-change-search="searchGradeChangeList"
|
|
|
v-if="curPaper.id"
|
|
|
ref="GradeAction"
|
|
|
></mark-action>
|
|
@@ -105,7 +105,8 @@ import {
|
|
|
workLevelList,
|
|
|
taskSnSearch,
|
|
|
markStepChangeLevel,
|
|
|
- getParamsSet
|
|
|
+ getParamsSet,
|
|
|
+ markTaskPaperList
|
|
|
} from "@/api";
|
|
|
|
|
|
export default {
|
|
@@ -125,6 +126,7 @@ export default {
|
|
|
questionId: "",
|
|
|
sort: "score,desc"
|
|
|
},
|
|
|
+ speFilter: null,
|
|
|
stage: "SCORE",
|
|
|
workId: this.$route.params.workId,
|
|
|
subjectId: this.$route.params.subjectId,
|
|
@@ -182,28 +184,24 @@ export default {
|
|
|
this.setCurSubject(curSubject || {});
|
|
|
},
|
|
|
async getList() {
|
|
|
- let data = [];
|
|
|
- if (this.curStep.type === "shift") {
|
|
|
- const datas = {
|
|
|
- workId: this.workId,
|
|
|
- subject: this.subject,
|
|
|
- questionId: this.filter.questionId,
|
|
|
- status: this.applyChangeLevelStatus,
|
|
|
- page: this.page.current - 1,
|
|
|
- size: this.page.size
|
|
|
- };
|
|
|
- data = await changeLevelPaperList(datas);
|
|
|
+ let data = {
|
|
|
+ data: [],
|
|
|
+ totalCount: 0,
|
|
|
+ pageCount: 0
|
|
|
+ };
|
|
|
+ if (this.speFilter) {
|
|
|
+ const { type, params } = this.speFilter;
|
|
|
+ if (type === "mark") {
|
|
|
+ data = await this.getMarkList(params);
|
|
|
+ }
|
|
|
} else {
|
|
|
- const datas = {
|
|
|
- ...this.filter,
|
|
|
- isScore: true,
|
|
|
- page: this.page.current - 1,
|
|
|
- size: this.page.size
|
|
|
- };
|
|
|
- if (this.curStep.type === "done") datas.level = this.curStep.name;
|
|
|
-
|
|
|
- data = await paperList(datas);
|
|
|
+ if (this.curStep.type === "shift") {
|
|
|
+ data = await this.getChangeLevelList();
|
|
|
+ } else {
|
|
|
+ data = await this.getCommonList();
|
|
|
+ }
|
|
|
}
|
|
|
+
|
|
|
this.papers = data.data.map(paper => {
|
|
|
paper.key = this.$randomCode();
|
|
|
paper.title = this.IS_ADMIN ? paper.examNumber : `NO.${paper.sn}`;
|
|
@@ -215,6 +213,43 @@ export default {
|
|
|
totalPage: data.pageCount
|
|
|
});
|
|
|
},
|
|
|
+ async getCommonList() {
|
|
|
+ const datas = {
|
|
|
+ ...this.filter,
|
|
|
+ isScore: true,
|
|
|
+ page: this.page.current - 1,
|
|
|
+ size: this.page.size
|
|
|
+ };
|
|
|
+ if (this.curStep.type === "done") datas.level = this.curStep.name;
|
|
|
+
|
|
|
+ const data = await paperList(datas);
|
|
|
+ return data;
|
|
|
+ },
|
|
|
+ async getChangeLevelList() {
|
|
|
+ const datas = {
|
|
|
+ workId: this.workId,
|
|
|
+ subject: this.subject,
|
|
|
+ questionId: this.filter.questionId,
|
|
|
+ status: this.applyChangeLevelStatus,
|
|
|
+ page: this.page.current - 1,
|
|
|
+ size: this.page.size
|
|
|
+ };
|
|
|
+ const data = await changeLevelPaperList(datas);
|
|
|
+ return data;
|
|
|
+ },
|
|
|
+ async getMarkList(params) {
|
|
|
+ const datas = {
|
|
|
+ ...params,
|
|
|
+ workId: this.workId,
|
|
|
+ subject: this.subject,
|
|
|
+ stage: "SCORE",
|
|
|
+ page: this.page.current - 1,
|
|
|
+ size: this.page.size
|
|
|
+ };
|
|
|
+
|
|
|
+ const data = await markTaskPaperList(datas);
|
|
|
+ return data;
|
|
|
+ },
|
|
|
async toPage(page) {
|
|
|
this.setPage({
|
|
|
current: page
|
|
@@ -290,6 +325,7 @@ export default {
|
|
|
this.selectPaper(this.curPaperIndex);
|
|
|
},
|
|
|
async stepChange(step) {
|
|
|
+ this.speFilter = null;
|
|
|
this.applyChangeLevelStatus = 1;
|
|
|
this.setCurStep(step);
|
|
|
this.setPage({ current: 1 });
|
|
@@ -303,6 +339,7 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
async areaChange(curArea) {
|
|
|
+ this.speFilter = null;
|
|
|
this.setCurArea(curArea);
|
|
|
this.filter.questionId = curArea.id;
|
|
|
await this.getStepLevels();
|
|
@@ -368,6 +405,7 @@ export default {
|
|
|
this.selectPaper(this.curPaperIndex);
|
|
|
},
|
|
|
async serachPaperByCode(params) {
|
|
|
+ this.speFilter = null;
|
|
|
const data = await taskSnSearch(
|
|
|
params.codeType,
|
|
|
params.code,
|
|
@@ -382,8 +420,13 @@ export default {
|
|
|
this.setPage({ current: 1, total: 1, totalPage: 1 });
|
|
|
this.selectPaper(0);
|
|
|
},
|
|
|
- searchGradeChangeList(applyChangeLevelStatus) {
|
|
|
- this.applyChangeLevelStatus = applyChangeLevelStatus;
|
|
|
+ // searchGradeChangeList(applyChangeLevelStatus) {
|
|
|
+ // this.applyChangeLevelStatus = applyChangeLevelStatus;
|
|
|
+ // this.toPage(1);
|
|
|
+ // },
|
|
|
+ serachMarkPaper(data) {
|
|
|
+ console.log(data);
|
|
|
+ this.speFilter = { type: data.type, params: data.params };
|
|
|
this.toPage(1);
|
|
|
},
|
|
|
leaderSelectLevel(levelInfo) {
|