Commit 8c012c87 authored by tangfang's avatar tangfang

修改余额为0的处理,

添加银行卡空指针问题
parent bb784864
......@@ -669,7 +669,7 @@ public class CompanyServiceImpl implements CompanyService {
reqVo.setReservedPhone(reqVo.getPhone());
reqVo.setStatus(0);
ResponseResult<CompanyBankCardReqVo> result = new ResponseResult<>();
if (2 == reqVo.getType()) {
if (!StringHelper.isEmpty(reqVo.getType()) && 2 == reqVo.getType()) {
result = payFeign.bindCompanyAccount(reqVo);
} else {
result = payFeign.bindBack(reqVo);
......
......@@ -474,10 +474,14 @@ public class FinanceServiceImpl implements FinanceService {
public ResponseResult<String> saveCapitalFlow(CapitalFlowReqVo req) {
mqService.log(new MessageLogReqVo(ReportMqConstant.REPORT_PRODUCT_DETAIL_SAVE, req.getTempId()));
double money = req.getActualMoney();
System.out.println("处理余额:" + req.getOrderId() + "," + req.getOrderMonetDetailId() + ",money:" + money);
if (CompanyConstant.CATEGORY_REFUND == req.getCategory()) {
// 退款
money = -money;
if(money == 0 ){
money = 0;
}else{
money = -money;
}
}
if(StringHelper.isEmpty(money)){
throw new CodeException("金额不能为空");
......@@ -487,7 +491,7 @@ public class FinanceServiceImpl implements FinanceService {
updateCompanyMoneyReqVo.setCompanyId(req.getCompanyId());
updateCompanyMoneyReqVo.setNewWithdrawTotalCash(money);
companyExtendDao.updateCompanyMoney(updateCompanyMoneyReqVo);
System.out.println("处理余额:" + req.getOrderId() + "," + req.getOrderMonetDetailId());
CompanyResVo companyVo = companyDao.load(req.getCompanyId(), CompanyResVo.class);
if (StringHelper.isEmpty(companyVo)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment