Browse Source

党员先锋统计

master
zhaoqifeng 4 years ago
parent
commit
985765b016
  1. 179
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/stats/FactPartyMemberVanguardAgencyDailyDTO.java
  2. 179
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/stats/FactPartyMemberVanguardGridDailyDTO.java
  3. 11
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DemoController.java
  4. 20
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginGroupMainDailyDao.java
  5. 24
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginGroupMemberDailyDao.java
  6. 20
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginIssueMainDailyDao.java
  7. 41
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginProjectMainDailyDao.java
  8. 20
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginTopicMainDailyDao.java
  9. 44
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/FactPartyMemberVanguardAgencyDailyDao.java
  10. 42
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/FactPartyMemberVanguardGridDailyDao.java
  11. 149
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/stats/FactPartyMemberVanguardAgencyDailyEntity.java
  12. 149
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/stats/FactPartyMemberVanguardGridDailyEntity.java
  13. 31
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/StatsPartyMemberVanguardService.java
  14. 13
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginGroupMainDailyService.java
  15. 12
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginGroupMemberDailyService.java
  16. 12
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginIssueMainDailyService.java
  17. 23
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginProjectMainDailyService.java
  18. 12
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginTopicMainDailyService.java
  19. 39
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginGroupMainDailyServiceImpl.java
  20. 44
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginGroupMemberDailyServiceImpl.java
  21. 42
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginIssueMainDailyServiceImpl.java
  22. 75
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginProjectMainDailyServiceImpl.java
  23. 42
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginTopicMainDailyServiceImpl.java
  24. 414
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/StatsPartyMemberVanguardServiceImpl.java
  25. 105
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/FactPartyMemberVanguardAgencyDailyService.java
  26. 105
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/FactPartyMemberVanguardGridDailyService.java
  27. 118
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/impl/FactPartyMemberVanguardAgencyDailyServiceImpl.java
  28. 118
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/impl/FactPartyMemberVanguardGridDailyServiceImpl.java
  29. 26
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginGroupMainDailyDao.xml
  30. 44
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginGroupMemberDailyDao.xml
  31. 20
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginIssueMainDailyDao.xml
  32. 42
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectMainDailyDao.xml
  33. 20
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginTopicMainDailyDao.xml
  34. 40
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/FactPartyMemberVanguardAgencyDailyDao.xml
  35. 40
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/FactPartyMemberVanguardGridDailyDao.xml

179
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/stats/FactPartyMemberVanguardAgencyDailyDTO.java

@ -0,0 +1,179 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.dto.stats;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;
import java.math.BigDecimal;
/**
* 党员先锋-机关日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
@Data
public class FactPartyMemberVanguardAgencyDailyDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 唯一标识
*/
private String id;
/**
* 客户ID
*/
private String customerId;
/**
* 机构ID
*/
private String agencyId;
/**
* 父级机关ID
*/
private String pid;
/**
* 统计日期 关联日期dim表
*/
private String dateId;
/**
* 周ID
*/
private String weekId;
/**
* 月ID
*/
private String monthId;
/**
* 季ID
*/
private String quarterId;
/**
* 年ID
*/
private String yearId;
/**
* 党员建组数
*/
private Integer groupCount;
/**
* 党员建组数占比
*/
private BigDecimal groupRatio;
/**
* 组内党员人数
*/
private Integer groupMemberCount;
/**
* 组内党员人数占比
*/
private BigDecimal groupMemberRatio;
/**
* 党员发布话题数
*/
private Integer topicCount;
/**
* 党员发布话题数占比
*/
private BigDecimal topicRatio;
/**
* 党员发布话题转议题数
*/
private Integer issueCount;
/**
* 党员发布话题转议题数占比
*/
private BigDecimal issueRatio;
/**
* 党员发布话题转项目数
*/
private Integer projectCount;
/**
* 党员发布话题转项目数占比
*/
private BigDecimal projectRatio;
/**
* 党员发布话题转项目结案数
*/
private Integer projectClosedCount;
/**
* 党员发布话题转项目结案数占比
*/
private BigDecimal projectClosedRatio;
private Integer groupTotal;
private Integer groupMemberTotal;
private Integer topicTotal;
private Integer issueTotal;
private Integer projectTotal;
private Integer projectClosedTotal;
/**
* 删除标识 未删除0,已删除1
*/
private String delFlag;
/**
* 乐观锁
*/
private Integer revision;
/**
* 创建人
*/
private String createdBy;
/**
* 创建时间
*/
private Date createdTime;
/**
* 更新人
*/
private String updatedBy;
/**
* 更新时间
*/
private Date updatedTime;
}

179
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/stats/FactPartyMemberVanguardGridDailyDTO.java

@ -0,0 +1,179 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.dto.stats;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;
import java.math.BigDecimal;
/**
* 党员先锋-网格日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
@Data
public class FactPartyMemberVanguardGridDailyDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 唯一标识
*/
private String id;
/**
* 客户ID
*/
private String customerId;
/**
* 机构ID
*/
private String agencyId;
/**
* 网格ID
*/
private String gridId;
/**
* 统计日期 关联日期dim表
*/
private String dateId;
/**
* 周ID
*/
private String weekId;
/**
* 月ID
*/
private String monthId;
/**
* 季ID
*/
private String quarterId;
/**
* 年ID
*/
private String yearId;
/**
* 党员建组数
*/
private Integer groupCount;
/**
* 党员建组数占比
*/
private BigDecimal groupRatio;
/**
* 组内党员人数
*/
private Integer groupMemberCount;
/**
* 组内党员人数占比
*/
private BigDecimal groupMemberRatio;
/**
* 党员发布话题数
*/
private Integer topicCount;
/**
* 党员发布话题数占比
*/
private BigDecimal topicRatio;
/**
* 党员发布话题转议题数
*/
private Integer issueCount;
/**
* 党员发布话题转议题数占比
*/
private BigDecimal issueRatio;
/**
* 党员发布话题转项目数
*/
private Integer projectCount;
/**
* 党员发布话题转项目数占比
*/
private BigDecimal projectRatio;
/**
* 党员发布话题转项目结案数
*/
private Integer projectClosedCount;
/**
* 党员发布话题转项目结案数占比
*/
private BigDecimal projectClosedRatio;
private Integer groupTotal;
private Integer groupMemberTotal;
private Integer topicTotal;
private Integer issueTotal;
private Integer projectTotal;
private Integer projectClosedTotal;
/**
* 删除标识 未删除0,已删除1
*/
private String delFlag;
/**
* 乐观锁
*/
private Integer revision;
/**
* 创建人
*/
private String createdBy;
/**
* 创建时间
*/
private Date createdTime;
/**
* 更新人
*/
private String updatedBy;
/**
* 更新时间
*/
private Date updatedTime;
}

11
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DemoController.java

@ -18,6 +18,7 @@ import com.epmet.dao.stats.DimCustomerDao;
import com.epmet.dao.stats.DimDateDao;
import com.epmet.dao.stats.DimMonthDao;
import com.epmet.dto.AgencySubTreeDto;
import com.epmet.dto.StatsFormDTO;
import com.epmet.dto.extract.form.ExtractOriginFormDTO;
import com.epmet.dto.extract.form.ExtractScreenFormDTO;
import com.epmet.dto.indexcal.CalculateCommonFormDTO;
@ -34,6 +35,7 @@ import com.epmet.entity.stats.DimCustomerEntity;
import com.epmet.entity.stats.DimDateEntity;
import com.epmet.entity.stats.DimMonthEntity;
import com.epmet.service.StatsDemoService;
import com.epmet.service.StatsPartyMemberVanguardService;
import com.epmet.service.evaluationindex.extract.dataToIndex.*;
import com.epmet.service.evaluationindex.extract.todata.FactGroupActDailyService;
import com.epmet.service.evaluationindex.extract.todata.FactOriginProjectCategoryDailyService;
@ -111,6 +113,8 @@ public class DemoController {
@Autowired
private FactOriginProjectCategoryDailyService originProjectCategoryDailyService;
@Autowired
private StatsPartyMemberVanguardService statsPartyMemberVanguardService;
@Autowired
private FactGroupActDailyService factGroupActDailyService;
@GetMapping("testAlarm")
@ -873,6 +877,13 @@ public class DemoController {
return new Result().ok(ndddYhjfService.difficultyDataExtract(param));
}
@PostMapping("vanguard")
public Result partyMemberVanguard(StatsFormDTO formDTO) {
statsPartyMemberVanguardService.agencyStats(formDTO);
statsPartyMemberVanguardService.gridStats(formDTO);
return new Result();
}
@PostMapping("extractgroupact")
public Result extractGroupAct(@RequestParam("customerId") String customerId,@RequestParam("dateId")String dateId){
factGroupActDailyService.extractGridGroupActDaily(customerId,dateId);

20
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginGroupMainDailyDao.java

@ -205,4 +205,24 @@ public interface FactOriginGroupMainDailyDao extends BaseDao<FactOriginGroupMain
* @Description 查询客户小组维度下有效群组列表
**/
List<FactOriginGroupMainDailyEntity> selectCustomerGroupList(@Param("customerId") String customerId, @Param("dateId") String dateId);
/**
* 获取组织级别党员建组统计
* @author zhaoqifeng
* @date 2021/5/13 17:06
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberGroupStaticByAgency(@Param("customerId") String customerId, @Param("dateId") String dateId);
/**
* 获取网格级别党员建组统计
* @author zhaoqifeng
* @date 2021/5/13 17:07
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberGroupStaticByGrid(@Param("customerId") String customerId, @Param("dateId") String dateId);
}

24
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginGroupMemberDailyDao.java

@ -18,8 +18,12 @@
package com.epmet.dao.evaluationindex.extract;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.dto.extract.result.OrgStatisticsResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginGroupMemberDailyEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;
/**
*
@ -29,5 +33,25 @@ import org.apache.ibatis.annotations.Mapper;
*/
@Mapper
public interface FactOriginGroupMemberDailyDao extends BaseDao<FactOriginGroupMemberDailyEntity> {
/**
* 获取组织级别党员建组统计
* @author zhaoqifeng
* @date 2021/5/13 17:06
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectGroupPartyMemberStaticByAgency(@Param("customerId") String customerId, @Param("dateId") String dateId);
/**
* 获取网格级别党员建组统计
* @author zhaoqifeng
* @date 2021/5/13 17:07
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectGroupPartyMemberStaticByGrid(@Param("customerId") String customerId, @Param("dateId") String dateId);
}

20
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginIssueMainDailyDao.java

@ -205,4 +205,24 @@ public interface FactOriginIssueMainDailyDao extends BaseDao<FactOriginIssueMain
*/
List<OrgStatisticsResultDTO> selectOrgIssueCount(@Param("customerId") String customerId, @Param("monthId") String monthId,
@Param("level") String level);
/**
* 获取组织级别党员发布话题转议题统计
* @author zhaoqifeng
* @date 2021/5/17 15:02
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberIssueStaticByAgency(@Param("customerId") String customerId, @Param("dateId") String dateId);
/**
* 获取组织级别党员发布话题转议题统计
* @author zhaoqifeng
* @date 2021/5/17 15:03
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberIssueStaticByGrid(@Param("customerId") String customerId, @Param("dateId") String dateId);
}

41
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginProjectMainDailyDao.java

@ -370,4 +370,45 @@ public interface FactOriginProjectMainDailyDao extends BaseDao<FactOriginProject
List<FactOriginProjectOrgPeriodDailyEntity> getProjectPeriodForDiff(@Param("customerId") String customerId, @Param("dateId") String dateId);
List<ScreenProjectDataDTO> selectResponseCount(@Param("customerId") String customerId);
/**
* 获取组织级别党员发布话题转项目统计
* @author zhaoqifeng
* @date 2021/5/17 15:02
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberProjectStaticByAgency(@Param("customerId") String customerId, @Param("dateId") String dateId);
/**
* 获取组织级别党员发布话题转项目统计
* @author zhaoqifeng
* @date 2021/5/17 15:03
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberProjectStaticByGrid(@Param("customerId") String customerId, @Param("dateId") String dateId);
/**
* 获取组织级别党员发布话题结案统计
* @author zhaoqifeng
* @date 2021/5/17 15:02
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberClosedProjectStaticByAgency(@Param("customerId") String customerId, @Param("dateId") String dateId);
/**
* 获取组织级别党员发布话题结案统计
* @author zhaoqifeng
* @date 2021/5/17 15:03
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberClosedProjectStaticByGrid(@Param("customerId") String customerId, @Param("dateId") String dateId);
}

20
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginTopicMainDailyDao.java

@ -139,4 +139,24 @@ public interface FactOriginTopicMainDailyDao extends BaseDao<FactOriginTopicMain
*/
List<OrgStatisticsResultDTO> selectOrgTopicCount(@Param("customerId") String customerId, @Param("monthId") String monthId,
@Param("level") String level);
/**
* 组织内党员发布话题占比统计
* @author zhaoqifeng
* @date 2021/5/17 10:29
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberTopicStaticByAgency(@Param("customerId") String customerId, @Param("dateId") String dateId);
/**
* 网格内党员发布话题占比统计
* @author zhaoqifeng
* @date 2021/5/17 10:31
* @param customerId
* @param dateId
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> selectPartyMemberTopicStaticByGrid(@Param("customerId") String customerId, @Param("dateId") String dateId);
}

44
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/FactPartyMemberVanguardAgencyDailyDao.java

@ -0,0 +1,44 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.dao.stats;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.entity.stats.FactPartyMemberVanguardAgencyDailyEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
/**
* 党员先锋-机关日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
@Mapper
public interface FactPartyMemberVanguardAgencyDailyDao extends BaseDao<FactPartyMemberVanguardAgencyDailyEntity> {
/**
* 删除日统计数据
* @author zhaoqifeng
* @date 2021/5/17 17:19
* @param customerId
* @param dateId
* @return int
*/
int deleteDailyData(@Param("customerId") String customerId, @Param("dateId") String dateId);
}

42
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/FactPartyMemberVanguardGridDailyDao.java

@ -0,0 +1,42 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.dao.stats;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.entity.stats.FactPartyMemberVanguardGridDailyEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
/**
* 党员先锋-网格日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
@Mapper
public interface FactPartyMemberVanguardGridDailyDao extends BaseDao<FactPartyMemberVanguardGridDailyEntity> {
/**
* 删除日统计数据
* @author zhaoqifeng
* @date 2021/5/17 17:19
* @param customerId
* @param dateId
* @return int
*/
int deleteDailyData(@Param("customerId") String customerId, @Param("dateId") String dateId);
}

149
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/stats/FactPartyMemberVanguardAgencyDailyEntity.java

@ -0,0 +1,149 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.entity.stats;
import com.baomidou.mybatisplus.annotation.TableName;
import com.epmet.commons.mybatis.entity.BaseEpmetEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.math.BigDecimal;
import java.util.Date;
/**
* 党员先锋-机关日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
@Data
@EqualsAndHashCode(callSuper=false)
@TableName("fact_party_member_vanguard_agency_daily")
public class FactPartyMemberVanguardAgencyDailyEntity extends BaseEpmetEntity {
private static final long serialVersionUID = 1L;
/**
* 客户ID
*/
private String customerId;
/**
* 机构ID
*/
private String agencyId;
/**
* 父级机关ID
*/
private String pid;
/**
* 统计日期 关联日期dim表
*/
private String dateId;
/**
* 周ID
*/
private String weekId;
/**
* 月ID
*/
private String monthId;
/**
* 季ID
*/
private String quarterId;
/**
* 年ID
*/
private String yearId;
/**
* 党员建组数
*/
private Integer groupCount;
private Integer groupTotal;
private Integer groupMemberTotal;
private Integer topicTotal;
private Integer issueTotal;
private Integer projectTotal;
private Integer projectClosedTotal;
/**
* 党员建组数占比
*/
private BigDecimal groupRatio;
/**
* 组内党员人数
*/
private Integer groupMemberCount;
/**
* 组内党员人数占比
*/
private BigDecimal groupMemberRatio;
/**
* 党员发布话题数
*/
private Integer topicCount;
/**
* 党员发布话题数占比
*/
private BigDecimal topicRatio;
/**
* 党员发布话题转议题数
*/
private Integer issueCount;
/**
* 党员发布话题转议题数占比
*/
private BigDecimal issueRatio;
/**
* 党员发布话题转项目数
*/
private Integer projectCount;
/**
* 党员发布话题转项目数占比
*/
private BigDecimal projectRatio;
/**
* 党员发布话题转项目结案数
*/
private Integer projectClosedCount;
/**
* 党员发布话题转项目结案数占比
*/
private BigDecimal projectClosedRatio;
}

149
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/stats/FactPartyMemberVanguardGridDailyEntity.java

@ -0,0 +1,149 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.entity.stats;
import com.baomidou.mybatisplus.annotation.TableName;
import com.epmet.commons.mybatis.entity.BaseEpmetEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.math.BigDecimal;
import java.util.Date;
/**
* 党员先锋-网格日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
@Data
@EqualsAndHashCode(callSuper=false)
@TableName("fact_party_member_vanguard_grid_daily")
public class FactPartyMemberVanguardGridDailyEntity extends BaseEpmetEntity {
private static final long serialVersionUID = 1L;
/**
* 客户ID
*/
private String customerId;
/**
* 机构ID
*/
private String agencyId;
/**
* 网格ID
*/
private String gridId;
/**
* 统计日期 关联日期dim表
*/
private String dateId;
/**
* 周ID
*/
private String weekId;
/**
* 月ID
*/
private String monthId;
/**
* 季ID
*/
private String quarterId;
/**
* 年ID
*/
private String yearId;
/**
* 党员建组数
*/
private Integer groupCount;
private Integer groupTotal;
private Integer groupMemberTotal;
private Integer topicTotal;
private Integer issueTotal;
private Integer projectTotal;
private Integer projectClosedTotal;
/**
* 党员建组数占比
*/
private BigDecimal groupRatio;
/**
* 组内党员人数
*/
private Integer groupMemberCount;
/**
* 组内党员人数占比
*/
private BigDecimal groupMemberRatio;
/**
* 党员发布话题数
*/
private Integer topicCount;
/**
* 党员发布话题数占比
*/
private BigDecimal topicRatio;
/**
* 党员发布话题转议题数
*/
private Integer issueCount;
/**
* 党员发布话题转议题数占比
*/
private BigDecimal issueRatio;
/**
* 党员发布话题转项目数
*/
private Integer projectCount;
/**
* 党员发布话题转项目数占比
*/
private BigDecimal projectRatio;
/**
* 党员发布话题转项目结案数
*/
private Integer projectClosedCount;
/**
* 党员发布话题转项目结案数占比
*/
private BigDecimal projectClosedRatio;
}

31
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/StatsPartyMemberVanguardService.java

@ -0,0 +1,31 @@
package com.epmet.service;
import com.epmet.dto.StatsFormDTO;
import com.epmet.dto.group.form.GroupStatsFormDTO;
import com.epmet.dto.group.form.GroupTotalFormDTO;
/**
* 党员先锋相关统计
* @author zhaoqifeng
* @date 2021/5/13 15:07
*/
public interface StatsPartyMemberVanguardService {
/**
* 组织统计
* @author zhaoqifeng
* @date 2021/5/13 15:13
* @param formDTO
* @return void
*/
void agencyStats(StatsFormDTO formDTO);
/**
* 网格统计
* @author zhaoqifeng
* @date 2021/5/13 15:13
* @param formDTO
* @return void
*/
void gridStats(StatsFormDTO formDTO);
}

13
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginGroupMainDailyService.java

@ -26,6 +26,7 @@ import com.epmet.dto.group.result.ExtractGroupMemberActionRecordResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginGroupMainDailyEntity;
import java.util.List;
import java.util.Map;
/**
@ -112,4 +113,16 @@ public interface FactOriginGroupMainDailyService extends BaseService<FactOriginG
* @Description 查询客户小组维度下有效群组列表
**/
List<FactOriginGroupMainDailyEntity> getGroupListByCustomerId(String customerId, String dateId);
/**
* 获取组织/网格级别党员建组统计
* @author zhaoqifeng
* @date 2021/5/13 16:55
* @param customerId
* @param dateId
* @param type agency grid
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
Map<String, OrgStatisticsResultDTO> getPartyMemberGroupStatic(String customerId, String dateId, String type);
}

12
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginGroupMemberDailyService.java

@ -20,6 +20,7 @@ package com.epmet.service.evaluationindex.extract.todata;
import com.epmet.commons.mybatis.service.BaseService;
import com.epmet.commons.tools.page.PageData;
import com.epmet.dto.extract.FactOriginGroupMemberDailyDTO;
import com.epmet.dto.extract.result.OrgStatisticsResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginGroupMemberDailyEntity;
import java.util.List;
@ -92,4 +93,15 @@ public interface FactOriginGroupMemberDailyService extends BaseService<FactOrigi
* @date 2021-05-12
*/
void delete(String[] ids);
/**
* 获取小组党员统计
* @author zhaoqifeng
* @date 2021/5/14 10:33
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String,com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
Map<String, OrgStatisticsResultDTO> getGroupPartyMemberStatic(String customerId, String dateId, String type);
}

12
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginIssueMainDailyService.java

@ -22,6 +22,7 @@ import com.epmet.dto.extract.result.OrgStatisticsResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginIssueMainDailyEntity;
import java.util.List;
import java.util.Map;
/**
* 议题主表
@ -110,4 +111,15 @@ public interface FactOriginIssueMainDailyService extends BaseService<FactOriginI
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> getOrgIssueCount(String customerId, String monthId, String level);
/**
* 获取组织/网格级别党员发布话题转议题统计
* @author zhaoqifeng
* @date 2021/5/17 14:52
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String,com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
Map<String, OrgStatisticsResultDTO> getPartyMemberIssueStatic(String customerId, String dateId, String type);
}

23
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginProjectMainDailyService.java

@ -32,6 +32,7 @@ import com.epmet.entity.evaluationindex.extract.FactOriginProjectOrgPeriodDailyE
import com.epmet.entity.evaluationindex.screen.ScreenDifficultyDataEntity;
import java.util.List;
import java.util.Map;
/**
* 项目主表_日统计
@ -367,4 +368,26 @@ public interface FactOriginProjectMainDailyService extends BaseService<FactOrigi
*/
void setProjectLevel(List<ScreenProjectDataDTO> list, String customerId);
/**
* 获取组织/网格级别党员发布话题转项目统计
* @author zhaoqifeng
* @date 2021/5/17 15:25
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String,com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
Map<String, OrgStatisticsResultDTO> getPartyMemberProjectStatic(String customerId, String dateId, String type);
/**
* 获取组织/网格级别党员发布话题结案统计
* @author zhaoqifeng
* @date 2021/5/17 15:39
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String,com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
Map<String, OrgStatisticsResultDTO> getPartyMemberClosedProjectStatic(String customerId, String dateId, String type);
}

12
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginTopicMainDailyService.java

@ -25,6 +25,7 @@ import com.epmet.dto.indexcollect.result.CpcIndexCommonDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginTopicMainDailyEntity;
import java.util.List;
import java.util.Map;
/**
@ -111,4 +112,15 @@ public interface FactOriginTopicMainDailyService extends BaseService<FactOriginT
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
List<OrgStatisticsResultDTO> getOrgTopicCount(String customerId, String monthId, String level);
/**
* 获取组织/网格级别党员发布话题统计
* @author zhaoqifeng
* @date 2021/5/17 14:25
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String,com.epmet.dto.extract.result.OrgStatisticsResultDTO>
*/
Map<String, OrgStatisticsResultDTO> getPartyMemberTopicStatic(String customerId, String dateId, String type);
}

39
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginGroupMainDailyServiceImpl.java

@ -20,6 +20,7 @@ package com.epmet.service.evaluationindex.extract.todata.impl;
import com.epmet.commons.mybatis.service.impl.BaseServiceImpl;
import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.constant.OrgTypeConstant;
import com.epmet.dao.evaluationindex.extract.FactOriginGroupMainDailyDao;
import com.epmet.dao.evaluationindex.extract.FactOriginGroupMemberDailyDao;
import com.epmet.dto.extract.FactOriginGroupMainDailyDTO;
@ -37,8 +38,13 @@ import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.CollectionUtils;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.function.Function;
import java.util.stream.Collectors;
@ -159,4 +165,37 @@ public class FactOriginGroupMainDailyServiceImpl extends BaseServiceImpl<FactOri
return baseDao.selectCustomerGroupList(customerId, dateId);
}
/**
* 获取组织/网格级别党员建组统计
*
* @param customerId
* @param dateId
* @param type agency grid
* @return java.util.List<com.epmet.dto.extract.result.OrgStatisticsResultDTO>
* @author zhaoqifeng
* @date 2021/5/13 16:55
*/
@Override
public Map<String, OrgStatisticsResultDTO> getPartyMemberGroupStatic(String customerId, String dateId, String type) {
List<OrgStatisticsResultDTO> result;
if (OrgTypeConstant.AGENCY.equals(type)) {
result = baseDao.selectPartyMemberGroupStaticByAgency(customerId, dateId);
} else {
result = baseDao.selectPartyMemberGroupStaticByGrid(customerId, dateId);
}
if (CollectionUtils.isEmpty(result)) {
return Collections.emptyMap();
}
result.forEach(item -> {
BigDecimal count = new BigDecimal(item.getCount());
BigDecimal sum = new BigDecimal(item.getSum());
item.setRatio(count.divide(sum, NumConstant.SIX, RoundingMode.HALF_UP));
});
if (OrgTypeConstant.AGENCY.equals(type)) {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getAgencyId, Function.identity()));
} else {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getOrgId, Function.identity()));
}
}
}

44
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginGroupMemberDailyServiceImpl.java

@ -20,21 +20,30 @@ package com.epmet.service.evaluationindex.extract.todata.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.epmet.commons.mybatis.service.impl.BaseServiceImpl;
import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.commons.tools.constant.FieldConstant;
import com.epmet.constant.OrgTypeConstant;
import com.epmet.dao.evaluationindex.extract.FactOriginGroupMemberDailyDao;
import com.epmet.dto.extract.FactOriginGroupMemberDailyDTO;
import com.epmet.dto.extract.result.OrgStatisticsResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginGroupMemberDailyEntity;
import com.epmet.service.evaluationindex.extract.todata.FactOriginGroupMemberDailyService;
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 org.springframework.util.CollectionUtils;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.function.Function;
import java.util.stream.Collectors;
/**
*
@ -98,4 +107,39 @@ public class FactOriginGroupMemberDailyServiceImpl extends BaseServiceImpl<FactO
baseDao.deleteBatchIds(Arrays.asList(ids));
}
/**
* 获取小组党员统计
*
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String, com.epmet.dto.extract.result.OrgStatisticsResultDTO>
* @author zhaoqifeng
* @date 2021/5/14 10:33
*/
@Override
public Map<String, OrgStatisticsResultDTO> getGroupPartyMemberStatic(String customerId, String dateId, String type) {
List<OrgStatisticsResultDTO> staticsList;
if (OrgTypeConstant.AGENCY.equals(type)) {
//组织级别统计
staticsList = baseDao.selectGroupPartyMemberStaticByAgency(customerId, dateId);
} else {
//网格级别统计
staticsList = baseDao.selectGroupPartyMemberStaticByGrid(customerId, dateId);
}
if (CollectionUtils.isEmpty(staticsList)) {
return Collections.emptyMap();
}
staticsList.forEach(item -> {
BigDecimal count = new BigDecimal(item.getCount());
BigDecimal sum = new BigDecimal(item.getSum());
item.setRatio(count.divide(sum, NumConstant.SIX, RoundingMode.HALF_UP));
});
if (OrgTypeConstant.AGENCY.equals(type)) {
return staticsList.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getAgencyId, Function.identity()));
} else {
return staticsList.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getOrgId, Function.identity()));
}
}
}

42
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginIssueMainDailyServiceImpl.java

@ -19,15 +19,24 @@ package com.epmet.service.evaluationindex.extract.todata.impl;
import com.epmet.commons.dynamic.datasource.annotation.DataSource;
import com.epmet.commons.mybatis.service.impl.BaseServiceImpl;
import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.constant.DataSourceConstant;
import com.epmet.constant.OrgTypeConstant;
import com.epmet.dao.evaluationindex.extract.FactOriginIssueMainDailyDao;
import com.epmet.dto.extract.result.OrgStatisticsResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginIssueMainDailyEntity;
import com.epmet.service.evaluationindex.extract.todata.FactOriginIssueMainDailyService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.util.CollectionUtils;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.function.Function;
import java.util.stream.Collectors;
/**
* 议题主表
@ -127,4 +136,37 @@ public class FactOriginIssueMainDailyServiceImpl extends BaseServiceImpl<FactOri
public List<OrgStatisticsResultDTO> getOrgIssueCount(String customerId, String monthId, String level) {
return baseDao.selectOrgIssueCount(customerId, monthId, level);
}
/**
* 获取组织/网格级别党员发布话题转议题统计
*
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String, com.epmet.dto.extract.result.OrgStatisticsResultDTO>
* @author zhaoqifeng
* @date 2021/5/17 14:52
*/
@Override
public Map<String, OrgStatisticsResultDTO> getPartyMemberIssueStatic(String customerId, String dateId, String type) {
List<OrgStatisticsResultDTO> result;
if (OrgTypeConstant.AGENCY.equals(type)) {
result = baseDao.selectPartyMemberIssueStaticByAgency(customerId, dateId);
} else {
result = baseDao.selectPartyMemberIssueStaticByGrid(customerId, dateId);
}
if (CollectionUtils.isEmpty(result)) {
return Collections.emptyMap();
}
result.forEach(item -> {
BigDecimal count = new BigDecimal(item.getCount());
BigDecimal sum = new BigDecimal(item.getSum());
item.setRatio(count.divide(sum, NumConstant.SIX, RoundingMode.HALF_UP));
});
if (OrgTypeConstant.AGENCY.equals(type)) {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getAgencyId, Function.identity()));
} else {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getOrgId, Function.identity()));
}
}
}

75
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginProjectMainDailyServiceImpl.java

@ -23,6 +23,7 @@ import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.commons.tools.utils.DateUtils;
import com.epmet.commons.tools.utils.Result;
import com.epmet.constant.DataSourceConstant;
import com.epmet.constant.OrgTypeConstant;
import com.epmet.constant.ProjectConstant;
import com.epmet.dao.evaluationindex.extract.FactOriginProjectMainDailyDao;
import com.epmet.dao.evaluationindex.extract.FactOriginProjectOrgPeriodDailyDao;
@ -47,10 +48,10 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.CollectionUtils;
import java.util.ArrayList;
import java.util.Comparator;
import java.util.List;
import java.util.Map;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.*;
import java.util.function.Function;
import java.util.stream.Collectors;
/**
@ -528,5 +529,71 @@ public class FactOriginProjectMainDailyServiceImpl extends BaseServiceImpl<FactO
});
}
/**
* 获取组织/网格级别党员发布话题转项目统计
*
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String, com.epmet.dto.extract.result.OrgStatisticsResultDTO>
* @author zhaoqifeng
* @date 2021/5/17 15:25
*/
@Override
public Map<String, OrgStatisticsResultDTO> getPartyMemberProjectStatic(String customerId, String dateId, String type) {
List<OrgStatisticsResultDTO> result;
if (OrgTypeConstant.AGENCY.equals(type)) {
result = baseDao.selectPartyMemberProjectStaticByAgency(customerId, dateId);
} else {
result = baseDao.selectPartyMemberProjectStaticByGrid(customerId, dateId);
}
if (CollectionUtils.isEmpty(result)) {
return Collections.emptyMap();
}
result.forEach(item -> {
BigDecimal count = new BigDecimal(item.getCount());
BigDecimal sum = new BigDecimal(item.getSum());
item.setRatio(count.divide(sum, NumConstant.SIX, RoundingMode.HALF_UP));
});
if (OrgTypeConstant.AGENCY.equals(type)) {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getAgencyId, Function.identity()));
} else {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getOrgId, Function.identity()));
}
}
/**
* 获取组织/网格级别党员发布话题结案统计
*
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String, com.epmet.dto.extract.result.OrgStatisticsResultDTO>
* @author zhaoqifeng
* @date 2021/5/17 15:39
*/
@Override
public Map<String, OrgStatisticsResultDTO> getPartyMemberClosedProjectStatic(String customerId, String dateId, String type) {
List<OrgStatisticsResultDTO> result;
if (OrgTypeConstant.AGENCY.equals(type)) {
result = baseDao.selectPartyMemberClosedProjectStaticByAgency(customerId, dateId);
} else {
result = baseDao.selectPartyMemberClosedProjectStaticByGrid(customerId, dateId);
}
if (CollectionUtils.isEmpty(result)) {
return Collections.emptyMap();
}
result.forEach(item -> {
BigDecimal count = new BigDecimal(item.getCount());
BigDecimal sum = new BigDecimal(item.getSum());
item.setRatio(count.divide(sum, NumConstant.SIX, RoundingMode.HALF_UP));
});
if (OrgTypeConstant.AGENCY.equals(type)) {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getAgencyId, Function.identity()));
} else {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getOrgId, Function.identity()));
}
}
}

42
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginTopicMainDailyServiceImpl.java

@ -26,6 +26,7 @@ import com.epmet.commons.tools.utils.DateUtils;
import com.epmet.constant.DataSourceConstant;
import com.epmet.constant.DimObjectActionConstant;
import com.epmet.constant.IndexCalConstant;
import com.epmet.constant.OrgTypeConstant;
import com.epmet.dao.evaluationindex.extract.FactOriginTopicLogDailyDao;
import com.epmet.dao.evaluationindex.extract.FactOriginTopicMainDailyDao;
import com.epmet.dto.extract.form.ExtractOriginFormDTO;
@ -46,10 +47,10 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.util.CollectionUtils;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.*;
import java.util.function.Function;
import java.util.stream.Collectors;
@ -325,4 +326,37 @@ public class FactOriginTopicMainDailyServiceImpl extends BaseServiceImpl<FactOri
return baseDao.selectOrgTopicCount(customerId, monthId, level);
}
/**
* 获取组织/网格级别党员发布话题统计
*
* @param customerId
* @param dateId
* @param type
* @return java.util.Map<java.lang.String, com.epmet.dto.extract.result.OrgStatisticsResultDTO>
* @author zhaoqifeng
* @date 2021/5/17 14:25
*/
@Override
public Map<String, OrgStatisticsResultDTO> getPartyMemberTopicStatic(String customerId, String dateId, String type) {
List<OrgStatisticsResultDTO> result;
if (OrgTypeConstant.AGENCY.equals(type)) {
result = baseDao.selectPartyMemberTopicStaticByAgency(customerId, dateId);
} else {
result = baseDao.selectPartyMemberTopicStaticByGrid(customerId, dateId);
}
if (CollectionUtils.isEmpty(result)) {
return Collections.emptyMap();
}
result.forEach(item -> {
BigDecimal count = new BigDecimal(item.getCount());
BigDecimal sum = new BigDecimal(item.getSum());
item.setRatio(count.divide(sum, NumConstant.SIX, RoundingMode.HALF_UP));
});
if (OrgTypeConstant.AGENCY.equals(type)) {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getAgencyId, Function.identity()));
} else {
return result.stream().collect(Collectors.toMap(OrgStatisticsResultDTO::getOrgId, Function.identity()));
}
}
}

414
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/StatsPartyMemberVanguardServiceImpl.java

@ -0,0 +1,414 @@
package com.epmet.service.impl;
import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.commons.tools.utils.DateUtils;
import com.epmet.constant.OrgTypeConstant;
import com.epmet.dto.StatsFormDTO;
import com.epmet.dto.extract.result.OrgStatisticsResultDTO;
import com.epmet.dto.stats.DimAgencyDTO;
import com.epmet.dto.stats.DimGridDTO;
import com.epmet.entity.stats.DimGridEntity;
import com.epmet.entity.stats.FactPartyMemberVanguardAgencyDailyEntity;
import com.epmet.entity.stats.FactPartyMemberVanguardGridDailyEntity;
import com.epmet.service.StatsPartyMemberVanguardService;
import com.epmet.service.evaluationindex.extract.todata.*;
import com.epmet.service.stats.*;
import com.epmet.util.DimIdGenerator;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.math.BigDecimal;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
/**
* @author zhaoqifeng
* @dscription
* @date 2021/5/13 15:13
*/
@Slf4j
@Service
public class StatsPartyMemberVanguardServiceImpl implements StatsPartyMemberVanguardService {
@Resource
private DimCustomerService dimCustomerService;
@Resource
private DimAgencyService dimAgencyService;
@Resource
private DimGridService dimGridService;
@Resource
private FactPartyMemberVanguardAgencyDailyService factPartyMemberVanguardAgencyDailyService;
@Resource
private FactPartyMemberVanguardGridDailyService factPartyMemberVanguardGridDailyService;
@Resource
private FactOriginGroupMainDailyService factOriginGroupMainDailyService;
@Resource
private FactOriginGroupMemberDailyService factOriginGroupMemberDailyService;
@Resource
private FactOriginTopicMainDailyService factOriginTopicMainDailyService;
@Resource
private FactOriginIssueMainDailyService factOriginIssueMainDailyService;
@Resource
private FactOriginProjectMainDailyService factOriginProjectMainDailyService;
/**
* 组织统计
*
* @param formDTO
* @return void
* @author zhaoqifeng
* @date 2021/5/13 15:13
*/
@Override
public void agencyStats(StatsFormDTO formDTO) {
Date date = yesterday();
//入参有时间的则按具体时间执行,没有的则按当前时间前一天执行
if (null != formDTO && StringUtils.isNotBlank(formDTO.getDate())) {
date = DateUtils.parse(formDTO.getDate(), DateUtils.DATE_PATTERN_YYYYMMDD);
}
//入参有客户Id的则按客户Id执行,没有的则全部客户都执行
if (null != formDTO && StringUtils.isNotBlank(formDTO.getCustomerId())) {
customerAgencyStats(formDTO.getCustomerId(), date);
} else {
int pageNo = 1;
int pageSize = 100;
List<String> customerIdList;
do {
customerIdList = dimCustomerService.selectCustomerIdPage(pageNo++, pageSize);
if (CollectionUtils.isNotEmpty(customerIdList)) {
for (String customerId : customerIdList) {
try {
//遍历统计每一个客户数据
customerAgencyStats(customerId, date);
} catch (Exception e) {
log.error("Error creating model JSON", e);
}
}
}
} while (CollectionUtils.isNotEmpty(customerIdList) && customerIdList.size() == pageSize);
}
}
private void customerAgencyStats(String customerId, Date date) {
//1:查询日期各维度表Id
DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date);
//2:根据客户Id查询机关维度表数据
log.info("根据客户Id查询机关维度数据,对应客户Id:" + customerId);
DimAgencyDTO dimAgencyDTO = new DimAgencyDTO();
dimAgencyDTO.setCustomerId(customerId);
List<DimAgencyDTO> dimAgencyList = dimAgencyService.getDimAgencyList(dimAgencyDTO);
if (CollectionUtils.isNotEmpty(dimAgencyList)) {
List<FactPartyMemberVanguardAgencyDailyEntity> vanguardList = dimAgencyList.stream().map(item -> initAgencyDailyEntity(item, dimId)).collect(Collectors.toList());
//党员建组占比统计
Map<String, OrgStatisticsResultDTO> groupStatic = factOriginGroupMainDailyService.getPartyMemberGroupStatic(customerId,
dimId.getDateId(), OrgTypeConstant.AGENCY);
if (!groupStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = groupStatic.get(item.getAgencyId());
if (null != dto) {
item.setGroupCount(dto.getCount());
item.setGroupRatio(dto.getRatio());
item.setGroupTotal(dto.getSum());
}
});
}
//小组成员党员占比统计
Map<String, OrgStatisticsResultDTO> memberStatic = factOriginGroupMemberDailyService.getGroupPartyMemberStatic(customerId,
dimId.getDateId(), OrgTypeConstant.AGENCY);
if (!memberStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = memberStatic.get(item.getAgencyId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//党员发布话题占比统计
Map<String, OrgStatisticsResultDTO> topicStatic = factOriginTopicMainDailyService.getPartyMemberTopicStatic(customerId,
dimId.getDateId(), OrgTypeConstant.AGENCY);
if (!topicStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = topicStatic.get(item.getAgencyId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//党员发布话题转议题占比统计
Map<String, OrgStatisticsResultDTO> issueStatic = factOriginIssueMainDailyService.getPartyMemberIssueStatic(customerId,
dimId.getDateId(), OrgTypeConstant.AGENCY);
if (!issueStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = issueStatic.get(item.getAgencyId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//党员发布话题转项目占比统计
Map<String, OrgStatisticsResultDTO> projectStatic = factOriginProjectMainDailyService.getPartyMemberProjectStatic(customerId,
dimId.getDateId(), OrgTypeConstant.AGENCY);
if (!projectStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = projectStatic.get(item.getAgencyId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//项目结案占比统计
Map<String, OrgStatisticsResultDTO> closedStatic = factOriginProjectMainDailyService.getPartyMemberClosedProjectStatic(customerId,
dimId.getDateId(), OrgTypeConstant.AGENCY);
if (!closedStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = closedStatic.get(item.getAgencyId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//删除旧数据
factPartyMemberVanguardAgencyDailyService.deleteDailyData(customerId, dimId.getDateId());
//批量插入
factPartyMemberVanguardAgencyDailyService.insertBatch(vanguardList);
}
}
/**
* 网格统计
*
* @param formDTO
* @return void
* @author zhaoqifeng
* @date 2021/5/13 15:13
*/
@Override
public void gridStats(StatsFormDTO formDTO) {
Date date = yesterday();
//入参有时间的则按具体时间执行,没有的则按当前时间前一天执行
if (null != formDTO && StringUtils.isNotBlank(formDTO.getDate())) {
date = DateUtils.parse(formDTO.getDate(), DateUtils.DATE_PATTERN_YYYYMMDD);
}
//入参有客户Id的则按客户Id执行,没有的则全部客户都执行
if (null != formDTO && StringUtils.isNotBlank(formDTO.getCustomerId())) {
customerAgencyStats(formDTO.getCustomerId(), date);
} else {
int pageNo = 1;
int pageSize = 100;
List<String> customerIdList;
do {
customerIdList = dimCustomerService.selectCustomerIdPage(pageNo++, pageSize);
if (CollectionUtils.isNotEmpty(customerIdList)) {
for (String customerId : customerIdList) {
try {
//遍历统计每一个客户数据
customerGridStats(customerId, date);
} catch (Exception e) {
log.error("Error creating model JSON", e);
}
}
}
} while (CollectionUtils.isNotEmpty(customerIdList) && customerIdList.size() == pageSize);
}
}
private void customerGridStats(String customerId, Date date) {
//1:查询日期各维度表Id
DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date);
//2:根据客户Id查询机关维度表数据
log.info("根据客户Id查询网格维度数据,对应客户Id:" + customerId);
DimAgencyDTO dimAgencyDTO = new DimAgencyDTO();
dimAgencyDTO.setCustomerId(customerId);
List<DimGridEntity> dimGridList = dimGridService.getGridListByCustomerId(customerId);
if (CollectionUtils.isNotEmpty(dimGridList)) {
List<FactPartyMemberVanguardGridDailyEntity> vanguardList =
dimGridList.stream().map(item -> initGridDailyEntity(item, dimId)).collect(Collectors.toList());
//党员建组占比统计
Map<String, OrgStatisticsResultDTO> groupStatic = factOriginGroupMainDailyService.getPartyMemberGroupStatic(customerId,
dimId.getDateId(), OrgTypeConstant.GRID);
if (!groupStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = groupStatic.get(item.getGridId());
if (null != dto) {
item.setGroupCount(dto.getCount());
item.setGroupRatio(dto.getRatio());
item.setGroupTotal(dto.getSum());
}
});
}
//小组成员党员占比统计
Map<String, OrgStatisticsResultDTO> memberStatic = factOriginGroupMemberDailyService.getGroupPartyMemberStatic(customerId,
dimId.getDateId(), OrgTypeConstant.GRID);
if (!memberStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = memberStatic.get(item.getGridId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//党员发布话题占比统计
Map<String, OrgStatisticsResultDTO> topicStatic = factOriginTopicMainDailyService.getPartyMemberTopicStatic(customerId,
dimId.getDateId(), OrgTypeConstant.GRID);
if (!topicStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = topicStatic.get(item.getGridId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//党员发布话题转议题占比统计
Map<String, OrgStatisticsResultDTO> issueStatic = factOriginIssueMainDailyService.getPartyMemberIssueStatic(customerId,
dimId.getDateId(), OrgTypeConstant.GRID);
if (!issueStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = issueStatic.get(item.getGridId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//党员发布话题转项目占比统计
Map<String, OrgStatisticsResultDTO> projectStatic = factOriginProjectMainDailyService.getPartyMemberProjectStatic(customerId,
dimId.getDateId(), OrgTypeConstant.GRID);
if (!projectStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = projectStatic.get(item.getGridId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//项目结案占比统计
Map<String, OrgStatisticsResultDTO> closedStatic = factOriginProjectMainDailyService.getPartyMemberClosedProjectStatic(customerId,
dimId.getDateId(), OrgTypeConstant.GRID);
if (!closedStatic.isEmpty()) {
vanguardList.forEach(item -> {
OrgStatisticsResultDTO dto = closedStatic.get(item.getGridId());
if (null != dto) {
item.setGroupMemberCount(dto.getCount());
item.setGroupMemberRatio(dto.getRatio());
item.setGroupMemberTotal(dto.getSum());
}
});
}
//删除旧数据
factPartyMemberVanguardGridDailyService.deleteDailyData(customerId, dimId.getDateId());
//批量插入
factPartyMemberVanguardGridDailyService.insertBatch(vanguardList);
}
}
private Date yesterday() {
Date date = new Date();
try {
DateFormat sdf = new SimpleDateFormat(DateUtils.DATE_PATTERN_YYYYMMDD);
Calendar calendar = Calendar.getInstance();
calendar.set(Calendar.HOUR_OF_DAY, -24);
String str = sdf.format(calendar.getTime());
date = sdf.parse(str);
} catch (Exception e) {
e.printStackTrace();
}
return date;
}
private FactPartyMemberVanguardAgencyDailyEntity initAgencyDailyEntity(DimAgencyDTO agency, DimIdGenerator.DimIdBean dimId) {
FactPartyMemberVanguardAgencyDailyEntity entity = new FactPartyMemberVanguardAgencyDailyEntity();
entity.setCustomerId(agency.getCustomerId());
entity.setAgencyId(agency.getId());
entity.setPid(agency.getPid());
entity.setDateId(dimId.getDateId());
entity.setWeekId(dimId.getWeekId());
entity.setMonthId(dimId.getMonthId());
entity.setQuarterId(dimId.getQuarterId());
entity.setYearId(dimId.getYearId());
entity.setGroupCount(NumConstant.ZERO);
entity.setGroupRatio(new BigDecimal(NumConstant.ZERO));
entity.setGroupTotal(NumConstant.ZERO);
entity.setGroupMemberCount(NumConstant.ZERO);
entity.setGroupMemberRatio(new BigDecimal(NumConstant.ZERO));
entity.setGroupMemberTotal(NumConstant.ZERO);
entity.setTopicCount(NumConstant.ZERO);
entity.setTopicRatio(new BigDecimal(NumConstant.ZERO));
entity.setTopicTotal(NumConstant.ZERO);
entity.setIssueCount(NumConstant.ZERO);
entity.setIssueRatio(new BigDecimal(NumConstant.ZERO));
entity.setIssueTotal(NumConstant.ZERO);
entity.setProjectCount(NumConstant.ZERO);
entity.setProjectRatio(new BigDecimal(NumConstant.ZERO));
entity.setProjectTotal(NumConstant.ZERO);
entity.setProjectClosedCount(NumConstant.ZERO);
entity.setProjectClosedRatio(new BigDecimal(NumConstant.ZERO));
entity.setProjectClosedTotal(NumConstant.ZERO);
return entity;
}
private FactPartyMemberVanguardGridDailyEntity initGridDailyEntity(DimGridEntity grid, DimIdGenerator.DimIdBean dimId) {
FactPartyMemberVanguardGridDailyEntity entity = new FactPartyMemberVanguardGridDailyEntity();
entity.setCustomerId(grid.getCustomerId());
entity.setAgencyId(grid.getAgencyId());
entity.setGridId(grid.getId());
entity.setDateId(dimId.getDateId());
entity.setWeekId(dimId.getWeekId());
entity.setMonthId(dimId.getMonthId());
entity.setQuarterId(dimId.getQuarterId());
entity.setYearId(dimId.getYearId());
entity.setGroupCount(NumConstant.ZERO);
entity.setGroupRatio(new BigDecimal(NumConstant.ZERO));
entity.setGroupTotal(NumConstant.ZERO);
entity.setGroupMemberCount(NumConstant.ZERO);
entity.setGroupMemberRatio(new BigDecimal(NumConstant.ZERO));
entity.setGroupMemberTotal(NumConstant.ZERO);
entity.setTopicCount(NumConstant.ZERO);
entity.setTopicRatio(new BigDecimal(NumConstant.ZERO));
entity.setTopicTotal(NumConstant.ZERO);
entity.setIssueCount(NumConstant.ZERO);
entity.setIssueRatio(new BigDecimal(NumConstant.ZERO));
entity.setIssueTotal(NumConstant.ZERO);
entity.setProjectCount(NumConstant.ZERO);
entity.setProjectRatio(new BigDecimal(NumConstant.ZERO));
entity.setProjectTotal(NumConstant.ZERO);
entity.setProjectClosedCount(NumConstant.ZERO);
entity.setProjectClosedRatio(new BigDecimal(NumConstant.ZERO));
entity.setProjectClosedTotal(NumConstant.ZERO);
return entity;
}
}

105
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/FactPartyMemberVanguardAgencyDailyService.java

@ -0,0 +1,105 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.service.stats;
import com.epmet.commons.mybatis.service.BaseService;
import com.epmet.commons.tools.page.PageData;
import com.epmet.dto.stats.FactPartyMemberVanguardAgencyDailyDTO;
import com.epmet.entity.stats.FactPartyMemberVanguardAgencyDailyEntity;
import java.util.List;
import java.util.Map;
/**
* 党员先锋-机关日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
public interface FactPartyMemberVanguardAgencyDailyService extends BaseService<FactPartyMemberVanguardAgencyDailyEntity> {
/**
* 默认分页
*
* @param params
* @return PageData<FactPartyMemberVanguardAgencyDailyDTO>
* @author generator
* @date 2021-05-13
*/
PageData<FactPartyMemberVanguardAgencyDailyDTO> page(Map<String, Object> params);
/**
* 默认查询
*
* @param params
* @return java.util.List<FactPartyMemberVanguardAgencyDailyDTO>
* @author generator
* @date 2021-05-13
*/
List<FactPartyMemberVanguardAgencyDailyDTO> list(Map<String, Object> params);
/**
* 单条查询
*
* @param id
* @return FactPartyMemberVanguardAgencyDailyDTO
* @author generator
* @date 2021-05-13
*/
FactPartyMemberVanguardAgencyDailyDTO get(String id);
/**
* 默认保存
*
* @param dto
* @return void
* @author generator
* @date 2021-05-13
*/
void save(FactPartyMemberVanguardAgencyDailyDTO dto);
/**
* 默认更新
*
* @param dto
* @return void
* @author generator
* @date 2021-05-13
*/
void update(FactPartyMemberVanguardAgencyDailyDTO dto);
/**
* 批量删除
*
* @param ids
* @return void
* @author generator
* @date 2021-05-13
*/
void delete(String[] ids);
/**
* 清除日数据
* @author zhaoqifeng
* @date 2021/5/17 15:55
* @param customerId
* @param dateId
* @return void
*/
void deleteDailyData(String customerId, String dateId);
}

105
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/FactPartyMemberVanguardGridDailyService.java

@ -0,0 +1,105 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.service.stats;
import com.epmet.commons.mybatis.service.BaseService;
import com.epmet.commons.tools.page.PageData;
import com.epmet.dto.stats.FactPartyMemberVanguardGridDailyDTO;
import com.epmet.entity.stats.FactPartyMemberVanguardGridDailyEntity;
import java.util.List;
import java.util.Map;
/**
* 党员先锋-网格日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
public interface FactPartyMemberVanguardGridDailyService extends BaseService<FactPartyMemberVanguardGridDailyEntity> {
/**
* 默认分页
*
* @param params
* @return PageData<FactPartyMemberVanguardGridDailyDTO>
* @author generator
* @date 2021-05-13
*/
PageData<FactPartyMemberVanguardGridDailyDTO> page(Map<String, Object> params);
/**
* 默认查询
*
* @param params
* @return java.util.List<FactPartyMemberVanguardGridDailyDTO>
* @author generator
* @date 2021-05-13
*/
List<FactPartyMemberVanguardGridDailyDTO> list(Map<String, Object> params);
/**
* 单条查询
*
* @param id
* @return FactPartyMemberVanguardGridDailyDTO
* @author generator
* @date 2021-05-13
*/
FactPartyMemberVanguardGridDailyDTO get(String id);
/**
* 默认保存
*
* @param dto
* @return void
* @author generator
* @date 2021-05-13
*/
void save(FactPartyMemberVanguardGridDailyDTO dto);
/**
* 默认更新
*
* @param dto
* @return void
* @author generator
* @date 2021-05-13
*/
void update(FactPartyMemberVanguardGridDailyDTO dto);
/**
* 批量删除
*
* @param ids
* @return void
* @author generator
* @date 2021-05-13
*/
void delete(String[] ids);
/**
* 清除日数据
* @author zhaoqifeng
* @date 2021/5/17 15:55
* @param customerId
* @param dateId
* @return void
*/
void deleteDailyData(String customerId, String dateId);
}

118
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/impl/FactPartyMemberVanguardAgencyDailyServiceImpl.java

@ -0,0 +1,118 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.service.stats.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.epmet.commons.dynamic.datasource.annotation.DataSource;
import com.epmet.commons.mybatis.service.impl.BaseServiceImpl;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.commons.tools.constant.FieldConstant;
import com.epmet.constant.DataSourceConstant;
import com.epmet.dao.stats.FactPartyMemberVanguardAgencyDailyDao;
import com.epmet.dto.stats.FactPartyMemberVanguardAgencyDailyDTO;
import com.epmet.entity.stats.FactPartyMemberVanguardAgencyDailyEntity;
import com.epmet.service.stats.FactPartyMemberVanguardAgencyDailyService;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
/**
* 党员先锋-机关日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
@Service
@DataSource(DataSourceConstant.STATS)
public class FactPartyMemberVanguardAgencyDailyServiceImpl extends BaseServiceImpl<FactPartyMemberVanguardAgencyDailyDao, FactPartyMemberVanguardAgencyDailyEntity> implements FactPartyMemberVanguardAgencyDailyService {
@Override
public PageData<FactPartyMemberVanguardAgencyDailyDTO> page(Map<String, Object> params) {
IPage<FactPartyMemberVanguardAgencyDailyEntity> page = baseDao.selectPage(
getPage(params, FieldConstant.CREATED_TIME, false),
getWrapper(params)
);
return getPageData(page, FactPartyMemberVanguardAgencyDailyDTO.class);
}
@Override
public List<FactPartyMemberVanguardAgencyDailyDTO> list(Map<String, Object> params) {
List<FactPartyMemberVanguardAgencyDailyEntity> entityList = baseDao.selectList(getWrapper(params));
return ConvertUtils.sourceToTarget(entityList, FactPartyMemberVanguardAgencyDailyDTO.class);
}
private QueryWrapper<FactPartyMemberVanguardAgencyDailyEntity> getWrapper(Map<String, Object> params){
String id = (String)params.get(FieldConstant.ID_HUMP);
QueryWrapper<FactPartyMemberVanguardAgencyDailyEntity> wrapper = new QueryWrapper<>();
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id);
return wrapper;
}
@Override
public FactPartyMemberVanguardAgencyDailyDTO get(String id) {
FactPartyMemberVanguardAgencyDailyEntity entity = baseDao.selectById(id);
return ConvertUtils.sourceToTarget(entity, FactPartyMemberVanguardAgencyDailyDTO.class);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void save(FactPartyMemberVanguardAgencyDailyDTO dto) {
FactPartyMemberVanguardAgencyDailyEntity entity = ConvertUtils.sourceToTarget(dto, FactPartyMemberVanguardAgencyDailyEntity.class);
insert(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void update(FactPartyMemberVanguardAgencyDailyDTO dto) {
FactPartyMemberVanguardAgencyDailyEntity entity = ConvertUtils.sourceToTarget(dto, FactPartyMemberVanguardAgencyDailyEntity.class);
updateById(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void delete(String[] ids) {
// 逻辑删除(@TableLogic 注解)
baseDao.deleteBatchIds(Arrays.asList(ids));
}
/**
* 清除日数据
*
* @param customerId
* @param dateId
* @return void
* @author zhaoqifeng
* @date 2021/5/17 15:55
*/
@Override
@Transactional(rollbackFor = Exception.class)
public void deleteDailyData(String customerId, String dateId) {
baseDao.deleteDailyData(customerId, dateId);
}
}

118
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/impl/FactPartyMemberVanguardGridDailyServiceImpl.java

@ -0,0 +1,118 @@
/**
* Copyright 2018 人人开源 https://www.renren.io
* <p>
* 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.
* <p>
* 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.
* <p>
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.epmet.service.stats.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.epmet.commons.dynamic.datasource.annotation.DataSource;
import com.epmet.commons.mybatis.service.impl.BaseServiceImpl;
import com.epmet.commons.tools.constant.FieldConstant;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.constant.DataSourceConstant;
import com.epmet.dao.stats.FactPartyMemberVanguardGridDailyDao;
import com.epmet.dto.stats.FactPartyMemberVanguardGridDailyDTO;
import com.epmet.entity.stats.FactPartyMemberVanguardGridDailyEntity;
import com.epmet.service.stats.FactPartyMemberVanguardGridDailyService;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
/**
* 党员先锋-网格日统计数据
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-13
*/
@Service
@DataSource(DataSourceConstant.STATS)
public class FactPartyMemberVanguardGridDailyServiceImpl extends BaseServiceImpl<FactPartyMemberVanguardGridDailyDao, FactPartyMemberVanguardGridDailyEntity> implements FactPartyMemberVanguardGridDailyService {
@Override
public PageData<FactPartyMemberVanguardGridDailyDTO> page(Map<String, Object> params) {
IPage<FactPartyMemberVanguardGridDailyEntity> page = baseDao.selectPage(
getPage(params, FieldConstant.CREATED_TIME, false),
getWrapper(params)
);
return getPageData(page, FactPartyMemberVanguardGridDailyDTO.class);
}
@Override
public List<FactPartyMemberVanguardGridDailyDTO> list(Map<String, Object> params) {
List<FactPartyMemberVanguardGridDailyEntity> entityList = baseDao.selectList(getWrapper(params));
return ConvertUtils.sourceToTarget(entityList, FactPartyMemberVanguardGridDailyDTO.class);
}
private QueryWrapper<FactPartyMemberVanguardGridDailyEntity> getWrapper(Map<String, Object> params){
String id = (String)params.get(FieldConstant.ID_HUMP);
QueryWrapper<FactPartyMemberVanguardGridDailyEntity> wrapper = new QueryWrapper<>();
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id);
return wrapper;
}
@Override
public FactPartyMemberVanguardGridDailyDTO get(String id) {
FactPartyMemberVanguardGridDailyEntity entity = baseDao.selectById(id);
return ConvertUtils.sourceToTarget(entity, FactPartyMemberVanguardGridDailyDTO.class);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void save(FactPartyMemberVanguardGridDailyDTO dto) {
FactPartyMemberVanguardGridDailyEntity entity = ConvertUtils.sourceToTarget(dto, FactPartyMemberVanguardGridDailyEntity.class);
insert(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void update(FactPartyMemberVanguardGridDailyDTO dto) {
FactPartyMemberVanguardGridDailyEntity entity = ConvertUtils.sourceToTarget(dto, FactPartyMemberVanguardGridDailyEntity.class);
updateById(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void delete(String[] ids) {
// 逻辑删除(@TableLogic 注解)
baseDao.deleteBatchIds(Arrays.asList(ids));
}
/**
* 清除日数据
*
* @param customerId
* @param dateId
* @return void
* @author zhaoqifeng
* @date 2021/5/17 15:55
*/
@Override
@Transactional(rollbackFor = Exception.class)
public void deleteDailyData(String customerId, String dateId) {
baseDao.deleteDailyData(customerId, dateId);
}
}

26
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginGroupMainDailyDao.xml

@ -350,5 +350,31 @@
AND customer_id = #{customerId}
<![CDATA[AND DATE_ID <= #{dateId}]]>
</select>
<select id="selectPartyMemberGroupStaticByAgency" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
AGENCY_ID,
count( ID ) AS "sum",
sum(IF( IS_OWNER_PARTY = 1, 1, 0 )) AS "count"
FROM
fact_origin_group_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
AND (GROUP_STATE = 'approved' OR GROUP_STATE = 'hidden')
GROUP BY
AGENCY_ID
</select>
<select id="selectPartyMemberGroupStaticByGrid" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
GRID_ID AS "orgId",
count( ID ) AS "sum",
sum(IF( IS_OWNER_PARTY = 1, 1, 0 )) AS "count"
FROM
fact_origin_group_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
AND ( GROUP_STATE = 'approved' OR GROUP_STATE = 'hidden' )
GROUP BY
GRID_ID
</select>
</mapper>

44
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginGroupMemberDailyDao.xml

@ -27,6 +27,50 @@
<result property="updatedBy" column="UPDATED_BY"/>
<result property="updatedTime" column="UPDATED_TIME"/>
</resultMap>
<select id="selectGroupPartyMemberStaticByAgency" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
a.AGENCY_ID,
COUNT( DISTINCT MEMBER_ID ) AS "sum",
IFNULL( b.partyCount, 0 ) AS "count"
FROM
fact_origin_group_member_daily a
LEFT JOIN
(SELECT
AGENCY_ID,
COUNT( DISTINCT MEMBER_ID ) AS partyCount
FROM fact_origin_group_member_daily
WHERE IS_PARTY = 1
AND CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
GROUP BY AGENCY_ID
) b ON a.AGENCY_ID = b.AGENCY_ID
WHERE a.CUSTOMER_ID = #{customerId}
AND a.DATE_ID &lt;= #{dateId}
GROUP BY
a.AGENCY_ID
</select>
<select id="selectGroupPartyMemberStaticByGrid" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
a.GRID_ID AS "orgId",
COUNT( DISTINCT MEMBER_ID ) AS "sum",
IFNULL( b.partyCount, 0 ) AS "count"
FROM
fact_origin_group_member_daily a
LEFT JOIN
(SELECT
GRID_ID,
COUNT( DISTINCT MEMBER_ID ) AS partyCount
FROM fact_origin_group_member_daily
WHERE IS_PARTY = 1
AND CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
GROUP BY GRID_ID
) b ON a.GRID_ID = b.GRID_ID
WHERE a.CUSTOMER_ID = #{customerId}
AND a.DATE_ID &lt;= #{dateId}
GROUP BY
a.GRID_ID
</select>
</mapper>

20
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginIssueMainDailyDao.xml

@ -291,4 +291,24 @@
AND f.MONTH_ID = #{monthId}
GROUP BY f.AGENCY_ID
</select>
<select id="selectPartyMemberIssueStaticByAgency" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
AGENCY_ID,
COUNT(ID) AS "sum",
SUM(IF(IS_PARTY = 1 ,1, 0)) AS "count"
FROM fact_origin_issue_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
GROUP BY AGENCY_ID
</select>
<select id="selectPartyMemberIssueStaticByGrid" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
GRID_ID AS "orgId",
COUNT(ID) AS "sum",
SUM(IF(IS_PARTY = 1 ,1, 0)) AS "count"
FROM fact_origin_issue_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
GROUP BY GRID_ID
</select>
</mapper>

42
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginProjectMainDailyDao.xml

@ -761,5 +761,47 @@
WHERE CUSTOMER_ID = #{customerId}
AND DEL_FLAG = '0'
</select>
<select id="selectPartyMemberProjectStaticByAgency" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
AGENCY_ID,
COUNT(ID) AS "sum",
SUM(IF(IS_PARTY = 1 ,1, 0)) AS "count"
FROM fact_origin_project_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
GROUP BY AGENCY_ID
</select>
<select id="selectPartyMemberProjectStaticByGrid" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
GRID_ID AS "orgId",
COUNT(ID) AS "sum",
SUM(IF(IS_PARTY = 1 ,1, 0)) AS "count"
FROM fact_origin_project_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
GROUP BY GRID_ID
</select>
<select id="selectPartyMemberClosedProjectStaticByAgency" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
AGENCY_ID,
COUNT(ID) AS "sum",
SUM(IF(IS_PARTY = 1 ,1, 0)) AS "count"
FROM fact_origin_project_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
AND PROJECT_STATUS = 'closed'
GROUP BY AGENCY_ID
</select>
<select id="selectPartyMemberClosedProjectStaticByGrid" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
GRID_ID AS "orgId",
COUNT(ID) AS "sum",
SUM(IF(IS_PARTY = 1 ,1, 0)) AS "count"
FROM fact_origin_project_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
AND PROJECT_STATUS = 'closed'
GROUP BY GRID_ID
</select>
</mapper>

20
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginTopicMainDailyDao.xml

@ -177,4 +177,24 @@
AND f.MONTH_ID = #{monthId}
GROUP BY f.AGENCY_ID
</select>
<select id="selectPartyMemberTopicStaticByAgency" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
AGENCY_ID,
COUNT(ID) as "sum",
SUM(IF(CREATE_TOPIC_USER_IS_PARTY = 1 ,1, 0)) as "count"
FROM fact_origin_topic_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
GROUP BY AGENCY_ID
</select>
<select id="selectPartyMemberTopicStaticByGrid" resultType="com.epmet.dto.extract.result.OrgStatisticsResultDTO">
SELECT
GRID_ID AS "orgId",
COUNT(ID) as "sum",
SUM(IF(CREATE_TOPIC_USER_IS_PARTY = 1 ,1, 0)) as "count"
FROM fact_origin_topic_main_daily
WHERE CUSTOMER_ID = #{customerId}
AND DATE_ID &lt;= #{dateId}
GROUP BY GRID_ID
</select>
</mapper>

40
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/FactPartyMemberVanguardAgencyDailyDao.xml

@ -0,0 +1,40 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.epmet.dao.stats.FactPartyMemberVanguardAgencyDailyDao">
<resultMap type="com.epmet.entity.stats.FactPartyMemberVanguardAgencyDailyEntity" id="factPartyMemberVanguardAgencyDailyMap">
<result property="id" column="ID"/>
<result property="customerId" column="CUSTOMER_ID"/>
<result property="agencyId" column="AGENCY_ID"/>
<result property="pid" column="PID"/>
<result property="dateId" column="DATE_ID"/>
<result property="weekId" column="WEEK_ID"/>
<result property="monthId" column="MONTH_ID"/>
<result property="quarterId" column="QUARTER_ID"/>
<result property="yearId" column="YEAR_ID"/>
<result property="groupCount" column="GROUP_COUNT"/>
<result property="groupRatio" column="GROUP_RATIO"/>
<result property="groupMemberCount" column="GROUP_MEMBER_COUNT"/>
<result property="groupMemberRatio" column="GROUP_MEMBER_RATIO"/>
<result property="topicCount" column="TOPIC_COUNT"/>
<result property="topicRatio" column="TOPIC_RATIO"/>
<result property="issueCount" column="ISSUE_COUNT"/>
<result property="issueRatio" column="ISSUE_RATIO"/>
<result property="projectCount" column="PROJECT_COUNT"/>
<result property="projectRatio" column="PROJECT_RATIO"/>
<result property="projectClosedCount" column="PROJECT_CLOSED_COUNT"/>
<result property="projectClosedRatio" column="PROJECT_CLOSED_RATIO"/>
<result property="delFlag" column="DEL_FLAG"/>
<result property="revision" column="REVISION"/>
<result property="createdBy" column="CREATED_BY"/>
<result property="createdTime" column="CREATED_TIME"/>
<result property="updatedBy" column="UPDATED_BY"/>
<result property="updatedTime" column="UPDATED_TIME"/>
</resultMap>
<delete id="deleteDailyData">
delete from fact_party_member_vanguard_agency_daily where customer_id = #{customerId} and DATE_ID = #{dateId}
</delete>
</mapper>

40
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/FactPartyMemberVanguardGridDailyDao.xml

@ -0,0 +1,40 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.epmet.dao.stats.FactPartyMemberVanguardGridDailyDao">
<resultMap type="com.epmet.entity.stats.FactPartyMemberVanguardGridDailyEntity" id="factPartyMemberVanguardGridDailyMap">
<result property="id" column="ID"/>
<result property="customerId" column="CUSTOMER_ID"/>
<result property="agencyId" column="AGENCY_ID"/>
<result property="gridId" column="GRID_ID"/>
<result property="dateId" column="DATE_ID"/>
<result property="weekId" column="WEEK_ID"/>
<result property="monthId" column="MONTH_ID"/>
<result property="quarterId" column="QUARTER_ID"/>
<result property="yearId" column="YEAR_ID"/>
<result property="groupCount" column="GROUP_COUNT"/>
<result property="groupRatio" column="GROUP_RATIO"/>
<result property="groupMemberCount" column="GROUP_MEMBER_COUNT"/>
<result property="groupMemberRatio" column="GROUP_MEMBER_RATIO"/>
<result property="topicCount" column="TOPIC_COUNT"/>
<result property="topicRatio" column="TOPIC_RATIO"/>
<result property="issueCount" column="ISSUE_COUNT"/>
<result property="issueRatio" column="ISSUE_RATIO"/>
<result property="projectCount" column="PROJECT_COUNT"/>
<result property="projectRatio" column="PROJECT_RATIO"/>
<result property="projectClosedCount" column="PROJECT_CLOSED_COUNT"/>
<result property="projectClosedRatio" column="PROJECT_CLOSED_RATIO"/>
<result property="delFlag" column="DEL_FLAG"/>
<result property="revision" column="REVISION"/>
<result property="createdBy" column="CREATED_BY"/>
<result property="createdTime" column="CREATED_TIME"/>
<result property="updatedBy" column="UPDATED_BY"/>
<result property="updatedTime" column="UPDATED_TIME"/>
</resultMap>
<delete id="deleteDailyData">
delete from fact_party_member_vanguard_grid_daily where customer_id = #{customerId} and DATE_ID = #{dateId}
</delete>
</mapper>
Loading…
Cancel
Save