| | |
| | | import com.java110.core.context.ICmdDataFlowContext; |
| | | import com.java110.core.event.cmd.Cmd; |
| | | import com.java110.core.event.cmd.CmdEvent; |
| | | import com.java110.core.factory.GenerateCodeFactory; |
| | | import com.java110.intf.common.IChargeRuleV1InnerServiceSMO; |
| | | import com.java110.po.chargeRule.ChargeRulePo; |
| | | import com.java110.po.charge.ChargeRulePo; |
| | | import com.java110.utils.exception.CmdException; |
| | | import com.java110.utils.util.Assert; |
| | | import com.java110.utils.util.BeanConvertUtil; |
| | |
| | | @Java110Cmd(serviceCode = "chargeRule.updateChargeRule") |
| | | public class UpdateChargeRuleCmd extends Cmd { |
| | | |
| | | private static Logger logger = LoggerFactory.getLogger(UpdateChargeRuleCmd.class); |
| | | private static Logger logger = LoggerFactory.getLogger(UpdateChargeRuleCmd.class); |
| | | |
| | | |
| | | @Autowired |
| | |
| | | @Override |
| | | public void validate(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) { |
| | | Assert.hasKeyAndValue(reqJson, "ruleId", "ruleId不能为空"); |
| | | Assert.hasKeyAndValue(reqJson, "communityId", "communityId不能为空"); |
| | | Assert.hasKeyAndValue(reqJson, "communityId", "communityId不能为空"); |
| | | |
| | | } |
| | | |
| | |
| | | @Java110Transactional |
| | | public void doCmd(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) throws CmdException { |
| | | |
| | | ChargeRulePo chargeRulePo = BeanConvertUtil.covertBean(reqJson, ChargeRulePo.class); |
| | | ChargeRulePo chargeRulePo = BeanConvertUtil.covertBean(reqJson, ChargeRulePo.class); |
| | | int flag = chargeRuleV1InnerServiceSMOImpl.updateChargeRule(chargeRulePo); |
| | | |
| | | if (flag < 1) { |