|
|
@ -12,6 +12,7 @@ import com.yxt.anrui.fin.api.finpaymentapplydetailsbeloweve.FinPaymentapplyDetai |
|
|
|
import com.yxt.anrui.fin.biz.finpaymentapplydetailsbelow.FinPaymentapplyDetailsBelowService; |
|
|
|
import com.yxt.anrui.fin.biz.finpaymentapplydetailsbeloweve.FinPaymentapplyDetailsBelowEveService; |
|
|
|
import com.yxt.common.base.service.MybatisBaseService; |
|
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.stereotype.Service; |
|
|
|
|
|
|
@ -55,14 +56,18 @@ public class FinPaymentapplyDetailsService extends MybatisBaseService<FinPayment |
|
|
|
List<FinPaymentapplyDetailsBelowDto> finPaymentapplyDetailsBelowList = dto.getFinPaymentapplyDetailsBelowList(); |
|
|
|
for (FinPaymentapplyDetailsBelowDto finPaymentapplyDetailsBelowDto : finPaymentapplyDetailsBelowList) { |
|
|
|
finPaymentapplyDetailsBelowDto.setDetailSid(finPaymentapplyDetails.getSid()); |
|
|
|
if (StringUtils.isBlank(finPaymentapplyDetailsBelowDto.getBankShortName())){ |
|
|
|
finPaymentapplyDetailsBelowDto.setClosFundName(DateUtil.formatDate(new Date()) + dto.getPaymentType() + new BigDecimal(dto.getPayAccount()).divide(new BigDecimal(10000)) + "万元"); |
|
|
|
}else { |
|
|
|
finPaymentapplyDetailsBelowDto.setClosFundName(DateUtil.formatDate(new Date()) + dto.getPaymentType() + finPaymentapplyDetailsBelowDto.getBankShortName() + new BigDecimal(dto.getPayAccount()).divide(new BigDecimal(10000)) + "万元"); |
|
|
|
} |
|
|
|
finPaymentapplyDetailsBelowDto.setPayCompanySid(finPaymentapply.getPayCompanySid()); |
|
|
|
finPaymentapplyDetailsBelowDto.setPayCompany(finPaymentapply.getPayCompany()); |
|
|
|
String belowSid = finPaymentapplyDetailsBelowService.insertByDto(finPaymentapplyDetailsBelowDto); |
|
|
|
List<FinPaymentapplyDetailsBelowEveDto> finPaymentapplyDetailsBelowEveList = finPaymentapplyDetailsBelowDto.getFinPaymentapplyDetailsBelowEveList(); |
|
|
|
for (FinPaymentapplyDetailsBelowEveDto finPaymentapplyDetailsBelowEveDto : finPaymentapplyDetailsBelowEveList) { |
|
|
|
finPaymentapplyDetailsBelowEveDto.setCreateBySid(finPaymentapply.getCreateBySid()); |
|
|
|
finPaymentapplyDetailsBelowEveDto.setCostTitleValue(DateUtil.formatDate(new Date()) + dto.getPaymentType() + finPaymentapplyDetailsBelowDto.getBankShortName() + new BigDecimal(dto.getPayAccount()).divide(new BigDecimal(10000)) + "万元"); |
|
|
|
finPaymentapplyDetailsBelowEveDto.setCostTitleValue(finPaymentapplyDetailsBelowDto.getClosFundName()); |
|
|
|
finPaymentapplyDetailsBelowEveDto.setDeptSid(finPaymentapply.getDeptSid()); |
|
|
|
finPaymentapplyDetailsBelowEveDto.setDeptName(finPaymentapply.getDeptName()); |
|
|
|
finPaymentapplyDetailsBelowEveDto.setPayCompanySid(finPaymentapply.getPayCompanySid()); |
|
|
|