Browse Source

Merge remote-tracking branch 'origin/dev_pyscreen' into dev

dev_shibei_match
zxc 5 years ago
parent
commit
ad20480bb0
  1. 1
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenCustomerAgencyDao.java
  2. 6
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateStreetServiceImpl.java
  3. 4
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/indexcal/CommunityScoreDao.xml
  4. 4
      epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenCustomerAgencyDao.xml

1
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenCustomerAgencyDao.java

@ -96,6 +96,7 @@ public interface ScreenCustomerAgencyDao extends BaseDao<ScreenCustomerAgencyEnt
*/
String selectPid(@Param("agencyId") String agencyId);
String selectParentId(@Param("agencyId") String agencyId);
String selectAgencyId(@Param("areaCode") String areaCode);
/**
* 返回当前客户下未匹配到的 街道区县级 组织信息

6
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/indexcal/impl/IndexCalculateStreetServiceImpl.java

@ -20,6 +20,7 @@ import com.epmet.dao.evaluationindex.indexcoll.FactIndexGovrnAblityOrgMonthlyDao
import com.epmet.dao.evaluationindex.indexcoll.FactIndexPartyAblityOrgMonthlyDao;
import com.epmet.dao.evaluationindex.indexcoll.FactIndexServiceAblityOrgMonthlyDao;
import com.epmet.dao.evaluationindex.screen.IndexGroupDetailDao;
import com.epmet.dao.evaluationindex.screen.ScreenCustomerAgencyDao;
import com.epmet.dto.indexcal.AgencyCalResultDTO;
import com.epmet.dto.indexcal.AgencyScoreDTO;
import com.epmet.dto.indexcal.CalculateCommonFormDTO;
@ -80,6 +81,8 @@ public class IndexCalculateStreetServiceImpl implements IndexCalculateStreetServ
private IndexGroupDetailDao indexGroupDetailDao;
@Autowired
private AgencySelfSubScoreDao agencySelfSubScoreDao;
@Autowired
private ScreenCustomerAgencyDao customerAgencyDao;
/**
* @param form
@ -623,6 +626,7 @@ public class IndexCalculateStreetServiceImpl implements IndexCalculateStreetServ
partition.forEach(publish -> {
List<SampleValue> index1SampleValues = new ArrayList<>();
publish.forEach(c -> {
c.setParentId(customerAgencyDao.selectAgencyId(form.getCustomerAreaCode()));
pid.put(c.getAgencyId(),c.getParentId());
SampleValue s = new SampleValue(c.getAgencyId(), c.getScore());
index1SampleValues.add(s);
@ -697,6 +701,7 @@ public class IndexCalculateStreetServiceImpl implements IndexCalculateStreetServ
governAvg.forEach(avg -> {
List<SampleValue> index1SampleValues = new ArrayList<>();
avg.forEach(c -> {
c.setParentId(customerAgencyDao.selectAgencyId(form.getCustomerAreaCode()));
pid.put(c.getAgencyId(),c.getParentId());
SampleValue s = new SampleValue(c.getAgencyId(), c.getScore());
index1SampleValues.add(s);
@ -772,6 +777,7 @@ public class IndexCalculateStreetServiceImpl implements IndexCalculateStreetServ
BigDecimalScoreCalculator sc1 = new BigDecimalScoreCalculator(maxAndMinBigDecimal.getMin(), maxAndMinBigDecimal.getMax(), ScoreConstants.MIN_SCORE, ScoreConstants.MAX_SCORE, Correlation.getCorrelation(detail.getCorrelation()));
List<SampleValue> index1SampleValues = new ArrayList<>();
serviceAvg.forEach(c -> {
c.setParentId(customerAgencyDao.selectAgencyId(form.getCustomerAreaCode()));
pid.put(c.getAgencyId(),c.getParentId());
SampleValue s = new SampleValue(c.getAgencyId(), c.getScore());
index1SampleValues.add(s);

4
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/indexcal/CommunityScoreDao.xml

@ -183,8 +183,8 @@
WHERE
fics.del_flag = '0'
AND sca.DEL_FLAG = 0
AND sca.AREA_CODE LIKE CONCAT(#{areaCode},'%')
AND sca.AREA_CODE != #{areaCode}
AND sca.AREA_CODE IN
(SELECT AREA_CODE FROM screen_customer_agency WHERE DEL_FLAG = '0' AND PARENT_AREA_CODE = #{areaCode})
AND fics.month_id = #{monthId}
AND fics.index_code = #{indexCode}
GROUP BY fics.parent_agency_id

4
epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenCustomerAgencyDao.xml

@ -412,4 +412,8 @@
where m.AGENCY_ID=#{agencyId}
)
</select>
<select id="selectAgencyId" resultType="java.lang.String">
select sca.AGENCY_ID from screen_customer_agency sca
where sca.AREA_CODE= #{areaCode}
</select>
</mapper>

Loading…
Cancel
Save