fixbug: 修改页面改造bug
This commit is contained in:
+21
-8
@@ -52,7 +52,7 @@
|
||||
<view class="yp_item" v-for="item in faddishProduct" :key="item.id"
|
||||
@click.stop="jumpInfo(item)">
|
||||
<view class="yp_item_image_wrapper">
|
||||
<up-image :src="item.url" width="100%" height="80" bgColor="#f1f6ff00"
|
||||
<up-image :src="item.url" width="100%" height="88" bgColor="#f1f6ff00"
|
||||
shape="square" radius="15"></up-image>
|
||||
</view>
|
||||
<view class="yp_item_info">
|
||||
@@ -102,8 +102,8 @@
|
||||
<view class="product_comm_tip" @click="jumpPage(item.path)">
|
||||
<view class="product_comm_tip_left">
|
||||
<image class="uni-image" :src="item.title_icon"></image>
|
||||
<view class="tip_title" v-if="item.title_text">{{ item.title_text }}</view>
|
||||
<view class="tip_title_lable">{{ item.title }}</view>
|
||||
<view :class="[activedTabId === 'actived' ? 'tip_title_lable' : 'tip_title']" style="margin-right: 10rpx;" v-if="item.title_text" @click.stop="jumpTab(item, 'actived')">{{ item.title_text }}</view>
|
||||
<view :class="[activedTabId === 'seckill' ? 'tip_title_lable' : 'tip_title']" @click.stop="jumpTab(item, 'seckill')">{{ item.title }}</view>
|
||||
</view>
|
||||
|
||||
<view class="product_comm_tip_right">{{ item.rightText }}
|
||||
@@ -125,6 +125,10 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 为您精选 -->
|
||||
<choiceness />
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
@@ -197,6 +201,7 @@ import {
|
||||
getGoodsDetail,
|
||||
searchList,
|
||||
getSeckillCurrent,
|
||||
getSeckillPreview,
|
||||
getSeckillGoodsList,
|
||||
getGoodsTags,
|
||||
} from "@/api/product.js";
|
||||
@@ -266,8 +271,8 @@ export default {
|
||||
rightText: '专属补贴 . 低价秒杀',
|
||||
activedType: 'seckill'
|
||||
},
|
||||
|
||||
], // 首页活动列表
|
||||
activedTabId: 'seckill', // 当前选中的活动类型
|
||||
};
|
||||
},
|
||||
onShow() {
|
||||
@@ -311,9 +316,15 @@ export default {
|
||||
},
|
||||
mounted() { },
|
||||
methods: {
|
||||
// 切换活动类型
|
||||
jumpTab(item, type) {
|
||||
this.activedTabId = type;
|
||||
this.onGetSeckillCurrent();
|
||||
},
|
||||
// 获取秒杀
|
||||
onGetSeckillCurrent() {
|
||||
getSeckillCurrent().then((res) => {
|
||||
const url = this.activedTabId === 'seckill' ? getSeckillCurrent : getSeckillPreview;
|
||||
url().then((res) => {
|
||||
console.log("获取秒杀", res);
|
||||
if (res.bizcode === 100) {
|
||||
res.data.activityId && this.onGetSeckillGoodsList(res.data.activityId, 'seckillGoodsList');
|
||||
@@ -812,7 +823,11 @@ export default {
|
||||
}
|
||||
|
||||
.yp_item {
|
||||
flex: 0 0 32%;
|
||||
// flex: 0 0 32%;
|
||||
flex:1;
|
||||
// height: 268rpx;
|
||||
max-width: 33.3%;
|
||||
gap: 10rpx;
|
||||
min-width: 0;
|
||||
background-color: #ffffff;
|
||||
border-radius: 24rpx;
|
||||
@@ -828,7 +843,6 @@ export default {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin-bottom: 12rpx;
|
||||
}
|
||||
|
||||
.yp_item_info {
|
||||
@@ -1065,7 +1079,6 @@ export default {
|
||||
|
||||
.tip_title {
|
||||
color: #666666;
|
||||
margin-right: 12rpx;
|
||||
}
|
||||
|
||||
.tip_title_lable {
|
||||
|
||||
Reference in New Issue
Block a user