From 628fa5bfdc1abae8a2e23aab8312dc26c7d3a780 Mon Sep 17 00:00:00 2001 From: ctw <> Date: Thu, 16 Jan 2025 09:54:43 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BD=BF=E7=94=A8=E5=9B=BE=E7=89=87=E6=87=92?= =?UTF-8?q?=E5=8A=A0=E8=BD=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/PreviewImage/index.vue | 98 +++++++++++--------- src/views/canteen/canteenDailyMenu/index.vue | 12 ++- 2 files changed, 61 insertions(+), 49 deletions(-) diff --git a/src/components/PreviewImage/index.vue b/src/components/PreviewImage/index.vue index ad3044a..a20361b 100644 --- a/src/components/PreviewImage/index.vue +++ b/src/components/PreviewImage/index.vue @@ -1,72 +1,78 @@ - \ No newline at end of file + diff --git a/src/views/canteen/canteenDailyMenu/index.vue b/src/views/canteen/canteenDailyMenu/index.vue index ddf45a1..fd89d14 100644 --- a/src/views/canteen/canteenDailyMenu/index.vue +++ b/src/views/canteen/canteenDailyMenu/index.vue @@ -12,7 +12,7 @@ v-for="(item, index) in weekData.data" :key="index" @click="timeClick(item, index)" - :class="{ selectedSpan: isActive === index ? 'selected' : '' }" + :class="{ selectedSpan: isActive === index }" class="border-2 border-solid border-gray-200 text-center" > {{ item }} @@ -55,7 +55,12 @@ 晚餐
- +
{{ item.name }} | @@ -114,7 +119,7 @@ const addFood = async (hourType: number) => { //选中具体时间数据 const timeClick = async (time: string, index: number) => { //数据查询操作 - if (time) { + if (time && isActive.value !== index) { //时间处理 time = time.substring(0, time.indexOf("(")) timedata = time @@ -265,6 +270,7 @@ onMounted(async () => { border-left: 2px solid transparent; color: rgb(255, 187, 0); position: relative; + cursor: default; } .selectedSpan::before { content: "";