Commit fa60aac2 by wangzhihui

Merge branch 'SAAS+V4.56.0-0908' of http://192.168.3.233:8090/saas/mini-program/…

…points-mall into SAAS+V4.56.0-0908
2 parents 32ef5a21 42eb0432
...@@ -63,7 +63,7 @@ Page({ ...@@ -63,7 +63,7 @@ Page({
}, },
goodsActionClick(e) { goodsActionClick(e) {
let { detailInfo } = this.data let { detailInfo } = this.data
if (e.detail == 'join' && detailInfo.goodsSource == 1) return this.toAddShopCar() // if (e.detail == 'join' && detailInfo.goodsSource == 1) return this.toAddShopCar()
this.showSkuModal(e.detail) this.showSkuModal(e.detail)
}, },
onLoad(options) { onLoad(options) {
......
...@@ -132,6 +132,7 @@ Page({ ...@@ -132,6 +132,7 @@ Page({
// 未开通弹出开通钱包弹窗 // 未开通弹出开通钱包弹窗
this.setData({ this.setData({
showEnableWallet: true, showEnableWallet: true,
loginPageFlag: false,
copyWalletObj: {name: r?.data?.staffName || userInfo?.nickName, phone: r?.data?.staffPhone || userInfo?.phone, scoreSource: userInfo?.channelSource} copyWalletObj: {name: r?.data?.staffName || userInfo?.nickName, phone: r?.data?.staffPhone || userInfo?.phone, scoreSource: userInfo?.channelSource}
}) })
} }
...@@ -250,22 +251,22 @@ Page({ ...@@ -250,22 +251,22 @@ Page({
scoreSource: userInfo?.channelSource, scoreSource: userInfo?.channelSource,
merchantId: userInfo?.merchantId merchantId: userInfo?.merchantId
} }
if (value.goodsSource == 1) { // if (value.goodsSource == 1) {
if (!value.goodsStock) return wx.p.wxApi.showToast('暂无库存') // if (!value.goodsStock) return wx.p.wxApi.showToast('暂无库存')
cartApi.addToCart(PARAMS).then(res => { // cartApi.addToCart(PARAMS).then(res => {
wx.p.wxApi.showToast('加入购物车成功') // wx.p.wxApi.showToast('加入购物车成功')
}) // })
} else { // } else {
// 获取商品详情 // 获取商品详情
this.getDetail(value) this.getDetail(value)
} // }
}, },
getDetail(options) { getDetail(options) {
homeApi.getGoodsDetailInfo({id: options.id, businessType: 1}).then(res => { homeApi.getGoodsDetailInfo({id: options.id, businessType: 1}).then(res => {
res.goodsSource = options.goodsSource res.goodsSource = options.goodsSource
if (res && res.specificationResponses?.length) { // if (res && res.specificationResponses?.length) {
this.toGetSpecString(res, res.startQty) // this.toGetSpecString(res, res.startQty)
} // }
if (res && res.platformGlGoodsSpecifications?.length) { if (res && res.platformGlGoodsSpecifications?.length) {
let item = res.platformGlGoodsSpecifications[0] || {} let item = res.platformGlGoodsSpecifications[0] || {}
res.redeemPoints = item.retailPrice res.redeemPoints = item.retailPrice
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!