diff --git a/esua-epdc/docker-compose/test/app/admin/docker-compose.yml b/esua-epdc/docker-compose/test/app/admin/docker-compose.yml index 0f2d27f7f..497085e29 100644 --- a/esua-epdc/docker-compose/test/app/admin/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/admin/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-admin-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-admin-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-admin-server:test container_name: epdc-admin-server-01 ports: - 10001:10001 diff --git a/esua-epdc/docker-compose/test/app/analysis/docker-compose.yml b/esua-epdc/docker-compose/test/app/analysis/docker-compose.yml index cc004bc44..0c008bf44 100644 --- a/esua-epdc/docker-compose/test/app/analysis/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/analysis/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-analysis-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-analysis-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-analysis-server:test container_name: epdc-analysis-server-01 ports: - 10003:10003 diff --git a/esua-epdc/docker-compose/test/app/api/docker-compose.yml b/esua-epdc/docker-compose/test/app/api/docker-compose.yml index 0d509209e..44278b637 100644 --- a/esua-epdc/docker-compose/test/app/api/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/api/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-api-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-api-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-api-server:test container_name: epdc-api-server-01 ports: - 10004:10004 diff --git a/esua-epdc/docker-compose/test/app/auth/docker-compose.yml b/esua-epdc/docker-compose/test/app/auth/docker-compose.yml index aac8787fa..e6da970e7 100644 --- a/esua-epdc/docker-compose/test/app/auth/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/auth/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-auth: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-auth:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-auth:test container_name: epdc-auth-server-01 ports: - 10002:10002 diff --git a/esua-epdc/docker-compose/test/app/custom/docker-compose.yml b/esua-epdc/docker-compose/test/app/custom/docker-compose.yml index 48ae797e1..48bbb8568 100644 --- a/esua-epdc/docker-compose/test/app/custom/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/custom/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-custom-server-01: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-custom-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-custom-server:test container_name: epdc-custom-server-01 ports: - 10005:10005 diff --git a/esua-epdc/docker-compose/test/app/events/docker-compose.yml b/esua-epdc/docker-compose/test/app/events/docker-compose.yml index b12646d79..4cb66504b 100644 --- a/esua-epdc/docker-compose/test/app/events/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/events/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-events-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-events-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-events-server:test container_name: epdc-events-server-01 ports: - 10006:10006 diff --git a/esua-epdc/docker-compose/test/app/gateway/docker-compose.yml b/esua-epdc/docker-compose/test/app/gateway/docker-compose.yml index ecae7f10c..79f0ef09b 100644 --- a/esua-epdc/docker-compose/test/app/gateway/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/gateway/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-gateway: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-gateway:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-gateway:test container_name: epdc-gateway-server-01 ports: - 10000:10000 diff --git a/esua-epdc/docker-compose/test/app/group/docker-compose.yml b/esua-epdc/docker-compose/test/app/group/docker-compose.yml index 348885883..6ada55ddd 100644 --- a/esua-epdc/docker-compose/test/app/group/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/group/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-group-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-group-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-group-server:test container_name: epdc-group-server-01 ports: - 10007:10007 diff --git a/esua-epdc/docker-compose/test/app/heart/docker-compose.yml b/esua-epdc/docker-compose/test/app/heart/docker-compose.yml index 8c73b0efc..0cbb13580 100644 --- a/esua-epdc/docker-compose/test/app/heart/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/heart/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-heart-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-heart-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-heart-server:test container_name: epdc-heart-server-01 ports: - 10008:10008 diff --git a/esua-epdc/docker-compose/test/app/kpi/docker-compose.yml b/esua-epdc/docker-compose/test/app/kpi/docker-compose.yml index 0eb745bf3..7b623b685 100644 --- a/esua-epdc/docker-compose/test/app/kpi/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/kpi/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-kpi-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-kpi-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-kpi-server:test container_name: epdc-kpi-server-01 ports: - 10009:10009 diff --git a/esua-epdc/docker-compose/test/app/message/docker-compose.yml b/esua-epdc/docker-compose/test/app/message/docker-compose.yml index 7bf8759d0..cfaace090 100644 --- a/esua-epdc/docker-compose/test/app/message/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/message/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-message-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-message-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-message-server:test container_name: epdc-message-server-01 ports: - 10010:10010 diff --git a/esua-epdc/docker-compose/test/app/news/docker-compose.yml b/esua-epdc/docker-compose/test/app/news/docker-compose.yml index cf120910a..405f47ef4 100644 --- a/esua-epdc/docker-compose/test/app/news/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/news/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-news-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-news-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-news-server:test container_name: epdc-news-server-01 ports: - 10011:10011 diff --git a/esua-epdc/docker-compose/test/app/oss/docker-compose.yml b/esua-epdc/docker-compose/test/app/oss/docker-compose.yml index d677638c4..3940cbce8 100644 --- a/esua-epdc/docker-compose/test/app/oss/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/oss/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-oss-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-oss-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-oss-server:test container_name: epdc-oss-server-01 ports: - 10012:10012 diff --git a/esua-epdc/docker-compose/test/app/user/docker-compose.yml b/esua-epdc/docker-compose/test/app/user/docker-compose.yml index 8ad2e482b..f3209f6a6 100644 --- a/esua-epdc/docker-compose/test/app/user/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/user/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-user-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-user-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-user-server:test container_name: epdc-user-server-01 ports: - 10014:10014 diff --git a/esua-epdc/docker-compose/test/app/webservice/docker-compose.yml b/esua-epdc/docker-compose/test/app/webservice/docker-compose.yml index 77397cdea..6eb85b0ac 100644 --- a/esua-epdc/docker-compose/test/app/webservice/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/webservice/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-websocket-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-webservice:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-webservice:test container_name: epdc-webservice-01 ports: - 10015:10015 diff --git a/esua-epdc/docker-compose/test/app/websocket/docker-compose.yml b/esua-epdc/docker-compose/test/app/websocket/docker-compose.yml index b78cd6043..3fb41729c 100644 --- a/esua-epdc/docker-compose/test/app/websocket/docker-compose.yml +++ b/esua-epdc/docker-compose/test/app/websocket/docker-compose.yml @@ -1,7 +1,7 @@ version: '3.7' services: epdc-websocket-server: - image: registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-websocket-server:test + image: registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/epdc-websocket-server:test container_name: epdc-websocket-server-01 ports: - 10016:10016 diff --git a/esua-epdc/dockerfile/Dockerfile b/esua-epdc/dockerfile/Dockerfile new file mode 100755 index 000000000..9e1c30f4f --- /dev/null +++ b/esua-epdc/dockerfile/Dockerfile @@ -0,0 +1,20 @@ +# 基础镜像 +FROM openjdk:8u242-jdk-buster +# 作者 +MAINTAINER rongchao@elink-cn.com +# 对应pom.xml文件中的dockerfile-maven-plugin插件JAR_FILE的值 +ARG JAR_FILE +# 对应pom.xml文件中的dockerfile-maven-plugin插件JAR_NAME的值 +ARG JAR_NAME +# 对应pom.xml文件中的dockerfile-maven-plugin插件SERVER_PORT的值 +ARG SERVER_PORT +# 复制打包完成后的jar文件到/opt目录下 +ENV JAR_PATH /mnt/epdc/${JAR_NAME}.jar +ADD ${JAR_FILE} $JAR_PATH +# /data设为环境变量 +ENV DATAPATH /data +# 挂载/data目录到主机 +VOLUME $DATAPATH +# 启动容器时执行 +ENTRYPOINT java -jar -Xmx1024m $JAR_PATH +EXPOSE ${SERVER_PORT} diff --git a/esua-epdc/epdc-admin/epdc-admin-server/pom.xml b/esua-epdc/epdc-admin/epdc-admin-server/pom.xml index cac6d48fb..25640901b 100644 --- a/esua-epdc/epdc-admin/epdc-admin-server/pom.xml +++ b/esua-epdc/epdc-admin/epdc-admin-server/pom.xml @@ -137,6 +137,7 @@ 9092 dev + dev false diff --git a/esua-epdc/epdc-auth/pom.xml b/esua-epdc/epdc-auth/pom.xml index abf19149b..d5a7a67d3 100644 --- a/esua-epdc/epdc-auth/pom.xml +++ b/esua-epdc/epdc-auth/pom.xml @@ -106,6 +106,7 @@ 9091 dev + dev 2 diff --git a/esua-epdc/epdc-commons/epdc-commons-tools/src/main/java/com/elink/esua/epdc/commons/tools/utils/DateUtils.java b/esua-epdc/epdc-commons/epdc-commons-tools/src/main/java/com/elink/esua/epdc/commons/tools/utils/DateUtils.java index 0de5d2834..bff6daf43 100644 --- a/esua-epdc/epdc-commons/epdc-commons-tools/src/main/java/com/elink/esua/epdc/commons/tools/utils/DateUtils.java +++ b/esua-epdc/epdc-commons/epdc-commons-tools/src/main/java/com/elink/esua/epdc/commons/tools/utils/DateUtils.java @@ -14,9 +14,11 @@ import org.joda.time.LocalDate; import org.joda.time.format.DateTimeFormat; import org.joda.time.format.DateTimeFormatter; +import java.text.DateFormat; import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Date; +import java.util.Locale; /** * 日期处理工具类 @@ -185,4 +187,28 @@ public class DateUtils { DateTime dateTime = new DateTime(date); return dateTime.plusYears(years).toDate(); } + + /*** + * 前端上传信息解析 + * @param oldDate + * @return java.lang.String + * @author qushutong + * @date 2020/3/26 10:09 + */ + public static String dealDateFormat(String oldDate) { + Date date1 = null; + DateFormat df2 = null; + try { + oldDate= oldDate.replace("Z", " UTC"); + DateFormat df = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS Z"); + Date date = df.parse(oldDate); + SimpleDateFormat df1 = new SimpleDateFormat ("EEE MMM dd HH:mm:ss Z yyyy", Locale.UK); + date1 = df1.parse(date.toString()); + df2 = new SimpleDateFormat("yyyy-MM-dd"); + } catch (ParseException e) { + e.printStackTrace(); + } + return df2.format(date1); + } + } diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserGridOpiningDTO.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserGridOpiningDTO.java new file mode 100644 index 000000000..c3b3d3769 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserGridOpiningDTO.java @@ -0,0 +1,146 @@ +/** + * 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.elink.esua.epdc.dto.user; + +import java.io.Serializable; +import java.util.Date; +import lombok.Data; + + +/** + * 网格开通情况 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-25 + */ +@Data +public class MetaUserGridOpiningDTO implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 主键 + */ + private String id; + + /** + * 网格id + */ + private String gridId; + + /** + * 用户总数 + */ + private int registerCount; + + /** + * 党员数 + */ + private int partyCount; + + /** + * 已注册居民 + */ + private int residentCount; + + /** + * 未注册居民 + */ + private int unAuthorizedCount; + + /** + * 新闻发布数 + */ + private int newsCount; + + /** + * 社群数 + */ + private int communityCount; + + /** + * 群成员数 + */ + private int communityMemberCount; + + /** + * 群话题数 + */ + private int communityTopicCount; + + /** + * 议题总数 + */ + private int eventCount; + + /** + * 项目数 + */ + private int itemCount; + + /** + * 项目已解决数 + */ + private int itemCloseCount; + + /** + * 好评数 + */ + private int itemPraiseCount; + + /** + * 网格名称 + */ + private String allDeptName; + + /** + * 网格党建指导员姓名 + */ + private String gridLeader; + + /** + * 删除标记 + */ + private String 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/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserPartyRankDTO.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserPartyRankDTO.java new file mode 100644 index 000000000..be8c514e5 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserPartyRankDTO.java @@ -0,0 +1,127 @@ +/** + * 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.elink.esua.epdc.dto.user; + +import java.io.Serializable; +import java.util.Date; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * 党员排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Data +public class MetaUserPartyRankDTO implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 主键 + */ + private String id; + + /** + * 街道id + */ + private String streetId; + + /** + * 街道名称 + */ + private String streetName; + + /** + * 已注册党员数量(已认证) + */ + private Integer partyMemberCount; + + /** + * 年龄超过50岁党员数量 + */ + private Integer oldCount; + + /** + * 老龄化比例 + */ + private BigDecimal oldPercent; + + /** + * 年龄50岁以下的党员数量 + */ + private Integer youngCount; + + /** + * 年轻化比例 + */ + private BigDecimal youngPercent; + + /** + * 男 + */ + private Integer maleCount; + + /** + * 女 + */ + private Integer femaleCount; + + /** + * 未知性别 + */ + private Integer unknownSexCount; + + /** + * 党员认证失败数 + */ + private Integer partyAuthFailureCount; + + /** + * 删除标记 + */ + private String 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/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserRegisterRankDTO.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserRegisterRankDTO.java new file mode 100644 index 000000000..52f3b7107 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-client/src/main/java/com/elink/esua/epdc/dto/user/MetaUserRegisterRankDTO.java @@ -0,0 +1,137 @@ +/** + * 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.elink.esua.epdc.dto.user; + +import java.io.Serializable; +import java.util.Date; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * 用户注册排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Data +public class MetaUserRegisterRankDTO implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 主键 + */ + private String id; + + /** + * 街道id + */ + private String streetId; + + /** + * 街道名称 + */ + private String streetName; + + /** + * 用户总数 + */ + private Integer userCount; + + /** + * 党员数 + */ + private Integer partyMemberCount; + + /** + * 已注册居民 + */ + private Integer residentCount; + + /** + * 为注册居民 + */ + private Integer unAuthorizedCount; + + /** + * 年龄超过50岁 + */ + private Integer oldCount; + + /** + * 老龄化比例 + */ + private BigDecimal oldPercent; + + /** + * 50岁以下用户数量 + */ + private Integer youngCount; + + /** + * 年轻化比例 + */ + private BigDecimal youngPercent; + + /** + * 男 + */ + private Integer maleCount; + + /** + * 女 + */ + private Integer femaleCount; + + /** + * 未知性别 + */ + private Integer unknownSexCount; + + /** + * 删除标记 + */ + private String 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/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/datasources/DataSourceNames.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/datasources/DataSourceNames.java index e75611937..55b1b3a2e 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/datasources/DataSourceNames.java +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/datasources/DataSourceNames.java @@ -19,4 +19,5 @@ public interface DataSourceNames { String NINTH = "ninth"; String TENTH = "tenth"; String ELEVENTH = "eleventh"; + String TWELVE = "twelve"; } diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/datasources/DynamicDataSourceConfig.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/datasources/DynamicDataSourceConfig.java index 9f078d3a1..bf0541ddd 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/datasources/DynamicDataSourceConfig.java +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/datasources/DynamicDataSourceConfig.java @@ -86,6 +86,12 @@ public class DynamicDataSourceConfig { return DruidDataSourceBuilder.create().build(); } + @Bean + @ConfigurationProperties("spring.datasource.druid.twelve") + public DataSource twelvethDataSource() { + return DruidDataSourceBuilder.create().build(); + } + @Bean @Primary public DynamicDataSource dataSource(DataSource firstDataSource, DataSource secondDataSource, @@ -93,7 +99,7 @@ public class DynamicDataSourceConfig { DataSource fifthDataSource, DataSource sixthDataSource, DataSource seventhDataSource, DataSource eighthDataSource, DataSource ninthDataSource, DataSource tenthDataSource, - DataSource eleventhDataSource) { + DataSource eleventhDataSource,DataSource twelvethDataSource) { Map targetDataSources = new HashMap<>(); targetDataSources.put(DataSourceNames.FIRST, firstDataSource); targetDataSources.put(DataSourceNames.SECOND, secondDataSource); @@ -106,6 +112,7 @@ public class DynamicDataSourceConfig { targetDataSources.put(DataSourceNames.NINTH, ninthDataSource); targetDataSources.put(DataSourceNames.TENTH, tenthDataSource); targetDataSources.put(DataSourceNames.ELEVENTH, eleventhDataSource); + targetDataSources.put(DataSourceNames.TWELVE, twelvethDataSource); return new DynamicDataSource(firstDataSource, targetDataSources); } } diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserGridOpiningController.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserGridOpiningController.java new file mode 100644 index 000000000..0f5b1fc1f --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserGridOpiningController.java @@ -0,0 +1,104 @@ +/** + * 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.elink.esua.epdc.modules.user.controller; + +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.utils.ExcelUtils; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.commons.tools.validator.AssertUtils; +import com.elink.esua.epdc.commons.tools.validator.ValidatorUtils; +import com.elink.esua.epdc.commons.tools.validator.group.AddGroup; +import com.elink.esua.epdc.commons.tools.validator.group.UpdateGroup; +import com.elink.esua.epdc.commons.tools.validator.group.DefaultGroup; +import com.elink.esua.epdc.dto.user.MetaUserGridOpiningDTO; +import com.elink.esua.epdc.dto.user.result.GridOpeningResultDTO; +import com.elink.esua.epdc.modules.user.excel.MetaUserGridOpiningExcel; +import com.elink.esua.epdc.modules.user.service.MetaUserGridOpiningService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import javax.servlet.http.HttpServletResponse; +import java.util.List; +import java.util.Map; + + +/** + * 网格开通情况 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-25 + */ +@RestController +@RequestMapping("metausergridopining") +public class MetaUserGridOpiningController { + + @Autowired + private MetaUserGridOpiningService metaUserGridOpiningService; + + @GetMapping("page") + public Result> page(@RequestParam Map params){ + PageData page = metaUserGridOpiningService.page(params); + return new Result>().ok(page); + } + + @GetMapping("{id}") + public Result get(@PathVariable("id") String id){ + MetaUserGridOpiningDTO data = metaUserGridOpiningService.get(id); + return new Result().ok(data); + } + + @PostMapping + public Result save(@RequestBody MetaUserGridOpiningDTO dto){ + //效验数据 + ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); + metaUserGridOpiningService.save(dto); + return new Result(); + } + + @PutMapping + public Result update(@RequestBody MetaUserGridOpiningDTO dto){ + //效验数据 + ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); + metaUserGridOpiningService.update(dto); + return new Result(); + } + + @DeleteMapping + public Result delete(@RequestBody String[] ids){ + //效验数据 + AssertUtils.isArrayEmpty(ids, "id"); + metaUserGridOpiningService.delete(ids); + return new Result(); + } + + @GetMapping("export") + public void export(@RequestParam Map params, HttpServletResponse response) throws Exception { + List list = metaUserGridOpiningService.list(params); + ExcelUtils.exportExcelToTarget(response, null, list, MetaUserGridOpiningExcel.class); + } + + /** + * @author: qushutong + * @Date: 2020/3/25 10:35 + * @Description: 临时表导入 + */ + @GetMapping("tolead") + public Result> tolead() { + return metaUserGridOpiningService.createUserAnalysisData(); + } +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserPartyRankController.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserPartyRankController.java new file mode 100644 index 000000000..b4d678432 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserPartyRankController.java @@ -0,0 +1,107 @@ +/** + * 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.elink.esua.epdc.modules.user.controller; + +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.utils.ExcelUtils; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.commons.tools.validator.AssertUtils; +import com.elink.esua.epdc.commons.tools.validator.ValidatorUtils; +import com.elink.esua.epdc.commons.tools.validator.group.AddGroup; +import com.elink.esua.epdc.commons.tools.validator.group.UpdateGroup; +import com.elink.esua.epdc.commons.tools.validator.group.DefaultGroup; +import com.elink.esua.epdc.dto.user.MetaUserPartyRankDTO; +import com.elink.esua.epdc.modules.user.excel.MetaUserPartyRankExcel; +import com.elink.esua.epdc.modules.user.service.MetaUserPartyRankService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import javax.servlet.http.HttpServletResponse; +import java.util.List; +import java.util.Map; + + +/** + * 党员排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@RestController +@RequestMapping("metauserpartyrank") +public class MetaUserPartyRankController { + + @Autowired + private MetaUserPartyRankService metaUserPartyRankService; + + @GetMapping("page") + public Result> page(@RequestParam Map params){ + PageData page = metaUserPartyRankService.page(params); + return new Result>().ok(page); + } + + @GetMapping("{id}") + public Result get(@PathVariable("id") String id){ + MetaUserPartyRankDTO data = metaUserPartyRankService.get(id); + return new Result().ok(data); + } + + @PostMapping + public Result save(@RequestBody MetaUserPartyRankDTO dto){ + //效验数据 + ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); + metaUserPartyRankService.save(dto); + return new Result(); + } + + @PutMapping + public Result update(@RequestBody MetaUserPartyRankDTO dto){ + //效验数据 + ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); + metaUserPartyRankService.update(dto); + return new Result(); + } + + @DeleteMapping + public Result delete(@RequestBody String[] ids){ + //效验数据 + AssertUtils.isArrayEmpty(ids, "id"); + metaUserPartyRankService.delete(ids); + return new Result(); + } + + @GetMapping("export") + public void export(@RequestParam Map params, HttpServletResponse response) throws Exception { + List list = metaUserPartyRankService.list(params); + ExcelUtils.exportExcelToTarget(response, null, list, MetaUserPartyRankExcel.class); + } + + /*** + * 定时任务导入 + * @param + * @return com.elink.esua.epdc.commons.tools.utils.Result + * @author qushutong + * @date 2020/3/26 18:22 + */ + @GetMapping("toLeadPartyRankData") + public Result toLeadPartyRankData(){ + + return metaUserPartyRankService.toLeadPartyRankData(); + } + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserRegisterRankController.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserRegisterRankController.java new file mode 100644 index 000000000..e3f049e58 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/MetaUserRegisterRankController.java @@ -0,0 +1,104 @@ +/** + * 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.elink.esua.epdc.modules.user.controller; + +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.utils.ExcelUtils; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.commons.tools.validator.AssertUtils; +import com.elink.esua.epdc.commons.tools.validator.ValidatorUtils; +import com.elink.esua.epdc.commons.tools.validator.group.AddGroup; +import com.elink.esua.epdc.commons.tools.validator.group.UpdateGroup; +import com.elink.esua.epdc.commons.tools.validator.group.DefaultGroup; +import com.elink.esua.epdc.dto.user.MetaUserRegisterRankDTO; +import com.elink.esua.epdc.modules.user.excel.MetaUserRegisterRankExcel; +import com.elink.esua.epdc.modules.user.service.MetaUserRegisterRankService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import javax.servlet.http.HttpServletResponse; +import java.util.List; +import java.util.Map; + + +/** + * 用户注册排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@RestController +@RequestMapping("metauserregisterrank") +public class MetaUserRegisterRankController { + + @Autowired + private MetaUserRegisterRankService metaUserRegisterRankService; + + @GetMapping("page") + public Result> page(@RequestParam Map params){ + PageData page = metaUserRegisterRankService.page(params); + return new Result>().ok(page); + } + + @GetMapping("{id}") + public Result get(@PathVariable("id") String id){ + MetaUserRegisterRankDTO data = metaUserRegisterRankService.get(id); + return new Result().ok(data); + } + + @PostMapping + public Result save(@RequestBody MetaUserRegisterRankDTO dto){ + //效验数据 + ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); + metaUserRegisterRankService.save(dto); + return new Result(); + } + + @PutMapping + public Result update(@RequestBody MetaUserRegisterRankDTO dto){ + //效验数据 + ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); + metaUserRegisterRankService.update(dto); + return new Result(); + } + + @DeleteMapping + public Result delete(@RequestBody String[] ids){ + //效验数据 + AssertUtils.isArrayEmpty(ids, "id"); + metaUserRegisterRankService.delete(ids); + return new Result(); + } + + @GetMapping("export") + public void export(@RequestParam Map params, HttpServletResponse response) throws Exception { + List list = metaUserRegisterRankService.list(params); + ExcelUtils.exportExcelToTarget(response, null, list, MetaUserRegisterRankExcel.class); + } + /*** + * 定时任务用户注册排行导入数据 + * @param + * @return com.elink.esua.epdc.commons.tools.utils.Result + * @author qushutong + * @date 2020/3/26 13:44 + */ + @GetMapping("toLeadUserRegisterRandData") + public Result toLeadUserRegisterRandData(){ + return metaUserRegisterRankService.toLeadUserRegisterRandData(); + } +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/UserAnalysisController.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/UserAnalysisController.java index b8ef9ddb5..18e38eeaa 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/UserAnalysisController.java +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/controller/UserAnalysisController.java @@ -209,7 +209,7 @@ public class UserAnalysisController { * @date 2020/3/23 16:36 */ @PostMapping("export/exportOperationData") - public void exportOperationData(@RequestBody ExportOperationFormDTO exportOperationFormDTO, HttpServletResponse response) throws Exception{ + public void exportOperationData(@RequestBody ExportOperationFormDTO exportOperationFormDTO, HttpServletResponse response) throws Exception { List list = userAnalysisService.listExportOperationCount(exportOperationFormDTO); ExcelUtils.exportExcelToTarget(response, "开通网格情况", list, ExportOperationDataExcel.class); } diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserGridOpiningDao.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserGridOpiningDao.java new file mode 100644 index 000000000..ca5c69bca --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserGridOpiningDao.java @@ -0,0 +1,45 @@ +/** + * 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.elink.esua.epdc.modules.user.dao; + +import com.elink.esua.epdc.commons.mybatis.dao.BaseDao; +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.modules.user.entity.MetaUserGridOpiningEntity; +import org.apache.ibatis.annotations.Mapper; + +import java.util.List; +import java.util.Map; + +/** + * 网格开通情况 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-25 + */ +@Mapper +public interface MetaUserGridOpiningDao extends BaseDao { + + /*** + * 列表 + * @param params + * @return com.elink.esua.epdc.commons.tools.page.PageData + * @author qushutong + * @date 2020/3/25 17:30 + */ + List pageselectListPage(Map params); +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserPartyRankDao.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserPartyRankDao.java new file mode 100644 index 000000000..9bebf3d7a --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserPartyRankDao.java @@ -0,0 +1,46 @@ +/** + * 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.elink.esua.epdc.modules.user.dao; +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.elink.esua.epdc.commons.mybatis.dao.BaseDao; +import com.elink.esua.epdc.modules.user.entity.MetaUserPartyRankEntity; +import org.apache.ibatis.annotations.Mapper; + +import java.util.List; +import java.util.Map; + +/** + * 党员排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Mapper +public interface MetaUserPartyRankDao extends BaseDao { + + /*** + * 分页 + * @param params + * @return java.util.List + * @author qushutong + * @date 2020/3/26 18:36 + */ + List selectPagePartyRank(Map params); + + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserRegisterRankDao.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserRegisterRankDao.java new file mode 100644 index 000000000..86223fd00 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/dao/MetaUserRegisterRankDao.java @@ -0,0 +1,55 @@ +/** + * 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.elink.esua.epdc.modules.user.dao; + +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.elink.esua.epdc.commons.mybatis.dao.BaseDao; +import com.elink.esua.epdc.modules.user.entity.MetaUserRegisterRankEntity; +import org.apache.ibatis.annotations.Mapper; + +import java.util.List; +import java.util.Map; + +/** + * 用户注册排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Mapper +public interface MetaUserRegisterRankDao extends BaseDao { + + /*** + * 分页 + * @param params + * @return java.util.List + * @author qushutong + * @date 2020/3/26 15:41 + */ + List selectPageUserRegisterRank(Map params); + + + /*** + * 获取当前用户拥有权限的街道id + * @param params + * @return java.util.List + * @author qushutong + * @date 2020/3/26 16:54 + */ + List selectListStreetId(Map params); +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserGridOpiningEntity.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserGridOpiningEntity.java new file mode 100644 index 000000000..cda46a4a2 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserGridOpiningEntity.java @@ -0,0 +1,116 @@ +/** + * 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.elink.esua.epdc.modules.user.entity; + +import com.baomidou.mybatisplus.annotation.TableName; + +import com.elink.esua.epdc.commons.mybatis.entity.BaseEpdcEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.util.Date; + +/** + * 网格开通情况 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-25 + */ +@Data +@EqualsAndHashCode(callSuper=false) +@TableName("meta_epdc_user_grid_opining") +public class MetaUserGridOpiningEntity extends BaseEpdcEntity { + + private static final long serialVersionUID = 1L; + + /** + * 网格id + */ + private String gridId; + + /** + * 用户总数 + */ + private int registerCount; + + /** + * 党员数 + */ + private int partyCount; + + /** + * 已注册居民 + */ + private int residentCount; + + /** + * 未注册居民 + */ + private int unAuthorizedCount; + + /** + * 新闻发布数 + */ + private int newsCount; + + /** + * 社群数 + */ + private int communityCount; + + /** + * 群成员数 + */ + private int communityMemberCount; + + /** + * 群话题数 + */ + private int communityTopicCount; + + /** + * 议题总数 + */ + private int eventCount; + + /** + * 项目数 + */ + private int itemCount; + + /** + * 项目已解决数 + */ + private int itemCloseCount; + + /** + * 好评数 + */ + private int itemPraiseCount; + + /** + * 网格名称 + */ + private String allDeptName; + + /** + * 网格党建指导员姓名 + */ + private String gridLeader; + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserPartyRankEntity.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserPartyRankEntity.java new file mode 100644 index 000000000..eec5ce88e --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserPartyRankEntity.java @@ -0,0 +1,97 @@ +/** + * 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.elink.esua.epdc.modules.user.entity; + +import com.baomidou.mybatisplus.annotation.TableName; + +import com.elink.esua.epdc.commons.mybatis.entity.BaseEpdcEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.math.BigDecimal; +import java.util.Date; + +/** + * 党员排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Data +@EqualsAndHashCode(callSuper=false) +@TableName("meta_epdc_user_party_rank") +public class MetaUserPartyRankEntity extends BaseEpdcEntity { + + private static final long serialVersionUID = 1L; + + /** + * 街道id + */ + private String streetId; + + /** + * 街道名称 + */ + private String streetName; + + /** + * 已注册党员数量(已认证) + */ + private Integer partyMemberCount; + + /** + * 年龄超过50岁党员数量 + */ + private Integer oldCount; + + /** + * 老龄化比例 + */ + private BigDecimal oldPercent; + + /** + * 年龄50岁以下的党员数量 + */ + private Integer youngCount; + + /** + * 年轻化比例 + */ + private BigDecimal youngPercent; + + /** + * 男 + */ + private Integer maleCount; + + /** + * 女 + */ + private Integer femaleCount; + + /** + * 未知性别 + */ + private Integer unknownSexCount; + + /** + * 党员认证失败数 + */ + private Integer partyAuthFailureCount; + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserRegisterRankEntity.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserRegisterRankEntity.java new file mode 100644 index 000000000..08f60b8be --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/entity/MetaUserRegisterRankEntity.java @@ -0,0 +1,107 @@ +/** + * 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.elink.esua.epdc.modules.user.entity; + +import com.baomidou.mybatisplus.annotation.TableName; + +import com.elink.esua.epdc.commons.mybatis.entity.BaseEpdcEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.math.BigDecimal; +import java.util.Date; + +/** + * 用户注册排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Data +@EqualsAndHashCode(callSuper=false) +@TableName("meta_epdc_user_register_rank") +public class MetaUserRegisterRankEntity extends BaseEpdcEntity { + + private static final long serialVersionUID = 1L; + + /** + * 街道id + */ + private String streetId; + + /** + * 街道名称 + */ + private String streetName; + + /** + * 用户总数 + */ + private Integer userCount; + + /** + * 党员数 + */ + private Integer partyMemberCount; + + /** + * 已注册居民 + */ + private Integer residentCount; + + /** + * 为注册居民 + */ + private Integer unAuthorizedCount; + + /** + * 年龄超过50岁 + */ + private Integer oldCount; + + /** + * 老龄化比例 + */ + private BigDecimal oldPercent; + + /** + * 50岁以下用户数量 + */ + private Integer youngCount; + + /** + * 年轻化比例 + */ + private BigDecimal youngPercent; + + /** + * 男 + */ + private Integer maleCount; + + /** + * 女 + */ + private Integer femaleCount; + + /** + * 未知性别 + */ + private Integer unknownSexCount; + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserGridOpiningExcel.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserGridOpiningExcel.java new file mode 100644 index 000000000..104301f23 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserGridOpiningExcel.java @@ -0,0 +1,80 @@ +/** + * 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.elink.esua.epdc.modules.user.excel; + +import cn.afterturn.easypoi.excel.annotation.Excel; +import lombok.Data; + +import java.util.Date; + +/** + * 网格开通情况 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-25 + */ +@Data +public class MetaUserGridOpiningExcel { + + @Excel(name = "网格名称") + private String allDeptNames; + + @Excel(name = "网格党建指导员姓名") + private String gridLeader; + + @Excel(name = "用户总数") + private int registerCount; + + @Excel(name = "党员数") + private int partyCount; + + @Excel(name = "已注册居民") + private int residentCount; + + @Excel(name = "未注册居民") + private int unAuthorizedCount; + + @Excel(name = "新闻发布数") + private String newsCount; + + @Excel(name = "社群数") + private int communityCount; + + @Excel(name = "群成员数") + private int communityMemberCount; + + @Excel(name = "群话题数") + private int communityTopicCount; + + @Excel(name = "议题总数") + private int eventCount; + + @Excel(name = "项目数") + private int itemCount; + + @Excel(name = "项目已解决数") + private int itemCloseCount; + + @Excel(name = "好评数") + private int itemPraiseCount; + + @Excel(name = "更新时间", format = "yyyy-MM-dd HH:mm:ss") + private Date updatedTime; + + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserPartyRankExcel.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserPartyRankExcel.java new file mode 100644 index 000000000..7700c7b3a --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserPartyRankExcel.java @@ -0,0 +1,70 @@ +/** + * 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.elink.esua.epdc.modules.user.excel; + +import cn.afterturn.easypoi.excel.annotation.Excel; +import lombok.Data; + +import java.math.BigDecimal; +import java.util.Date; + +/** + * 党员排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Data +public class MetaUserPartyRankExcel { + + + @Excel(name = "街道名称") + private String streetName; + + @Excel(name = "已注册党员数量(已认证)") + private Integer partyMemberCount; + + @Excel(name = "年龄超过50岁党员数量") + private Integer oldCount; + + @Excel(name = "老龄化比例") + private BigDecimal oldPercent; + + @Excel(name = "年龄50岁以下的党员数量") + private Integer youngCount; + + @Excel(name = "年轻化比例") + private BigDecimal youngPercent; + + @Excel(name = "男") + private Integer maleCount; + + @Excel(name = "女") + private Integer femaleCount; + + @Excel(name = "未知性别") + private Integer unknownSexCount; + + @Excel(name = "党员认证失败数") + private Integer partyAuthFailureCount; + + @Excel(name = "更新时间", format = "yyyy-MM-dd HH:mm:ss") + private Date updatedTime; + + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserRegisterRankExcel.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserRegisterRankExcel.java new file mode 100644 index 000000000..7fd0c6793 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/excel/MetaUserRegisterRankExcel.java @@ -0,0 +1,76 @@ +/** + * 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.elink.esua.epdc.modules.user.excel; + +import cn.afterturn.easypoi.excel.annotation.Excel; +import lombok.Data; + +import java.math.BigDecimal; +import java.util.Date; + +/** + * 用户注册排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Data +public class MetaUserRegisterRankExcel { + + + @Excel(name = "街道名称") + private String streetName; + + @Excel(name = "用户总数") + private Integer userCount; + + @Excel(name = "党员数") + private Integer partyMemberCount; + + @Excel(name = "已注册居民") + private Integer residentCount; + + @Excel(name = "为注册居民") + private Integer unAuthorizedCount; + + @Excel(name = "年龄超过50岁") + private Integer oldCount; + + @Excel(name = "老龄化比例") + private BigDecimal oldPercent; + + @Excel(name = "50岁以下用户数量") + private Integer youngCount; + + @Excel(name = "年轻化比例") + private BigDecimal youngPercent; + + @Excel(name = "男") + private Integer maleCount; + + @Excel(name = "女") + private Integer femaleCount; + + @Excel(name = "未知性别") + private Integer unknownSexCount; + + @Excel(name = "更新时间", format = "yyyy-MM-dd HH:mm:ss") + private Date updatedTime; + + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserGridOpiningService.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserGridOpiningService.java new file mode 100644 index 000000000..c28bfabce --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserGridOpiningService.java @@ -0,0 +1,107 @@ +/** + * 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.elink.esua.epdc.modules.user.service; + +import com.elink.esua.epdc.commons.mybatis.service.BaseService; +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.dto.user.MetaUserGridOpiningDTO; +import com.elink.esua.epdc.modules.user.entity.MetaUserGridOpiningEntity; + +import java.util.List; +import java.util.Map; + +/** + * 网格开通情况 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-25 + */ +public interface MetaUserGridOpiningService extends BaseService { + + /** + * 默认分页 + * + * @param params + * @return PageData + * @author generator + * @date 2020-03-25 + */ + PageData page(Map params); + + /** + * 默认查询 + * + * @param params + * @return java.util.List + * @author generator + * @date 2020-03-25 + */ + List list(Map params); + + /** + * 单条查询 + * + * @param id + * @return MetaUserGridOpiningDTO + * @author generator + * @date 2020-03-25 + */ + MetaUserGridOpiningDTO get(String id); + + /** + * 默认保存 + * + * @param dto + * @return void + * @author generator + * @date 2020-03-25 + */ + void save(MetaUserGridOpiningDTO dto); + + /** + * 默认更新 + * + * @param dto + * @return void + * @author generator + * @date 2020-03-25 + */ + void update(MetaUserGridOpiningDTO dto); + + /** + * 批量删除 + * + * @param ids + * @return void + * @author generator + * @date 2020-03-25 + */ + void delete(String[] ids); + + + + /*** + * 网格开通数据生成临时表导入 + * @param + * @return com.elink.esua.epdc.commons.tools.utils.Result + * @author qushutong + * @date 2020/3/25 10:42 + */ + Result createUserAnalysisData(); +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserPartyRankService.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserPartyRankService.java new file mode 100644 index 000000000..b98990bbb --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserPartyRankService.java @@ -0,0 +1,105 @@ +/** + * 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.elink.esua.epdc.modules.user.service; + +import com.elink.esua.epdc.commons.mybatis.service.BaseService; +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.dto.user.MetaUserPartyRankDTO; +import com.elink.esua.epdc.modules.user.entity.MetaUserPartyRankEntity; + +import java.util.List; +import java.util.Map; + +/** + * 党员排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +public interface MetaUserPartyRankService extends BaseService { + + /** + * 默认分页 + * + * @param params + * @return PageData + * @author generator + * @date 2020-03-26 + */ + PageData page(Map params); + + /** + * 默认查询 + * + * @param params + * @return java.util.List + * @author generator + * @date 2020-03-26 + */ + List list(Map params); + + /** + * 单条查询 + * + * @param id + * @return MetaUserPartyRankDTO + * @author generator + * @date 2020-03-26 + */ + MetaUserPartyRankDTO get(String id); + + /** + * 默认保存 + * + * @param dto + * @return void + * @author generator + * @date 2020-03-26 + */ + void save(MetaUserPartyRankDTO dto); + + /** + * 默认更新 + * + * @param dto + * @return void + * @author generator + * @date 2020-03-26 + */ + void update(MetaUserPartyRankDTO dto); + + /** + * 批量删除 + * + * @param ids + * @return void + * @author generator + * @date 2020-03-26 + */ + void delete(String[] ids); + + /*** + * 定时任务导入党员排行 + * @param + * @return com.elink.esua.epdc.commons.tools.utils.Result + * @author qushutong + * @date 2020/3/26 18:23 + */ + Result toLeadPartyRankData(); +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserRegisterRankService.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserRegisterRankService.java new file mode 100644 index 000000000..82adfb5f2 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/MetaUserRegisterRankService.java @@ -0,0 +1,105 @@ +/** + * 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.elink.esua.epdc.modules.user.service; + +import com.elink.esua.epdc.commons.mybatis.service.BaseService; +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.dto.user.MetaUserRegisterRankDTO; +import com.elink.esua.epdc.modules.user.entity.MetaUserRegisterRankEntity; + +import java.util.List; +import java.util.Map; + +/** + * 用户注册排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +public interface MetaUserRegisterRankService extends BaseService { + + /** + * 默认分页 + * + * @param params + * @return PageData + * @author generator + * @date 2020-03-26 + */ + PageData page(Map params); + + /** + * 默认查询 + * + * @param params + * @return java.util.List + * @author generator + * @date 2020-03-26 + */ + List list(Map params); + + /** + * 单条查询 + * + * @param id + * @return MetaUserRegisterRankDTO + * @author generator + * @date 2020-03-26 + */ + MetaUserRegisterRankDTO get(String id); + + /** + * 默认保存 + * + * @param dto + * @return void + * @author generator + * @date 2020-03-26 + */ + void save(MetaUserRegisterRankDTO dto); + + /** + * 默认更新 + * + * @param dto + * @return void + * @author generator + * @date 2020-03-26 + */ + void update(MetaUserRegisterRankDTO dto); + + /** + * 批量删除 + * + * @param ids + * @return void + * @author generator + * @date 2020-03-26 + */ + void delete(String[] ids); + + /*** + * 导入用户注册 + * @param + * @return com.elink.esua.epdc.commons.tools.utils.Result + * @author qushutong + * @date 2020/3/26 13:26 + */ + Result toLeadUserRegisterRandData(); +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/UserAnalysisService.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/UserAnalysisService.java index f2759b2e8..9f97ce3a9 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/UserAnalysisService.java +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/UserAnalysisService.java @@ -88,7 +88,6 @@ public interface UserAnalysisService { GridDataTotalResultDTO selectGridDataTotal(Map params); - /*** * 运营数据导出用户相关 * @param exportOperationFormDTO @@ -97,4 +96,32 @@ public interface UserAnalysisService { * @date 2020/3/23 15:16 */ List listExportOperationCount(ExportOperationFormDTO exportOperationFormDTO); + + /*** + * 获取所有网格 + * @param params + * @return java.util.List + * @author qushutong + * @date 2020/3/25 17:22 + */ + List selectListGridHasMaCode(Map params); + + + /*** + * 获取导入数据 + * @param params + * @return java.util.List + * @author qushutong + * @date 2020/3/25 19:13 + */ + List getToLeadGridOpenings(Map params); + + /*** + * 获取导入用户排行数据 + * @param params + * @return java.util.List + * @author qushutong + * @date 2020/3/26 13:32 + */ + List getToLeadUserRegisterRandData(Map params); } diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserGridOpiningServiceImpl.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserGridOpiningServiceImpl.java new file mode 100644 index 000000000..a126d5d1e --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserGridOpiningServiceImpl.java @@ -0,0 +1,138 @@ +/** + * 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.elink.esua.epdc.modules.user.service.impl; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.extension.toolkit.SqlHelper; +import com.elink.esua.epdc.commons.mybatis.service.impl.BaseServiceImpl; +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.utils.ConvertUtils; +import com.elink.esua.epdc.commons.tools.constant.FieldConstant; +import com.elink.esua.epdc.commons.tools.utils.DateUtils; +import com.elink.esua.epdc.commons.tools.utils.LocalDateUtils; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.datasources.DataSourceNames; +import com.elink.esua.epdc.datasources.annotation.DataSource; +import com.elink.esua.epdc.dto.user.MetaUserGridOpiningDTO; +import com.elink.esua.epdc.dto.user.result.GridOpeningResultDTO; +import com.elink.esua.epdc.modules.user.dao.MetaUserGridOpiningDao; +import com.elink.esua.epdc.modules.user.entity.MetaUserGridOpiningEntity; +import com.elink.esua.epdc.modules.user.service.MetaUserGridOpiningService; +import com.elink.esua.epdc.modules.user.service.UserAnalysisService; +import org.apache.commons.lang3.StringUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +import java.text.ParseException; +import java.text.SimpleDateFormat; +import java.util.*; + +/** + * 网格开通情况 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-25 + */ +@Service +public class MetaUserGridOpiningServiceImpl extends BaseServiceImpl implements MetaUserGridOpiningService { + @Autowired + private UserAnalysisService userAnalysisService; + + @Override + @DataSource(name = DataSourceNames.TWELVE) + public PageData page(Map params) { + IPage page = getPage(params); + List metaUserGridOpiningEntityList = getMetaUserGridOpiningEntities(params); + return getPageData(metaUserGridOpiningEntityList,page.getTotal(), MetaUserGridOpiningDTO.class); + } + + private List getMetaUserGridOpiningEntities(Map params) { + // 获取所有网格 + List gridOpeningResultDTOS = userAnalysisService.selectListGridHasMaCode(params); + List deptIdList = new ArrayList<>(); + for(GridOpeningResultDTO item:gridOpeningResultDTOS){ + deptIdList.add(item.getGridId()); + } + SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd"); + params.put("deptIdList",deptIdList); + String time = (String) params.get("createdTime"); + if(StringUtils.isBlank(time)){ + String createdTime = format.format(new Date()); + params.put("createdTime",createdTime); + }else { + String createdTime = DateUtils.dealDateFormat(time); + params.put("createdTime",createdTime); + } + return baseDao.pageselectListPage(params); + } + + @Override + @DataSource(name = DataSourceNames.TWELVE) + public List list(Map params) { + List entityList = getMetaUserGridOpiningEntities(params); + + return ConvertUtils.sourceToTarget(entityList, MetaUserGridOpiningDTO.class); + } + + private QueryWrapper getWrapper(Map params){ + String id = (String)params.get(FieldConstant.ID_HUMP); + + QueryWrapper wrapper = new QueryWrapper<>(); + wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); + return wrapper; + } + + @Override + public MetaUserGridOpiningDTO get(String id) { + MetaUserGridOpiningEntity entity = baseDao.selectById(id); + return ConvertUtils.sourceToTarget(entity, MetaUserGridOpiningDTO.class); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void save(MetaUserGridOpiningDTO dto) { + MetaUserGridOpiningEntity entity = ConvertUtils.sourceToTarget(dto, MetaUserGridOpiningEntity.class); + insert(entity); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void update(MetaUserGridOpiningDTO dto) { + MetaUserGridOpiningEntity entity = ConvertUtils.sourceToTarget(dto, MetaUserGridOpiningEntity.class); + updateById(entity); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void delete(String[] ids) { + // 逻辑删除(@TableLogic 注解) + baseDao.deleteBatchIds(Arrays.asList(ids)); + } + + + @Override + @DataSource(name = DataSourceNames.TWELVE) + public Result createUserAnalysisData() { + List list = userAnalysisService.getToLeadGridOpenings(new HashMap<>()); + List metaUserGridOpiningEntities = ConvertUtils.sourceToTarget(list, MetaUserGridOpiningEntity.class); + boolean b = insertBatch(metaUserGridOpiningEntities); + return b?new Result<>():new Result().error("录入失败"); + } +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserPartyRankServiceImpl.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserPartyRankServiceImpl.java new file mode 100644 index 000000000..5da1eb35a --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserPartyRankServiceImpl.java @@ -0,0 +1,140 @@ +/** + * 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.elink.esua.epdc.modules.user.service.impl; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.elink.esua.epdc.commons.mybatis.service.impl.BaseServiceImpl; +import com.elink.esua.epdc.commons.tools.enums.YesOrNoEnum; +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.utils.ConvertUtils; +import com.elink.esua.epdc.commons.tools.constant.FieldConstant; +import com.elink.esua.epdc.commons.tools.utils.DateUtils; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.datasources.DataSourceNames; +import com.elink.esua.epdc.datasources.annotation.DataSource; +import com.elink.esua.epdc.dto.user.MetaUserPartyRankDTO; +import com.elink.esua.epdc.dto.user.result.UserDataRankResultDTO; +import com.elink.esua.epdc.modules.user.dao.MetaUserPartyRankDao; +import com.elink.esua.epdc.modules.user.entity.MetaUserPartyRankEntity; +import com.elink.esua.epdc.modules.user.service.MetaUserPartyRankService; +import com.elink.esua.epdc.modules.user.service.MetaUserRegisterRankService; +import com.elink.esua.epdc.modules.user.service.UserAnalysisService; +import org.apache.commons.lang3.StringUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +import java.text.SimpleDateFormat; +import java.util.*; + +/** + * 党员排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Service +public class MetaUserPartyRankServiceImpl extends BaseServiceImpl implements MetaUserPartyRankService { + + @Autowired + private UserAnalysisService userAnalysisService; + + @Autowired + private MetaUserRegisterRankServiceImpl metaUserRegisterRankService; + + @Override + @DataSource(name = DataSourceNames.TWELVE) + public PageData page(Map params) { + IPage page = getPage(params); + List metaUserRegisterRankEntities = getMetaUserPartyRankEntities(params); + return getPageData(metaUserRegisterRankEntities,page.getTotal(), MetaUserPartyRankDTO.class); + } + + private List getMetaUserPartyRankEntities(Map params) { + // 获取权限下的街道id + List streetIdList = metaUserRegisterRankService.getListStreetId(); + params.put("streetIdList",streetIdList); + SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd"); + String time = (String) params.get("createdTime"); + if(StringUtils.isBlank(time)){ + String createdTime = format.format(new Date()); + params.put("createdTime",createdTime); + }else { + String createdTime = DateUtils.dealDateFormat(time); + params.put("createdTime",createdTime); + } + return baseDao.selectPagePartyRank(params); + } + + @Override + @DataSource(name = DataSourceNames.TWELVE) + public List list(Map params) { + List entityList = getMetaUserPartyRankEntities(params); + + return ConvertUtils.sourceToTarget(entityList, MetaUserPartyRankDTO.class); + } + + private QueryWrapper getWrapper(Map params){ + String id = (String)params.get(FieldConstant.ID_HUMP); + + QueryWrapper wrapper = new QueryWrapper<>(); + wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); + + return wrapper; + } + + @Override + public MetaUserPartyRankDTO get(String id) { + MetaUserPartyRankEntity entity = baseDao.selectById(id); + return ConvertUtils.sourceToTarget(entity, MetaUserPartyRankDTO.class); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void save(MetaUserPartyRankDTO dto) { + MetaUserPartyRankEntity entity = ConvertUtils.sourceToTarget(dto, MetaUserPartyRankEntity.class); + insert(entity); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void update(MetaUserPartyRankDTO dto) { + MetaUserPartyRankEntity entity = ConvertUtils.sourceToTarget(dto, MetaUserPartyRankEntity.class); + updateById(entity); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void delete(String[] ids) { + // 逻辑删除(@TableLogic 注解) + baseDao.deleteBatchIds(Arrays.asList(ids)); + } + + @Override + @DataSource(name = DataSourceNames.TWELVE) + public Result toLeadPartyRankData() { + // 获取导出数据 + Map params = new HashMap<>(); + params.put("partyFlag", YesOrNoEnum.YES.value()); + List toLeadUserRegisterRandData = userAnalysisService.getToLeadUserRegisterRandData(params); + List metaUserPartyRankEntities = ConvertUtils.sourceToTarget(toLeadUserRegisterRandData, MetaUserPartyRankEntity.class); + return insertBatch(metaUserPartyRankEntities)? new Result(): new Result().error("导入党员排行失败") ; + } + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserRegisterRankServiceImpl.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserRegisterRankServiceImpl.java new file mode 100644 index 000000000..6d89b576e --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/MetaUserRegisterRankServiceImpl.java @@ -0,0 +1,147 @@ +/** + * 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.elink.esua.epdc.modules.user.service.impl; + +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.elink.esua.epdc.commons.mybatis.service.impl.BaseServiceImpl; +import com.elink.esua.epdc.commons.tools.page.PageData; +import com.elink.esua.epdc.commons.tools.security.user.SecurityUser; +import com.elink.esua.epdc.commons.tools.utils.ConvertUtils; +import com.elink.esua.epdc.commons.tools.constant.FieldConstant; +import com.elink.esua.epdc.commons.tools.utils.DateUtils; +import com.elink.esua.epdc.commons.tools.utils.Result; +import com.elink.esua.epdc.datasources.DataSourceNames; +import com.elink.esua.epdc.datasources.annotation.DataSource; +import com.elink.esua.epdc.dto.user.MetaUserRegisterRankDTO; +import com.elink.esua.epdc.dto.user.result.UserDataRankResultDTO; +import com.elink.esua.epdc.modules.user.dao.MetaUserRegisterRankDao; +import com.elink.esua.epdc.modules.user.entity.MetaUserRegisterRankEntity; +import com.elink.esua.epdc.modules.user.service.MetaUserRegisterRankService; +import com.elink.esua.epdc.modules.user.service.UserAnalysisService; +import org.apache.commons.lang3.StringUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +import java.text.SimpleDateFormat; +import java.util.*; + +/** + * 用户注册排行 + * + * @author qu elink@elink-cn.com + * @since v1.0.0 2020-03-26 + */ +@Service +public class MetaUserRegisterRankServiceImpl extends BaseServiceImpl implements MetaUserRegisterRankService { + + @Autowired + private UserAnalysisService userAnalysisService; + @Override + @DataSource(name = DataSourceNames.TWELVE) + public PageData page(Map params) { + IPage page = getPage(params); + List metaUserRegisterRankEntities = getMetaUserRegisterRankEntities(params); + return getPageData(metaUserRegisterRankEntities,page.getTotal(), MetaUserRegisterRankDTO.class); + } + + private List getMetaUserRegisterRankEntities(Map params) { + // 获取权限下的街道id + List streetIdList = getListStreetId(); + params.put("streetIdList",streetIdList); + SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd"); + String time = (String) params.get("createdTime"); + if(StringUtils.isBlank(time)){ + String createdTime = format.format(new Date()); + params.put("createdTime",createdTime); + }else { + String createdTime = DateUtils.dealDateFormat(time); + params.put("createdTime",createdTime); + } + return baseDao.selectPageUserRegisterRank(params); + } + + @Override + @DataSource(name = DataSourceNames.TWELVE) + public List list(Map params) { + List entityList = getMetaUserRegisterRankEntities(params); + + return ConvertUtils.sourceToTarget(entityList, MetaUserRegisterRankDTO.class); + } + + private QueryWrapper getWrapper(Map params){ + String id = (String)params.get(FieldConstant.ID_HUMP); + + QueryWrapper wrapper = new QueryWrapper<>(); + wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); + + return wrapper; + } + + @Override + public MetaUserRegisterRankDTO get(String id) { + MetaUserRegisterRankEntity entity = baseDao.selectById(id); + return ConvertUtils.sourceToTarget(entity, MetaUserRegisterRankDTO.class); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void save(MetaUserRegisterRankDTO dto) { + MetaUserRegisterRankEntity entity = ConvertUtils.sourceToTarget(dto, MetaUserRegisterRankEntity.class); + insert(entity); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void update(MetaUserRegisterRankDTO dto) { + MetaUserRegisterRankEntity entity = ConvertUtils.sourceToTarget(dto, MetaUserRegisterRankEntity.class); + updateById(entity); + } + + @Override + @Transactional(rollbackFor = Exception.class) + public void delete(String[] ids) { + // 逻辑删除(@TableLogic 注解) + baseDao.deleteBatchIds(Arrays.asList(ids)); + } + + @Override + @DataSource(name = DataSourceNames.TWELVE) + public Result toLeadUserRegisterRandData() { + // 获取导出数据 + List toLeadUserRegisterRandData = userAnalysisService.getToLeadUserRegisterRandData(new HashMap<>()); + // 导入数据 + List metaUserRegisterRankEntities = ConvertUtils.sourceToTarget(toLeadUserRegisterRandData, MetaUserRegisterRankEntity.class); + return insertBatch(metaUserRegisterRankEntities) ? new Result():new Result().error("导入注册用户排行失败"); + } + + /*** + * 获取当前用户拥有权限的街道id + * @param + * @return java.util.List + * @author qushutong + * @date 2020/3/26 16:57 + */ + public List getListStreetId() { + Map params = new HashMap(); + params.put("deptIdList", SecurityUser.getUser().getDeptIdList()); + return baseDao.selectListStreetId(params); + } + +} \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/UserAnalysisServiceImpl.java b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/UserAnalysisServiceImpl.java index 79b3bf943..274e26ca7 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/UserAnalysisServiceImpl.java +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/java/com/elink/esua/epdc/modules/user/service/impl/UserAnalysisServiceImpl.java @@ -53,7 +53,6 @@ public class UserAnalysisServiceImpl extends BaseServiceImpl listPageGridOpeningsForExport(Map params) { params.put("deptIdList", SecurityUser.getUser().getDeptIdList()); - List list = baseDao.selectListGridHasMaCode(params); list = fillFieldForGridOpening(list, params); @@ -141,6 +140,11 @@ public class UserAnalysisServiceImpl extends BaseServiceImpl page = getPage(params); + List list = getListUserDataRankResultDro(params); + return new PageData<>(list, page.getTotal()); + } + + private List getListUserDataRankResultDro(Map params) { List list = baseDao.selectListUserDataRank(params); if (CollUtil.isNotEmpty(list)) { @@ -175,7 +179,7 @@ public class UserAnalysisServiceImpl extends BaseServiceImpl(list, page.getTotal()); + return list; } @@ -284,7 +288,7 @@ public class UserAnalysisServiceImpl extends BaseServiceImpl listExportOperationCount(ExportOperationFormDTO exportOperationFormDTO) { List allStreetIds = new ArrayList<>(); - for(Long[] item : exportOperationFormDTO.getAllDeptIdsShow()){ + for (Long[] item : exportOperationFormDTO.getAllDeptIdsShow()) { allStreetIds.add(item[0]); } exportOperationFormDTO.setAllStreetIds(allStreetIds); @@ -308,11 +312,11 @@ public class UserAnalysisServiceImpl extends BaseServiceImpl enterpriseDataResultDTOS = baseDao.selectExportEnterpriseCount(exportOperationFormDTO); //居民数 - for(int i= 0;i selectListGridHasMaCode(Map params) { + params.put("deptIdList", SecurityUser.getUser().getDeptIdList()); + params.put("category", YesOrNoEnum.YES.value()); + return baseDao.selectListGridHasMaCode(params); + } + + @Override + public List getToLeadGridOpenings(Map params) { + params.put("category", YesOrNoEnum.YES.value()); + List list = baseDao.selectListGridHasMaCode(params); + list = fillFieldForGridOpening(list, params); + return list; + } + + @Override + public List getToLeadUserRegisterRandData(Map params) { + return getListUserDataRankResultDro(params); + } + + } diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-dev.yml b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-dev.yml index 5a5ab6e28..8c0fcdf01 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-dev.yml +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-dev.yml @@ -47,6 +47,10 @@ spring: url: jdbc:mysql://47.104.224.45:3308/esua_epdc_user?allowMultiQueries=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=Asia/Shanghai username: epdc password: elink833066 + twelve: #数据源12 + url: jdbc:mysql://47.104.224.45:3308/esua_epdc_analysis?allowMultiQueries=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=Asia/Shanghai + username: epdc + password: elink833066 initial-size: 10 max-active: 100 min-idle: 10 diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-prod.yml b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-prod.yml index f57e18dc1..516bc46e8 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-prod.yml +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-prod.yml @@ -46,6 +46,10 @@ spring: url: jdbc:mysql://172.16.0.52:3306/esua_epdc_user?allowMultiQueries=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=Asia/Shanghai username: epdc password: Elink@833066 + twelve: #数据源12 + url: jdbc:mysql://172.16.0.52:3306/esua_epdc_analysis?allowMultiQueries=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=Asia/Shanghai + username: epdc + password: Elink@833066 initial-size: 10 max-active: 100 min-idle: 10 diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-test.yml b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-test.yml index 5a5ab6e28..8c0fcdf01 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-test.yml +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/application-test.yml @@ -47,6 +47,10 @@ spring: url: jdbc:mysql://47.104.224.45:3308/esua_epdc_user?allowMultiQueries=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=Asia/Shanghai username: epdc password: elink833066 + twelve: #数据源12 + url: jdbc:mysql://47.104.224.45:3308/esua_epdc_analysis?allowMultiQueries=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=Asia/Shanghai + username: epdc + password: elink833066 initial-size: 10 max-active: 100 min-idle: 10 diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserGridOpiningDao.xml b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserGridOpiningDao.xml new file mode 100644 index 000000000..363aff585 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserGridOpiningDao.xml @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserPartyRankDao.xml b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserPartyRankDao.xml new file mode 100644 index 000000000..fb795db24 --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserPartyRankDao.xml @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserRegisterRankDao.xml b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserRegisterRankDao.xml new file mode 100644 index 000000000..592c90d7c --- /dev/null +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/MetaUserRegisterRankDao.xml @@ -0,0 +1,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/UserAnalysisDao.xml b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/UserAnalysisDao.xml index 76944bafb..3485a5d16 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/UserAnalysisDao.xml +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/UserAnalysisDao.xml @@ -44,6 +44,7 @@ AND uu.CREATED_TIME BETWEEN #{startTime} AND #{endTime} + AND ad2.id is NOT NULL AND ad.id IS NOT NULL ) t GROUP BY t.streetId ) t1 diff --git a/esua-epdc/epdc-module/epdc-api/epdc-api-client/pom.xml b/esua-epdc/epdc-module/epdc-api/epdc-api-client/pom.xml index fb4e2c8d7..2e5262f42 100644 --- a/esua-epdc/epdc-module/epdc-api/epdc-api-client/pom.xml +++ b/esua-epdc/epdc-module/epdc-api/epdc-api-client/pom.xml @@ -28,11 +28,6 @@ epdc-heart-client 1.0.0 - - com.esua.epdc - epdc-neighbor-client - 1.0.0 - com.esua.epdc epdc-news-client @@ -43,11 +38,6 @@ epdc-events-client 1.0.0 - - com.esua.epdc - epdc-services-client - 1.0.0 - com.esua.epdc epdc-user-client diff --git a/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml b/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml index a6528b3a2..6dcad3cfc 100755 --- a/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml +++ b/esua-epdc/epdc-module/epdc-events/epdc-events-server/src/main/resources/mapper/item/ItemDao.xml @@ -152,25 +152,40 @@ LEFT JOIN epdc_item_handle_process hp ON item.ID = hp.ITEM_ID AND hp.DEL_FLAG = '0' AND hp.CREATED_TIME = ( SELECT MAX( a.CREATED_TIME ) FROM epdc_item_handle_process a WHERE a.DEL_FLAG = '0' AND a.ITEM_ID = hp.ITEM_ID ) - LEFT JOIN epdc_item_dept dept ON item.Id = dept.ITEM_ID AND dept.DEL_FLAG = '0' WHERE - item.DEL_FLAG = '0' - - #{formDto.timestamp} - - AND dept.DEPT_ID IN + item.ID IN ( + SELECT + tmp.ITEM_ID + FROM + ( + SELECT DISTINCT + d.ITEM_ID + FROM + epdc_item_dept d + LEFT JOIN epdc_item it ON d.ITEM_ID = it.ID + WHERE + d.DEL_FLAG = '0' + AND it.DEL_FLAG = '0' + AND d.DEPT_ID IN #{deptIdItem} - - AND dept.DEPT_ID = #{formDto.deptId} + + #{formDto.timestamp} - AND item.ITEM_STATE = #{formDto.itemState} + AND it.ITEM_STATE = #{formDto.itemState} + + + AND d.DEPT_ID = #{formDto.deptId} ORDER BY - item.CREATED_TIME DESC + it.CREATED_TIME DESC LIMIT #{formDto.pageIndex},#{formDto.pageSize} + ) tmp + ) + ORDER BY + item.CREATED_TIME DESC + @@ -453,4 +493,46 @@ ORDER BY u.register_time desc + + diff --git a/esua-epdc/pom.xml b/esua-epdc/pom.xml index dd49e5c39..a1db4d450 100644 --- a/esua-epdc/pom.xml +++ b/esua-epdc/pom.xml @@ -36,7 +36,7 @@ 47.104.85.99:9002 1.4.13 prod - registry.cn-qingdao.aliyuncs.com/esua-epdc-shibei/ + registry-vpc.cn-qingdao.aliyuncs.com/esua-epdc-shibei/ 9508 @@ -77,12 +77,6 @@ - - com.spotify - dockerfile-maven-plugin - ${dockerfile-maven-plugin.version} - - com.spotify dockerfile-maven-plugin