Browse Source

党员数据抽取

dev_shibei_match
zxc 5 years ago
parent
commit
27c543b9cc
  1. 3
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/user/FactParticipationUserGridDailyDao.java
  2. 8
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/toscreen/impl/PartyBaseInfoServiceImpl.java
  3. 3
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/user/FactParticipationUserGridDailyService.java
  4. 5
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/user/impl/FactParticipationUserGridDailyServiceImpl.java
  5. 1
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/user/FactParticipationUserGridDailyDao.xml

3
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/stats/user/FactParticipationUserGridDailyDao.java

@ -43,9 +43,8 @@ public interface FactParticipationUserGridDailyDao extends BaseDao<FactParticipa
/** /**
* @Description 查询网格下用户信息 * @Description 查询网格下用户信息
* @param customerId * @param customerId
* @param dateId
* @author zxc * @author zxc
* @date 2020/9/23 9:57 上午 * @date 2020/9/23 9:57 上午
*/ */
List<UserCountResultDTO> selectUserCount(String customerId, String dateId); List<UserCountResultDTO> selectUserCount(String customerId);
} }

8
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/toscreen/impl/PartyBaseInfoServiceImpl.java

@ -8,7 +8,6 @@ import com.epmet.service.evaluationindex.screen.ScreenCpcBaseDataService;
import com.epmet.service.evaluationindex.screen.ScreenCustomerAgencyService; import com.epmet.service.evaluationindex.screen.ScreenCustomerAgencyService;
import com.epmet.service.evaluationindex.screen.ScreenCustomerGridService; import com.epmet.service.evaluationindex.screen.ScreenCustomerGridService;
import com.epmet.service.stats.DimCustomerPartymemberService; import com.epmet.service.stats.DimCustomerPartymemberService;
import com.epmet.service.stats.user.FactParticipationUserAgencyDailyService;
import com.epmet.service.stats.user.FactParticipationUserGridDailyService; import com.epmet.service.stats.user.FactParticipationUserGridDailyService;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.ListUtils; import org.apache.commons.collections4.ListUtils;
@ -45,8 +44,6 @@ public class PartyBaseInfoServiceImpl implements PartyBaseInfoService {
@Autowired @Autowired
private FactParticipationUserGridDailyService userGridDailyService; private FactParticipationUserGridDailyService userGridDailyService;
@Autowired @Autowired
private FactParticipationUserAgencyDailyService userAgencyDailyService;
@Autowired
private ScreenCpcBaseDataService cpcBaseDataService; private ScreenCpcBaseDataService cpcBaseDataService;
/** /**
@ -104,7 +101,6 @@ public class PartyBaseInfoServiceImpl implements PartyBaseInfoService {
List<PartyBaseInfoFormDTO> result = new ArrayList<>(); List<PartyBaseInfoFormDTO> result = new ArrayList<>();
if (isGrid == true){ if (isGrid == true){
// 是 community 级别,子级为gridId // 是 community 级别,子级为gridId
List<UserCountResultDTO> userCountList = userGridDailyService.selectUserCount(customerId, dateId);
agencyIdList.forEach(agency -> { agencyIdList.forEach(agency -> {
GridPartyDTO gridPartyDTO = gridParty(customerId, dateId, agency); GridPartyDTO gridPartyDTO = gridParty(customerId, dateId, agency);
result.addAll(gridPartyDTO.getResult()); result.addAll(gridPartyDTO.getResult());
@ -142,7 +138,7 @@ public class PartyBaseInfoServiceImpl implements PartyBaseInfoService {
}else { }else {
// 级别为 street,district,city,province // 级别为 street,district,city,province
List<GridInfoResultDTO> directGridIds = gridService.selectDirectGrid(orgIds); List<GridInfoResultDTO> directGridIds = gridService.selectDirectGrid(orgIds);
List<UserCountResultDTO> userCountList = userGridDailyService.selectUserCount(customerId, dateId); List<UserCountResultDTO> userCountList = userGridDailyService.selectUserCount(customerId);
agencyIdList.forEach(agency -> { agencyIdList.forEach(agency -> {
String agencyId = agency.getAgencyId(); String agencyId = agency.getAgencyId();
List<String> dGridId = new ArrayList<>(); List<String> dGridId = new ArrayList<>();
@ -334,7 +330,7 @@ public class PartyBaseInfoServiceImpl implements PartyBaseInfoService {
public GridPartyDTO gridParty(String customerId,String dateId,CustomerAgencyInfoResultDTO agency){ public GridPartyDTO gridParty(String customerId,String dateId,CustomerAgencyInfoResultDTO agency){
List<PartyBaseInfoFormDTO> result = new ArrayList<>(); List<PartyBaseInfoFormDTO> result = new ArrayList<>();
List<String> orgIds = new ArrayList<>(); List<String> orgIds = new ArrayList<>();
List<UserCountResultDTO> userCountList = userGridDailyService.selectUserCount(customerId, dateId); List<UserCountResultDTO> userCountList = userGridDailyService.selectUserCount(customerId);
// 1. 处理社区下的所有网格中的党员信息 // 1. 处理社区下的所有网格中的党员信息
String agencyId = agency.getAgencyId(); String agencyId = agency.getAgencyId();
// 获取下级所有agencyId【根据agencyMap中的level判断下级orgId是否是gridId】(此处直接作为gridId) // 获取下级所有agencyId【根据agencyMap中的level判断下级orgId是否是gridId】(此处直接作为gridId)

3
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/user/FactParticipationUserGridDailyService.java

@ -98,9 +98,8 @@ public interface FactParticipationUserGridDailyService extends BaseService<FactP
/** /**
* @Description 查询网格下用户信息 * @Description 查询网格下用户信息
* @param customerId * @param customerId
* @param dateId
* @author zxc * @author zxc
* @date 2020/9/23 9:57 上午 * @date 2020/9/23 9:57 上午
*/ */
List<UserCountResultDTO> selectUserCount(String customerId,String dateId); List<UserCountResultDTO> selectUserCount(String customerId);
} }

5
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/stats/user/impl/FactParticipationUserGridDailyServiceImpl.java

@ -103,13 +103,12 @@ public class FactParticipationUserGridDailyServiceImpl extends BaseServiceImpl<F
/** /**
* @Description 查询网格下用户信息 * @Description 查询网格下用户信息
* @param customerId * @param customerId
* @param dateId
* @author zxc * @author zxc
* @date 2020/9/23 9:57 上午 * @date 2020/9/23 9:57 上午
*/ */
@Override @Override
public List<UserCountResultDTO> selectUserCount(String customerId, String dateId) { public List<UserCountResultDTO> selectUserCount(String customerId) {
return baseDao.selectUserCount(customerId, dateId); return baseDao.selectUserCount(customerId);
} }
} }

1
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/stats/user/FactParticipationUserGridDailyDao.xml

@ -118,7 +118,6 @@
fact_participation_user_grid_daily fact_participation_user_grid_daily
WHERE DEL_FLAG = '0' WHERE DEL_FLAG = '0'
AND CUSTOMER_ID = #{customerId} AND CUSTOMER_ID = #{customerId}
AND DATE_ID = #{dateId}
</select> </select>

Loading…
Cancel
Save