From ca91b7a11484862c95a1b5eefadbf579e371aac9 Mon Sep 17 00:00:00 2001
From: java110 <928255095@qq.com>
Date: 星期一, 23 十一月 2020 10:09:17 +0800
Subject: [PATCH] 优化diamante
---
service-community/src/main/java/com/java110/community/CommunityServiceApplicationStart.java | 15 +++++++
service-front/src/main/java/com/java110/front/smo/meterWaterImport/impl/MeterWaterImportSMOImpl.java | 2
service-order/src/main/java/com/java110/order/OrderServiceApplicationStart.java | 15 +++++++
service-common/src/main/java/com/java110/common/CommonServiceApplicationStart.java | 15 +++++++
service-fee/src/main/java/com/java110/fee/bmo/meterWater/impl/QueryPreMeterWaterImpl.java | 2 +
service-front/src/main/java/com/java110/front/smo/assetImport/impl/ImportMeterWaterFeeSMOImpl.java | 16 ++++++-
java110-db/src/main/resources/mapper/fee/MeterWaterServiceDaoImplMapper.xml | 2
service-eureka/src/main/java/com/java110/eureka/ConfigServerEurekaApplication.java | 15 +++++++
8 files changed, 77 insertions(+), 5 deletions(-)
diff --git a/java110-db/src/main/resources/mapper/fee/MeterWaterServiceDaoImplMapper.xml b/java110-db/src/main/resources/mapper/fee/MeterWaterServiceDaoImplMapper.xml
index 96f35bc..2eb81d5 100644
--- a/java110-db/src/main/resources/mapper/fee/MeterWaterServiceDaoImplMapper.xml
+++ b/java110-db/src/main/resources/mapper/fee/MeterWaterServiceDaoImplMapper.xml
@@ -280,7 +280,7 @@
VALUES
<foreach collection="meterWaterPos" item="item" separator=",">
(#{item.remark},'0',#{item.curReadingTime},#{item.waterId},#{item.curDegrees},#{item.meterType},#{item.preDegrees},
- '-1',#{item.objId},#{item.preReadingTime},'-1',#{item.communityId},#{item.objType},#{item.feeId},#{item.objName})
+ #{item.objId},#{item.preReadingTime},'-1',#{item.communityId},#{item.objType},#{item.feeId},#{item.objName})
</foreach>
</insert>
diff --git a/service-common/src/main/java/com/java110/common/CommonServiceApplicationStart.java b/service-common/src/main/java/com/java110/common/CommonServiceApplicationStart.java
index 28a8f8d..2efb9e6 100644
--- a/service-common/src/main/java/com/java110/common/CommonServiceApplicationStart.java
+++ b/service-common/src/main/java/com/java110/common/CommonServiceApplicationStart.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright 2017-2020 鍚村鏂� and java110 team.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.java110.common;
import com.java110.core.annotation.Java110ListenerDiscovery;
diff --git a/service-community/src/main/java/com/java110/community/CommunityServiceApplicationStart.java b/service-community/src/main/java/com/java110/community/CommunityServiceApplicationStart.java
index 982c9ae..4ba88c6 100644
--- a/service-community/src/main/java/com/java110/community/CommunityServiceApplicationStart.java
+++ b/service-community/src/main/java/com/java110/community/CommunityServiceApplicationStart.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright 2017-2020 鍚村鏂� and java110 team.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.java110.community;
import com.java110.core.annotation.Java110ListenerDiscovery;
diff --git a/service-eureka/src/main/java/com/java110/eureka/ConfigServerEurekaApplication.java b/service-eureka/src/main/java/com/java110/eureka/ConfigServerEurekaApplication.java
index 0684f6b..c54fe2e 100644
--- a/service-eureka/src/main/java/com/java110/eureka/ConfigServerEurekaApplication.java
+++ b/service-eureka/src/main/java/com/java110/eureka/ConfigServerEurekaApplication.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright 2017-2020 鍚村鏂� and java110 team.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.java110.eureka;
import org.springframework.boot.SpringApplication;
diff --git a/service-fee/src/main/java/com/java110/fee/bmo/meterWater/impl/QueryPreMeterWaterImpl.java b/service-fee/src/main/java/com/java110/fee/bmo/meterWater/impl/QueryPreMeterWaterImpl.java
index aff42e4..f2ceae9 100644
--- a/service-fee/src/main/java/com/java110/fee/bmo/meterWater/impl/QueryPreMeterWaterImpl.java
+++ b/service-fee/src/main/java/com/java110/fee/bmo/meterWater/impl/QueryPreMeterWaterImpl.java
@@ -160,6 +160,7 @@
payFeePo.setUserId(userId);
payFeePo.setFeeTypeCd(feeTypeCd);
payFeePo.setConfigId(configId);
+ payFeePo.setCommunityId(communityId);
fees.add(payFeePo);
MeterWaterPo meterWaterPo = new MeterWaterPo();
@@ -174,6 +175,7 @@
meterWaterPo.setPreDegrees(importExportMeterWaterDto.getPreDegrees());
meterWaterPo.setPreReadingTime(importExportMeterWaterDto.getPreReadingTime());
meterWaterPo.setWaterId(GenerateCodeFactory.getGeneratorId(GenerateCodeFactory.CODE_PREFIX_waterId));
+ meterWaterPo.setRemark(importExportMeterWaterDto.getRemark());
meterWaterPos.add(meterWaterPo);
}
diff --git a/service-front/src/main/java/com/java110/front/smo/assetImport/impl/ImportMeterWaterFeeSMOImpl.java b/service-front/src/main/java/com/java110/front/smo/assetImport/impl/ImportMeterWaterFeeSMOImpl.java
index 99f4213..8e499ad 100644
--- a/service-front/src/main/java/com/java110/front/smo/assetImport/impl/ImportMeterWaterFeeSMOImpl.java
+++ b/service-front/src/main/java/com/java110/front/smo/assetImport/impl/ImportMeterWaterFeeSMOImpl.java
@@ -135,7 +135,17 @@
String apiUrl = ServiceConstant.SERVICE_API_URL + "/api/meterWater/importMeterWater";
- this.callCenterService(restTemplate, pd, data.toJSONString(), apiUrl, HttpMethod.POST);
+ ResponseEntity<String> responseEntity = this.callCenterService(restTemplate, pd, data.toJSONString(), apiUrl, HttpMethod.POST);
+
+ if (responseEntity.getStatusCode() != HttpStatus.OK) {
+ throw new IllegalArgumentException(responseEntity.getBody());
+ }
+
+ JSONObject paramOut = JSONObject.parseObject(responseEntity.getBody());
+ if (ResultVo.CODE_OK != paramOut.getInteger("code")) {
+ throw new IllegalArgumentException(paramOut.getString("msg"));
+ }
+
}
@@ -179,8 +189,8 @@
importRoomFee.setRoomNum(os[2].toString());
importRoomFee.setPreDegrees(os[3].toString());
importRoomFee.setPreReadingTime(startTime);
- importRoomFee.setCurDegrees(endTime);
- importRoomFee.setCurReadingTime(os[6].toString());
+ importRoomFee.setCurDegrees(os[5].toString());
+ importRoomFee.setCurReadingTime(endTime);
rooms.add(importRoomFee);
}
}
diff --git a/service-front/src/main/java/com/java110/front/smo/meterWaterImport/impl/MeterWaterImportSMOImpl.java b/service-front/src/main/java/com/java110/front/smo/meterWaterImport/impl/MeterWaterImportSMOImpl.java
index 8cd0766..6c9ead6 100644
--- a/service-front/src/main/java/com/java110/front/smo/meterWaterImport/impl/MeterWaterImportSMOImpl.java
+++ b/service-front/src/main/java/com/java110/front/smo/meterWaterImport/impl/MeterWaterImportSMOImpl.java
@@ -38,7 +38,7 @@
* @Version 1.0
* add by wuxw 2019/9/23
**/
-@Service("feeImportSMOImpl")
+@Service("meterWaterImportSMOImpl")
public class MeterWaterImportSMOImpl extends BaseComponentSMO implements IMeterWaterImportSMO {
private final static Logger logger = LoggerFactory.getLogger(MeterWaterImportSMOImpl.class);
diff --git a/service-order/src/main/java/com/java110/order/OrderServiceApplicationStart.java b/service-order/src/main/java/com/java110/order/OrderServiceApplicationStart.java
index b9b1f51..7e2652e 100644
--- a/service-order/src/main/java/com/java110/order/OrderServiceApplicationStart.java
+++ b/service-order/src/main/java/com/java110/order/OrderServiceApplicationStart.java
@@ -1,3 +1,18 @@
+/*
+ * Copyright 2017-2020 鍚村鏂� and java110 team.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package com.java110.order;
import com.java110.utils.cache.MappingCache;
--
Gitblit v1.8.0