diff --git a/src/api/apis/apis.js b/src/api/apis/apis.js
index 8b67145..9f29251 100644
--- a/src/api/apis/apis.js
+++ b/src/api/apis/apis.js
@@ -740,6 +740,7 @@ export default {
url: setUpUrls.exportSchoolContrast,
method: "POST",
data,
+ responseType: 'arraybuffer',
});
},
// 导出年级使用对比
@@ -748,6 +749,7 @@ export default {
url: setUpUrls.exportGradeContrast,
method: "POST",
data,
+ responseType: 'arraybuffer',
});
},
};
diff --git a/src/utils/index.js b/src/utils/index.js
index 33a70fa..3e708ee 100644
--- a/src/utils/index.js
+++ b/src/utils/index.js
@@ -454,7 +454,7 @@ export function checkAnswer(
//单选
console.log(s.length + " " + questionCount);
if (s.length > questionCount) {
- s = s.substring(s.length - questionCount, s.length);
+ s = s.substring(0, questionCount+1);
}
} else if (questionType == 3) {
//多选
diff --git a/src/views/analysis/index.vue b/src/views/analysis/index.vue
index f901615..0d3636f 100644
--- a/src/views/analysis/index.vue
+++ b/src/views/analysis/index.vue
@@ -133,7 +133,7 @@
-
+
取 消
-
+
{
// return item[1];
// });
- if(typeof query.classIds == 'string' || typeof query.classIds == 'number'){
+ if (
+ typeof query.classIds == "string" ||
+ typeof query.classIds == "number"
+ ) {
query.classIds = [query.classIds];
- }else{
+ } else {
query.classIds = [query.classIds[1]];
}
-
- let deviceApi = this.isAdd?this.$request.addStation:this.$request.updateDevice
+
+ let deviceApi = this.isAdd
+ ? this.$request.addStation
+ : this.$request.updateDevice;
const { data, status, info } = await deviceApi({
...query,
});
@@ -799,8 +809,8 @@ export default {
this.diaAnswerEqu = false;
this.$message.success(info);
this._QueryData();
- if(this.isAdd){
- this.stationReport()
+ if (this.isAdd) {
+ this.stationReport();
}
} else {
this.$message.error(info);
@@ -1030,9 +1040,16 @@ export default {
return item;
})) ||
[];
+
this.total = data.count;
this.$nextTick(function () {
this.$refs.main.scrollTop = 0;
+ if (this.query.classId.length) {
+ this.selectionTabIds = this.tableData.map((item) => {
+ this.$refs.multipleTable.toggleRowSelection(item);
+ return item.id;
+ });
+ }
});
} else {
this.$message.error(info);
diff --git a/src/views/examinationPaper/add.vue b/src/views/examinationPaper/add.vue
index 47551d3..6cbdc13 100644
--- a/src/views/examinationPaper/add.vue
+++ b/src/views/examinationPaper/add.vue
@@ -400,7 +400,7 @@
{{ setBigNum(index) }}、
{{ question.questionTitle }}
- 共:{{ question.subQuestions.length }}题
+ 共:{{ setNums(question.subQuestions) }}题
共:{{ setScore(question) }} 分
@@ -519,13 +519,13 @@
{{ setSubPro(formAns.qusType) }}:
@@ -782,6 +782,14 @@ export default {
}
return lengths + subIndex + 1;
},
+ setNums(ques) {
+ let lengths = 0;
+ let subArr = ques.filter((item) => {
+ return !!item.questionType;
+ });
+ lengths = subArr.length;
+ return lengths
+ },
setBigNum(num) {
let txt = "";
let bigNum = [
@@ -912,12 +920,12 @@ export default {
event.returnValue = "";
}
},
- setAllAnswer(event, type){
+ setAllAnswer(event, type) {
let str = this.formAns.answerList;
let str2 = checkAnswer(
str,
type,
- this.formAns.answerOptions.split(',').length,
+ this.formAns.answerOptions.split(",").length,
this.formAns.subNum
);
this.formAns.answerList = str2;
diff --git a/src/views/login/index.vue b/src/views/login/index.vue
index ffa3fe8..c723022 100644
--- a/src/views/login/index.vue
+++ b/src/views/login/index.vue
@@ -95,8 +95,8 @@ export default {
loginForm: {
// username: "15911715665",
// password: "715665",
- // username: "18314340313",
- // password: "Pw340313#",
+ username: "18314340313",
+ password: "Pw340313#",
// username: "18687826606",
// password: "Pw826606#",
// username: "18893712576",
diff --git a/src/views/setUp/teacher.vue b/src/views/setUp/teacher.vue
index c39949a..32d3620 100644
--- a/src/views/setUp/teacher.vue
+++ b/src/views/setUp/teacher.vue
@@ -5,7 +5,7 @@
教师管理
-
+
*
+
{{ scope.row["answer" + item.id] }}
@@ -349,9 +352,7 @@
- {{ scope.row["questionType" + item.id] == 5 ? "*" : "-" }}
-
+ >-