修改自提以及订阅逻辑

main
lenovo008\lenovo 4 months ago
parent fcee418cad
commit 7f2456c0f4

@ -1,5 +1,5 @@
# SHOPRO_DEV_BASE_URL = https://yanghaodong.51vip.biz # SHOPRO_DEV_BASE_URL = https://yanghaodong.51vip.biz
SHOPRO_DEV_BASE_URL = http://192.168.1.114:48080 # SHOPRO_DEV_BASE_URL = http://192.168.1.114:48080
# 线上地址 # 线上地址
# SHOPRO_DEV_BASE_URL = https://zda.huamar.com SHOPRO_DEV_BASE_URL = https://zda.huamar.com

@ -186,8 +186,8 @@
items: [], // items: [], //
price: {}, // price: {}, //
}, },
deliType:2, deliType:2,
pickUpInfo:{},// pickUpInfo:{},//
addressInfo: {}, // addressInfo: {}, //
showCoupon: false, // showCoupon: false, //
couponInfo: [], // couponInfo: [], //
@ -230,9 +230,18 @@
// //
function onConfirm() { function onConfirm() {
if (!state.addressInfo.id) { console.log(state.deliType, '11111111111111111');
sheep.$helper.toast('请选择收货地址');
return; if (state.deliType == 1) {
if (!state.addressInfo.id) {
sheep.$helper.toast('请选择收货地址');
return;
}
}else{
if (!state.pickUpInfo.id) {
sheep.$helper.toast('请选择自提门店');
return;
}
} }
submitOrder(); submitOrder();
} }
@ -250,7 +259,7 @@
items: state.orderPayload.items, items: state.orderPayload.items,
couponId: state.orderPayload.couponId, couponId: state.orderPayload.couponId,
addressId: state.deliType === 1 ? state.addressInfo.id: null, addressId: state.deliType === 1 ? state.addressInfo.id: null,
pickUpStoreId:state.deliType === 2 ? state.pickUpInfo.id : null, pickUpStoreId:state.deliType === 2 ? state.pickUpInfo.id : null,
deliveryType: state.deliType, // TODO deliveryType: state.deliType, // TODO
pointStatus: false, // TODO pointStatus: false, // TODO
combinationActivityId: state.orderPayload.combinationActivityId, combinationActivityId: state.orderPayload.combinationActivityId,

@ -164,10 +164,11 @@ const checkUpdate = async (silence = true) => {
// 获取订阅消息模板 // 获取订阅消息模板
async function getSubscribeTemplate() { async function getSubscribeTemplate() {
const { error, data } = await third.wechat.subscribeTemplate(); // const { error, data } = await third.wechat.subscribeTemplate();
if (error === 0) { // if (error === 0) {
subscribeEventList = data; // subscribeEventList = data;
} // }
console.log('获取订阅消息模板');
} }
// 订阅消息 // 订阅消息

Loading…
Cancel
Save