diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/constant/IndexCalConstant.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/constant/IndexCalConstant.java
index 13b27760a5..12b5c2a136 100644
--- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/constant/IndexCalConstant.java
+++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/constant/IndexCalConstant.java
@@ -20,4 +20,18 @@ public interface IndexCalConstant {
String USER_ID="USER_ID";
String YEAR_ID = "YEAR_ID";
+
+ String COMMUNITY_GOVERN = "zhilinengli";
+
+ String COMMUNITY_PARTY = "dangjiannengli";
+
+ String COMMUNITY_SERVICE = "fuwunengli";
+
+ String COMMUNITY_SERVICE_AVG = "shequxiajisywgfwnldfpjz";
+
+ String COMMUNITY_GOVERN_AVG = "shequxiashusywgzlnlhzpyz";
+
+ String COMMUNITY_PARTY_AVG = "xiazhusuoyouwgddjnlpjz";
+
+ String COMMUNITY_RELATE = "shequxiangguan";
}
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityGovrnFiveScoreDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityGovrnFiveScoreDTO.java
deleted file mode 100644
index 5f2fbf85b7..0000000000
--- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityGovrnFiveScoreDTO.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/**
- * Copyright 2018 人人开源 https://www.renren.io
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-
-package com.epmet.dto.screen;
-
-import java.io.Serializable;
-import java.math.BigDecimal;
-
-import lombok.Data;
-
-/**
- * 社区相关-治理能力【五级权重】分数表
- *
- * @author generator generator@elink-cn.com
- * @since v1.0.0 2020-08-27
- */
-@Data
-public class FactIndexCommunityGovrnFiveScoreDTO implements Serializable {
-
- private static final long serialVersionUID = 1L;
-
- /**
- *
- */
- private String id;
-
- /**
- * 机关iD
- */
- private String agencyId;
-
- /**
- * 月份ID
- */
- private String monthId;
-
- /**
- * 指标ID
- */
- private String indexId;
-
- /**
- * 总指数分值
- */
- private BigDecimal totalScore;
-
- /**
- * 党建能力分值
- */
- private BigDecimal partyAbilityScore;
-
- /**
- * 治理能力分值
- */
- private BigDecimal govrnAbilityScore;
-
- /**
- * 服务能力分值
- */
- private BigDecimal serviceAbilityScore;
-
- /**
- * 删除状态,0正常,1删除
- */
- private Integer delFlag;
-
- /**
- * 乐观锁
- */
- private Integer revision;
-
- /**
- * 创建人
- */
- private String createdBy;
-
- /**
- * 更新人
- */
- private String updatedBy ;
-
- public FactIndexCommunityGovrnFiveScoreDTO() {
- this.agencyId = "";
- this.monthId = "";
- this.indexId = "";
- this.totalScore = new BigDecimal(0);
- this.partyAbilityScore = new BigDecimal(0);
- this.govrnAbilityScore = new BigDecimal(0);
- this.serviceAbilityScore = new BigDecimal(0);
- this.delFlag = 0;
- this.revision = 0;
- this.createdBy = "APP_USER";
- this.updatedBy = "APP_USER";
- }
-}
\ No newline at end of file
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityPartyFiveScoreDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityPartyFiveScoreDTO.java
deleted file mode 100644
index 79024c60ca..0000000000
--- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityPartyFiveScoreDTO.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/**
- * Copyright 2018 人人开源 https://www.renren.io
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-
-package com.epmet.dto.screen;
-
-import java.io.Serializable;
-import java.math.BigDecimal;
-
-import lombok.Data;
-
-/**
- * 社区相关-党建能力【五级权重】分数表
- *
- * @author generator generator@elink-cn.com
- * @since v1.0.0 2020-08-27
- */
-@Data
-public class FactIndexCommunityPartyFiveScoreDTO implements Serializable {
-
- private static final long serialVersionUID = 1L;
-
- /**
- * id
- */
- private String id;
-
- /**
- * 机关ID
- */
- private String agencyId;
-
- /**
- * 月度ID
- */
- private String monthId;
-
- /**
- * 指标ID
- */
- private String indexId;
-
- /**
- * 总指数分值
- */
- private BigDecimal totalScore;
-
- /**
- * 党建能力分值
- */
- private BigDecimal partyAbilityScore;
-
- /**
- * 治理能力分值
- */
- private BigDecimal govrnAbilityScore;
-
- /**
- * 服务能力分值
- */
- private BigDecimal serviceAbilityScore;
-
- /**
- * 删除状态,0正常,1删除
- */
- private Integer delFlag;
-
- /**
- * 乐观锁
- */
- private Integer revision;
-
- /**
- * 创建人
- */
- private String createdBy;
-
- /**
- * 更新人
- */
- private String updatedBy;
-
- public FactIndexCommunityPartyFiveScoreDTO() {
- this.agencyId = "";
- this.monthId = "";
- this.indexId = "";
- this.totalScore = new BigDecimal(0);
- this.partyAbilityScore = new BigDecimal(0);
- this.govrnAbilityScore = new BigDecimal(0);
- this.serviceAbilityScore = new BigDecimal(0);
- this.delFlag = 0;
- this.revision = 0;
- this.createdBy = "APP_USER";
- this.updatedBy = "APP_USER";
- }
-
-}
\ No newline at end of file
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityScoreDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityScoreDTO.java
index 805e28ef7f..8ad2ec6658 100644
--- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityScoreDTO.java
+++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityScoreDTO.java
@@ -27,7 +27,7 @@ import java.math.BigDecimal;
* 社区相关分数表
*
* @author generator generator@elink-cn.com
- * @since v1.0.0 2020-08-27
+ * @since v1.0.0 2020-08-31
*/
@Data
public class FactIndexCommunityScoreDTO implements Serializable {
@@ -35,49 +35,59 @@ public class FactIndexCommunityScoreDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
- *
+ * ID 主键
*/
private String id;
/**
- * 机关ID
+ * 客户Id
+ */
+ private String customerId;
+
+ /**
+ * 组织id
*/
private String agencyId;
/**
- * 月份ID
+ * 社区上一级组织id
*/
- private String monthId;
+ private String parentAgencyId;
+
+ /**
+ * 年度ID: yyyy
+ */
+ private String yearId;
/**
- * 季度ID
+ * 季度id: yyyyQ1、yyyyQ2、yyyyQ3、yyyyQ4
*/
private String quarterId;
/**
- * 年度ID
+ * 月维度Id: yyyyMM
*/
- private String yearId;
+ private String monthId;
/**
- * 指标ID
+ * 1:总分;0不是;默认0
*/
- private String indexId;
+ private String isTotal;
/**
- * 分数
+ * 分值
*/
private BigDecimal score;
/**
- * 党建能力:party,治理能力:govrn,服务能力:service
+ * 党建能力:dangjiannengli;治理能力:zhilinengli;服务能力:fuwunengli;社区相关:shequxiangguan
*/
- private String type;
+ private String indexCode;
/**
- * 删除状态,0正常,1删除
+ * 删除状态
*/
- private Integer delFlag;
+ private Integer delFlag;
/**
* 乐观锁
@@ -104,4 +114,19 @@ public class FactIndexCommunityScoreDTO implements Serializable {
*/
private Date updatedTime;
+ public FactIndexCommunityScoreDTO() {
+ this.customerId = "";
+ this.agencyId = "";
+ this.parentAgencyId = "";
+ this.yearId = "";
+ this.quarterId = "";
+ this.monthId = "";
+ this.isTotal = "0";
+ this.score = new BigDecimal(0);
+ this.indexCode = "";
+ this.delFlag = 0;
+ this.revision = 0;
+ this.createdBy = "APP_USER";
+ this.updatedBy = "APP_USER";
+ }
}
\ No newline at end of file
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityServiceFiveScoreDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityServiceFiveScoreDTO.java
deleted file mode 100644
index 1eb6386bcc..0000000000
--- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/FactIndexCommunityServiceFiveScoreDTO.java
+++ /dev/null
@@ -1,107 +0,0 @@
-/**
- * Copyright 2018 人人开源 https://www.renren.io
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-
-package com.epmet.dto.screen;
-
-import java.io.Serializable;
-import java.util.Date;
-import lombok.Data;
-
-import java.math.BigDecimal;
-
-/**
- * 社区相关-服务能力【五级权重】分数表
- *
- * @author generator generator@elink-cn.com
- * @since v1.0.0 2020-08-27
- */
-@Data
-public class FactIndexCommunityServiceFiveScoreDTO implements Serializable {
-
- private static final long serialVersionUID = 1L;
-
- /**
- *
- */
- private String id;
-
- /**
- * 机关ID
- */
- private String agencyId;
-
- /**
- * 月度ID
- */
- private String monthId;
-
- /**
- * 指标ID
- */
- private String indexId;
-
- /**
- * 总指数分值
- */
- private BigDecimal totalScore;
-
- /**
- * 党建能力分值
- */
- private BigDecimal partyAbilityScore;
-
- /**
- * 治理能力分值
- */
- private BigDecimal govrnAbilityScore;
-
- /**
- * 服务能力分值
- */
- private BigDecimal serviceAbilityScore;
-
- /**
- * 删除状态,0正常,1删除
- */
- private Integer delFlag;
-
- /**
- * 乐观锁
- */
- private Integer revision;
-
- /**
- * 创建人
- */
- private String createdBy;
-
- /**
- * 创建时间
- */
- private Date createdTime;
-
- /**
- * 更新人
- */
- private String updatedBy;
-
- /**
- * 更新时间
- */
- private Date updatedTime;
-
-}
\ No newline at end of file
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/CommunityActivityCountResultDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/CommunityActivityCountResultDTO.java
new file mode 100644
index 0000000000..ec3b17f615
--- /dev/null
+++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/CommunityActivityCountResultDTO.java
@@ -0,0 +1,59 @@
+package com.epmet.dto.screen.result;
+
+import lombok.Data;
+
+import java.io.Serializable;
+
+/**
+ * @Author zxc
+ * @DateTime 2020/8/31 2:12 下午
+ */
+@Data
+public class CommunityActivityCountResultDTO implements Serializable {
+
+ private static final long serialVersionUID = -6623426101220283941L;
+
+ /**
+ * 客户ID
+ */
+ private String customerId;
+
+ /**
+ * 机关ID
+ */
+ private String agencyId;
+
+ /**
+ * 上级组织ID
+ */
+ private String parentId;
+
+ /**
+ * 月度ID
+ */
+ private String monthId;
+
+ /**
+ * 季度ID
+ */
+ private String quarterId;
+
+ /**
+ * 年度ID
+ */
+ private String yearId;
+
+ /**
+ * 发文数
+ */
+ public Integer activityCount;
+
+ public CommunityActivityCountResultDTO() {
+ this.agencyId = "";
+ this.parentId = "";
+ this.monthId = "";
+ this.quarterId = "";
+ this.yearId = "";
+ this.activityCount = 0;
+ }
+}
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/CommunityPublishArticleCountResultDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/CommunityPublishArticleCountResultDTO.java
index fe50bbf597..cf29133001 100644
--- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/CommunityPublishArticleCountResultDTO.java
+++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/CommunityPublishArticleCountResultDTO.java
@@ -13,6 +13,11 @@ public class CommunityPublishArticleCountResultDTO implements Serializable {
private static final long serialVersionUID = -8260746179353253237L;
+ /**
+ * 客户ID
+ */
+ private String customerId;
+
/**
* 机关ID
*/
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/MaxAndMinBigDecimalResultDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/MaxAndMinBigDecimalResultDTO.java
new file mode 100644
index 0000000000..aa9f471405
--- /dev/null
+++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/MaxAndMinBigDecimalResultDTO.java
@@ -0,0 +1,21 @@
+package com.epmet.dto.screen.result;
+
+import lombok.Data;
+
+import java.io.Serializable;
+import java.math.BigDecimal;
+
+/**
+ * @Author zxc
+ * @DateTime 2020/8/30 8:11 下午
+ */
+@Data
+public class MaxAndMinBigDecimalResultDTO implements Serializable {
+
+ private static final long serialVersionUID = 76227645470470839L;
+
+ private BigDecimal min;
+
+ private BigDecimal max;
+
+}
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridGovernAvgResultDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridGovernAvgResultDTO.java
new file mode 100644
index 0000000000..64f3cc7319
--- /dev/null
+++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridGovernAvgResultDTO.java
@@ -0,0 +1,46 @@
+package com.epmet.dto.screen.result;
+
+import lombok.Data;
+
+import java.io.Serializable;
+import java.math.BigDecimal;
+
+/**
+ * @Author zxc
+ * @DateTime 2020/8/31 9:11 上午
+ */
+@Data
+public class SubGridGovernAvgResultDTO implements Serializable {
+
+ private static final long serialVersionUID = -1354963771895272899L;
+
+ /**
+ * 机关ID
+ */
+ private String agencyId;
+
+ /**
+ * 上级组织ID
+ */
+ private String parentId;
+
+ /**
+ * 月度ID
+ */
+ private String monthId;
+
+ /**
+ * 季度ID
+ */
+ private String quarterId;
+
+ /**
+ * 年度ID
+ */
+ private String yearId;
+
+ /**
+ * 分数
+ */
+ private BigDecimal score;
+}
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridPartyAvgResultDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridPartyAvgResultDTO.java
index 38263c4dc1..48b4501606 100644
--- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridPartyAvgResultDTO.java
+++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridPartyAvgResultDTO.java
@@ -19,6 +19,11 @@ public class SubGridPartyAvgResultDTO implements Serializable {
*/
private String agencyId;
+ /**
+ * 客户ID
+ */
+ private String customerId;
+
/**
* 上级组织ID
*/
diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridServiceAvgResultDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridServiceAvgResultDTO.java
new file mode 100644
index 0000000000..ba6329aef1
--- /dev/null
+++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/screen/result/SubGridServiceAvgResultDTO.java
@@ -0,0 +1,51 @@
+package com.epmet.dto.screen.result;
+
+import lombok.Data;
+
+import java.io.Serializable;
+import java.math.BigDecimal;
+
+/**
+ * @Author zxc
+ * @DateTime 2020/8/31 1:53 下午
+ */
+@Data
+public class SubGridServiceAvgResultDTO implements Serializable {
+
+ private static final long serialVersionUID = -405197363477213644L;
+
+ /**
+ *
+ */
+ private String customerId;
+
+ /**
+ * 机关ID
+ */
+ private String agencyId;
+
+ /**
+ * 上级组织ID
+ */
+ private String parentId;
+
+ /**
+ * 月度ID
+ */
+ private String monthId;
+
+ /**
+ * 季度ID
+ */
+ private String quarterId;
+
+ /**
+ * 年度ID
+ */
+ private String yearId;
+
+ /**
+ * 分数
+ */
+ private BigDecimal score;
+}
diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DemoController.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DemoController.java
index 5f18b920f9..2b88f53f42 100644
--- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DemoController.java
+++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DemoController.java
@@ -120,7 +120,25 @@ public class DemoController {
@PostMapping("zxc")
public Result getZxc(){
// indexCalculateCommunityService.communityPublishArticleCountCalculate("b09527201c4409e19d1dbc5e3c3429a1","202008");
- indexCalculateCommunityService.communityPublishArticleCountCalculate("","202008");
+ indexCalculateCommunityService.communityGovernAbilityCalculate("b09527201c4409e19d1dbc5e3c3429a1","202008");
+ return new Result();
+ }
+
+ @PostMapping("zxc1")
+ public Result getZxc1(){
+ indexCalculateCommunityService.communityPartyCalculate("b09527201c4409e19d1dbc5e3c3429a1","202008");
+ return new Result();
+ }
+
+ @PostMapping("zxc2")
+ public Result getZxc2(){
+ indexCalculateCommunityService.communityServiceAbilityCalculate("b09527201c4409e19d1dbc5e3c3429a1","202008");
+ return new Result();
+ }
+
+ @PostMapping("zxcAll")
+ public Result getZxcAll(){
+ indexCalculateCommunityService.communityRelate("b09527201c4409e19d1dbc5e3c3429a1","202008");
return new Result();
}
diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/indexcoll/FactIndexGovrnAblityOrgMonthlyDao.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/indexcoll/FactIndexGovrnAblityOrgMonthlyDao.java
index fa9b8569b9..f28e6a2fd3 100644
--- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/indexcoll/FactIndexGovrnAblityOrgMonthlyDao.java
+++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/indexcoll/FactIndexGovrnAblityOrgMonthlyDao.java
@@ -25,6 +25,7 @@ import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;
+import java.util.Map;
/**
* 治理能力-街道及社区相关数据
@@ -70,5 +71,5 @@ public interface FactIndexGovrnAblityOrgMonthlyDao extends BaseDao selectCommunityGovernAbility(@Param("customerId")String customerId, @Param("monthId")String monthId);
+ List