From 7958f1dddb8a7f4e70d232b07a7703955ecedae0 Mon Sep 17 00:00:00 2001
From: Your Name <you@example.com>
Date: 星期六, 26 八月 2023 12:45:33 +0800
Subject: [PATCH] 优化diamante

---
 service-fee/src/main/java/com/java110/fee/cmd/feeConfig/UpdateFeeConfigCmd.java |   15 ++++-----------
 1 files changed, 4 insertions(+), 11 deletions(-)

diff --git a/service-fee/src/main/java/com/java110/fee/cmd/feeConfig/UpdateFeeConfigCmd.java b/service-fee/src/main/java/com/java110/fee/cmd/feeConfig/UpdateFeeConfigCmd.java
index bc944c0..8ac718e 100644
--- a/service-fee/src/main/java/com/java110/fee/cmd/feeConfig/UpdateFeeConfigCmd.java
+++ b/service-fee/src/main/java/com/java110/fee/cmd/feeConfig/UpdateFeeConfigCmd.java
@@ -2,12 +2,11 @@
 
 import com.alibaba.fastjson.JSONObject;
 import com.java110.core.annotation.Java110Cmd;
+import com.java110.core.annotation.Java110Transactional;
 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.fee.FeeConfigDto;
-import com.java110.fee.smo.impl.FeeConfigInnerServiceSMOImpl;
 import com.java110.intf.fee.IFeeConfigInnerServiceSMO;
 import com.java110.intf.fee.IPayFeeConfigV1InnerServiceSMO;
 import com.java110.po.fee.PayFeeConfigPo;
@@ -20,7 +19,7 @@
 import java.util.List;
 
 @Java110Cmd(serviceCode = "feeConfig.updateFeeConfig")
-public class UpdateFeeConfigCmd extends AbstractServiceCmdListener {
+public class UpdateFeeConfigCmd extends Cmd {
 
     @Autowired
     private IPayFeeConfigV1InnerServiceSMO payFeeConfigV1InnerServiceSMOImpl;
@@ -30,7 +29,6 @@
 
     @Override
     public void validate(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) throws CmdException {
-
         Assert.hasKeyAndValue(reqJson, "configId", "璐圭敤椤笽D涓嶈兘涓虹┖");
         Assert.hasKeyAndValue(reqJson, "feeTypeCd", "蹇呭~锛岃閫夋嫨璐圭敤绫诲瀷");
         Assert.hasKeyAndValue(reqJson, "feeName", "蹇呭~锛岃濉啓鏀惰垂椤圭洰");
@@ -42,12 +40,10 @@
         Assert.hasKeyAndValue(reqJson, "additionalAmount", "蹇呭~锛岃濉啓闄勫姞璐圭敤");
         Assert.hasKeyAndValue(reqJson, "communityId", "鏈寘鍚皬鍖篒D");
         Assert.hasKeyAndValue(reqJson, "billType", "蹇呭~锛岃濉啓鍑鸿处绫诲瀷");
-
-
-
     }
 
     @Override
+    @Java110Transactional
     public void doCmd(CmdEvent event, ICmdDataFlowContext cmdDataFlowContext, JSONObject reqJson) throws CmdException {
         FeeConfigDto feeConfigDto = new FeeConfigDto();
         feeConfigDto.setCommunityId(reqJson.getString("communityId"));
@@ -58,13 +54,10 @@
         businessFeeConfig.putAll(reqJson);
         businessFeeConfig.put("isDefault", feeConfigDtos.get(0).getIsDefault());
         PayFeeConfigPo payFeeConfigPo = BeanConvertUtil.covertBean(businessFeeConfig, PayFeeConfigPo.class);
-
         int flag = payFeeConfigV1InnerServiceSMOImpl.updatePayFeeConfig(payFeeConfigPo);
-
         if (flag < 1) {
             throw new CmdException("淇敼璐圭敤椤瑰け璐�");
         }
-
         cmdDataFlowContext.setResponseEntity(ResultVo.success());
     }
 }

--
Gitblit v1.8.0