1
0
Code Issues Pull Requests Packages Projects Releases Wiki Activity GitHub Gitee
epp/mini-program/pages/coupon/coupon-detail/index.js

33 lines
562 B
JavaScript
Raw Normal View History

import { fetchCouponDetail } from '../../../services/coupon/index';
Page({
data: {
detail: null,
storeInfoList: [],
storeInfoStr: '',
showStoreInfoList: false,
},
id: '',
onLoad(query) {
const id = parseInt(query.id);
this.id = id;
this.getGoodsList(id);
},
getGoodsList(id) {
fetchCouponDetail(id).then(({ detail }) => {
this.setData({
detail,
});
});
},
navGoodListHandle() {
wx.navigateTo({
url: `/pages/coupon/coupon-activity-goods/index?id=${this.id}`,
});
},
});