diff --git a/apis/index.js b/apis/index.js index 7a3e1e6..1482555 100644 --- a/apis/index.js +++ b/apis/index.js @@ -10,8 +10,8 @@ import router from '../router' // 基础配置 const config = { - // apiUrl : 'https://api.gongli.vip/api/', // 正式环境 - apiUrl : 'http://api.gl.shangkelian.cn/api/', // 测试 + apiUrl : 'https://api.gongli.vip/api/', // 正式环境 + // apiUrl : 'http://api.gl.shangkelian.cn/api/', // 测试 timeout : 60000 } diff --git a/apis/interfaces/store.js b/apis/interfaces/store.js index 17aec21..ecbdcdc 100644 --- a/apis/interfaces/store.js +++ b/apis/interfaces/store.js @@ -34,20 +34,18 @@ const shops = (categoryId,page) => { // 店铺详情 const shopsDetail = (shopId) => { + console.log(shopId,'shopId.....') return request({ url: 'mall/shops/' + shopId, }) } // 店铺商品 -const shopsGoods = (shopId, categoryId,page) => { +const shopsGoods = (data) => { + console.log(data,'shopsGoods.....') return request({ url: 'mall/goods', - data: { - shop_id:shopId, - category_id:categoryId, - page:page, - } + data: data }) } diff --git a/apis/interfaces/user.js b/apis/interfaces/user.js index c5e2a65..4450865 100644 --- a/apis/interfaces/user.js +++ b/apis/interfaces/user.js @@ -51,10 +51,21 @@ const relationsVerify = (invite) => { }) } +// 我的卡券 +const myCard = (data) => { + data.receive = 'desc' + return request({ + url: 'mall/shops/users', + data:data + }) +} + + export { info, chainSeed, invitationCode, relationsBind, - relationsVerify + relationsVerify, + myCard } diff --git a/apis/interfaces/vip.js b/apis/interfaces/vip.js index ecf1911..e360612 100644 --- a/apis/interfaces/vip.js +++ b/apis/interfaces/vip.js @@ -22,7 +22,7 @@ const vipPay = () => { }) } -// 获取支付信息 +// 获取支付信息 const payInfo = (orderId) => { return request({ url: 'user/identities/pay/' + orderId + '/wechat' @@ -36,6 +36,28 @@ const agreement = (id) => { }) } +// 店铺会员 +const shopVipInfo = (id) => { + return request({ + url: 'mall/shops/'+id+'/identities' + }) +} + +//开通店铺会员 +const shopVipCreate = (id,identity) => { + return request({ + url: 'mall/shops/'+id+'/identities/'+identity, + method:'POST' + }) +} + +// 开通店铺会员微信支付 +const shopVipWeChat = (id) => { + return request({ + url: 'mall/shops/identities/wechat/'+id, + method:'POST' + }) +} export { @@ -43,4 +65,7 @@ export { vipPay, payInfo, agreement, + shopVipInfo, + shopVipCreate, + shopVipWeChat } diff --git a/components/pin-goods-item/index.vue b/components/pin-goods-item/index.vue index 0f99d71..726e315 100644 --- a/components/pin-goods-item/index.vue +++ b/components/pin-goods-item/index.vue @@ -1,20 +1,16 @@