|
@@ -68,7 +68,7 @@
|
|
|
<div style="margin-bottom:10px;">
|
|
<div style="margin-bottom:10px;">
|
|
|
<i class="el-icon-delete" @click="ansCardImgList.splice(index,1)"
|
|
<i class="el-icon-delete" @click="ansCardImgList.splice(index,1)"
|
|
|
style="float:right;color:red;cursor: pointer;"></i>
|
|
style="float:right;color:red;cursor: pointer;"></i>
|
|
|
- <i class="el-icon-edit" @click="editAnsCard(item,curPaperId)"
|
|
|
|
|
|
|
+ <i class="el-icon-edit" @click="editAnsCard(item,curPaperId,index)"
|
|
|
style="float:right;color:blue;margin-right:20px;cursor: pointer;"></i>
|
|
style="float:right;color:blue;margin-right:20px;cursor: pointer;"></i>
|
|
|
<div class="clear"></div>
|
|
<div class="clear"></div>
|
|
|
</div>
|
|
</div>
|
|
@@ -108,7 +108,6 @@
|
|
|
<!-- 客观题设置 -->
|
|
<!-- 客观题设置 -->
|
|
|
<el-dialog title="客观题设置" :visible.sync="open" width="90%" append-to-body>
|
|
<el-dialog title="客观题设置" :visible.sync="open" width="90%" append-to-body>
|
|
|
<el-row :gutter="20">
|
|
<el-row :gutter="20">
|
|
|
-
|
|
|
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
|
<h4>分数设置</h4>
|
|
<h4>分数设置</h4>
|
|
|
<!-- <div class="tag-group">
|
|
<!-- <div class="tag-group">
|
|
@@ -151,7 +150,7 @@
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</el-form>
|
|
</el-form>
|
|
|
|
|
|
|
|
- <el-table :data="stdQueList.slice((currentPage-1)*pageSize,currentPage*pageSize)">
|
|
|
|
|
|
|
+ <el-table :data="curStdQueList.slice((currentPage-1)*pageSize,currentPage*pageSize)">
|
|
|
<el-table-column label="序号" prop="qno" width="60px"></el-table-column>
|
|
<el-table-column label="序号" prop="qno" width="60px"></el-table-column>
|
|
|
<el-table-column label="题号" prop="qno"></el-table-column>
|
|
<el-table-column label="题号" prop="qno"></el-table-column>
|
|
|
<el-table-column label="分数" prop="score"></el-table-column>
|
|
<el-table-column label="分数" prop="score"></el-table-column>
|
|
@@ -172,7 +171,7 @@
|
|
|
</el-table-column>
|
|
</el-table-column>
|
|
|
</el-table>
|
|
</el-table>
|
|
|
<el-pagination background layout="prev, pager, next" :page-sizes="[10,20,30,50]" :page-size="pageSize"
|
|
<el-pagination background layout="prev, pager, next" :page-sizes="[10,20,30,50]" :page-size="pageSize"
|
|
|
- @current-change="handleCurrentChange" :current-page.sync="currentPage" :total="stdQueList.length">
|
|
|
|
|
|
|
+ @current-change="handleCurrentChange" :current-page.sync="currentPage" :total="curStdQueList.length">
|
|
|
</el-pagination>
|
|
</el-pagination>
|
|
|
</div>
|
|
</div>
|
|
|
</el-col>
|
|
</el-col>
|
|
@@ -217,28 +216,27 @@
|
|
|
<div style="margin-top:10px;margin-bottom:10px;" v-if="choiceType==2">
|
|
<div style="margin-top:10px;margin-bottom:10px;" v-if="choiceType==2">
|
|
|
<span class="tag-group__title">选项框:</span>
|
|
<span class="tag-group__title">选项框:</span>
|
|
|
<div>
|
|
<div>
|
|
|
- <div v-for="(item,index) in stdChoiceList" style="display:inline-block;position:relative;">
|
|
|
|
|
- <i class="el-icon-close delChoice" @click="stdChoiceList.splice(index,1)"></i>
|
|
|
|
|
|
|
+ <div v-for="(item,index) in curStdChoiceList" style="display:inline-block;position:relative;">
|
|
|
|
|
+ <i class="el-icon-close delChoice" @click="curStdChoiceList.splice(index,1)"></i>
|
|
|
<el-image class="choiceImg" :src="item"></el-image>
|
|
<el-image class="choiceImg" :src="item"></el-image>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
</el-col>
|
|
</el-col>
|
|
|
<el-col :span="10">
|
|
<el-col :span="10">
|
|
|
- <el-button @click="autoSetScore" style="float:right;margin-left:10px;" type="warning" size="mini">设置分值
|
|
|
|
|
- </el-button>
|
|
|
|
|
<el-button style="float:right;" type="primary" @click="tryRecPaper" size="mini">识别测试
|
|
<el-button style="float:right;" type="primary" @click="tryRecPaper" size="mini">识别测试
|
|
|
</el-button>
|
|
</el-button>
|
|
|
|
|
|
|
|
</el-col>
|
|
</el-col>
|
|
|
</el-row>
|
|
</el-row>
|
|
|
<div style="border:1px solid #ddd;position:relative;" v-loading="ansImgLoading">
|
|
<div style="border:1px solid #ddd;position:relative;" v-loading="ansImgLoading">
|
|
|
- <img v-if="recCurAnsImg || stdChoiceList.length>0" id="ansImage" ref="ansImage" width="100%"
|
|
|
|
|
|
|
+ <img v-if="recCurAnsImg || stdChoiceList.length>0 && false" id="ansImage" ref="ansImage" width="100%"
|
|
|
:src="recCurAnsImg" />
|
|
:src="recCurAnsImg" />
|
|
|
- <img v-else id="ansImage" ref="ansImage" width="100%" :src="curAnsImg" />
|
|
|
|
|
|
|
+ <img v-else test="11" id="ansImage" ref="ansImage" width="100%" :src="curAnsImg" />
|
|
|
<!-- 题号 -->
|
|
<!-- 题号 -->
|
|
|
<!-- <div :style="'display:inline-block;color:red;border:1px solid red;left:'+(item[0].x)+'px;top:'+(item[0].y)+'px;position:absolute;font-size:18px;'" v-for="(item,index) in stdQnoPoints" :key="index">{{item[0].qno}}</div> -->
|
|
<!-- <div :style="'display:inline-block;color:red;border:1px solid red;left:'+(item[0].x)+'px;top:'+(item[0].y)+'px;position:absolute;font-size:18px;'" v-for="(item,index) in stdQnoPoints" :key="index">{{item[0].qno}}</div> -->
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+ <div style="margin:20px 0px;font-size:18px;">共识别出:{{recQueNum}}题,{{recFillNum}}个填涂框</div>
|
|
|
</el-col>
|
|
</el-col>
|
|
|
</el-row>
|
|
</el-row>
|
|
|
<div slot="footer" class="dialog-footer">
|
|
<div slot="footer" class="dialog-footer">
|
|
@@ -344,7 +342,9 @@
|
|
|
score: 0
|
|
score: 0
|
|
|
},
|
|
},
|
|
|
stdQueList: [],
|
|
stdQueList: [],
|
|
|
|
|
+ curStdQueList:[],
|
|
|
stdQnoPoints: [],
|
|
stdQnoPoints: [],
|
|
|
|
|
+ curStdQnoPoints:[],
|
|
|
paperImgs: [],
|
|
paperImgs: [],
|
|
|
curPaperImg: "",
|
|
curPaperImg: "",
|
|
|
recCurAnsImg: "",
|
|
recCurAnsImg: "",
|
|
@@ -364,13 +364,17 @@
|
|
|
khOpen: false,
|
|
khOpen: false,
|
|
|
stdPoints: null,
|
|
stdPoints: null,
|
|
|
khPointsCrop: {},
|
|
khPointsCrop: {},
|
|
|
- ansPointsCrop: {},
|
|
|
|
|
|
|
+ ansPointsCrop: [],
|
|
|
subImgList: [],
|
|
subImgList: [],
|
|
|
activePaper: true,
|
|
activePaper: true,
|
|
|
curPaperIndex: 0,
|
|
curPaperIndex: 0,
|
|
|
curQueIndex: 0,
|
|
curQueIndex: 0,
|
|
|
curPressKey: null,
|
|
curPressKey: null,
|
|
|
- drag: false
|
|
|
|
|
|
|
+ drag: false,
|
|
|
|
|
+ curStdChoiceList:[],
|
|
|
|
|
+ curAnsIndex:0,
|
|
|
|
|
+ recQueNum:0,
|
|
|
|
|
+ recFillNum:0
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
watch: {
|
|
watch: {
|
|
@@ -420,13 +424,24 @@
|
|
|
this.stdPoints = res.data.data.stdPoints ? JSON.parse(res.data.data.stdPoints) : {};
|
|
this.stdPoints = res.data.data.stdPoints ? JSON.parse(res.data.data.stdPoints) : {};
|
|
|
this.snoImg = res.data.data.khPoints;
|
|
this.snoImg = res.data.data.khPoints;
|
|
|
this.khPointsCrop = res.data.data.khPointsCrop ? JSON.parse(res.data.data.khPointsCrop) : {};
|
|
this.khPointsCrop = res.data.data.khPointsCrop ? JSON.parse(res.data.data.khPointsCrop) : {};
|
|
|
- this.ansCardImgList = res.data.data.ansPoints ? JSON.parse(res.data.data.ansPoints) : [];
|
|
|
|
|
- this.ansPointsCrop = res.data.data.ansPointsCrop ? [res.data.data.ansPointsCrop] : [];
|
|
|
|
|
|
|
+ // 客观题
|
|
|
|
|
+ this.ansPoints = res.data.data.ansPoints ? JSON.parse(res.data.data.ansPoints) : [];
|
|
|
|
|
+ let ansPointsCrop = res.data.data.ansPointsCrop ? JSON.parse(res.data.data.ansPointsCrop) : [];
|
|
|
|
|
+ this.ansCardImgList = ansPointsCrop;
|
|
|
|
|
+ if (res.data.data.stdChoices) {
|
|
|
|
|
+ this.stdChoiceList = JSON.parse(res.data.data.stdChoices);
|
|
|
|
|
+ }
|
|
|
|
|
+ if (res.data.data.stdQueList) {
|
|
|
|
|
+ this.stdQueList = JSON.parse(res.data.data.stdQueList);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
this.khType = res.data.data.khType;
|
|
this.khType = res.data.data.khType;
|
|
|
this.khLength = res.data.data.khLength;
|
|
this.khLength = res.data.data.khLength;
|
|
|
|
|
+ // 主观题
|
|
|
let subQueImgList = [];
|
|
let subQueImgList = [];
|
|
|
paperPieces.forEach((item, index) => {
|
|
paperPieces.forEach((item, index) => {
|
|
|
subQueImgList.push({
|
|
subQueImgList.push({
|
|
|
|
|
+ pno:item.paper_no,
|
|
|
qno: item.qno,
|
|
qno: item.qno,
|
|
|
qimg: item.imgs,
|
|
qimg: item.imgs,
|
|
|
point: item.imgs_points
|
|
point: item.imgs_points
|
|
@@ -457,29 +472,26 @@
|
|
|
activeQue(index) {
|
|
activeQue(index) {
|
|
|
this.curQueIndex = index;
|
|
this.curQueIndex = index;
|
|
|
},
|
|
},
|
|
|
- editAnsCard(item, curPaperId) {
|
|
|
|
|
|
|
+ editAnsCard(item, curPaperId,index) {
|
|
|
this.open = true;
|
|
this.open = true;
|
|
|
this.curAnsImg = item;
|
|
this.curAnsImg = item;
|
|
|
this.recCurAnsImg = null;
|
|
this.recCurAnsImg = null;
|
|
|
- this.stdQueList = [];
|
|
|
|
|
this.addQueForm = {};
|
|
this.addQueForm = {};
|
|
|
- this.stdChoiceList = [];
|
|
|
|
|
this.ansImgLoading = false;
|
|
this.ansImgLoading = false;
|
|
|
- this.$api.getPaperInfo({
|
|
|
|
|
- id: curPaperId
|
|
|
|
|
- }).then((res) => {
|
|
|
|
|
- let imgs = JSON.parse(res.data.data.imgs);
|
|
|
|
|
- this.curPaperImg = imgs[0];
|
|
|
|
|
- this.ansCardImgList = res.data.data.ansPoints ? JSON.parse(res.data.data.ansPoints) : [];
|
|
|
|
|
- this.snoImg = res.data.data.khPoints;
|
|
|
|
|
- if (res.data.data.stdChoices) {
|
|
|
|
|
- this.stdChoiceList = JSON.parse(res.data.data.stdChoices);
|
|
|
|
|
- }
|
|
|
|
|
- if (res.data.data.stdQueList) {
|
|
|
|
|
- this.stdQueList = JSON.parse(res.data.data.stdQueList);
|
|
|
|
|
- }
|
|
|
|
|
- this.loading = false;
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ this.curAnsIndex = index;
|
|
|
|
|
+ // 标准识别模板
|
|
|
|
|
+ if(this.stdChoiceList.length>index){
|
|
|
|
|
+ this.curStdChoiceList = this.stdChoiceList[index];
|
|
|
|
|
+ }
|
|
|
|
|
+ // 标准客观题数据
|
|
|
|
|
+ if(this.stdQueList.length>index){
|
|
|
|
|
+ this.curStdQueList = this.stdQueList[index];
|
|
|
|
|
+ }
|
|
|
|
|
+ // 识别出的标准填涂框
|
|
|
|
|
+ if(this.stdQnoPoints.length>index){
|
|
|
|
|
+ this.curStdQnoPoints = this.stdQnoPoints[index];
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
this.initAnsCropper();
|
|
this.initAnsCropper();
|
|
|
},
|
|
},
|
|
|
updatePaperRecInfo() {
|
|
updatePaperRecInfo() {
|
|
@@ -491,53 +503,56 @@
|
|
|
this.msgError("请标注考号区域!")
|
|
this.msgError("请标注考号区域!")
|
|
|
return
|
|
return
|
|
|
}
|
|
}
|
|
|
- if (!this.ansCardImgList.length) {
|
|
|
|
|
- this.msgError("请标注客观题区域!")
|
|
|
|
|
- return
|
|
|
|
|
- }
|
|
|
|
|
- let params = {
|
|
|
|
|
- id: this.$route.query.id,
|
|
|
|
|
- stdQnoPoints: this.stdQnoPoints,
|
|
|
|
|
- khPoints: this.snoImg,
|
|
|
|
|
- ansPoints: this.ansCardImgList,
|
|
|
|
|
- stdChoices: this.stdChoiceList,
|
|
|
|
|
- stdQueList: this.stdQueList,
|
|
|
|
|
- khType: this.khType,
|
|
|
|
|
- khLength: this.khLength,
|
|
|
|
|
- ansPointsCrop: this.ansPointsCrop,
|
|
|
|
|
- subImgList: this.subImgList
|
|
|
|
|
|
|
+ // 主观题保存
|
|
|
|
|
+ if(this.stepNum == 4){
|
|
|
|
|
+ let params = {
|
|
|
|
|
+ paper_id:this.$route.query.id,
|
|
|
|
|
+ subImgList:this.subImgList
|
|
|
|
|
+ }
|
|
|
|
|
+ this.$api.savePaperTplSubjectiveQue(params).then(res=>{
|
|
|
|
|
+ if(!res.data.code){
|
|
|
|
|
+ this.msgSuccess("成功!");
|
|
|
|
|
+ }else{
|
|
|
|
|
+ this.msgError(res.data.message);
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ }else{
|
|
|
|
|
+ let params = {
|
|
|
|
|
+ id: this.$route.query.id,
|
|
|
|
|
+ stdQnoPoints: this.stdQnoPoints,
|
|
|
|
|
+ khPoints: this.snoImg,
|
|
|
|
|
+ ansPoints: this.ansPointsCrop,
|
|
|
|
|
+ stdChoices: this.stdChoiceList,
|
|
|
|
|
+ stdQueList: this.stdQueList,
|
|
|
|
|
+ khType: this.khType,
|
|
|
|
|
+ khLength: this.khLength,
|
|
|
|
|
+ ansPointsCrop: this.ansCardImgList,
|
|
|
|
|
+ subImgList: this.subImgList
|
|
|
|
|
+ }
|
|
|
|
|
+ this.$api.updatePaperInfo(params).then(res => {
|
|
|
|
|
+ this.msgSuccess("成功!");
|
|
|
|
|
+ this.getData();
|
|
|
|
|
+ this.open = false;
|
|
|
|
|
+ })
|
|
|
}
|
|
}
|
|
|
- this.$api.updatePaperInfo(params).then(res => {
|
|
|
|
|
- this.msgSuccess("成功!");
|
|
|
|
|
- this.getData();
|
|
|
|
|
- this.open = false;
|
|
|
|
|
- })
|
|
|
|
|
},
|
|
},
|
|
|
updatePaperScore() {
|
|
updatePaperScore() {
|
|
|
- if (!this.stdPointImg) {
|
|
|
|
|
- this.msgError("请标注标准点!")
|
|
|
|
|
- return
|
|
|
|
|
- }
|
|
|
|
|
- if (!this.snoImg) {
|
|
|
|
|
- this.msgError("请标注考号区域!")
|
|
|
|
|
- return
|
|
|
|
|
- }
|
|
|
|
|
- if (!this.ansCardImgList.length) {
|
|
|
|
|
- this.msgError("请标注客观题区域!")
|
|
|
|
|
- return
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ //更新客观题识别信息
|
|
|
|
|
+ this.stdChoiceList[this.curAnsIndex]=this.curStdChoiceList;
|
|
|
|
|
+ this.stdQueList[this.curAnsIndex] = this.curStdQueList;
|
|
|
|
|
+ this.stdQnoPoints[this.curAnsIndex] = this.curStdQnoPoints;
|
|
|
let params = {
|
|
let params = {
|
|
|
- id: this.$route.query.id,
|
|
|
|
|
|
|
+ paper_id: this.$route.query.id,
|
|
|
stdQnoPoints: this.stdQnoPoints,
|
|
stdQnoPoints: this.stdQnoPoints,
|
|
|
- khPoints: this.snoImg,
|
|
|
|
|
- ansPoints: this.ansCardImgList,
|
|
|
|
|
stdChoices: this.stdChoiceList,
|
|
stdChoices: this.stdChoiceList,
|
|
|
stdQueList: this.stdQueList,
|
|
stdQueList: this.stdQueList,
|
|
|
- khType: this.khType,
|
|
|
|
|
- khLength: this.khLength,
|
|
|
|
|
}
|
|
}
|
|
|
- this.$api.updatePaperInfo(params).then(res => {
|
|
|
|
|
- this.msgSuccess("成功!");
|
|
|
|
|
|
|
+ this.$api.savePaperTplObjectiveQue(params).then(res => {
|
|
|
|
|
+ if(!res.data.code){
|
|
|
|
|
+ this.msgSuccess("成功!");
|
|
|
|
|
+ }else{
|
|
|
|
|
+ this.msgError(res.data.message)
|
|
|
|
|
+ }
|
|
|
this.getData();
|
|
this.getData();
|
|
|
this.open = false;
|
|
this.open = false;
|
|
|
})
|
|
})
|
|
@@ -628,8 +643,9 @@
|
|
|
|
|
|
|
|
khPointsCrop["x"] = khPointsCrop["x"] - that.stdPoints["x"];
|
|
khPointsCrop["x"] = khPointsCrop["x"] - that.stdPoints["x"];
|
|
|
khPointsCrop["y"] = khPointsCrop["y"] - that.stdPoints["y"];
|
|
khPointsCrop["y"] = khPointsCrop["y"] - that.stdPoints["y"];
|
|
|
- that.ansPointsCrop = khPointsCrop;
|
|
|
|
|
|
|
+ that.ansPointsCrop.push(khPointsCrop);
|
|
|
that.ansCardImgList.push(cropperImgData);
|
|
that.ansCardImgList.push(cropperImgData);
|
|
|
|
|
+ console.log(that.ansCardImgList,3333333333333)
|
|
|
}
|
|
}
|
|
|
// 主观题
|
|
// 主观题
|
|
|
if (that.stepNum == 4) {
|
|
if (that.stepNum == 4) {
|
|
@@ -720,7 +736,8 @@
|
|
|
let cropperImgData = this.cropper.getCroppedCanvas({
|
|
let cropperImgData = this.cropper.getCroppedCanvas({
|
|
|
width: 1310
|
|
width: 1310
|
|
|
}).toDataURL("image/jpeg");
|
|
}).toDataURL("image/jpeg");
|
|
|
- that.stdChoiceList.push(cropperImgData)
|
|
|
|
|
|
|
+ console.log(that.curStdChoiceList,2222222222222222)
|
|
|
|
|
+ that.curStdChoiceList.push(cropperImgData)
|
|
|
}
|
|
}
|
|
|
that.myAnsCropper.clear()
|
|
that.myAnsCropper.clear()
|
|
|
},
|
|
},
|
|
@@ -738,11 +755,28 @@
|
|
|
queDir: this.queDir,
|
|
queDir: this.queDir,
|
|
|
choiceType: this.choiceType,
|
|
choiceType: this.choiceType,
|
|
|
threshVal: this.threshVal,
|
|
threshVal: this.threshVal,
|
|
|
- stdChoiceList: this.stdChoiceList
|
|
|
|
|
|
|
+ stdChoiceList: this.curStdChoiceList
|
|
|
}).then(res => {
|
|
}).then(res => {
|
|
|
if (!res.data.code) {
|
|
if (!res.data.code) {
|
|
|
this.recCurAnsImg = res.data.data.recImg;
|
|
this.recCurAnsImg = res.data.data.recImg;
|
|
|
- this.stdQnoPoints = res.data.data.ansCnts;
|
|
|
|
|
|
|
+ this.curStdQnoPoints = res.data.data.ansCnts;
|
|
|
|
|
+ // 组装分数设置数值
|
|
|
|
|
+ this.curStdQueList = [];
|
|
|
|
|
+ this.recFillNum = 0;
|
|
|
|
|
+ this.curStdQnoPoints.forEach((item, index) => {
|
|
|
|
|
+ let queRow = {
|
|
|
|
|
+ qno: item[0].qno,
|
|
|
|
|
+ score: null,
|
|
|
|
|
+ qtype: "",
|
|
|
|
|
+ stdAns: "",
|
|
|
|
|
+ points:item
|
|
|
|
|
+ }
|
|
|
|
|
+ this.curStdQueList.push(queRow)
|
|
|
|
|
+ // 填涂框数量
|
|
|
|
|
+ this.recFillNum += item.length;
|
|
|
|
|
+ })
|
|
|
|
|
+ // 识别出的客观题数量
|
|
|
|
|
+ this.recQueNum = this.curStdQueList.length;
|
|
|
this.myAnsCropper.destroy();
|
|
this.myAnsCropper.destroy();
|
|
|
this.initAnsCropper();
|
|
this.initAnsCropper();
|
|
|
} else {
|
|
} else {
|
|
@@ -756,31 +790,19 @@
|
|
|
let fQno = parseInt(this.addQueForm.fQno);
|
|
let fQno = parseInt(this.addQueForm.fQno);
|
|
|
let tQno = parseInt(this.addQueForm.tQno);
|
|
let tQno = parseInt(this.addQueForm.tQno);
|
|
|
for (var i = fQno; i < tQno + 1; i++) {
|
|
for (var i = fQno; i < tQno + 1; i++) {
|
|
|
- this.stdQueList.forEach((item, index) => {
|
|
|
|
|
|
|
+ this.curStdQueList.forEach((item, index) => {
|
|
|
if (item.qno == String(i)) {
|
|
if (item.qno == String(i)) {
|
|
|
// item.score = this.addQueForm.score
|
|
// item.score = this.addQueForm.score
|
|
|
// item.qtype = this.addQueForm.qtype
|
|
// item.qtype = this.addQueForm.qtype
|
|
|
- this.stdQueList[index].score = this.addQueForm.score
|
|
|
|
|
- this.stdQueList[index].qtype = this.addQueForm.qtype
|
|
|
|
|
|
|
+ this.curStdQueList[index].score = this.addQueForm.score
|
|
|
|
|
+ this.curStdQueList[index].qtype = this.addQueForm.qtype
|
|
|
// this.stdQueList[index].stdAns = this.addQueForm.stdAns.join(",")
|
|
// this.stdQueList[index].stdAns = this.addQueForm.stdAns.join(",")
|
|
|
- this.$set(this.stdQueList[index], "score", this.addQueForm.score)
|
|
|
|
|
|
|
+ this.$set(this.curStdQueList[index], "score", this.addQueForm.score)
|
|
|
this.$forceUpdate();
|
|
this.$forceUpdate();
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
- autoSetScore() {
|
|
|
|
|
- this.stdQueList = [];
|
|
|
|
|
- this.stdQnoPoints.forEach((item, index) => {
|
|
|
|
|
- let queRow = {
|
|
|
|
|
- qno: item[0].qno,
|
|
|
|
|
- score: null,
|
|
|
|
|
- qtype: "",
|
|
|
|
|
- stdAns: ""
|
|
|
|
|
- }
|
|
|
|
|
- this.stdQueList.push(queRow)
|
|
|
|
|
- })
|
|
|
|
|
- },
|
|
|
|
|
setStdAns(row, item) {
|
|
setStdAns(row, item) {
|
|
|
let orgAns = row.stdAns.split(",")
|
|
let orgAns = row.stdAns.split(",")
|
|
|
orgAns = orgAns.filter((item) => {
|
|
orgAns = orgAns.filter((item) => {
|
|
@@ -830,7 +852,8 @@
|
|
|
let params = {
|
|
let params = {
|
|
|
id: this.$route.query.id,
|
|
id: this.$route.query.id,
|
|
|
khPoints: this.snoImg,
|
|
khPoints: this.snoImg,
|
|
|
- khPointsCrop: this.khPointsCrop
|
|
|
|
|
|
|
+ khPointsCrop: this.khPointsCrop,
|
|
|
|
|
+ khType:this.khType
|
|
|
}
|
|
}
|
|
|
this.$api.updatePaperInfo(params).then(res => {
|
|
this.$api.updatePaperInfo(params).then(res => {
|
|
|
let rst = res.data;
|
|
let rst = res.data;
|
|
@@ -853,14 +876,14 @@
|
|
|
}
|
|
}
|
|
|
// 客观题
|
|
// 客观题
|
|
|
if (this.stepNum == 3) {
|
|
if (this.stepNum == 3) {
|
|
|
- let params = {
|
|
|
|
|
- id: this.$route.query.id,
|
|
|
|
|
- ansPoints: this.ansCardImgList,
|
|
|
|
|
- khPointsCrop: this.khPointsCrop
|
|
|
|
|
- }
|
|
|
|
|
- this.$api.updatePaperInfo(params).then(res => {
|
|
|
|
|
- this.getData();
|
|
|
|
|
- })
|
|
|
|
|
|
|
+ // let params = {
|
|
|
|
|
+ // id: this.$route.query.id,
|
|
|
|
|
+ // ansPoints: this.ansCardImgList,
|
|
|
|
|
+ // khPointsCrop: this.khPointsCrop
|
|
|
|
|
+ // }
|
|
|
|
|
+ // this.$api.updatePaperInfo(params).then(res => {
|
|
|
|
|
+ // this.getData();
|
|
|
|
|
+ // })
|
|
|
this.stepNum += 1
|
|
this.stepNum += 1
|
|
|
}
|
|
}
|
|
|
// 主观题
|
|
// 主观题
|