Kaynağa Gözat

业绩对标管理修改

hlf 1 yıl önce
ebeveyn
işleme
69f72abed9

+ 9 - 3
ims-service/ims-eval/src/main/java/com/ims/eval/service/impl/PerformanceBenchmarkInfoServiceImpl.java

@@ -170,7 +170,7 @@ public class PerformanceBenchmarkInfoServiceImpl extends ServiceImpl<Performance
 		if (benchmarkingRecordList.size() == 0) {
 			String zq = checkCycle;
 			List<PerformanceBenchmarkInfo> performanceBenchmarkInfoList = new ArrayList<>();
-			if ("YDKP".equals(checkCycle)){
+			if ("YDKP".equals(checkCycle)) {
 				checkCycle = "JDKP";
 			}
 			EvaluateRule evaluateRule = evaluateRuleService.getEvaluateRuleListByYear(String.valueOf(degreeYear), checkCycle, manageCategory);
@@ -184,8 +184,14 @@ public class PerformanceBenchmarkInfoServiceImpl extends ServiceImpl<Performance
 						//实际完成值
 						IndicatorDictionary wcz = indicatorDictionaryList.stream().filter(p -> p.getOptionCode().equals("WCZ")).findFirst().orElse(null);
 						if (jhz != null && wcz != null) {
-							List<OrganizationEvaluationInfo> jhzList = organizationEvaluationInfoService.getOrganizationEvaluationInfoListByIndicatorDictionaryId(jhz.getId(), String.valueOf(degreeYear), String.valueOf(quarterlyMonth));
-							List<OrganizationEvaluationInfo> wczList = organizationEvaluationInfoService.getOrganizationEvaluationInfoListByIndicatorDictionaryId(wcz.getId(), String.valueOf(degreeYear), String.valueOf(quarterlyMonth));
+							String qm;
+							if (null != quarterlyMonth) {
+								qm = String.valueOf(quarterlyMonth);
+							} else {
+								qm = "";
+							}
+							List<OrganizationEvaluationInfo> jhzList = organizationEvaluationInfoService.getOrganizationEvaluationInfoListByIndicatorDictionaryId(jhz.getId(), String.valueOf(degreeYear), qm);
+							List<OrganizationEvaluationInfo> wczList = organizationEvaluationInfoService.getOrganizationEvaluationInfoListByIndicatorDictionaryId(wcz.getId(), String.valueOf(degreeYear), qm);
 							if (jhzList.size() == wczList.size()) {
 								for (int i = 0; i < wczList.size(); i++) {
 									OrganizationEvaluationInfo jhzObj = jhzList.get(i);

+ 3 - 3
ims-service/ims-eval/src/main/resources/mappers/OrganizationEvaluationInfoMapper.xml

@@ -416,13 +416,13 @@
         left join unit_install_capacity uic on uic.unit_id = oei.organization_id
         <where>
             oei.is_quantified = 't'
-            <if test="indicatorDictionaryId != null and indicatorDictionaryId != '' ">
+            <if test="indicatorDictionaryId != null and indicatorDictionaryId != ''">
                 and oei.indicator_dictionary_id = #{indicatorDictionaryId}
             </if>
-            <if test="degreeYear != null and degreeYear != '' ">
+            <if test="degreeYear != null and degreeYear != ''">
                 and oe.year = #{degreeYear}
             </if>
-            <if test="quarterlyMonth != null and quarterlyMonth != '' and quarterlyMonth != 'null' ">
+            <if test="quarterlyMonth != null and quarterlyMonth != ''">
                 and oe.month = #{quarterlyMonth}
             </if>
         </where>