Commit feb3f027 by 前端

Merge branch 'dev_v4.15.6' into 'develop'

Dev v4.15.6

See merge request !25
2 parents 071a63d1 913b8743
...@@ -33,6 +33,9 @@ Component({ ...@@ -33,6 +33,9 @@ Component({
thisPage.setData({ thisPage.setData({
orderObj orderObj
}) })
this.setData({
orderObj: {}
})
} }
} }
}, },
...@@ -97,6 +100,7 @@ Component({ ...@@ -97,6 +100,7 @@ Component({
}) })
this.setData({ this.setData({
subShopMerchantList: data, subShopMerchantList: data,
orderObj: {}
}) })
} else { } else {
// 无二级流量方字段时 清空选择的二级流量方字段 // 无二级流量方字段时 清空选择的二级流量方字段
...@@ -121,19 +125,19 @@ Component({ ...@@ -121,19 +125,19 @@ Component({
subShopMerchantId: item.subMerchantId, subShopMerchantId: item.subMerchantId,
subShopMerchantName: item.subMerchantName subShopMerchantName: item.subMerchantName
} }
orderObj = Object.assign(orderObj, selectedSubShopMerchantObj) orderObj = (orderObj || selectedSubShopMerchantObj) ? Object.assign(orderObj, selectedSubShopMerchantObj) : selectedSubShopMerchantObj
subShopMerchantList.map(i => (i.active = false)) subShopMerchantList.map(i => (i.active = false))
subShopMerchantList[index].active = true subShopMerchantList[index].active = true
this.setData({ this.setData({
subShopMerchantList, subShopMerchantList,
...orderObj orderObj
}) })
}, },
async confirm() { async confirm() {
let data = this.data.orderObj let data = this.data.orderObj
let thisPage = wx.$router.getPageInstance() let thisPage = wx.$router.getPageInstance()
let { orderObj } = thisPage.data let { orderObj } = thisPage.data
orderObj = Object.assign(orderObj, data) orderObj = (orderObj || data) ? Object.assign(orderObj, data) : orderObj
thisPage.setData({ thisPage.setData({
orderObj orderObj
}) })
......
...@@ -328,7 +328,7 @@ ...@@ -328,7 +328,7 @@
show="{{subShopMerchantBox}}" show="{{subShopMerchantBox}}"
title="选择二级流量方" title="选择二级流量方"
selectedSelesMerchantId="{{orderObj.merchantId}}" selectedSelesMerchantId="{{orderObj.merchantId}}"
selectedCustomerInfo="{{orderObj.customer.customerName}}" selectedCustomerInfo="{{orderObj.customer.customerId}}"
selectedSubShopMerchantId="{{orderObj.subShopMerchantId}}"/> selectedSubShopMerchantId="{{orderObj.subShopMerchantId}}"/>
<car-brands <car-brands
show="{{carBrandBox}}" show="{{carBrandBox}}"
......
...@@ -370,7 +370,7 @@ ...@@ -370,7 +370,7 @@
show="{{subShopMerchantBox}}" show="{{subShopMerchantBox}}"
title="选择二级流量方" title="选择二级流量方"
selectedSelesMerchantId="{{orderObj.merchantId}}" selectedSelesMerchantId="{{orderObj.merchantId}}"
selectedCustomerInfo="{{orderObj.customer.customerName}}" selectedCustomerInfo="{{orderObj.customer.customerId}}"
selectedSubShopMerchantId="{{orderObj.subShopMerchantId}}"/> selectedSubShopMerchantId="{{orderObj.subShopMerchantId}}"/>
<car-brands <car-brands
show="{{carBrandBox}}" show="{{carBrandBox}}"
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!