提交 99b93df3 编写于 作者: zhangzhiwei's avatar zhangzhiwei

.

上级 4b49e662
<template> <template>
<view> <view>
<div class="image-container" @click="goto(`/pages/good/detail?skuId=${item.skuId}&spuId=${item.spuId}`)"> <div class="image-container" @click="goto(`/pages/good/detail?skuId=${item.skuId}&spuId=${item.spuId}`)">
<van-image fit="cover" lazy-load :src="item.mainImg" <van-image fit="cover" lazy-load :src="item.mainImg" height="45vw"
loading-icon="https://img.edsmall.com/ROOT/ETao/fenxiao/h5/default1.png" icon-size="30vw" /> loading-icon="https://img.edsmall.com/ROOT/ETao/fenxiao/h5/default1.png" icon-size="30vw" />
</div> </div>
<view style="padding: 15rpx;background: #ffffff"> <view style="padding: 15rpx;background: #ffffff" @click="goto(`/pages/good/detail?skuId=${item.skuId}&spuId=${item.spuId}`)">
<text class="text-s ellipsis line_over2" style="text-align: left;background: #ffffff;min-height: 60rpx;overflow: hidden"> <text class="text-s ellipsis line_over2" style="text-align: left;background: #ffffff;min-height: 60rpx;overflow: hidden">
{{ item.title }} {{ item.title }}
</text> </text>
......
...@@ -285,49 +285,12 @@ ...@@ -285,49 +285,12 @@
src="https://img.edsmall.com/ROOT/ETao/fenxiao/h5/price_tip1.png" /> src="https://img.edsmall.com/ROOT/ETao/fenxiao/h5/price_tip1.png" />
<template v-if="!state.switch.newView"> <template v-if="!state.switch.newView">
<view id="otherSku" class="good_anchor">同系列推荐</view> <view id="otherSku" class="good_anchor">同系列推荐</view>
<van-list v-if="state.data.skuJson" class="mg-t-15" :finished="true" finished-text="已经到底了哦~"> <van-list v-if="state.data.skuJson" :finished="true" finished-text="已经到底了哦~">
<van-grid :center="false" :column-num="2" :gutter="7"> <van-row gutter="12" style="margin: 0rpx 20rpx 20rpx;" >
<template v-for="item in state.data.skuJson"> <van-col span="12" v-for="item in state.data.skuJson" style="margin-bottom: 25rpx;align-self: baseline">
<van-grid-item v-if="item.skuId != state.skuId" class="text-left" <ShopCard v-if="item.skuId != state.skuId" :item="item"></ShopCard>
@tap="goto(`/pages/good/detail?skuId=${item.skuId}&spuId=${state.data.spuId}`)"> </van-col>
<van-image class="self_center" width="30vw" height="30vw" lazy-load </van-row>
loading-icon="https://img.edsmall.com/ROOT/ETao/fenxiao/h5/default1.png"
icon-size="30vw"
:src="item.mainImg" />
<view class="mg-t-30-m">
<van-image v-if="zoneIcon" width="60rpx" height="32rpx"
:src="zoneIcon[0]" />
<van-image v-if="item.isVideoIcon" class="mg-l-5" width="32rpx"
height="32rpx"
src="/static/img/play.png" />
</view>
<text class="text-s ellipsis line_over2 pd-t-10"
style="width: 320rpx;height: 32px;margin-bottom:6px">
{{ item.title }}
</text>
<text class="text-ss"
v-if="item.specHeight || item.specLength || item.specWidth">
{{ `W(宽):${item.specWidth} H(高):${item.specHeight}
D(深):${item.specLength}` }}
</text>
<text class="text-gray text-ss"></text>
<template v-if="item.salePrice !== null">
<view class="text-gray text-ss line-through">零售价¥{{
item.productPrice }}
</view>
<view class="text-orange text-ss">优惠价¥
<text class="text-bold text-l">{{ item.salePrice }}</text>
</view>
</template>
<template v-else>
<view class="text-orange text-ss">零售价¥
<text class="text-bold text-l">{{ item.productPrice }}
</text>
</view>
</template>
</van-grid-item>
</template>
</van-grid>
</van-list> </van-list>
</template> </template>
</van-skeleton> </van-skeleton>
...@@ -388,6 +351,7 @@ ...@@ -388,6 +351,7 @@
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import ShopCard from '@/components/ShopCard.vue';
import {Enum, PageUtils, WXUtils} from '@/utils/utils' import {Enum, PageUtils, WXUtils} from '@/utils/utils'
import {computed, nextTick, onBeforeMount, reactive, ref, onUnmounted,onMounted} from 'vue'; import {computed, nextTick, onBeforeMount, reactive, ref, onUnmounted,onMounted} from 'vue';
import {onPageScroll, onShow, onHide} from '@dcloudio/uni-app' import {onPageScroll, onShow, onHide} from '@dcloudio/uni-app'
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
<van-list :loading="state.good.loading" :finished="state.good.finished" finished-text="没有更多了" <van-list :loading="state.good.loading" :finished="state.good.finished" finished-text="没有更多了"
@load="onGoodLoad"> @load="onGoodLoad">
<van-row gutter="12" style="margin: 20rpx 20rpx;" v-if="state.showStyle"> <van-row gutter="12" style="margin: 20rpx 20rpx;" v-if="state.showStyle">
<van-col span="12" v-for="item in state.good.list" style="margin-bottom: 25rpx"> <van-col span="12" v-for="item in state.good.list" style="margin-bottom: 25rpx;align-self: baseline">
<ShopCard :item="item"></ShopCard> <ShopCard :item="item"></ShopCard>
</van-col> </van-col>
</van-row> </van-row>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册