|
|
@@ -318,14 +318,17 @@ class MemberController extends BaseController implements PaymentStatusCallback {
|
|
|
}
|
|
|
|
|
|
void onBuyClick() async {
|
|
|
- if (selectedGoods == null) {
|
|
|
+ final buyGoods = selectedGoods;
|
|
|
+ final buyPayWay = selectedPayWay;
|
|
|
+ if (buyGoods == null) {
|
|
|
ToastUtil.show(StringName.memberPleaseChoiceGoods);
|
|
|
return;
|
|
|
}
|
|
|
- if (selectedPayWay == null && !Platform.isIOS) {
|
|
|
+ if (buyPayWay == null) {
|
|
|
ToastUtil.show(StringName.memberPleaseChoicePayment);
|
|
|
return;
|
|
|
}
|
|
|
+ memberRepository.setLastSelectedMember(buyGoods, buyPayWay);
|
|
|
//增加渠道登录判断
|
|
|
if (Platform.isAndroid && atmobPlatformInfo.tgPlatform == ChannelId.sd) {
|
|
|
if (!accountRepository.isLogin.value) {
|
|
|
@@ -336,8 +339,6 @@ class MemberController extends BaseController implements PaymentStatusCallback {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- final buyGoods = selectedGoods!;
|
|
|
- final buyPayWay = selectedPayWay!;
|
|
|
|
|
|
int goodsId = buyGoods.id;
|
|
|
int payPlatform = buyPayWay.payPlatform;
|
|
|
@@ -347,7 +348,6 @@ class MemberController extends BaseController implements PaymentStatusCallback {
|
|
|
|
|
|
LoadingDialog.show(StringName.payLoading,
|
|
|
backDismiss: true, clickMaskDismiss: true);
|
|
|
- memberRepository.setLastSelectedMember(buyGoods, buyPayWay);
|
|
|
memberRepository
|
|
|
.submitAndRequestPay(
|
|
|
goodsId: goodsId, payPlatform: payPlatform, payMethod: payMethod)
|