xbx #40

Merged
theluyuan merged 6 commits from xbx into master 2020-07-03 01:10:59 +00:00
2 changed files with 30 additions and 3 deletions
Showing only changes of commit 5a99dfc2c9 - Show all commits

View File

@ -109,6 +109,12 @@ export default {
goods_id: id goods_id: id
}); });
}, },
getStoreGoodsList({ id, page = 0}){
return vm.$u.post('Store/getStoreGoodsList', {
id: id,
page:page
});
}
} }
} }

View File

@ -40,8 +40,8 @@
<view class="classify" v-if="cur==0"> <view class="classify" v-if="cur==0">
111 111
</view> </view>
<view class="list" v-if="cur==1"> <view class="item" v-if="cur==1">
222 <item v-for="item in list" :key="item.gc_id" :info="item" class="item"></item>
</view> </view>
</view> </view>
<view class="tabbar"> <view class="tabbar">
@ -65,13 +65,18 @@
</view> </view>
</template> </template>
<script> <script>
import item from "@/components/shop/list/item"
export default { export default {
data() { data() {
return { return {
show: false, show: false,
cur: 0 cur: 0,
list:[]
} }
}, },
components:{
item
},
methods: { methods: {
toDetailsPage() { toDetailsPage() {
uni.navigateTo({ uni.navigateTo({
@ -79,6 +84,12 @@ export default {
}); });
} }
}, },
onLoad(){
this.$u.api.getStoreGoodsList({id:1}).then((res)=>{
console.log(res.data)
this.list= res.data.list
})
}
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
@ -191,6 +202,9 @@ export default {
} }
} }
} }
.main{
padding-bottom: 98rpx;
}
.tabbar { .tabbar {
border-top: 1rpx #DBDADA solid; border-top: 1rpx #DBDADA solid;
width: 100%; width: 100%;
@ -218,5 +232,12 @@ export default {
} }
} }
} }
.item{
display: flex;
flex-wrap: wrap;
justify-content: space-between;
// margin-top: 20rpx;
padding:25rpx;
}
} }
</style> </style>