From 1af4e76f8440b1efbbce3689fdcc16f4a4f2c6c3 Mon Sep 17 00:00:00 2001
From: java110 <928255095@qq.com>
Date: 星期五, 18 六月 2021 00:01:42 +0800
Subject: [PATCH] Merge branch 'master' of http://git.homecommunity.cn/supervip/MicroCommunity
---
service-acct/src/main/java/com/java110/acct/bmo/accountWithdrawalApply/impl/UpdateAccountWithdrawalApplyBMOImpl.java | 24 +++++++++++++++++++++++-
1 files changed, 23 insertions(+), 1 deletions(-)
diff --git a/service-acct/src/main/java/com/java110/acct/bmo/accountWithdrawalApply/impl/UpdateAccountWithdrawalApplyBMOImpl.java b/service-acct/src/main/java/com/java110/acct/bmo/accountWithdrawalApply/impl/UpdateAccountWithdrawalApplyBMOImpl.java
index cdca7ea..993481a 100644
--- a/service-acct/src/main/java/com/java110/acct/bmo/accountWithdrawalApply/impl/UpdateAccountWithdrawalApplyBMOImpl.java
+++ b/service-acct/src/main/java/com/java110/acct/bmo/accountWithdrawalApply/impl/UpdateAccountWithdrawalApplyBMOImpl.java
@@ -1,14 +1,20 @@
package com.java110.acct.bmo.accountWithdrawalApply.impl;
+import com.alibaba.fastjson.JSONObject;
import com.java110.acct.bmo.accountWithdrawalApply.IUpdateAccountWithdrawalApplyBMO;
import com.java110.core.annotation.Java110Transactional;
+import com.java110.dto.accountWithdrawalApply.AccountWithdrawalApplyDto;
+import com.java110.intf.acct.IAccountInnerServiceSMO;
import com.java110.intf.acct.IAccountWithdrawalApplyInnerServiceSMO;
+import com.java110.po.accountDetail.AccountDetailPo;
import com.java110.po.accountWithdrawalApply.AccountWithdrawalApplyPo;
import com.java110.vo.ResultVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Service;
+
+import java.util.List;
@Service("updateAccountWithdrawalApplyBMOImpl")
@@ -16,7 +22,8 @@
@Autowired
private IAccountWithdrawalApplyInnerServiceSMO accountWithdrawalApplyInnerServiceSMOImpl;
-
+ @Autowired
+ private IAccountInnerServiceSMO accountInnerServiceSMOImpl;
/**
*
*
@@ -26,6 +33,21 @@
@Java110Transactional
public ResponseEntity<String> update(AccountWithdrawalApplyPo accountWithdrawalApplyPo) {
+ if(accountWithdrawalApplyPo.getState().equals( AccountWithdrawalApplyPo.STATE_PASS ) || accountWithdrawalApplyPo.getState().equals( AccountWithdrawalApplyPo.STATE_ERROR_PAYER )){
+ AccountWithdrawalApplyDto accountWithdrawalApplyDto = new AccountWithdrawalApplyDto();
+ accountWithdrawalApplyDto.setApplyId( accountWithdrawalApplyPo.getApplyId() );
+ accountWithdrawalApplyDto.setState( "0" );
+ List<AccountWithdrawalApplyDto> accountWithdrawalApplyDtos = accountWithdrawalApplyInnerServiceSMOImpl.queryAccountWithdrawalApplys( accountWithdrawalApplyDto );
+ if(null != accountWithdrawalApplyDtos && accountWithdrawalApplyDtos.size() > 0){
+ AccountWithdrawalApplyDto WithdrawalApplyDto = accountWithdrawalApplyDtos.get( 0 );
+ AccountDetailPo accountDetailPo = new AccountDetailPo();
+ accountDetailPo.setAcctId( WithdrawalApplyDto.getAcctId() );
+ accountDetailPo.setAmount( WithdrawalApplyDto.getAmount() );
+ accountDetailPo.setRemark( accountWithdrawalApplyPo.getContext() );
+ accountInnerServiceSMOImpl.prestoreAccount( accountDetailPo );
+ }
+ }
+
int flag = accountWithdrawalApplyInnerServiceSMOImpl.updateAccountWithdrawalApply(accountWithdrawalApplyPo);
if (flag > 0) {
--
Gitblit v1.8.0