Browse Source

小组成员添加是否党员身份

dev_shibei_match
zhaoqifeng 4 years ago
parent
commit
827b66b4cc
  1. 146
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/FactOriginGroupMemberDailyDTO.java
  2. 187
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/stats/FactAgencyOriginProjectDailyDTO.java
  3. 172
      epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/stats/FactAgencyOriginProjectMonthlyDTO.java
  4. 4
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/FactOriginExtractController.java
  5. 33
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/extract/FactOriginGroupMemberDailyDao.java
  6. 33
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/FactAgencyOriginProjectDailyDao.java
  7. 33
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/FactAgencyOriginProjectMonthlyDao.java
  8. 116
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/evaluationindex/extract/FactOriginGroupMemberDailyEntity.java
  9. 157
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/stats/FactAgencyOriginProjectDailyEntity.java
  10. 142
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/stats/FactAgencyOriginProjectMonthlyEntity.java
  11. 3
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginGroupMainDailyService.java
  12. 95
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/FactOriginGroupMemberDailyService.java
  13. 18
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginGroupMainDailyServiceImpl.java
  14. 101
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/FactOriginGroupMemberDailyServiceImpl.java
  15. 7
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/todata/impl/GroupExtractServiceImpl.java
  16. 95
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/FactAgencyOriginProjectDailyService.java
  17. 95
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/FactAgencyOriginProjectMonthlyService.java
  18. 101
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/impl/FactAgencyOriginProjectDailyServiceImpl.java
  19. 101
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/impl/FactAgencyOriginProjectMonthlyServiceImpl.java
  20. 32
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/extract/FactOriginGroupMemberDailyDao.xml
  21. 40
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/FactAgencyOriginProjectDailyDao.xml
  22. 37
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/FactAgencyOriginProjectMonthlyDao.xml

146
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/extract/FactOriginGroupMemberDailyDTO.java

@ -0,0 +1,146 @@
/**
* 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.extract;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;
/**
*
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
@Data
public class FactOriginGroupMemberDailyDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 主键
*/
private String id;
/**
* 组Id
*/
private String groupId;
/**
* 小组所在的网格id
*/
private String gridId;
/**
* 小组所在的社区id
*/
private String agencyId;
/**
* 小组所在的街道id
*/
private String parentId;
/**
* 所有上级组织ID,英文:隔开
*/
private String pids;
/**
* 成员IduserId
*/
private String memberId;
/**
* 客户Id
*/
private String customerId;
/**
* leader(群主) member(成员)
*/
private String leaderFlag;
/**
* 入群审核通过或自动加入群的日期 yyyyMMdd
*/
private String dateId;
/**
* 入群周 2020W15
*/
private String weekId;
/**
* 入群月 202004
*/
private String monthId;
/**
* 入群季 2020Q2
*/
private String quarterId;
/**
* 入群年 2020
*/
private String yearId;
/**
* join入群群主建群自己入群也是join
*/
private String actionCode;
/**
* 是否是党员
*/
private Integer isParty;
/**
* 乐观锁
*/
private Integer revision;
/**
* 删除标识
*/
private String delFlag;
/**
*
*/
private String createdBy;
/**
*
*/
private Date createdTime;
/**
*
*/
private String updatedBy;
/**
*
*/
private Date updatedTime;
}

187
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/stats/FactAgencyOriginProjectDailyDTO.java

@ -0,0 +1,187 @@
/**
* 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-12
*/
@Data
public class FactAgencyOriginProjectDailyDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 唯一标识
*/
private String id;
/**
* 客户Id dim_customer.id
*/
private String customerId;
/**
* 机关Id dim_agency.id
*/
private String agencyId;
/**
* 上级组织Iddim_agency.pid
*/
private String parentId;
/**
* 日维度Id dim_date.id
*/
private String dateId;
/**
* 周维度Id dim_week.id
*/
private String weekId;
/**
* 月维度Id dim_month.id
*/
private String monthId;
/**
* 季度ID
*/
private String quarterId;
/**
* 年维度Id dim_year.id
*/
private String yearId;
/**
* 项目来源 来源议题issue 组织agency
*/
private String origin;
/**
* 截止当日项目总数 当前组织及下级项目总数
*/
private Integer projectTotal;
/**
* 截止当日处理中项目数 当前组织及下级所有未结案项目总数
*/
private Integer pendingTotal;
/**
* 截止当日处理中项目占比 当前组织及下级未结案项目百分比存百分比数小数点后两位
*/
private BigDecimal pendingRatio;
/**
* 截止当日已结案项目数 当前组织及下级已结案项目总数
*/
private Integer closedTotal;
/**
* 截止当日已结案项目占比 当前组织及下级已结案项目百分比存百分比数小数点后两位
*/
private BigDecimal closedRatio;
/**
* 截止当日已结案中已解决项目数 当前组织及下级已结案项目中已解决总数
*/
private Integer resolvedTotal;
/**
* 截止当日已结案中已解决项目占比 当前组织及下级已结案项目中已解决占比
*/
private BigDecimal resolvedRatio;
/**
* 截止当日已结案中未解决项目数 当前组织及下级已结案项目中未解决总数
*/
private Integer unresolvedTotal;
/**
* 截止当日已结案中未解决项目占比 当前组织及下级已结案项目中未解决占比
*/
private BigDecimal unresolvedRatio;
/**
* 当日项目总数 当前组织及下级项目总数
*/
private Integer projectIncr;
/**
* 当日处理中项目数 当前组织及下级前一日新增处理中项目数
*/
private Integer pendingIncr;
/**
* 当日已结案项目数 当前组织及下级前一日新增结案项目数
*/
private Integer closedIncr;
/**
* 当日已结案项目中已解决数 当前组织及下级前一日新增结案中已解决项目数
*/
private Integer resolvedIncr;
/**
* 当日已结案项目组未解决数 当前组织及下级前一日新增结案中未解决项目数
*/
private Integer unresolvedIncr;
/**
* 删除标识 0.未删除 1.已删除
*/
private Integer delFlag;
/**
* 乐观锁
*/
private Integer revision;
/**
* 创建人
*/
private String createdBy;
/**
* 创建时间
*/
private Date createdTime;
/**
* 更新人
*/
private String updatedBy;
/**
* 更新时间
*/
private Date updatedTime;
}

172
epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/stats/FactAgencyOriginProjectMonthlyDTO.java

@ -0,0 +1,172 @@
/**
* 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-12
*/
@Data
public class FactAgencyOriginProjectMonthlyDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 唯一标识
*/
private String id;
/**
* 客户Id dim_customer.id
*/
private String customerId;
/**
* 机关Id dim_agency.id
*/
private String agencyId;
/**
* 上级组织Iddim_agency.pid
*/
private String parentId;
/**
* 月维度Id dim_month.id
*/
private String monthId;
/**
* 季维度Id dim_quarter.id
*/
private String quarterId;
/**
* 年维度Id dim_year.id
*/
private String yearId;
/**
* 截止当月项目总数 当前组织及下级项目总数
*/
private Integer projectTotal;
/**
* 截止当月处理中项目数 当前组织及下级所有未结案项目总数
*/
private Integer pendingTotal;
/**
* 截止当月处理中项目占比 当前组织及下级未结案项目百分比存百分比数小数点后两位
*/
private BigDecimal pendingRatio;
/**
* 截止当月已结案项目数 当前组织及下级已结案项目总数
*/
private Integer closedTotal;
/**
* 截止当月已结案项目占比 当前组织及下级已结案项目百分比存百分比数小数点后两位
*/
private BigDecimal closedRatio;
/**
* 截止当月已结案中已解决项目数 当前组织及下级已结案项目中已解决总数
*/
private Integer resolvedTotal;
/**
* 截止当月已结案中已解决项目占比 当前组织及下级已结案项目中已解决占比
*/
private BigDecimal resolvedRatio;
/**
* 截止当月已结案中未解决项目数 当前组织及下级已结案项目中未解决总数
*/
private Integer unresolvedTotal;
/**
* 截止当月已结案中未解决项目占比 当前组织及下级已结案项目中未解决占比
*/
private BigDecimal unresolvedRatio;
/**
* 当月项目总数 当前组织及下级前一月新增项目数
*/
private Integer projectIncr;
/**
* 当月处理中项目数 当前组织及下级前一月新增处理中项目数
*/
private Integer pendingIncr;
/**
* 当月已结案项目数 当前组织及下级前一月新增结案项目数
*/
private Integer closedIncr;
/**
* 当月已结案项目中已解决数 当前组织及下级前一日新增结案中已解决项目数
*/
private Integer resolvedIncr;
/**
* 当月已结案项目组未解决数 当前组织及下级前一日新增结案中未解决项目数
*/
private Integer unresolvedIncr;
/**
* 删除标识 0.未删除 1.已删除
*/
private Integer delFlag;
/**
* 乐观锁
*/
private Integer revision;
/**
* 创建人
*/
private String createdBy;
/**
* 创建时间
*/
private Date createdTime;
/**
* 更新人
*/
private String updatedBy;
/**
* 更新时间
*/
private Date updatedTime;
}

4
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/FactOriginExtractController.java

@ -126,7 +126,9 @@ public class FactOriginExtractController {
paramNew.setDateId(dateDimId);
groupExtractService.extractGroupData(paramNew);
}
}else groupExtractService.extractGroupData(param);
}else {
groupExtractService.extractGroupData(param);
}
return new Result();
}
}

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

@ -0,0 +1,33 @@
/**
* 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.evaluationindex.extract;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.entity.evaluationindex.extract.FactOriginGroupMemberDailyEntity;
import org.apache.ibatis.annotations.Mapper;
/**
*
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
@Mapper
public interface FactOriginGroupMemberDailyDao extends BaseDao<FactOriginGroupMemberDailyEntity> {
}

33
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/FactAgencyOriginProjectDailyDao.java

@ -0,0 +1,33 @@
/**
* 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.FactAgencyOriginProjectDailyEntity;
import org.apache.ibatis.annotations.Mapper;
/**
* 机关下日项目数据统计 存放机关下截止到当前日期的各项总数据以及昨日新增各项数据每日定时执行先删后增
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
@Mapper
public interface FactAgencyOriginProjectDailyDao extends BaseDao<FactAgencyOriginProjectDailyEntity> {
}

33
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/FactAgencyOriginProjectMonthlyDao.java

@ -0,0 +1,33 @@
/**
* 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.FactAgencyOriginProjectMonthlyEntity;
import org.apache.ibatis.annotations.Mapper;
/**
* 机关下月项目数据统计 存放机关下截止到当前月份的各项总数据以及上月新增各项数据每月月初定时执行先删后增
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
@Mapper
public interface FactAgencyOriginProjectMonthlyDao extends BaseDao<FactAgencyOriginProjectMonthlyEntity> {
}

116
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/evaluationindex/extract/FactOriginGroupMemberDailyEntity.java

@ -0,0 +1,116 @@
/**
* 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.evaluationindex.extract;
import com.baomidou.mybatisplus.annotation.TableName;
import com.epmet.commons.mybatis.entity.BaseEpmetEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.Date;
/**
*
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
@Data
@EqualsAndHashCode(callSuper=false)
@TableName("fact_origin_group_member_daily")
public class FactOriginGroupMemberDailyEntity extends BaseEpmetEntity {
private static final long serialVersionUID = 1L;
/**
* 组Id
*/
private String groupId;
/**
* 小组所在的网格id
*/
private String gridId;
/**
* 小组所在的社区id
*/
private String agencyId;
/**
* 小组所在的街道id
*/
private String parentId;
/**
* 所有上级组织ID,英文:隔开
*/
private String pids;
/**
* 成员IduserId
*/
private String memberId;
/**
* 客户Id
*/
private String customerId;
/**
* leader(群主) member(成员)
*/
private String leaderFlag;
/**
* 入群审核通过或自动加入群的日期 yyyyMMdd
*/
private String dateId;
/**
* 入群周 2020W15
*/
private String weekId;
/**
* 入群月 202004
*/
private String monthId;
/**
* 入群季 2020Q2
*/
private String quarterId;
/**
* 入群年 2020
*/
private String yearId;
/**
* join入群群主建群自己入群也是join
*/
private String actionCode;
/**
* 是否是党员
*/
private Integer isParty;
}

157
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/stats/FactAgencyOriginProjectDailyEntity.java

@ -0,0 +1,157 @@
/**
* 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-12
*/
@Data
@EqualsAndHashCode(callSuper=false)
@TableName("fact_agency_origin_project_daily")
public class FactAgencyOriginProjectDailyEntity extends BaseEpmetEntity {
private static final long serialVersionUID = 1L;
/**
* 客户Id dim_customer.id
*/
private String customerId;
/**
* 机关Id dim_agency.id
*/
private String agencyId;
/**
* 上级组织Iddim_agency.pid
*/
private String parentId;
/**
* 日维度Id dim_date.id
*/
private String dateId;
/**
* 周维度Id dim_week.id
*/
private String weekId;
/**
* 月维度Id dim_month.id
*/
private String monthId;
/**
* 季度ID
*/
private String quarterId;
/**
* 年维度Id dim_year.id
*/
private String yearId;
/**
* 项目来源 来源议题issue 组织agency
*/
private String origin;
/**
* 截止当日项目总数 当前组织及下级项目总数
*/
private Integer projectTotal;
/**
* 截止当日处理中项目数 当前组织及下级所有未结案项目总数
*/
private Integer pendingTotal;
/**
* 截止当日处理中项目占比 当前组织及下级未结案项目百分比存百分比数小数点后两位
*/
private BigDecimal pendingRatio;
/**
* 截止当日已结案项目数 当前组织及下级已结案项目总数
*/
private Integer closedTotal;
/**
* 截止当日已结案项目占比 当前组织及下级已结案项目百分比存百分比数小数点后两位
*/
private BigDecimal closedRatio;
/**
* 截止当日已结案中已解决项目数 当前组织及下级已结案项目中已解决总数
*/
private Integer resolvedTotal;
/**
* 截止当日已结案中已解决项目占比 当前组织及下级已结案项目中已解决占比
*/
private BigDecimal resolvedRatio;
/**
* 截止当日已结案中未解决项目数 当前组织及下级已结案项目中未解决总数
*/
private Integer unresolvedTotal;
/**
* 截止当日已结案中未解决项目占比 当前组织及下级已结案项目中未解决占比
*/
private BigDecimal unresolvedRatio;
/**
* 当日项目总数 当前组织及下级项目总数
*/
private Integer projectIncr;
/**
* 当日处理中项目数 当前组织及下级前一日新增处理中项目数
*/
private Integer pendingIncr;
/**
* 当日已结案项目数 当前组织及下级前一日新增结案项目数
*/
private Integer closedIncr;
/**
* 当日已结案项目中已解决数 当前组织及下级前一日新增结案中已解决项目数
*/
private Integer resolvedIncr;
/**
* 当日已结案项目组未解决数 当前组织及下级前一日新增结案中未解决项目数
*/
private Integer unresolvedIncr;
}

142
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/entity/stats/FactAgencyOriginProjectMonthlyEntity.java

@ -0,0 +1,142 @@
/**
* 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-12
*/
@Data
@EqualsAndHashCode(callSuper=false)
@TableName("fact_agency_origin_project_monthly")
public class FactAgencyOriginProjectMonthlyEntity extends BaseEpmetEntity {
private static final long serialVersionUID = 1L;
/**
* 客户Id dim_customer.id
*/
private String customerId;
/**
* 机关Id dim_agency.id
*/
private String agencyId;
/**
* 上级组织Iddim_agency.pid
*/
private String parentId;
/**
* 月维度Id dim_month.id
*/
private String monthId;
/**
* 季维度Id dim_quarter.id
*/
private String quarterId;
/**
* 年维度Id dim_year.id
*/
private String yearId;
/**
* 截止当月项目总数 当前组织及下级项目总数
*/
private Integer projectTotal;
/**
* 截止当月处理中项目数 当前组织及下级所有未结案项目总数
*/
private Integer pendingTotal;
/**
* 截止当月处理中项目占比 当前组织及下级未结案项目百分比存百分比数小数点后两位
*/
private BigDecimal pendingRatio;
/**
* 截止当月已结案项目数 当前组织及下级已结案项目总数
*/
private Integer closedTotal;
/**
* 截止当月已结案项目占比 当前组织及下级已结案项目百分比存百分比数小数点后两位
*/
private BigDecimal closedRatio;
/**
* 截止当月已结案中已解决项目数 当前组织及下级已结案项目中已解决总数
*/
private Integer resolvedTotal;
/**
* 截止当月已结案中已解决项目占比 当前组织及下级已结案项目中已解决占比
*/
private BigDecimal resolvedRatio;
/**
* 截止当月已结案中未解决项目数 当前组织及下级已结案项目中未解决总数
*/
private Integer unresolvedTotal;
/**
* 截止当月已结案中未解决项目占比 当前组织及下级已结案项目中未解决占比
*/
private BigDecimal unresolvedRatio;
/**
* 当月项目总数 当前组织及下级前一月新增项目数
*/
private Integer projectIncr;
/**
* 当月处理中项目数 当前组织及下级前一月新增处理中项目数
*/
private Integer pendingIncr;
/**
* 当月已结案项目数 当前组织及下级前一月新增结案项目数
*/
private Integer closedIncr;
/**
* 当月已结案项目中已解决数 当前组织及下级前一日新增结案中已解决项目数
*/
private Integer resolvedIncr;
/**
* 当月已结案项目组未解决数 当前组织及下级前一日新增结案中未解决项目数
*/
private Integer unresolvedIncr;
}

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

@ -64,7 +64,8 @@ public interface FactOriginGroupMainDailyService extends BaseService<FactOriginG
* @author wangc
* @date 2020.09.23 16:30
**/
boolean insertExtractedData(boolean isFirst, String customerId, String dateId, List<FactOriginGroupMainDailyDTO> originGroupData, List<ExtractGroupMemberActionRecordResultDTO> memberList, List<String> missing);
boolean insertExtractedData(boolean isFirst, String customerId, String dateId, List<FactOriginGroupMainDailyDTO> originGroupData,
List<ExtractGroupMemberActionRecordResultDTO> memberList, List<String> missing, List<String> partyIds);
/**
* @param customerId

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

@ -0,0 +1,95 @@
/**
* 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.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.entity.evaluationindex.extract.FactOriginGroupMemberDailyEntity;
import java.util.List;
import java.util.Map;
/**
*
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
public interface FactOriginGroupMemberDailyService extends BaseService<FactOriginGroupMemberDailyEntity> {
/**
* 默认分页
*
* @param params
* @return PageData<FactOriginGroupMemberDailyDTO>
* @author generator
* @date 2021-05-12
*/
PageData<FactOriginGroupMemberDailyDTO> page(Map<String, Object> params);
/**
* 默认查询
*
* @param params
* @return java.util.List<FactOriginGroupMemberDailyDTO>
* @author generator
* @date 2021-05-12
*/
List<FactOriginGroupMemberDailyDTO> list(Map<String, Object> params);
/**
* 单条查询
*
* @param id
* @return FactOriginGroupMemberDailyDTO
* @author generator
* @date 2021-05-12
*/
FactOriginGroupMemberDailyDTO get(String id);
/**
* 默认保存
*
* @param dto
* @return void
* @author generator
* @date 2021-05-12
*/
void save(FactOriginGroupMemberDailyDTO dto);
/**
* 默认更新
*
* @param dto
* @return void
* @author generator
* @date 2021-05-12
*/
void update(FactOriginGroupMemberDailyDTO dto);
/**
* 批量删除
*
* @param ids
* @return void
* @author generator
* @date 2021-05-12
*/
void delete(String[] ids);
}

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

@ -18,15 +18,21 @@
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.dao.evaluationindex.extract.FactOriginGroupMainDailyDao;
import com.epmet.dao.evaluationindex.extract.FactOriginGroupMemberDailyDao;
import com.epmet.dto.extract.FactOriginGroupMainDailyDTO;
import com.epmet.dto.extract.form.ScreenPartyLinkMassesDataFormDTO;
import com.epmet.dto.extract.result.GridGroupUserCountResultDTO;
import com.epmet.dto.extract.result.OrgStatisticsResultDTO;
import com.epmet.dto.group.result.ExtractGroupMemberActionRecordResultDTO;
import com.epmet.entity.evaluationindex.extract.FactOriginGroupMainDailyEntity;
import com.epmet.entity.evaluationindex.extract.FactOriginGroupMemberDailyEntity;
import com.epmet.service.evaluationindex.extract.todata.FactOriginGroupMainDailyService;
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;
@ -45,6 +51,8 @@ import java.util.stream.Collectors;
@Service
public class FactOriginGroupMainDailyServiceImpl extends BaseServiceImpl<FactOriginGroupMainDailyDao, FactOriginGroupMainDailyEntity> implements FactOriginGroupMainDailyService {
@Autowired
private FactOriginGroupMemberDailyService factOriginGroupMemberDailyService;
/**
* @return java.util.List<java.lang.String>
@ -84,7 +92,7 @@ public class FactOriginGroupMainDailyServiceImpl extends BaseServiceImpl<FactOri
**/
@Override
@Transactional(rollbackFor = Exception.class)
public boolean insertExtractedData(boolean isFirst, String customerId, String dateId,List<FactOriginGroupMainDailyDTO> originGroupData, List<ExtractGroupMemberActionRecordResultDTO> memberList,List<String> missing) {
public boolean insertExtractedData(boolean isFirst, String customerId, String dateId,List<FactOriginGroupMainDailyDTO> originGroupData, List<ExtractGroupMemberActionRecordResultDTO> memberList,List<String> missing, List<String> partyIds) {
if(!CollectionUtils.isEmpty(originGroupData)) {
if (isFirst) {
//isFirst
@ -96,9 +104,15 @@ public class FactOriginGroupMainDailyServiceImpl extends BaseServiceImpl<FactOri
}
//删除要插入的组主表数据
baseDao.deleteBatchByGroupId(customerId, originGroupData.stream().map(FactOriginGroupMainDailyDTO::getId).distinct().collect(Collectors.toList()));
List<FactOriginGroupMemberDailyEntity> members = ConvertUtils.sourceToTarget(memberList, FactOriginGroupMemberDailyEntity.class);
members.forEach(item -> {
if (partyIds.contains(item.getMemberId())) {
item.setIsParty(NumConstant.ONE);
}
});
baseDao.insertBatchMain(originGroupData);
baseDao.insertBatchMembers(memberList);
factOriginGroupMemberDailyService.insertBatch(members);
}
if(!CollectionUtils.isEmpty(missing)){
baseDao.deleteBatchByGroupId(customerId,missing);

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

@ -0,0 +1,101 @@
/**
* 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.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.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.commons.tools.constant.FieldConstant;
import com.epmet.dao.evaluationindex.extract.FactOriginGroupMemberDailyDao;
import com.epmet.dto.extract.FactOriginGroupMemberDailyDTO;
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 java.util.Arrays;
import java.util.List;
import java.util.Map;
/**
*
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
@Service
public class FactOriginGroupMemberDailyServiceImpl extends BaseServiceImpl<FactOriginGroupMemberDailyDao, FactOriginGroupMemberDailyEntity> implements FactOriginGroupMemberDailyService {
@Override
public PageData<FactOriginGroupMemberDailyDTO> page(Map<String, Object> params) {
IPage<FactOriginGroupMemberDailyEntity> page = baseDao.selectPage(
getPage(params, FieldConstant.CREATED_TIME, false),
getWrapper(params)
);
return getPageData(page, FactOriginGroupMemberDailyDTO.class);
}
@Override
public List<FactOriginGroupMemberDailyDTO> list(Map<String, Object> params) {
List<FactOriginGroupMemberDailyEntity> entityList = baseDao.selectList(getWrapper(params));
return ConvertUtils.sourceToTarget(entityList, FactOriginGroupMemberDailyDTO.class);
}
private QueryWrapper<FactOriginGroupMemberDailyEntity> getWrapper(Map<String, Object> params){
String id = (String)params.get(FieldConstant.ID_HUMP);
QueryWrapper<FactOriginGroupMemberDailyEntity> wrapper = new QueryWrapper<>();
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id);
return wrapper;
}
@Override
public FactOriginGroupMemberDailyDTO get(String id) {
FactOriginGroupMemberDailyEntity entity = baseDao.selectById(id);
return ConvertUtils.sourceToTarget(entity, FactOriginGroupMemberDailyDTO.class);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void save(FactOriginGroupMemberDailyDTO dto) {
FactOriginGroupMemberDailyEntity entity = ConvertUtils.sourceToTarget(dto, FactOriginGroupMemberDailyEntity.class);
insert(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void update(FactOriginGroupMemberDailyDTO dto) {
FactOriginGroupMemberDailyEntity entity = ConvertUtils.sourceToTarget(dto, FactOriginGroupMemberDailyEntity.class);
updateById(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void delete(String[] ids) {
// 逻辑删除(@TableLogic 注解)
baseDao.deleteBatchIds(Arrays.asList(ids));
}
}

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

@ -89,7 +89,7 @@ public class GroupExtractServiceImpl implements GroupExtractService {
List<ExtractGroupMemberActionRecordResultDTO> memberList = new LinkedList<>();
if (!CollectionUtils.isEmpty(originGroupData)) {
List<GridAttributesResultDTO> gridList = dimGridService.getGridAttributes(param.getCustomerId(),null);
List<String> partyIds = userService.getPartymembersByCustomerId(param.getCustomerId());
if (!CollectionUtils.isEmpty(gridList)) {
Map<String, GridAttributesResultDTO> gridMap =
gridList.stream().collect(Collectors.toMap(GridAttributesResultDTO::getGridId, Function.identity(), (key1, key2) -> key2));
@ -166,14 +166,13 @@ public class GroupExtractServiceImpl implements GroupExtractService {
param.getDateId(),
originGroupData,
memberList,
missingGroups
missingGroups,
partyIds
);
}
List<String> partyIds = userService.getPartymembersByCustomerId(param.getCustomerId());
List<GridHeartedFormDTO> heartedIds = userService.getWarmHeartedByCustomerId(param.getCustomerId());
if(!partyIds.isEmpty()) {
factOriginGroupMainDailyDao.updatePartyFlag(partyIds, param.getCustomerId());

95
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/FactAgencyOriginProjectDailyService.java

@ -0,0 +1,95 @@
/**
* 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.FactAgencyOriginProjectDailyDTO;
import com.epmet.entity.stats.FactAgencyOriginProjectDailyEntity;
import java.util.List;
import java.util.Map;
/**
* 机关下日项目数据统计 存放机关下截止到当前日期的各项总数据以及昨日新增各项数据每日定时执行先删后增
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
public interface FactAgencyOriginProjectDailyService extends BaseService<FactAgencyOriginProjectDailyEntity> {
/**
* 默认分页
*
* @param params
* @return PageData<FactAgencyOriginProjectDailyDTO>
* @author generator
* @date 2021-05-12
*/
PageData<FactAgencyOriginProjectDailyDTO> page(Map<String, Object> params);
/**
* 默认查询
*
* @param params
* @return java.util.List<FactAgencyOriginProjectDailyDTO>
* @author generator
* @date 2021-05-12
*/
List<FactAgencyOriginProjectDailyDTO> list(Map<String, Object> params);
/**
* 单条查询
*
* @param id
* @return FactAgencyOriginProjectDailyDTO
* @author generator
* @date 2021-05-12
*/
FactAgencyOriginProjectDailyDTO get(String id);
/**
* 默认保存
*
* @param dto
* @return void
* @author generator
* @date 2021-05-12
*/
void save(FactAgencyOriginProjectDailyDTO dto);
/**
* 默认更新
*
* @param dto
* @return void
* @author generator
* @date 2021-05-12
*/
void update(FactAgencyOriginProjectDailyDTO dto);
/**
* 批量删除
*
* @param ids
* @return void
* @author generator
* @date 2021-05-12
*/
void delete(String[] ids);
}

95
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/FactAgencyOriginProjectMonthlyService.java

@ -0,0 +1,95 @@
/**
* 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.FactAgencyOriginProjectMonthlyDTO;
import com.epmet.entity.stats.FactAgencyOriginProjectMonthlyEntity;
import java.util.List;
import java.util.Map;
/**
* 机关下月项目数据统计 存放机关下截止到当前月份的各项总数据以及上月新增各项数据每月月初定时执行先删后增
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
public interface FactAgencyOriginProjectMonthlyService extends BaseService<FactAgencyOriginProjectMonthlyEntity> {
/**
* 默认分页
*
* @param params
* @return PageData<FactAgencyOriginProjectMonthlyDTO>
* @author generator
* @date 2021-05-12
*/
PageData<FactAgencyOriginProjectMonthlyDTO> page(Map<String, Object> params);
/**
* 默认查询
*
* @param params
* @return java.util.List<FactAgencyOriginProjectMonthlyDTO>
* @author generator
* @date 2021-05-12
*/
List<FactAgencyOriginProjectMonthlyDTO> list(Map<String, Object> params);
/**
* 单条查询
*
* @param id
* @return FactAgencyOriginProjectMonthlyDTO
* @author generator
* @date 2021-05-12
*/
FactAgencyOriginProjectMonthlyDTO get(String id);
/**
* 默认保存
*
* @param dto
* @return void
* @author generator
* @date 2021-05-12
*/
void save(FactAgencyOriginProjectMonthlyDTO dto);
/**
* 默认更新
*
* @param dto
* @return void
* @author generator
* @date 2021-05-12
*/
void update(FactAgencyOriginProjectMonthlyDTO dto);
/**
* 批量删除
*
* @param ids
* @return void
* @author generator
* @date 2021-05-12
*/
void delete(String[] ids);
}

101
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/impl/FactAgencyOriginProjectDailyServiceImpl.java

@ -0,0 +1,101 @@
/**
* 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.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.dao.stats.FactAgencyOriginProjectDailyDao;
import com.epmet.dto.stats.FactAgencyOriginProjectDailyDTO;
import com.epmet.entity.stats.FactAgencyOriginProjectDailyEntity;
import com.epmet.service.stats.FactAgencyOriginProjectDailyService;
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.util.Arrays;
import java.util.List;
import java.util.Map;
/**
* 机关下日项目数据统计 存放机关下截止到当前日期的各项总数据以及昨日新增各项数据每日定时执行先删后增
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
@Service
public class FactAgencyOriginProjectDailyServiceImpl extends BaseServiceImpl<FactAgencyOriginProjectDailyDao, FactAgencyOriginProjectDailyEntity> implements FactAgencyOriginProjectDailyService {
@Override
public PageData<FactAgencyOriginProjectDailyDTO> page(Map<String, Object> params) {
IPage<FactAgencyOriginProjectDailyEntity> page = baseDao.selectPage(
getPage(params, FieldConstant.CREATED_TIME, false),
getWrapper(params)
);
return getPageData(page, FactAgencyOriginProjectDailyDTO.class);
}
@Override
public List<FactAgencyOriginProjectDailyDTO> list(Map<String, Object> params) {
List<FactAgencyOriginProjectDailyEntity> entityList = baseDao.selectList(getWrapper(params));
return ConvertUtils.sourceToTarget(entityList, FactAgencyOriginProjectDailyDTO.class);
}
private QueryWrapper<FactAgencyOriginProjectDailyEntity> getWrapper(Map<String, Object> params){
String id = (String)params.get(FieldConstant.ID_HUMP);
QueryWrapper<FactAgencyOriginProjectDailyEntity> wrapper = new QueryWrapper<>();
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id);
return wrapper;
}
@Override
public FactAgencyOriginProjectDailyDTO get(String id) {
FactAgencyOriginProjectDailyEntity entity = baseDao.selectById(id);
return ConvertUtils.sourceToTarget(entity, FactAgencyOriginProjectDailyDTO.class);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void save(FactAgencyOriginProjectDailyDTO dto) {
FactAgencyOriginProjectDailyEntity entity = ConvertUtils.sourceToTarget(dto, FactAgencyOriginProjectDailyEntity.class);
insert(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void update(FactAgencyOriginProjectDailyDTO dto) {
FactAgencyOriginProjectDailyEntity entity = ConvertUtils.sourceToTarget(dto, FactAgencyOriginProjectDailyEntity.class);
updateById(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void delete(String[] ids) {
// 逻辑删除(@TableLogic 注解)
baseDao.deleteBatchIds(Arrays.asList(ids));
}
}

101
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/impl/FactAgencyOriginProjectMonthlyServiceImpl.java

@ -0,0 +1,101 @@
/**
* 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.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.dao.stats.FactAgencyOriginProjectMonthlyDao;
import com.epmet.dto.stats.FactAgencyOriginProjectMonthlyDTO;
import com.epmet.entity.stats.FactAgencyOriginProjectMonthlyEntity;
import com.epmet.service.stats.FactAgencyOriginProjectMonthlyService;
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.util.Arrays;
import java.util.List;
import java.util.Map;
/**
* 机关下月项目数据统计 存放机关下截止到当前月份的各项总数据以及上月新增各项数据每月月初定时执行先删后增
*
* @author generator generator@elink-cn.com
* @since v1.0.0 2021-05-12
*/
@Service
public class FactAgencyOriginProjectMonthlyServiceImpl extends BaseServiceImpl<FactAgencyOriginProjectMonthlyDao, FactAgencyOriginProjectMonthlyEntity> implements FactAgencyOriginProjectMonthlyService {
@Override
public PageData<FactAgencyOriginProjectMonthlyDTO> page(Map<String, Object> params) {
IPage<FactAgencyOriginProjectMonthlyEntity> page = baseDao.selectPage(
getPage(params, FieldConstant.CREATED_TIME, false),
getWrapper(params)
);
return getPageData(page, FactAgencyOriginProjectMonthlyDTO.class);
}
@Override
public List<FactAgencyOriginProjectMonthlyDTO> list(Map<String, Object> params) {
List<FactAgencyOriginProjectMonthlyEntity> entityList = baseDao.selectList(getWrapper(params));
return ConvertUtils.sourceToTarget(entityList, FactAgencyOriginProjectMonthlyDTO.class);
}
private QueryWrapper<FactAgencyOriginProjectMonthlyEntity> getWrapper(Map<String, Object> params){
String id = (String)params.get(FieldConstant.ID_HUMP);
QueryWrapper<FactAgencyOriginProjectMonthlyEntity> wrapper = new QueryWrapper<>();
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id);
return wrapper;
}
@Override
public FactAgencyOriginProjectMonthlyDTO get(String id) {
FactAgencyOriginProjectMonthlyEntity entity = baseDao.selectById(id);
return ConvertUtils.sourceToTarget(entity, FactAgencyOriginProjectMonthlyDTO.class);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void save(FactAgencyOriginProjectMonthlyDTO dto) {
FactAgencyOriginProjectMonthlyEntity entity = ConvertUtils.sourceToTarget(dto, FactAgencyOriginProjectMonthlyEntity.class);
insert(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void update(FactAgencyOriginProjectMonthlyDTO dto) {
FactAgencyOriginProjectMonthlyEntity entity = ConvertUtils.sourceToTarget(dto, FactAgencyOriginProjectMonthlyEntity.class);
updateById(entity);
}
@Override
@Transactional(rollbackFor = Exception.class)
public void delete(String[] ids) {
// 逻辑删除(@TableLogic 注解)
baseDao.deleteBatchIds(Arrays.asList(ids));
}
}

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

@ -0,0 +1,32 @@
<?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.evaluationindex.extract.FactOriginGroupMemberDailyDao">
<resultMap type="com.epmet.entity.evaluationindex.extract.FactOriginGroupMemberDailyEntity" id="factOriginGroupMemberDailyMap">
<result property="id" column="ID"/>
<result property="groupId" column="GROUP_ID"/>
<result property="gridId" column="GRID_ID"/>
<result property="agencyId" column="AGENCY_ID"/>
<result property="parentId" column="PARENT_ID"/>
<result property="pids" column="PIDS"/>
<result property="memberId" column="MEMBER_ID"/>
<result property="customerId" column="CUSTOMER_ID"/>
<result property="leaderFlag" column="LEADER_FLAG"/>
<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="actionCode" column="ACTION_CODE"/>
<result property="isParty" column="IS_PARTY"/>
<result property="revision" column="REVISION"/>
<result property="delFlag" column="DEL_FLAG"/>
<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>
</mapper>

40
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/FactAgencyOriginProjectDailyDao.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.FactAgencyOriginProjectDailyDao">
<resultMap type="com.epmet.entity.stats.FactAgencyOriginProjectDailyEntity" id="factAgencyOriginProjectDailyMap">
<result property="id" column="ID"/>
<result property="customerId" column="CUSTOMER_ID"/>
<result property="agencyId" column="AGENCY_ID"/>
<result property="parentId" column="PARENT_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="origin" column="ORIGIN"/>
<result property="projectTotal" column="PROJECT_TOTAL"/>
<result property="pendingTotal" column="PENDING_TOTAL"/>
<result property="pendingRatio" column="PENDING_RATIO"/>
<result property="closedTotal" column="CLOSED_TOTAL"/>
<result property="closedRatio" column="CLOSED_RATIO"/>
<result property="resolvedTotal" column="RESOLVED_TOTAL"/>
<result property="resolvedRatio" column="RESOLVED_RATIO"/>
<result property="unresolvedTotal" column="UNRESOLVED_TOTAL"/>
<result property="unresolvedRatio" column="UNRESOLVED_RATIO"/>
<result property="projectIncr" column="PROJECT_INCR"/>
<result property="pendingIncr" column="PENDING_INCR"/>
<result property="closedIncr" column="CLOSED_INCR"/>
<result property="resolvedIncr" column="RESOLVED_INCR"/>
<result property="unresolvedIncr" column="UNRESOLVED_INCR"/>
<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>
</mapper>

37
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/FactAgencyOriginProjectMonthlyDao.xml

@ -0,0 +1,37 @@
<?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.FactAgencyOriginProjectMonthlyDao">
<resultMap type="com.epmet.entity.stats.FactAgencyOriginProjectMonthlyEntity" id="factAgencyOriginProjectMonthlyMap">
<result property="id" column="ID"/>
<result property="customerId" column="CUSTOMER_ID"/>
<result property="agencyId" column="AGENCY_ID"/>
<result property="parentId" column="PARENT_ID"/>
<result property="monthId" column="MONTH_ID"/>
<result property="quarterId" column="QUARTER_ID"/>
<result property="yearId" column="YEAR_ID"/>
<result property="projectTotal" column="PROJECT_TOTAL"/>
<result property="pendingTotal" column="PENDING_TOTAL"/>
<result property="pendingRatio" column="PENDING_RATIO"/>
<result property="closedTotal" column="CLOSED_TOTAL"/>
<result property="closedRatio" column="CLOSED_RATIO"/>
<result property="resolvedTotal" column="RESOLVED_TOTAL"/>
<result property="resolvedRatio" column="RESOLVED_RATIO"/>
<result property="unresolvedTotal" column="UNRESOLVED_TOTAL"/>
<result property="unresolvedRatio" column="UNRESOLVED_RATIO"/>
<result property="projectIncr" column="PROJECT_INCR"/>
<result property="pendingIncr" column="PENDING_INCR"/>
<result property="closedIncr" column="CLOSED_INCR"/>
<result property="resolvedIncr" column="RESOLVED_INCR"/>
<result property="unresolvedIncr" column="UNRESOLVED_INCR"/>
<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>
</mapper>
Loading…
Cancel
Save