1.季度审核节点删除无用的审核方法
2.季度审核获取项目列表增加时间倒序 3.结项编辑附件列表修改
This commit is contained in:
parent
d037ecc204
commit
0066572118
@ -153,6 +153,7 @@
|
|||||||
#{id}
|
#{id}
|
||||||
</foreach>
|
</foreach>
|
||||||
</if>
|
</if>
|
||||||
|
order by project_info.created_at desc
|
||||||
</select>
|
</select>
|
||||||
<select id="getInfoByProName" resultType="com.xqopen.kehui.project.entity.ProjectInfo"
|
<select id="getInfoByProName" resultType="com.xqopen.kehui.project.entity.ProjectInfo"
|
||||||
parameterType="java.lang.String">
|
parameterType="java.lang.String">
|
||||||
|
@ -17,7 +17,6 @@ import com.xqopen.kehui.personal.service.IPersonalMemberService;
|
|||||||
import com.xqopen.kehui.project.api.ProjectAssessmentIndicatorsApi;
|
import com.xqopen.kehui.project.api.ProjectAssessmentIndicatorsApi;
|
||||||
import com.xqopen.kehui.project.entity.ProjectAssessmentIndicators;
|
import com.xqopen.kehui.project.entity.ProjectAssessmentIndicators;
|
||||||
import com.xqopen.kehui.project.entity.ProjectInfo;
|
import com.xqopen.kehui.project.entity.ProjectInfo;
|
||||||
import com.xqopen.kehui.project.entity.ProjectQuarterlyEvaluation;
|
|
||||||
import com.xqopen.kehui.project.service.IProjectAssessmentIndicatorsService;
|
import com.xqopen.kehui.project.service.IProjectAssessmentIndicatorsService;
|
||||||
import com.xqopen.kehui.project.service.IProjectInfoService;
|
import com.xqopen.kehui.project.service.IProjectInfoService;
|
||||||
import com.xqopen.kehui.project.service.ProjectQuarterlyEvaluationService;
|
import com.xqopen.kehui.project.service.ProjectQuarterlyEvaluationService;
|
||||||
@ -32,7 +31,6 @@ import org.springframework.util.ObjectUtils;
|
|||||||
import org.springframework.util.StringUtils;
|
import org.springframework.util.StringUtils;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
import java.sql.Timestamp;
|
|
||||||
import java.text.DecimalFormat;
|
import java.text.DecimalFormat;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@ -433,73 +431,6 @@ public class ProjectAssessmentIndicatorsController implements ProjectAssessmentI
|
|||||||
indicatorsService.updateAllColumnBatchById(list);
|
indicatorsService.updateAllColumnBatchById(list);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 审核
|
|
||||||
*
|
|
||||||
* @param taskName
|
|
||||||
* @param ext
|
|
||||||
* @param role
|
|
||||||
* @param projectInfo
|
|
||||||
*/
|
|
||||||
public void examine(Long userId, String taskName, JSONObject ext, String role, ProjectInfo projectInfo) {
|
|
||||||
EntityWrapper<ProjectQuarterlyEvaluation> evaluationEntityWrapper = new EntityWrapper<>();
|
|
||||||
evaluationEntityWrapper.eq("project_id", String.valueOf(projectInfo.getId()));
|
|
||||||
evaluationEntityWrapper.eq("is_deleted", "0");
|
|
||||||
ProjectQuarterlyEvaluation quarterlyEvaluation = evaluationService.selectOne(evaluationEntityWrapper);
|
|
||||||
if (!ObjectUtils.isEmpty(quarterlyEvaluation)) {
|
|
||||||
JSONObject quarterlyEvaluationExt = quarterlyEvaluation.getExt();
|
|
||||||
String user = new String();
|
|
||||||
if (!"部门主任评级".equals(taskName)) {
|
|
||||||
user = String.valueOf(quarterlyEvaluationExt.get(role));
|
|
||||||
if ("流程结束".equals(taskName)) {
|
|
||||||
user = " ";
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
//如果节点是部门主任评级时,则当前责任人是四个业务部的部门主任
|
|
||||||
EntityWrapper<SystemOrg> orgEntityWrapper = new EntityWrapper<>();
|
|
||||||
orgEntityWrapper.andNew().eq("is_deleted", false);
|
|
||||||
orgEntityWrapper.andNew().eq("org_name", "战略规划部").or()
|
|
||||||
.eq("org_name", "平台建设部").or()
|
|
||||||
.eq("org_name", "市场发展部").or()
|
|
||||||
.eq("org_name", "服务产品部");
|
|
||||||
orgEntityWrapper.setSqlSelect("id_");
|
|
||||||
List<Object> objectList = orgService.selectObjs(orgEntityWrapper);//先拿到部门集合ids
|
|
||||||
if (!StringUtils.isEmpty(objectList)) {
|
|
||||||
// 使用Streams将Object集合转换为Long集合
|
|
||||||
List<Long> longs = objectList.stream()
|
|
||||||
.map(obj -> (Long) obj) // 强制类型转换
|
|
||||||
.collect(Collectors.toList());
|
|
||||||
EntityWrapper<FlowsConfiguration> flowsConfigurationEntityWrapper = new EntityWrapper<>();
|
|
||||||
flowsConfigurationEntityWrapper.eq("approved_role", "business");
|
|
||||||
flowsConfigurationEntityWrapper.eq("is_deleted", false);
|
|
||||||
flowsConfigurationEntityWrapper.in("org_id", longs);
|
|
||||||
flowsConfigurationEntityWrapper.setSqlSelect("approver_id");
|
|
||||||
List<Object> objectList1 = flowsConfigurationService.selectObjs(flowsConfigurationEntityWrapper);//拿到人事集合ids
|
|
||||||
longs = objectList1.stream()
|
|
||||||
.map(obj -> (Long) obj) // 强制类型转换
|
|
||||||
.collect(Collectors.toList());
|
|
||||||
EntityWrapper<SystemUserLogin> userLoginEntityWrapper = new EntityWrapper<>();
|
|
||||||
userLoginEntityWrapper.eq("is_deleted", false);
|
|
||||||
userLoginEntityWrapper.in("userinfo_id", longs);
|
|
||||||
userLoginEntityWrapper.setSqlSelect("string_agg(id_::text,',')");
|
|
||||||
user = String.valueOf(userLoginService.selectObj(userLoginEntityWrapper));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
quarterlyEvaluationExt.put("taskName", taskName);
|
|
||||||
quarterlyEvaluationExt.put("executor", user);
|
|
||||||
quarterlyEvaluation.setExt(quarterlyEvaluationExt);
|
|
||||||
quarterlyEvaluation.setUpdatedAt(new Timestamp(System.currentTimeMillis()));
|
|
||||||
quarterlyEvaluation.setUpdatedBy(String.valueOf(userId));
|
|
||||||
evaluationService.updateById(quarterlyEvaluation);
|
|
||||||
|
|
||||||
ext.put("taskName", taskName);
|
|
||||||
ext.put("executor", user);
|
|
||||||
projectInfo.setExt(ext);
|
|
||||||
projectInfoService.updateById(projectInfo);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private SystemUserLogin getSystemUserLogin(String name) {
|
private SystemUserLogin getSystemUserLogin(String name) {
|
||||||
SystemUserLogin systemUserLogin = new SystemUserLogin();
|
SystemUserLogin systemUserLogin = new SystemUserLogin();
|
||||||
if (!StringUtils.isEmpty(name)) {
|
if (!StringUtils.isEmpty(name)) {
|
||||||
|
@ -369,10 +369,7 @@ public class ProjectInitComtroller implements ProjectInitApi {
|
|||||||
String execution = String.valueOf(map.get("execution"));
|
String execution = String.valueOf(map.get("execution"));
|
||||||
if (!StringUtils.isEmpty(execution)) {
|
if (!StringUtils.isEmpty(execution)) {
|
||||||
ext.put("execution", execution);
|
ext.put("execution", execution);
|
||||||
ArrayList conclusionFile= (ArrayList) map.get("conclusionFile");
|
ext.put("conclusionFile",map.get("conclusionFile"));
|
||||||
if(!ObjectUtils.isEmpty(conclusionFile)){
|
|
||||||
ext.put("conclusionFile",conclusionFile);
|
|
||||||
}
|
|
||||||
if (infoService.updateById(projectInfo)) {
|
if (infoService.updateById(projectInfo)) {
|
||||||
return ApiResponse.fillSuccess("操作成功!");
|
return ApiResponse.fillSuccess("操作成功!");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user