|
@@ -18,7 +18,7 @@
|
|
|
<swiper class="swiper" @change="swiperChange" :indicator-dots="false" circular :current="current"
|
|
|
indicatorMode="line" :autoplay="true" :interval="3000" :duration="1000">
|
|
|
<swiper-item v-for="(item, index) in advList" :key="index">
|
|
|
- <image class="swiper-item" mode="" :src="item.advertsImg"> </image>
|
|
|
+ <image class="swiper-item" mode="" @click="jump(item.jumpUrl)" :src="item.advertsImg"> </image>
|
|
|
</swiper-item>
|
|
|
</swiper>
|
|
|
</view>
|
|
@@ -38,7 +38,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
- <view class="card-item">
|
|
|
+ <!-- <view class="card-item">
|
|
|
<view class="card-title">
|
|
|
<view class="card-item-title">
|
|
|
<view class="card-img">
|
|
@@ -50,7 +50,7 @@
|
|
|
</view>
|
|
|
|
|
|
</view>
|
|
|
- </view>
|
|
|
+ </view> -->
|
|
|
</view>
|
|
|
|
|
|
<view class="swiper-box" style="height: 200rpx">
|
|
@@ -152,18 +152,20 @@ export default {
|
|
|
"location.lon": 0,
|
|
|
pageCurrent: 1,
|
|
|
pageSize: 10,
|
|
|
- status:3
|
|
|
+ status: 3
|
|
|
},
|
|
|
};
|
|
|
},
|
|
|
- onLoad() { },
|
|
|
+ onLoad(options) {
|
|
|
+ this.columnId = options.columnId;
|
|
|
+ Promise.all([this.getMenu(), this.getBanner(), this.getAdv()]).then((res) => {
|
|
|
+ this.search();
|
|
|
+ });
|
|
|
+ },
|
|
|
created() {
|
|
|
this.loading = true;
|
|
|
this.navBarHeight = this.$navHight(1);
|
|
|
this.navBarHeight = this.navBarHeight + 10 + "px";
|
|
|
- Promise.all([this.getMenu(), this.getBanner(), this.getAdv()]).then((res) => {
|
|
|
- this.search();
|
|
|
- });
|
|
|
},
|
|
|
methods: {
|
|
|
goGoodsDetail(item) {
|
|
@@ -176,11 +178,12 @@ export default {
|
|
|
swiperChange(val) {
|
|
|
this.current = val.target.current;
|
|
|
},
|
|
|
- toTeaShop(){
|
|
|
+ toTeaShop() {
|
|
|
const shopId = uni.getStorageSync("gdTeaId");
|
|
|
+ const teaCateId = uni.getStorageSync("teaCateId");
|
|
|
uni.navigateTo({
|
|
|
- url: `../pages/index/searchResult?column=奶茶&goodsCateId=46&shopId=${shopId}&columnId=66`,
|
|
|
- });
|
|
|
+ url: `../pages/index/searchResult?column=奶茶&goodsCateId=${teaCateId}&shopId=${shopId}&columnId=${this.columnId}`,
|
|
|
+ });
|
|
|
},
|
|
|
|
|
|
// Banner
|
|
@@ -243,6 +246,11 @@ export default {
|
|
|
},
|
|
|
});
|
|
|
},
|
|
|
+ jump(url) {
|
|
|
+ uni.navigateTo({
|
|
|
+ url,
|
|
|
+ });
|
|
|
+ },
|
|
|
search() {
|
|
|
if (this.status == "noMore") return;
|
|
|
this.status = "loading";
|
|
@@ -388,18 +396,18 @@ page {
|
|
|
flex: 1;
|
|
|
}
|
|
|
|
|
|
- .card-item:nth-child(1) {
|
|
|
- ::after {
|
|
|
- content: "";
|
|
|
- position: absolute;
|
|
|
- margin: 0 auto;
|
|
|
- right: 0;
|
|
|
- top: 30rpx;
|
|
|
- width: 1px;
|
|
|
- height: 120rpx;
|
|
|
- background: #FFD9D9;
|
|
|
- }
|
|
|
- }
|
|
|
+ // .card-item:nth-child(1) {
|
|
|
+ // ::after {
|
|
|
+ // content: "";
|
|
|
+ // position: absolute;
|
|
|
+ // margin: 0 auto;
|
|
|
+ // right: 0;
|
|
|
+ // top: 30rpx;
|
|
|
+ // width: 1px;
|
|
|
+ // height: 120rpx;
|
|
|
+ // background: #FFD9D9;
|
|
|
+ // }
|
|
|
+ // }
|
|
|
|
|
|
.card-img {
|
|
|
display: flex;
|