From 15a611d29aa8e4700d14b39571383a4897af16ff Mon Sep 17 00:00:00 2001 From: xjs Date: Fri, 13 Jun 2025 11:13:26 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=B8=93=E4=B8=9A=E5=88=86=E6=95=B0?= =?UTF-8?q?=E7=BA=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../home/wishesList/components/CollegeMajor.vue | 6 +++++- .../home/wishesList/components/DataTable.vue | 11 ++++++++++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/pages-sub/home/wishesList/components/CollegeMajor.vue b/src/pages-sub/home/wishesList/components/CollegeMajor.vue index 50bceec..8c66f83 100644 --- a/src/pages-sub/home/wishesList/components/CollegeMajor.vue +++ b/src/pages-sub/home/wishesList/components/CollegeMajor.vue @@ -50,7 +50,11 @@ {{ checkActive(major) ? '已填报' : '填报' }} - + diff --git a/src/pages-sub/home/wishesList/components/DataTable.vue b/src/pages-sub/home/wishesList/components/DataTable.vue index 2b4f8a7..24d6d12 100644 --- a/src/pages-sub/home/wishesList/components/DataTable.vue +++ b/src/pages-sub/home/wishesList/components/DataTable.vue @@ -92,6 +92,10 @@ const props = defineProps({ type: Number, default: 0, }, + lowscoreRank: { + type: Number, + default: -1, + }, }) const title = ref('') @@ -138,7 +142,12 @@ const rankDiff = (index: number, item) => { const recompileData = computed(() => { if (!props.data) return [] let _data = props.data.map((item, index) => { - item['rankDiff'] = rankDiff(index, item) + item['rankDiff'] = + props.lowscoreRank !== -1 + ? props.lowscoreRank === 0 + ? '--' + : item['rankLine'] - props.lowscoreRank + : rankDiff(index, item) item['lineDiff'] = item['score'] - props.score return item })