| | |
| | | payFeeDetailPo.setFeeId(tmpFeeDto.getFeeId()); |
| | | payFeeDetailPo.setStartTime(importRoomFee.getStartTime()); |
| | | payFeeDetailPo.setEndTime(importRoomFee.getEndTime()); |
| | | payFeeDetailPo.setDetailId(GenerateCodeFactory.getGeneratorId(GenerateCodeFactory.CODE_PREFIX_detailId)); |
| | | payFeeDetailPo.setRemark(importRoomFee.getRemark()); |
| | | payFeeDetailPo.setCreateTime(importRoomFee.getCreateTime()); |
| | | payFeeDetailPo.setState("1400"); |
| | | payFeeDetailPo.setCashierName(importRoomFee.getStaffName()); |
| | | payFeeDetailPo.setPayableAmount(importRoomFee.getAmount()); |
| | | |
| | | int count = feeDetailInnerServiceSMOImpl.queryFeeDetailsCountByVo(payFeeDetailPo); |
| | | |
| | | if (count > 0) { |
| | | throw new IllegalStateException("重复的缴费记录"); |
| | | } |
| | | |
| | | payFeeDetailPo.setDetailId(GenerateCodeFactory.getGeneratorId(GenerateCodeFactory.CODE_PREFIX_detailId)); |
| | | if(importRoomFee.getOpenInv() != null){ |
| | | payFeeDetailPo.setOpenInvoice(importRoomFee.getOpenInv()); |
| | | } |
| | |
| | | fee.setFeeId(tmpFeeDto.getFeeId()); |
| | | FeeDto feeInfo = feeInnerServiceSMOImpl.queryFees(fee).get(0); |
| | | |
| | | if (feeInfo.getEndTime().after(feeInfo.getMaxEndTime()) || feeInfo.getEndTime().getTime() == feeInfo.getMaxEndTime().getTime()) { |
| | | PayFeePo payFeePo = new PayFeePo(); |
| | | payFeePo.setFeeId(feeInfo.getFeeId()); |
| | | payFeePo.setState(FeeDto.STATE_FINISH); |
| | | int i = feeInnerServiceSMOImpl.updateFee(payFeePo); |
| | | } |
| | | |
| | | // int i = feeInnerServiceSMOImpl.updateFee(feeInfo); |
| | | |
| | |
| | | payFeePo.setCommunityId(importRoomFee.getCommunityId()); |
| | | payFeePo.setStatusCd(StatusConstant.STATUS_CD_VALID); |
| | | payFeePo.setFeeId(tmpFeeDto.getFeeId()); |
| | | String[] arr = importRoomFee.getEndTime().split(" "); |
| | | if (arr.length >= 2 &&arr[1].equals("23:59:59")){ |
| | | importRoomFee.setEndTime(arr[0] + " 00:00:00"); |
| | | } |
| | | payFeePo.setEndTime(DateUtil.getNextSecTime(importRoomFee.getEndTime())); |
| | | if (FeeDto.FEE_FLAG_ONCE.equals(tmpFeeDto.getFeeFlag())) { |
| | | payFeePo.setState(FeeDto.STATE_FINISH); |
| | | } |
| | | |
| | | feeInnerServiceSMOImpl.updateFee(payFeePo); |
| | | feeInfo = feeInnerServiceSMOImpl.queryFees(fee).get(0); |
| | | if (DateUtil.getFormatTimeStringB(feeInfo.getEndTime()).equals(DateUtil.getFormatTimeStringB(feeInfo.getMaxEndTime()))) { |
| | | PayFeePo payFee = new PayFeePo(); |
| | | payFee.setFeeId(feeInfo.getFeeId()); |
| | | payFee.setState(FeeDto.STATE_FINISH); |
| | | int i = feeInnerServiceSMOImpl.updateFee(payFee); |
| | | } |
| | | } |
| | | |
| | | |