Style(店铺):商品列表接口对接
This commit is contained in:
@@ -182,6 +182,9 @@
|
||||
<text>{{ item.sales }}人已购买</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="btn" @click="viewAllGoodHandle">
|
||||
查看所有商品
|
||||
</view>
|
||||
</view>
|
||||
<!-- 最新资讯 -->
|
||||
<view
|
||||
@@ -760,11 +763,14 @@ export default {
|
||||
id: this.inn.id,
|
||||
page: this.goodsPage,
|
||||
limit: 12
|
||||
}).then(data => {
|
||||
const len = data.records.length;
|
||||
if (len > 0) {
|
||||
for (let i = 0; i < len; i++) {
|
||||
this.goodsList.push(data.records[i]);
|
||||
}).then(res => {
|
||||
const { success, data } = res
|
||||
if (success) {
|
||||
const len = data.records.length
|
||||
if (len > 0) {
|
||||
for (let i = 0; i < len; i++) {
|
||||
this.goodsList.push(data.records[i])
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
@@ -804,6 +810,11 @@ export default {
|
||||
},
|
||||
toggleMoreHandle(index) {
|
||||
this.$set(this.infoArray[index], 'showMore', !this.infoArray[index].showMore)
|
||||
},
|
||||
viewAllGoodHandle() {
|
||||
uni.navigateTo({
|
||||
url: '/pagesInn/inn/innGoodList?id=' + this.inn.id,
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user