fix:修复bug

This commit is contained in:
2026-03-18 09:24:35 +08:00
parent 60df817de5
commit 741769cbeb
14 changed files with 263 additions and 180 deletions
@@ -1,7 +1,7 @@
<script setup lang="ts">
import {thumbnailImg} from "@/utils/utils";
const props = defineProps<{
list: object[];
list: any[];
}>();
const { t } = useI18n();
@@ -16,11 +16,13 @@ function handleClickFood(item: any) {
<scroll-view scroll-x="true">
<view class="flex">
<view class="w-30rpx shrink-0"></view>
<template v-for="(item, index) in list">
<template v-for="(item, index) in list" :key="item?.id ?? index">
<view @click="handleClickFood(item)" :class="[index === 0 ? '' : 'ml-28rpx']">
<image :src="thumbnailImg(item?.shopImages?.split(',')[0])" class="w-448rpx h-252rpx rounded-24rpx mb-20rpx bg-common" mode="aspectFill"></image>
<text class="text-30rpx lh-30rpx text-#333 font-500 line-clamp-1">{{ item?.merchantName }}</text>
<view v-if="+item.deliveryService === 1" class="text-#CE7138 text-24rpx lh-24rpx mt-12rpx">${{ item.deliveryFee }} {{ t('pages.home.deliveryFee') }}</view>
<view v-if="+item.deliveryService === 1" class="text-#CE7138 text-24rpx lh-24rpx mt-12rpx">
{{ t('pages-store.store.tips5') }} ${{ item.deliveryFee }}{{ t('pages-store.store.start') }}
</view>
<view class="text-24rpx lh-24rpx flex items-center mt-12rpx">
<text class="text-#333 font-500">{{ item.rating }}</text>
<image src="@img/chef/124.png" class="w-24rpx h-24rpx mx-4rpx mt-2rpx"></image>
@@ -384,7 +384,10 @@ const debouncedEmit = debounce(1300, (isCollected: boolean, id: string, type: Co
</view>
<view class="flex-center-sb mt-12rpx">
<text class="text-32rpx lh-30rpx text-#333 font-500">US${{ item?.discountPrice }}</text>
<view class="member-price-tag text-[#FBE3C3] font-500 text-30rpx lh-30rpx center pl-6rpx break-all">
<view
v-if="Number(item?.memberPrice) > 0"
class="member-price-tag text-[#FBE3C3] font-500 text-30rpx lh-30rpx center pl-6rpx break-all"
>
<text>{{ t('pages-store.store.members') }}: </text>
${{ item?.memberPrice }}
</view>