From c0182f86d8461f16a147c1384f916c43171d1762 Mon Sep 17 00:00:00 2001
From: xiaoyong931011 <15274802129@163.com>
Date: Mon, 05 Dec 2022 14:36:24 +0800
Subject: [PATCH] 20221130

---
 src/main/java/cc/mrbird/febs/dapp/service/impl/DappSystemServiceImpl.java |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/src/main/java/cc/mrbird/febs/dapp/service/impl/DappSystemServiceImpl.java b/src/main/java/cc/mrbird/febs/dapp/service/impl/DappSystemServiceImpl.java
index 0f8dec3..8157cba 100644
--- a/src/main/java/cc/mrbird/febs/dapp/service/impl/DappSystemServiceImpl.java
+++ b/src/main/java/cc/mrbird/febs/dapp/service/impl/DappSystemServiceImpl.java
@@ -464,17 +464,19 @@
         }
         Integer count = dappFundFlowDao.updateStatusById(DappFundFlowEntity.WITHDRAW_STATUS_AGREE,dappFundFlowEntity.getId());
         if(count > 0){
+            DappFundFlowEntity dappFundFlow = dappFundFlowDao.selectById(id);
             //金额
-            BigDecimal amount = dappFundFlowEntity.getAmount();
+            BigDecimal amount = dappFundFlow.getAmount();
             //目标地址
-            String address = dappMemberEntity.getAddress();
+            String address = dappFundFlow.getAddress();
     //        String hash = ChainService.getInstance(ChainEnum.BSC_USDT.name()).transfer(address, amount);
             String hash = ChainService.getInstance(ChainEnum.BNB.name()).transferBaseToken(address, amount);
             if(StrUtil.isEmpty(hash)){
                 return;
             }
-            dappFundFlowEntity.setToHash(hash);
-            dappFundFlowDao.updateById(dappFundFlowEntity);
+            log.info("{},{}",id,hash);
+            dappFundFlow.setFromHash(hash);
+            dappFundFlowDao.updateById(dappFundFlow);
         }
     }
 

--
Gitblit v1.9.1