商城下单购买,品类接口,钱包依赖
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
</view>
|
||||
<!-- 健康产品分类 -->
|
||||
<u-scroll-list class="classify-box" indicatorColor="#ddd" indicatorActiveColor="#34CE98">
|
||||
<view v-for="(item, index) in goodTabs" :key="index" class="classify-item">
|
||||
<view v-for="(item, index) in goodTabs" :key="index" class="classify-item" @click="$Router.push({name: 'StoreList', params: {id: item.category_id, title: item.name}})">
|
||||
<view class="classify-item-nav">
|
||||
<image class="classify-item-cover" :src="item.cover"></image>
|
||||
<view class="classify-item-title">{{item.name}}</view>
|
||||
@@ -40,7 +40,7 @@
|
||||
<!-- 推荐品类 -->
|
||||
<view class="card-box">
|
||||
<block v-for="(item, index) in meals" :key="index">
|
||||
<view class="card-box-item" :style="{'backgrond': item.color}" @click="$Router.push({name: 'StoreList', params: {id: item.meal_id}})">
|
||||
<view class="card-box-item" :style="{'backgrond': item.color}" @click="$Router.push({name: 'StoreMeals', params: {id: item.meal_id}})">
|
||||
<view class="card-title">{{item.title}}</view>
|
||||
<view class="card-subtitle">{{item.subtitle}}</view>
|
||||
<image class="card-cover" :src="item.cover" mode="aspectFill"></image>
|
||||
@@ -78,15 +78,12 @@
|
||||
methods:{
|
||||
getMall(){
|
||||
mall().then(res => {
|
||||
console.log(res)
|
||||
this.banners = res.banners
|
||||
this.goodsArr = res.goods
|
||||
this.newGood = res.news
|
||||
this.goodTabs = res.categories
|
||||
this.meals = res.meals
|
||||
uni.stopPullDownRefresh()
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user