|
@@ -136,7 +136,7 @@
|
|
|
size="small"
|
|
|
:min="0"
|
|
|
:max="500"
|
|
|
- :step="0.5"
|
|
|
+ :step="0.1"
|
|
|
step-strictly
|
|
|
:controls="false"
|
|
|
placeholder="每题分值"
|
|
@@ -152,7 +152,7 @@
|
|
|
size="small"
|
|
|
:min="0"
|
|
|
:max="500"
|
|
|
- :step="0.5"
|
|
|
+ :step="0.1"
|
|
|
step-strictly
|
|
|
:controls="false"
|
|
|
placeholder="小题分值"
|
|
@@ -186,9 +186,9 @@
|
|
|
v-model="intervalScorePerTopic[scope.row.mainId]"
|
|
|
class="width-full"
|
|
|
size="small"
|
|
|
- :min="0.5"
|
|
|
+ :min="0.1"
|
|
|
:max="500"
|
|
|
- :step="0.5"
|
|
|
+ :step="0.1"
|
|
|
step-strictly
|
|
|
:controls="false"
|
|
|
placeholder="每题间隔分"
|
|
@@ -202,9 +202,9 @@
|
|
|
v-model="scope.row.intervalScore"
|
|
|
class="width-full"
|
|
|
size="small"
|
|
|
- :min="0.5"
|
|
|
+ :min="0.1"
|
|
|
:max="scope.row.totalScore"
|
|
|
- :step="0.5"
|
|
|
+ :step="0.1"
|
|
|
step-strictly
|
|
|
:controls="false"
|
|
|
placeholder="小题间隔分"
|
|
@@ -252,7 +252,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { calcSum, maxNum } from "@/plugins/utils";
|
|
|
+import { calcSum, maxNum, toPrecision } from "@/plugins/utils";
|
|
|
import { QUESTION_TYPE_LIST } from "@/constants/enumerate";
|
|
|
import { mapState, mapMutations } from "vuex";
|
|
|
import { markStructureSave } from "../../api";
|
|
@@ -281,7 +281,8 @@ export default {
|
|
|
"groupInfo",
|
|
|
]),
|
|
|
paperTotalScore() {
|
|
|
- return calcSum(this.tableData.map((item) => item.totalScore || 0));
|
|
|
+ const count = calcSum(this.tableData.map((item) => item.totalScore || 0));
|
|
|
+ return toPrecision(count, 1);
|
|
|
},
|
|
|
structureEditable() {
|
|
|
return this.structureCanEdit || this.editOpen;
|
|
@@ -628,8 +629,9 @@ export default {
|
|
|
|
|
|
return {
|
|
|
questionCount,
|
|
|
- paperTotalScore: calcSum(
|
|
|
- this.tableData.map((item) => item.totalScore || 0)
|
|
|
+ paperTotalScore: toPrecision(
|
|
|
+ calcSum(this.tableData.map((item) => item.totalScore || 0)),
|
|
|
+ 1
|
|
|
),
|
|
|
subjectiveQuestionCount,
|
|
|
objectiveQuestionCount: questionCount - subjectiveQuestionCount,
|