|
@@ -235,6 +235,18 @@ export default {
|
|
if (data.activeDateEnd) {
|
|
if (data.activeDateEnd) {
|
|
this.form.activeDate[1] = moment(data.activeDateEnd).format(this.dateFormat)
|
|
this.form.activeDate[1] = moment(data.activeDateEnd).format(this.dateFormat)
|
|
}
|
|
}
|
|
|
|
+ // 活动经费上限 单位为万元
|
|
|
|
+ if (data.activeAmountEnable && data.activeAmountEnable == '0') {
|
|
|
|
+ this.form.activeAmount = ''
|
|
|
|
+ } else if (data.activeAmountEnable && data.activeAmountEnable == '1' && data.activeAmount && data.activeAmount != 0) {
|
|
|
|
+ this.form.activeAmount = Number(data.activeAmount) / 10000
|
|
|
|
+ }
|
|
|
|
+ // 订单起订金额 单位为万元
|
|
|
|
+ if (data.orderAmountEnable && data.orderAmountEnable == '0') {
|
|
|
|
+ this.form.orderAmount = ''
|
|
|
|
+ } else if (data.orderAmountEnable && data.orderAmountEnable == '1' && data.orderAmount && data.orderAmount != 0) {
|
|
|
|
+ this.form.orderAmount = Number(data.orderAmount) / 10000
|
|
|
|
+ }
|
|
this.chooseCust = []
|
|
this.chooseCust = []
|
|
if (data.promoBuyerList && data.promoBuyerList.length > 0) {
|
|
if (data.promoBuyerList && data.promoBuyerList.length > 0) {
|
|
data.promoBuyerList.map(item => {
|
|
data.promoBuyerList.map(item => {
|
|
@@ -258,6 +270,14 @@ export default {
|
|
form.activeDateEnd = undefined
|
|
form.activeDateEnd = undefined
|
|
}
|
|
}
|
|
delete form.activeDate
|
|
delete form.activeDate
|
|
|
|
+ // 活动经费上限 单位为万元
|
|
|
|
+ if (form.activeAmountEnable == '1' && form.activeAmount) {
|
|
|
|
+ form.activeAmount = Number(form.activeAmount) * 100 * 100 // 分两次为解决精度问题
|
|
|
|
+ }
|
|
|
|
+ // 订单起订金额 单位为万元
|
|
|
|
+ if (form.orderAmountEnable == '1' && form.orderAmount) {
|
|
|
|
+ form.orderAmount = Number(form.orderAmount) * 100 * 100
|
|
|
|
+ }
|
|
if (!this.itemSn && form.id) {
|
|
if (!this.itemSn && form.id) {
|
|
delete form.id
|
|
delete form.id
|
|
}
|
|
}
|