细节修改

This commit is contained in:
kron
2025-07-16 17:04:57 +08:00
parent dc53653398
commit 5770fb2ce2
3 changed files with 8 additions and 1 deletions

View File

@@ -18,7 +18,12 @@ const roundsName = ["第一轮", "第二轮", "第三轮", "第四轮"];
<text>{{ scores.reduce((last, next) => last + next, 0) }}</text> <text>{{ scores.reduce((last, next) => last + next, 0) }}</text>
</view> </view>
<view <view
v-for="(_, index) in new Array(Math.ceil(scores.length / 3)).fill(1)" v-for="(_, index) in new Array(
Math.min(
Math.ceil(scores.length / 3) + (scores.length % 3 === 0 ? 1 : 0),
4
)
).fill(1)"
:key="index" :key="index"
> >
<text>{{ roundsName[index] }}</text> <text>{{ roundsName[index] }}</text>

View File

@@ -83,6 +83,7 @@ async function onComplete() {
) { ) {
uni.navigateBack(); uni.navigateBack();
} else { } else {
practiseId.value = "";
practiseResult.value = {}; practiseResult.value = {};
start.value = false; start.value = false;
scores.value = []; scores.value = [];

View File

@@ -77,6 +77,7 @@ async function onComplete() {
) { ) {
uni.navigateBack(); uni.navigateBack();
} else { } else {
practiseId.value = "";
practiseResult.value = {}; practiseResult.value = {};
start.value = false; start.value = false;
scores.value = []; scores.value = [];