|
@@ -20,6 +20,10 @@
|
|
|
@on-next="toNextImage"
|
|
|
@on-rotate="imageRotateChange"
|
|
|
></image-contain>
|
|
|
+ <div class="archives-student-content-tips">
|
|
|
+ 第{{ curPage.curPageIndex + 1 }}张 /
|
|
|
+ {{ curPage.pindex === 0 ? "正" : "反" }}面
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<div class="archives-student-action part-box">
|
|
|
<div class="archives-student-info">
|
|
@@ -51,25 +55,45 @@
|
|
|
<span>扫描批次号:</span><span>{{ curPage.batchNo }}</span>
|
|
|
</p>
|
|
|
</div>
|
|
|
- <el-divider></el-divider>
|
|
|
- <el-button v-if="showFix" type="primary" size="small" @click="toFix"
|
|
|
- >纠错</el-button
|
|
|
- >
|
|
|
- <el-button
|
|
|
- type="primary"
|
|
|
- size="small"
|
|
|
- :disabled="!curImageRotate"
|
|
|
- :loading="loading"
|
|
|
- @click="toSaveRotate"
|
|
|
- >保存旋转</el-button
|
|
|
- >
|
|
|
- <el-button type="danger" size="small" @click="toDelete"
|
|
|
- >删除</el-button
|
|
|
- >
|
|
|
- <p v-if="showFix" class="tips-info tips-error">
|
|
|
- 注意:<br />
|
|
|
- 当图片里学生信息与右侧学生信息不一致时请执行纠错操作!
|
|
|
- </p>
|
|
|
+ <div class="archives-student-mid">
|
|
|
+ <el-divider></el-divider>
|
|
|
+ <el-button v-if="showFix" type="primary" size="small" @click="toFix"
|
|
|
+ >纠错</el-button
|
|
|
+ >
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ size="small"
|
|
|
+ :disabled="!curImageRotate"
|
|
|
+ :loading="loading"
|
|
|
+ @click="toSaveRotate"
|
|
|
+ >保存旋转</el-button
|
|
|
+ >
|
|
|
+ <el-button type="danger" size="small" @click="toDelete"
|
|
|
+ >删除</el-button
|
|
|
+ >
|
|
|
+ <p v-if="showFix" class="tips-info tips-error">
|
|
|
+ 注意:<br />
|
|
|
+ 当图片里学生信息与右侧学生信息不一致时请执行纠错操作!
|
|
|
+ </p>
|
|
|
+ </div>
|
|
|
+ <div v-if="showFix" class="archives-student-pages">
|
|
|
+ <el-table
|
|
|
+ :data="pageList"
|
|
|
+ height="100%"
|
|
|
+ @selection-change="handleSelectionChange"
|
|
|
+ >
|
|
|
+ <el-table-column
|
|
|
+ type="selection"
|
|
|
+ width="30"
|
|
|
+ align="center"
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column label="全选">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ 第{{ scope.$index + 1 }}张
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
@@ -117,6 +141,7 @@ export default {
|
|
|
pageList: [],
|
|
|
studentInfo: {},
|
|
|
loading: false,
|
|
|
+ multipleSelection: [],
|
|
|
// image preview
|
|
|
curImage: { url: "" },
|
|
|
curImageIndex: 0,
|
|
@@ -145,6 +170,9 @@ export default {
|
|
|
closeHandle() {
|
|
|
this.$emit("close");
|
|
|
},
|
|
|
+ handleSelectionChange(vals) {
|
|
|
+ this.multipleSelection = vals;
|
|
|
+ },
|
|
|
async getImageList() {
|
|
|
const resData = await studentPictureList({
|
|
|
paperScanTaskId: this.student.paperScanTaskId,
|
|
@@ -159,6 +187,18 @@ export default {
|
|
|
},
|
|
|
// actions
|
|
|
toFix() {
|
|
|
+ if (this.multipleSelection.length) {
|
|
|
+ this.studentInfo = {
|
|
|
+ ...this.student,
|
|
|
+ curPagePaperIndex: 0,
|
|
|
+ pageList: this.multipleSelection.map((item) => {
|
|
|
+ return { ...item, paperScanTaskId: this.student.paperScanTaskId };
|
|
|
+ }),
|
|
|
+ };
|
|
|
+ this.$refs.LibraryDialog.open();
|
|
|
+ return;
|
|
|
+ }
|
|
|
+
|
|
|
const info = this.getImageInfo(this.curImage.url);
|
|
|
|
|
|
this.studentInfo = {
|
|
@@ -169,10 +209,12 @@ export default {
|
|
|
this.$refs.LibraryDialog.open();
|
|
|
},
|
|
|
getImageInfo(url) {
|
|
|
- console.log(url);
|
|
|
- const curPage = this.pageList.find((item) => item.fileUrls.includes(url));
|
|
|
+ const curPageIndex = this.pageList.findIndex((item) =>
|
|
|
+ item.fileUrls.includes(url)
|
|
|
+ );
|
|
|
+ const curPage = this.pageList[curPageIndex];
|
|
|
const pindex = curPage.fileUrls.indexOf(url);
|
|
|
- return { ...curPage, pindex };
|
|
|
+ return { ...curPage, curPageIndex, pindex };
|
|
|
},
|
|
|
imageRotateChange(rotate) {
|
|
|
this.curImageRotate = rotate;
|