diff --git a/src/main/java/com/lz/modules/app/controller/ResultRecordController.java b/src/main/java/com/lz/modules/app/controller/ResultRecordController.java index 95d696ed..4f51d89e 100644 --- a/src/main/java/com/lz/modules/app/controller/ResultRecordController.java +++ b/src/main/java/com/lz/modules/app/controller/ResultRecordController.java @@ -254,6 +254,7 @@ public class ResultRecordController extends AbstractController { list.add(resultDetailService.getWenHuaJiaZhiGuaResult2()); list.add(resultDetailService.getLastResult(resultRecord.getLastScore())); List comments = resultCommentService.selectByRecordId(resultRecord.getId()); + if (CollectionUtils.isNotEmpty(comments)) { ResultDetailResp header = new ResultDetailResp(); header.setCheckRange("领导"); @@ -966,13 +967,10 @@ public class ResultRecordController extends AbstractController { } - - - /** * 删除 */ - // 审批:http://localhost:8080/lz_management/user/lzresultrecord/new/approval?resultRecordId=267&status=1&comment=xxx&menuName=bbb + // 审批:http://localhost:8080/lz_management/user/lzresultrecord/new/approval?resultRecordId=215&status=1&comment=xxx&menuName=bbb // 跳过:http://localhost:8080/lz_management/user/lzresultrecord/new/approval?resultRecordId=215&status=4&menuName=bbb&flowRecordId=360 // 转交:http://localhost:8080/lz_management/user/lzresultrecord/new/approval?resultRecordId=215&status=8&menuName=bbb&flowRecordId=360&transferStaffId=294 @RequestMapping("/new/approval") @@ -990,7 +988,7 @@ public class ResultRecordController extends AbstractController { /** * 删除 */ - // http://localhost:8080/lz_management/user/lzresultrecord/new/resultRecordDetail?resultRecordId=322&loginUserId=313 + // http://localhost:8080/lz_management/user/lzresultrecord/new/resultRecordDetail?resultRecordId=331&loginUserId=825 @RequestMapping("/new/resultRecordDetail") public R newResultRecordList(RecordDetailDto recordDetailDto) { if(recordDetailDto.getLoginUserId() ==null && getUser() !=null ){ diff --git a/src/main/java/com/lz/modules/app/resp/FlowDetailResp.java b/src/main/java/com/lz/modules/app/resp/FlowDetailResp.java index a463ed2d..14c1225a 100644 --- a/src/main/java/com/lz/modules/app/resp/FlowDetailResp.java +++ b/src/main/java/com/lz/modules/app/resp/FlowDetailResp.java @@ -8,5 +8,6 @@ public class FlowDetailResp { private String staffName; private Long flowRecordId; private String departName; + private String avatar; } diff --git a/src/main/java/com/lz/modules/flow/entity/FlowRecord.java b/src/main/java/com/lz/modules/flow/entity/FlowRecord.java index f8a77c5f..f5c4a71f 100644 --- a/src/main/java/com/lz/modules/flow/entity/FlowRecord.java +++ b/src/main/java/com/lz/modules/flow/entity/FlowRecord.java @@ -68,6 +68,9 @@ public class FlowRecord implements java.io.Serializable { //flow_manager表中id @ApiModelProperty(value = "flow_manager表中id", name = "processId") private Long processId; + //当前是目标确认还是评分,0,目标制定,1,目标确认,2执行中,3,结果值录入,4,评分,5考核结束 + @ApiModelProperty(value = "当前是目标确认还是评分,0,目标制定,1,目标确认,2执行中,3,结果值录入,4,评分,5考核结束", name = "flowProcess") + private Integer flowProcess; /** * * @return @@ -323,6 +326,21 @@ public class FlowRecord implements java.io.Serializable { this.processId = processId; } + /** + * 当前是目标确认还是评分,0,目标制定,1,目标确认,2执行中,3,结果值录入,4,评分,5考核结束 + * @return + */ + public Integer getFlowProcess() { + return flowProcess; + } + /** + * 当前是目标确认还是评分,0,目标制定,1,目标确认,2执行中,3,结果值录入,4,评分,5考核结束 + * @param flowProcess + */ + public void setFlowProcess(Integer flowProcess) { + this.flowProcess = flowProcess; + } + @Override public String toString() { return "FlowRecord{" + @@ -343,6 +361,7 @@ public class FlowRecord implements java.io.Serializable { ",statusName=" + statusName + ",type=" + type + ",processId=" + processId + + ",flowProcess=" + flowProcess + "}"; } } \ No newline at end of file diff --git a/src/main/java/com/lz/modules/sys/entity/app/ResultComment.java b/src/main/java/com/lz/modules/sys/entity/app/ResultComment.java index d9eff989..e0e6d0d2 100644 --- a/src/main/java/com/lz/modules/sys/entity/app/ResultComment.java +++ b/src/main/java/com/lz/modules/sys/entity/app/ResultComment.java @@ -1,4 +1,5 @@ package com.lz.modules.sys.entity.app; +import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.IdType; @@ -6,6 +7,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import java.util.Date; +import java.util.List; + /** *

*

*业绩评论表 @@ -50,6 +53,10 @@ public class ResultComment implements java.io.Serializable { //操作名称 @ApiModelProperty(value = "操作名称", name = "optDesc") private String optDesc; + + + @TableField(exist=false) + private String avatar; /** * * @return diff --git a/src/main/java/com/lz/modules/sys/service/app/impl/ResultRecordServiceImpl.java b/src/main/java/com/lz/modules/sys/service/app/impl/ResultRecordServiceImpl.java index bd11b42d..0f218852 100644 --- a/src/main/java/com/lz/modules/sys/service/app/impl/ResultRecordServiceImpl.java +++ b/src/main/java/com/lz/modules/sys/service/app/impl/ResultRecordServiceImpl.java @@ -3,7 +3,6 @@ package com.lz.modules.sys.service.app.impl; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; -import com.dingtalk.api.response.OapiDepartmentListResponse; import com.lz.common.emun.WorkMsgTypeEnum; import com.lz.common.exception.RRException; import com.lz.common.utils.*; @@ -802,6 +801,7 @@ public class ResultRecordServiceImpl extends ServiceImpl flowDetailRespList = new ArrayList<>(); mySetFlowDetailRespList(flowDetailRespList,flowRecord); - resp.setFlowDetailRespList(flowDetailRespList); flowRecordList.add(resp); flowIndex = flowRecord.getFlowIndex(); } + boolean flag = true; + for(FlowRecordResp flowRecordResp : flowRecordList) { + if (flowRecordResp.getStatus() == 0) { + flag = false; + break; + } + } FlowRecordResp end = new FlowRecordResp(); end.setFlowName("结束"); + end.setStatus(flag ? 1 : 0); flowRecordList.add(end); List resultCommentList = resultCommentService.selectByRecordId(recordDetailDto.getResultRecordId()); + for(ResultComment resultComment:resultCommentList){ + StaffEntity staffEntity = staffService.selectStaffById(resultComment.getStaffId()); + resultComment.setAvatar(staffEntity.getAvatar()); + } Map auth = new HashMap<>(); + auth.put("showScore",1); + auth.put("showResult",1); List currentResultRecords = flowRecordService.selectFlowRecordByRecordIdStatus(recordDetailDto.getResultRecordId(),2); if(currentResultRecords !=null && currentResultRecords.size() > 0 ){ FlowRecord currentResultRecord = null; @@ -1159,7 +1173,9 @@ public class ResultRecordServiceImpl extends ServiceImpl - select * from lz_result_comment where record_id=#{recordId} and is_delete = 0 + select * from lz_result_comment where record_id=#{recordId} and is_delete = 0 order by id desc