| | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.java110.core.annotation.Java110Cmd; |
| | | import com.java110.core.context.ICmdDataFlowContext; |
| | | import com.java110.core.event.cmd.AbstractServiceCmdListener; |
| | | import com.java110.core.event.cmd.Cmd; |
| | | import com.java110.core.event.cmd.CmdEvent; |
| | | import com.java110.core.factory.GenerateCodeFactory; |
| | | import com.java110.dto.RoomDto; |
| | |
| | | import com.java110.po.fee.FeeAttrPo; |
| | | import com.java110.po.fee.PayFeePo; |
| | | import com.java110.po.payFeeBatch.PayFeeBatchPo; |
| | | import com.java110.utils.constant.CommonConstant; |
| | | import com.java110.utils.exception.CmdException; |
| | | import com.java110.utils.util.Assert; |
| | | import com.java110.utils.util.BeanConvertUtil; |
| | |
| | | import java.util.List; |
| | | |
| | | @Java110Cmd(serviceCode = "fee.createFeeByCombo") |
| | | public class CreateFeeByComboCmd extends AbstractServiceCmdListener { |
| | | public class CreateFeeByComboCmd extends Cmd { |
| | | |
| | | @Autowired |
| | | private IPayFeeBatchV1InnerServiceSMO payFeeBatchV1InnerServiceSMOImpl; |
| | |
| | | |
| | | FeeConfigDto feeConfigDto = new FeeConfigDto(); |
| | | feeConfigDto.setCommunityId(reqJson.getString("communityId")); |
| | | feeConfigDto.setConfigId(reqJson.getString("configId")); |
| | | feeConfigDto.setConfigId(config.getString("configId")); |
| | | List<FeeConfigDto> feeConfigDtos = feeConfigInnerServiceSMOImpl.queryFeeConfigs(feeConfigDto); |
| | | Assert.listOnlyOne(feeConfigDtos, "当前费用项ID不存在或存在多条" + reqJson.getString("configId")); |
| | | |
| | | if (FeeDto.FEE_FLAG_ONCE.equals(feeConfigDtos.get(0).getFeeFlag()) && config.containsKey("endTime")) { |
| | | if (!FeeDto.FEE_FLAG_CYCLE.equals(feeConfigDtos.get(0).getFeeFlag()) && config.containsKey("endTime")) { |
| | | Date endTime = null; |
| | | Date configEndTime = null; |
| | | try { |
| | |
| | | |
| | | feePos.add(BeanConvertUtil.covertBean(addRoomFee(config, reqJson,feeConfigDtos), PayFeePo.class)); |
| | | |
| | | if (FeeDto.FEE_FLAG_ONCE.equals(feeConfigDtos.get(0).getFeeFlag())) { |
| | | if (!FeeDto.FEE_FLAG_CYCLE.equals(feeConfigDtos.get(0).getFeeFlag())) { |
| | | feeAttrsPos.add(addFeeAttr(reqJson, FeeAttrDto.SPEC_CD_ONCE_FEE_DEADLINE_TIME, |
| | | config.containsKey("endTime") ? config.getString("endTime") : reqJson.getString("configEndTime"))); |
| | | } |
| | |
| | | businessUnit.put("startTime", config.getString("startTime")); |
| | | businessUnit.put("endTime", config.getString("startTime")); |
| | | businessUnit.put("communityId", paramInJson.getString("communityId")); |
| | | businessUnit.put("payerObjId", config.getString("payerObjId")); |
| | | businessUnit.put("payerObjType", config.getString("payerObjType")); |
| | | businessUnit.put("payerObjId", paramInJson.getString("payerObjId")); |
| | | businessUnit.put("payerObjType", paramInJson.getString("payerObjType")); |
| | | businessUnit.put("feeFlag", feeConfigDtos.get(0).getFeeFlag()); |
| | | businessUnit.put("state", "2008001"); |
| | | businessUnit.put("batchId", paramInJson.getString("batchId")); |