|
|
@ -15,6 +15,7 @@ import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.stereotype.Service; |
|
|
|
|
|
|
|
import java.math.BigDecimal; |
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Date; |
|
|
|
import java.util.List; |
|
|
|
import java.util.stream.Collectors; |
|
|
@ -38,6 +39,8 @@ public class AnScreenServiceImpl implements AnScreenService { |
|
|
|
private ScreenAnGrassRootsGovernMonthlyDao screenAnGrassRootsGovernMonthlyDao; |
|
|
|
@Autowired |
|
|
|
private ScreenAnCommunityProjectProfileDao screenAnCommunityProjectProfileDao; |
|
|
|
@Autowired |
|
|
|
private PartyMemberLeadServiceImpl partyMemberLeadServiceImpl; |
|
|
|
|
|
|
|
/** |
|
|
|
* 基层党员-各类总数 |
|
|
@ -65,7 +68,10 @@ public class AnScreenServiceImpl implements AnScreenService { |
|
|
|
@DataSource(value = DataSourceConstant.EVALUATION_INDEX,datasourceNameFromArg = true) |
|
|
|
public PmTotalTrendResultDTO pmTotalTrend(AnScreenTrendFormDTO formDTO) { |
|
|
|
PmTotalTrendResultDTO resultDTO = new PmTotalTrendResultDTO(); |
|
|
|
List<PmTotalTrendDTO> list = screenAnGrassRootsPmTotalMonthlyDao.selectPmTotalTrend(formDTO.getAgencyId(), formDTO.getMonthId()); |
|
|
|
String monthId = StringUtils.isNotBlank(formDTO.getMonthId()) ? formDTO.getMonthId() : DateUtils.format(new Date(), DateUtils.DATE_PATTERN_YYYYMM); |
|
|
|
String curDate = monthId.substring(0, 4) + "-" + monthId.substring(4, 6) + "-" + "01"; |
|
|
|
// 查询近一年的指数值【包括本月】
|
|
|
|
List<PmTotalTrendDTO> list = screenAnGrassRootsPmTotalMonthlyDao.selectPmTotalTrend(formDTO.getAgencyId(), curDate); |
|
|
|
List<String> xAxis = list.stream().map(item -> getMonth(item.getMonthId())).collect(Collectors.toList()); |
|
|
|
List<Integer> groupMemberTotalList = list.stream().map(PmTotalTrendDTO::getGroupMemberTotal).collect(Collectors.toList()); |
|
|
|
List<Integer> topicTotalList = list.stream().map(PmTotalTrendDTO::getTopicTotal).collect(Collectors.toList()); |
|
|
@ -123,8 +129,11 @@ public class AnScreenServiceImpl implements AnScreenService { |
|
|
|
@DataSource(value = DataSourceConstant.EVALUATION_INDEX,datasourceNameFromArg = true) |
|
|
|
public GrassRootsOrgTrendResultDTO grassRootsOrgTrend(AnScreenTrendFormDTO formDTO) { |
|
|
|
GrassRootsOrgTrendResultDTO resultDTO = new GrassRootsOrgTrendResultDTO(); |
|
|
|
String yearId = DateUtils.format(new Date(), DateUtils.DATE_PATTERN_YYYY); |
|
|
|
List<GrassRootsOrgTrendDTO> list = screenAnGrassRootsOrgMonthlyDao.selectGrassRootsOrgTrend(formDTO.getAgencyId(), yearId); |
|
|
|
|
|
|
|
String monthId = StringUtils.isNotBlank(formDTO.getMonthId()) ? formDTO.getMonthId() : DateUtils.format(new Date(), DateUtils.DATE_PATTERN_YYYYMM); |
|
|
|
String curDate = monthId.substring(0, 4) + "-" + monthId.substring(4, 6) + "-" + "01"; |
|
|
|
// 查询近一年的指数值【包括本月】
|
|
|
|
List<GrassRootsOrgTrendDTO> list = screenAnGrassRootsOrgMonthlyDao.selectGrassRootsOrgTrend(formDTO.getAgencyId(), curDate); |
|
|
|
List<String> xAxis = list.stream().map(item -> getMonth(item.getMonthId())).collect(Collectors.toList()); |
|
|
|
List<Integer> groupTotalList = list.stream().map(GrassRootsOrgTrendDTO::getGroupTotal).collect(Collectors.toList()); |
|
|
|
List<Integer> issueTotalList = list.stream().map(GrassRootsOrgTrendDTO::getIssueTotal).collect(Collectors.toList()); |
|
|
@ -176,8 +185,11 @@ public class AnScreenServiceImpl implements AnScreenService { |
|
|
|
@DataSource(value = DataSourceConstant.EVALUATION_INDEX,datasourceNameFromArg = true) |
|
|
|
public GrassRootsGovernTrendResultDTO grassRootsGovernTrend(AnScreenTrendFormDTO formDTO) { |
|
|
|
GrassRootsGovernTrendResultDTO resultDTO = new GrassRootsGovernTrendResultDTO(); |
|
|
|
String yearId = DateUtils.format(new Date(), DateUtils.DATE_PATTERN_YYYY); |
|
|
|
List<GrassRootsGovernTrendDTO> list = screenAnGrassRootsGovernMonthlyDao.selectGrassRootsGovernTrend(formDTO.getAgencyId(), yearId); |
|
|
|
|
|
|
|
String monthId = StringUtils.isNotBlank(formDTO.getMonthId()) ? formDTO.getMonthId() : DateUtils.format(new Date(), DateUtils.DATE_PATTERN_YYYYMM); |
|
|
|
String curDate = monthId.substring(0, 4) + "-" + monthId.substring(4, 6) + "-" + "01"; |
|
|
|
// 查询近一年的指数值【包括本月】
|
|
|
|
List<GrassRootsGovernTrendDTO> list = screenAnGrassRootsGovernMonthlyDao.selectGrassRootsGovernTrend(formDTO.getAgencyId(), curDate); |
|
|
|
List<String> xAxis = list.stream().map(item -> getMonth(item.getMonthId())).collect(Collectors.toList()); |
|
|
|
List<Integer> partiProjectTotalList = list.stream().map(GrassRootsGovernTrendDTO::getPartiProjectTotal).collect(Collectors.toList()); |
|
|
|
List<Integer> closedProjectTotalList = list.stream().map(GrassRootsGovernTrendDTO::getClosedProjectTotal).collect(Collectors.toList()); |
|
|
|