|
|
@ -124,8 +124,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
} else if (coupons != null && coupons != "" || tableId <= 0) { |
|
|
|
} else if (coupons != null && coupons != "" || tableId <= 0) { |
|
|
|
queryOrderInfo( |
|
|
|
queryOrderInfo( |
|
|
|
address != null ? address.id : null, |
|
|
|
address != null ? address.id : null, |
|
|
@ -137,8 +136,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
} else |
|
|
|
} else |
|
|
|
queryOrderInfo( |
|
|
|
queryOrderInfo( |
|
|
|
null, |
|
|
|
null, |
|
|
@ -150,8 +148,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
}); |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
weChatResponseEventHandler.listen((event) async { |
|
|
|
weChatResponseEventHandler.listen((event) async { |
|
|
@ -161,18 +158,8 @@ class _Settlement extends State<Settlement> { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
///订单结算信息 |
|
|
|
///订单结算信息 |
|
|
|
queryOrderInfo( |
|
|
|
queryOrderInfo(addressId, isTake, memberCouponId, orderId, promotionId, |
|
|
|
addressId, |
|
|
|
productSkuId, actProductId, actProductSkuId, buyNum, payChannel) async { |
|
|
|
isTake, |
|
|
|
|
|
|
|
memberCouponId, |
|
|
|
|
|
|
|
orderId, |
|
|
|
|
|
|
|
promotionId, |
|
|
|
|
|
|
|
productSkuId, |
|
|
|
|
|
|
|
actProductId, |
|
|
|
|
|
|
|
actProductSkuId, |
|
|
|
|
|
|
|
buyNum, |
|
|
|
|
|
|
|
payChannel |
|
|
|
|
|
|
|
) async { |
|
|
|
|
|
|
|
BaseData<SettleOrderInfo> baseData = await minService.getOrderInfo({ |
|
|
|
BaseData<SettleOrderInfo> baseData = await minService.getOrderInfo({ |
|
|
|
"addressId": addressId, |
|
|
|
"addressId": addressId, |
|
|
|
"isTake": isTake, |
|
|
|
"isTake": isTake, |
|
|
@ -228,8 +215,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
BaseData<List<Address>> baseDate = |
|
|
|
BaseData<List<Address>> baseDate = |
|
|
@ -283,8 +269,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -310,8 +295,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -404,14 +388,10 @@ class _Settlement extends State<Settlement> { |
|
|
|
placeOrderFirst.payChannel = payChannel; |
|
|
|
placeOrderFirst.payChannel = payChannel; |
|
|
|
placeOrderFirst.promotionInfoDTO = PromotionInfoDTOBean(); |
|
|
|
placeOrderFirst.promotionInfoDTO = PromotionInfoDTOBean(); |
|
|
|
placeOrderFirst.promotionInfoDTO.promotionId = |
|
|
|
placeOrderFirst.promotionInfoDTO.promotionId = |
|
|
|
(promotion != null && tableId <= 0) |
|
|
|
(promotion != null && tableId <= 0) ? promotion.id : ""; |
|
|
|
? promotion.id |
|
|
|
|
|
|
|
: ""; |
|
|
|
|
|
|
|
// : widget.arguments["pid"] ?? ""; |
|
|
|
// : widget.arguments["pid"] ?? ""; |
|
|
|
placeOrderFirst.promotionInfoDTO.couponId = |
|
|
|
placeOrderFirst.promotionInfoDTO.couponId = |
|
|
|
(couponListBean != null && tableId <= 0) |
|
|
|
(couponListBean != null && tableId <= 0) ? couponListBean.id : ""; |
|
|
|
? couponListBean.id |
|
|
|
|
|
|
|
: ""; |
|
|
|
|
|
|
|
// : widget.arguments["cid"] ?? ""; |
|
|
|
// : widget.arguments["cid"] ?? ""; |
|
|
|
placeOrderFirst.recMobile = |
|
|
|
placeOrderFirst.recMobile = |
|
|
|
(mobile == null || mobile == "") ? mobile : storeInfo.headMobile; |
|
|
|
(mobile == null || mobile == "") ? mobile : storeInfo.headMobile; |
|
|
@ -442,8 +422,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
if (placeOrder) { |
|
|
|
if (placeOrder) { |
|
|
|
// 结算 |
|
|
|
// 结算 |
|
|
|
querySettlement(); |
|
|
|
querySettlement(); |
|
|
|
} |
|
|
|
} else { |
|
|
|
else{ |
|
|
|
|
|
|
|
if (parentId == "") { |
|
|
|
if (parentId == "") { |
|
|
|
// 下单 |
|
|
|
// 下单 |
|
|
|
baseData = await minService |
|
|
|
baseData = await minService |
|
|
@ -466,8 +445,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
queryOrderDetails( |
|
|
|
queryOrderDetails( |
|
|
|
(parentId == null || parentId == "") ? baseData.data.id : parentId); |
|
|
|
(parentId == null || parentId == "") ? baseData.data.id : parentId); |
|
|
|
setState(() {}); |
|
|
|
setState(() {}); |
|
|
|
} |
|
|
|
} else { |
|
|
|
else { |
|
|
|
|
|
|
|
SmartDialog.showToast(baseData?.msg, alignment: Alignment.center); |
|
|
|
SmartDialog.showToast(baseData?.msg, alignment: Alignment.center); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -647,8 +625,8 @@ class _Settlement extends State<Settlement> { |
|
|
|
child: Container( |
|
|
|
child: Container( |
|
|
|
child: Column( |
|
|
|
child: Column( |
|
|
|
children: [ |
|
|
|
children: [ |
|
|
|
DistributionMode((addressId, isTake, |
|
|
|
DistributionMode((addressId, isTake, memberCouponId, |
|
|
|
memberCouponId, orderId, promotionId) { |
|
|
|
orderId, promotionId) { |
|
|
|
setState(() { |
|
|
|
setState(() { |
|
|
|
this.selectedBtn = 0; |
|
|
|
this.selectedBtn = 0; |
|
|
|
}); |
|
|
|
}); |
|
|
@ -662,8 +640,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
}, queryAddress, storeInfo, address, |
|
|
|
}, queryAddress, storeInfo, address, |
|
|
|
selectedAddress, pageType), |
|
|
|
selectedAddress, pageType), |
|
|
|
|
|
|
|
|
|
|
@ -709,8 +686,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
tableId, |
|
|
|
tableId, |
|
|
|
), |
|
|
|
), |
|
|
|
|
|
|
|
|
|
|
|
if (placeOrder && |
|
|
|
if (placeOrder && joinA != JoinActivity.BargainBug) |
|
|
|
joinA != JoinActivity.BargainBug) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
///支付方式 |
|
|
|
///支付方式 |
|
|
|
PayMethod(payChannelCheck), |
|
|
|
PayMethod(payChannelCheck), |
|
|
@ -783,7 +759,9 @@ class _Settlement extends State<Settlement> { |
|
|
|
: queryPlaceOrderFirst(); |
|
|
|
: queryPlaceOrderFirst(); |
|
|
|
}, |
|
|
|
}, |
|
|
|
), |
|
|
|
), |
|
|
|
SizedBox(width: 17,) |
|
|
|
SizedBox( |
|
|
|
|
|
|
|
width: 17, |
|
|
|
|
|
|
|
) |
|
|
|
], |
|
|
|
], |
|
|
|
), |
|
|
|
), |
|
|
|
), |
|
|
|
), |
|
|
@ -807,8 +785,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
mobileChange(String mobile) { |
|
|
|
mobileChange(String mobile) { |
|
|
@ -856,8 +833,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -886,8 +862,7 @@ class _Settlement extends State<Settlement> { |
|
|
|
actProductId ?? "", |
|
|
|
actProductId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
actProductSkuId ?? "", |
|
|
|
count1, |
|
|
|
count1, |
|
|
|
payChannel |
|
|
|
payChannel); |
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|