Browse Source

代码提交

全业务考评 1 year ago
parent
commit
9181796e66

+ 14 - 0
ims-service/ims-eval/src/main/java/com/ims/eval/service/impl/CiteCalculationIndicatorServiceImpl.java

@@ -3,6 +3,7 @@ package com.ims.eval.service.impl;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.ims.eval.cache.CacheContext;
 import com.ims.eval.config.CustomException;
 import com.ims.eval.entity.CiteCalculationIndicator;
 import com.ims.eval.dao.CiteCalculationIndicatorMapper;
@@ -12,6 +13,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.springframework.stereotype.Service;
 
 import java.util.List;
+import java.util.Map;
 
 /**
  * <p>
@@ -34,6 +36,18 @@ public class CiteCalculationIndicatorServiceImpl extends ServiceImpl<CiteCalcula
 		Page<Indicator> page = new Page<>(pageNum, pageSize);
 
 		IPage<CiteCalculationIndicator> list  = baseMapper.selectCiteCalculationIndicatorList(page,citeCalculationName,binSection);
+
+		list.getRecords().stream().forEach(i->{
+			StringBuilder binSectionName = new StringBuilder();
+			for(String key:CacheContext.bsnIdName.keySet()){
+
+				if(i.getBinSection().contains(key)){
+					binSectionName.append(CacheContext.bsnIdName.get(key)).append(",");
+				}
+			}
+			i.setBinSectionName(binSectionName.toString());
+		});
+
 		return list;
 	}
 

+ 18 - 8
ims-service/ims-eval/src/main/java/com/ims/eval/service/impl/EvaluateReportServiceImpl.java

@@ -93,7 +93,8 @@ public class EvaluateReportServiceImpl extends ServiceImpl<EvaluateReportMapper,
 		List<String> evaluationRuleIds = Arrays.asList(evaluationRuleId.split(","));
 
 		//获取所有当前考评配置所有权重单位
-		List<OrganizationEvaluationRule> ruleListall = organizationEvaluationRuleService.getOrganizationEvaluationRuleByIds(evaluationRuleIds, "");
+//		List<OrganizationEvaluationRule> ruleListall = organizationEvaluationRuleService.getOrganizationEvaluationRuleByIds(evaluationRuleIds, "");
+		List<OrganizationEvaluationRule> ruleListall = organizationEvaluationRuleService.listByIsCheck(evaluation.getOrganizationType(), evaluation.getCheckCycle(),evaluation.getYear(),true,false);
 
 		//按照组织id 分组
 		Map<String, OrganizationEvaluationRule> ruleMap = ruleListall.stream()
@@ -109,7 +110,9 @@ public class EvaluateReportServiceImpl extends ServiceImpl<EvaluateReportMapper,
 
 			reportName.append(evaluation.getYear()).append("年");
 			if ("NDKP".equals(evaluation.getCheckCycle())) {
-				if("FD".equals(bi.getSectionCode()) || "GD".equals(bi.getSectionCode())){
+				if("FD".equals(bi.getSectionCode()) || "GD".equals(bi.getSectionCode()) ||
+					"GLSX".equals(bi.getSectionCode()) || "KJCX".equals(bi.getSectionCode())||
+					"ZDZX".equals(bi.getSectionCode())){
 					continue;
 				}
 				des.append("年度");
@@ -119,13 +122,13 @@ public class EvaluateReportServiceImpl extends ServiceImpl<EvaluateReportMapper,
 			}
 			if ("JDKP".equals(evaluation.getCheckCycle())) {
 				des.append("季度");
+				month = evaluation.getMonth();
 				reportName.append(evaluation.getMonth()).append("季度-");
 				evaluateReport.setMonth(evaluation.getMonth());
 				if("XNYFG".equals(bi.getSectionCode()) || "ZHZC".equals(bi.getSectionCode())||
 					"GCGS".equals(bi.getSectionCode()) || "TJGS".equals(bi.getSectionCode())|
-					"GD".equals(bi.getSectionCode())){
-
-//					"QQ".equals(bi.getSectionCode()) || "JJ".equals(bi.getSectionCode())||
+					"GD".equals(bi.getSectionCode()) || "GLSX".equals(bi.getSectionCode()) ||
+					"KJCX".equals(bi.getSectionCode()) || "ZDZX".equals(bi.getSectionCode())){
 					continue;
 				}
 
@@ -134,7 +137,8 @@ public class EvaluateReportServiceImpl extends ServiceImpl<EvaluateReportMapper,
 				if("XNYFG".equals(bi.getSectionCode()) || "ZHZC".equals(bi.getSectionCode())||
 					"GCGS".equals(bi.getSectionCode()) || "TJGS".equals(bi.getSectionCode())||
 					"QQ".equals(bi.getSectionCode()) || "JJ".equals(bi.getSectionCode())||
-					"GD".equals(bi.getSectionCode())){
+					"GD".equals(bi.getSectionCode())|| "GLSX".equals(bi.getSectionCode()) ||
+					"KJCX".equals(bi.getSectionCode()) || "ZDZX".equals(bi.getSectionCode())){
 					continue;
 				}
 				des.append("月度");
@@ -216,12 +220,18 @@ public class EvaluateReportServiceImpl extends ServiceImpl<EvaluateReportMapper,
 
 
 				if ("JJ".equals(bi.getSectionCode()) || "QQ".equals(bi.getSectionCode())) {
-					if (("JJ".equals(bi.getSectionCode()) && rule.getJjWeight() < 0.75) || rule.getScjyWeight() > 0) {
+
+					if ( rule.getQqWeight() + rule.getJjWeight() < 1) {
 						continue;
 					}
-					if (("QQ".equals(bi.getSectionCode()) && rule.getQqWeight() < 0.25) || rule.getScjyWeight() > 0) {
+
+					if ("QQ".equals(bi.getSectionCode())  && rule.getJjWeight() == 1) {
 						continue;
 					}
+					if (("JJ".equals(bi.getSectionCode()) && rule.getJjWeight() < 1)) {
+						continue;
+					}
+
 				}
 
 				StringBuilder remark = new StringBuilder();

+ 0 - 1
ims-service/ims-eval/src/main/java/com/ims/eval/service/impl/IndicatorServiceImpl.java

@@ -105,7 +105,6 @@ public class IndicatorServiceImpl extends ServiceImpl<IndicatorMapper, Indicator
 
 	@Override
 	public List<Indicator> listAll(String id, String indicatorName, String indicatorCode, String binSection, String binStage, String dept, String company,String evaluationCycle) {
-		QueryWrapper<Indicator> qw = new QueryWrapper<>();
 		List<Indicator> list = baseMapper.seleclistAll(id, indicatorName, indicatorCode, binSection, binStage, dept, company,evaluationCycle);
 		return list;
 	}

+ 1 - 1
ims-service/ims-eval/src/main/java/com/ims/eval/service/impl/MultipleBrandServiceImpl.java

@@ -30,7 +30,7 @@ public class MultipleBrandServiceImpl extends ServiceImpl<MultipleBrandMapper, M
 	public IPage<MultipleBrand> getMultipleBranTree(Integer pageNum, Integer pageSize,String id, String parentId,String  binSection,String  checkCycle,String year,String month) {
 		Page<Indicator> page = new Page<>(pageNum, pageSize);
 		IPage<MultipleBrand> list  =  baseMapper.selectMultipleBranTree(page,id,"0",binSection,checkCycle,year,month);
-		List<MultipleBrand> list2  =  baseMapper.selectMultipleBranList(id,"",binSection,checkCycle,year,month);
+		List<MultipleBrand> list2  =  baseMapper.selectMultipleBranList(id,"","",checkCycle,year,month);
 
 		List<MultipleBrand> tree = convert(list.getRecords(),list2);
 		list.setRecords(tree);

+ 8 - 8
ims-service/ims-eval/src/main/java/com/ims/eval/service/impl/OrganizationEvaluationInfoServiceImpl.java

@@ -1070,14 +1070,14 @@ public class OrganizationEvaluationInfoServiceImpl extends ServiceImpl<Organizat
 				OrganizationEvaluationInfo info = this.getById(scoreid);
 				List<EvaluationScoreCount>  listcount = evaluatioinScoreCountService.getEvaluationScoreCountList(info.getOrganizationEvaluationId(),info.getOrganizationEvaluationRuleId(),info.getIndicatorId(),"");
 				if(null != listcount && listcount.size()>0){
-//					EvaluationScoreCount count = listcount.get(0);
-//					count.setJfScore(jfScore);
-//					count.setKfScore(kfScore);
-//					count.setJfRemark(jfRemark);
-//					count.setKfRemark(kfRemark);
-//					count.setScore(score);
-//					count.setObversionScore(score);
-//					evaluatioinScoreCountService.saveOrUpdate(count);
+					EvaluationScoreCount count = listcount.get(0);
+					count.setJfScore(jfScore);
+					count.setKfScore(kfScore);
+					count.setJfRemark(jfRemark);
+					count.setKfRemark(kfRemark);
+					count.setScore(score);
+					count.setObversionScore(score);
+					evaluatioinScoreCountService.saveOrUpdate(count);
 				}else {
 					calculationByEvaluationId("", info.getIndicatorId(),info.getOrganizationEvaluationId(),"");
 				}

+ 5 - 0
ims-service/ims-eval/src/main/java/com/ims/eval/service/impl/OrganizationEvaluationRuleServiceImpl.java

@@ -320,6 +320,11 @@ public class OrganizationEvaluationRuleServiceImpl extends ServiceImpl<Organizat
 			if (null != list && list.size() > 0) {
 				throw new CustomException("已存在同期考评配置");
 			}
+		}else{
+			OrganizationEvaluationRule orirule  = baseMapper.selectById(entity.getId());
+			if(null == entity.getOrganizationShortName() || "".equals(entity.getOrganizationShortName())){
+				entity.setOrganizationShortName(orirule.getOrganizationShortName());
+			}
 		}
 		//判断排序字段是否有值
 		if(null==entity.getOrderNum()){