linxk 2 тижнів тому
батько
коміт
7cba6d6e04

+ 6 - 2
cif-service/src/main/java/com/txz/cif/web/mng/RechargeRecordController.java

@@ -67,9 +67,13 @@ public class RechargeRecordController {
 			List<BizLog> logs = bizLogService.findByCondition(c);
 			bo.setBizLogs(logs);
 			Account wallet = accountService.getAccount(rechargeRecord.getUserId(), 1);
-			bo.setWalletBalance(wallet.getBalance());
+			if (wallet != null){
+				bo.setWalletBalance(wallet.getBalance());
+			}
 			Account earnings = accountService.getAccount(rechargeRecord.getUserId(), 2);
-			bo.setEarningsBalance(earnings.getBalance());
+			if (earnings != null){
+				bo.setEarningsBalance(earnings.getBalance());
+			}
 			return ResultGenerator.genSuccessResult(bo);
 		} catch (Exception e) {
 			log.error("查询对象操作异常e:{}",e);

+ 6 - 2
cif-service/src/main/java/com/txz/cif/web/mng/WithdrawRecordController.java

@@ -71,9 +71,13 @@ public class WithdrawRecordController {
 			bo.setBizLogs(logs);
 
 			Account wallet = accountService.getAccount(withdrawRecord.getUserId(), 1);
-			bo.setWalletBalance(wallet.getBalance());
+			if (wallet != null){
+				bo.setWalletBalance(wallet.getBalance());
+			}
 			Account earnings = accountService.getAccount(withdrawRecord.getUserId(), 2);
-			bo.setEarningsBalance(earnings.getBalance());
+			if (earnings != null){
+				bo.setEarningsBalance(earnings.getBalance());
+			}
 			return ResultGenerator.genSuccessResult(bo);
 		} catch (Exception e) {
 			log.error("查询对象操作异常e:{}",e);