更新部分代码
This commit is contained in:
parent
32861dc01f
commit
e6ba9b1635
38
src/main/java/com/lz/common/emun/ChartOptType.java
Normal file
38
src/main/java/com/lz/common/emun/ChartOptType.java
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
package com.lz.common.emun;
|
||||||
|
|
||||||
|
public enum ChartOptType {
|
||||||
|
|
||||||
|
SELF(-1, "考核人自己"),
|
||||||
|
APPOINT(0, "指定人员"),
|
||||||
|
MANAGER_1(1, "一级管理人员"),
|
||||||
|
MANAGER_2(2, "二级管理人员"),
|
||||||
|
MANAGER_3(3, "三级管理人员"),
|
||||||
|
MANAGER_4(4, "四级管理人员"),
|
||||||
|
MANAGER_5(5, "五级管理人员"),
|
||||||
|
MANAGER_6(6, "六级管理人员"),
|
||||||
|
MANAGER_7(7, "七级管理人员"),
|
||||||
|
;
|
||||||
|
|
||||||
|
ChartOptType(int code, String name){
|
||||||
|
this.code = code;
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
private int code;
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
public int getCode() {
|
||||||
|
return code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCode(int code) {
|
||||||
|
this.code = code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getName() {
|
||||||
|
return name;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setName(String name) {
|
||||||
|
this.name = name;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -80,4 +80,6 @@ public interface StaffDao extends BaseMapper<StaffEntity> {
|
|||||||
List<StaffEntity> selectAll();
|
List<StaffEntity> selectAll();
|
||||||
|
|
||||||
List<ReportProgressListDto> getPositionByStaffIds(@Param("req") ReportListReq req, @Param("staffIds") List<String> staffIds, @Param("page") IPage page);
|
List<ReportProgressListDto> getPositionByStaffIds(@Param("req") ReportListReq req, @Param("staffIds") List<String> staffIds, @Param("page") IPage page);
|
||||||
|
|
||||||
|
List<StaffSimpleDto> selectStaffSimpleInfoByIds(@Param("ids") List<Long> ids);
|
||||||
}
|
}
|
||||||
|
|||||||
39
src/main/java/com/lz/modules/app/dto/StaffSimpleDto.java
Normal file
39
src/main/java/com/lz/modules/app/dto/StaffSimpleDto.java
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
package com.lz.modules.app.dto;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 员工基本信息
|
||||||
|
*
|
||||||
|
* @author fumeiai
|
||||||
|
* @email fumeiai@linzikg.com
|
||||||
|
* @date 2020-04-29 20:59:20
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@ApiModel("人员简单信息Dto")
|
||||||
|
public class StaffSimpleDto implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 员工Id
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "员工id", name = "id")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 员工姓名
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "姓名", name = "name")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 职位
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "职位", name = "position")
|
||||||
|
private String position;
|
||||||
|
|
||||||
|
}
|
||||||
@ -3,10 +3,7 @@ package com.lz.modules.app.service;
|
|||||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
import com.lz.common.utils.PageUtils;
|
import com.lz.common.utils.PageUtils;
|
||||||
import com.lz.modules.app.dto.GraphicsStatisticalDto;
|
import com.lz.modules.app.dto.*;
|
||||||
import com.lz.modules.app.dto.StaffBaseInfoDto;
|
|
||||||
import com.lz.modules.app.dto.StaffDto;
|
|
||||||
import com.lz.modules.app.dto.StaffStatisticalDto;
|
|
||||||
import com.lz.modules.app.entity.StaffEntity;
|
import com.lz.modules.app.entity.StaffEntity;
|
||||||
import com.lz.modules.equipment.entity.model.FindByNameModel;
|
import com.lz.modules.equipment.entity.model.FindByNameModel;
|
||||||
import com.lz.modules.job.model.responseBo.DepartmentStaffBo;
|
import com.lz.modules.job.model.responseBo.DepartmentStaffBo;
|
||||||
@ -85,5 +82,7 @@ public interface StaffService extends IService<StaffEntity> {
|
|||||||
List<String> staffsByAllDeparmentIds(List<String> deparmentIds);
|
List<String> staffsByAllDeparmentIds(List<String> deparmentIds);
|
||||||
|
|
||||||
List<StaffEntity> selectAll();
|
List<StaffEntity> selectAll();
|
||||||
|
|
||||||
|
List<StaffSimpleDto> selectStaffSimpleInfoByIds(List<Long> ids);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -453,6 +453,11 @@ public class StaffServiceImpl extends ServiceImpl<StaffDao, StaffEntity> impleme
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<StaffSimpleDto> selectStaffSimpleInfoByIds(List<Long> ids){
|
||||||
|
return staffDao.selectStaffSimpleInfoByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -9,8 +9,12 @@ package com.lz.modules.flow.dao;
|
|||||||
*/
|
*/
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import com.lz.modules.flow.entity.FlowChartDetailRecord;
|
import com.lz.modules.flow.entity.FlowChartDetailRecord;
|
||||||
|
import com.lz.modules.flow.model.FlowChartDetailRecordDto;
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
@Mapper
|
@Mapper
|
||||||
public interface FlowChartDetailRecordMapper extends BaseMapper<FlowChartDetailRecord> {
|
public interface FlowChartDetailRecordMapper extends BaseMapper<FlowChartDetailRecord> {
|
||||||
|
|
||||||
@ -30,4 +34,5 @@ public interface FlowChartDetailRecordMapper extends BaseMapper<FlowChartDetailR
|
|||||||
int deleteFlowChartDetailRecordById(@Param("id")Long id);
|
int deleteFlowChartDetailRecordById(@Param("id")Long id);
|
||||||
|
|
||||||
|
|
||||||
|
List<FlowChartDetailRecord> selectFlowChartDetailRecordByGroupIdAndChartId(@Param("groupId") Long groupId, @Param("chartId") Long chartId);
|
||||||
}
|
}
|
||||||
@ -40,16 +40,19 @@ public class FlowChartDetailRecord implements java.io.Serializable {
|
|||||||
private Integer status;
|
private Integer status;
|
||||||
//操作者id集合,逗号隔开,当opt_type为0时才有值
|
//操作者id集合,逗号隔开,当opt_type为0时才有值
|
||||||
@ApiModelProperty(value = "操作者id集合,逗号隔开,当opt_type为0时才有值", name = "optIds")
|
@ApiModelProperty(value = "操作者id集合,逗号隔开,当opt_type为0时才有值", name = "optIds")
|
||||||
private Long optIds;
|
private String optIds;
|
||||||
//-1考核人员自己,0人员id,1一级主管,2二级主管....
|
//-1考核人员自己,0人员id,1一级主管,2二级主管....
|
||||||
@ApiModelProperty(value = "-1考核人员自己,0人员id,1一级主管,2二级主管....", name = "optType")
|
@ApiModelProperty(value = "-1考核人员自己,0人员id,1一级主管,2二级主管....", name = "optType")
|
||||||
private Integer optType;
|
private Integer optType;
|
||||||
//role id集合,逗号隔开
|
//role id集合,逗号隔开
|
||||||
@ApiModelProperty(value = "role id集合,逗号隔开", name = "roleIds")
|
@ApiModelProperty(value = "role id集合,逗号隔开", name = "roleIds")
|
||||||
private Long roleIds;
|
private String roleIds;
|
||||||
//步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)
|
//步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)
|
||||||
@ApiModelProperty(value = "步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)", name = "stepType")
|
@ApiModelProperty(value = "步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)", name = "stepType")
|
||||||
private Integer stepType;
|
private Integer stepType;
|
||||||
|
//第几步从0开始,按照有小到排序
|
||||||
|
@ApiModelProperty(value = "第几步从0开始,按照有小到排序", name = "stepIndex")
|
||||||
|
private Integer stepIndex;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @return
|
* @return
|
||||||
@ -159,14 +162,14 @@ public class FlowChartDetailRecord implements java.io.Serializable {
|
|||||||
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public Long getOptIds() {
|
public String getOptIds() {
|
||||||
return optIds;
|
return optIds;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
||||||
* @param optIds
|
* @param optIds
|
||||||
*/
|
*/
|
||||||
public void setOptIds(Long optIds) {
|
public void setOptIds(String optIds) {
|
||||||
this.optIds = optIds;
|
this.optIds = optIds;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -189,14 +192,14 @@ public class FlowChartDetailRecord implements java.io.Serializable {
|
|||||||
* role id集合,逗号隔开
|
* role id集合,逗号隔开
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public Long getRoleIds() {
|
public String getRoleIds() {
|
||||||
return roleIds;
|
return roleIds;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* role id集合,逗号隔开
|
* role id集合,逗号隔开
|
||||||
* @param roleIds
|
* @param roleIds
|
||||||
*/
|
*/
|
||||||
public void setRoleIds(Long roleIds) {
|
public void setRoleIds(String roleIds) {
|
||||||
this.roleIds = roleIds;
|
this.roleIds = roleIds;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -215,6 +218,21 @@ public class FlowChartDetailRecord implements java.io.Serializable {
|
|||||||
this.stepType = stepType;
|
this.stepType = stepType;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 第几步从0开始,按照有小到排序
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public Integer getStepIndex() {
|
||||||
|
return stepIndex;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 第几步从0开始,按照有小到排序
|
||||||
|
* @param stepIndex
|
||||||
|
*/
|
||||||
|
public void setStepIndex(Integer stepIndex) {
|
||||||
|
this.stepIndex = stepIndex;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return "FlowChartDetailRecord{" +
|
return "FlowChartDetailRecord{" +
|
||||||
@ -229,6 +247,7 @@ public class FlowChartDetailRecord implements java.io.Serializable {
|
|||||||
",optType=" + optType +
|
",optType=" + optType +
|
||||||
",roleIds=" + roleIds +
|
",roleIds=" + roleIds +
|
||||||
",stepType=" + stepType +
|
",stepType=" + stepType +
|
||||||
|
",stepIndex=" + stepIndex +
|
||||||
"}";
|
"}";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1,7 +1,11 @@
|
|||||||
package com.lz.modules.flow.model;
|
package com.lz.modules.flow.model;
|
||||||
|
import com.lz.modules.app.dto.StaffSimpleDto;
|
||||||
import io.swagger.annotations.ApiModel;
|
import io.swagger.annotations.ApiModel;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <p>
|
* <p>
|
||||||
* </p>*考核模板流程记录表
|
* </p>*考核模板流程记录表
|
||||||
@ -25,17 +29,20 @@ public class FlowChartDetailRecordDto {
|
|||||||
@ApiModelProperty(value = "0关闭,1开启", name = "status")
|
@ApiModelProperty(value = "0关闭,1开启", name = "status")
|
||||||
private Integer status;
|
private Integer status;
|
||||||
//操作者id集合,逗号隔开,当opt_type为0时才有值
|
//操作者id集合,逗号隔开,当opt_type为0时才有值
|
||||||
@ApiModelProperty(value = "操作者id集合,逗号隔开,当opt_type为0时才有值", name = "optIds")
|
@ApiModelProperty(value = "人员集合,如果人员中途离职,第二次返回会自动去掉", name = "staffs")
|
||||||
private Long optIds;
|
private List<StaffSimpleDto> staffs;
|
||||||
//-1考核人员自己,0人员id,1一级主管,2二级主管....
|
//-1考核人员自己,0人员id,1一级主管,2二级主管....
|
||||||
@ApiModelProperty(value = "-1考核人员自己,0人员id,1一级主管,2二级主管....", name = "optType")
|
@ApiModelProperty(value = "-1考核人员自己,0人员id,1一级主管,2二级主管....", name = "optType")
|
||||||
private Integer optType;
|
private Integer optType;
|
||||||
//role id集合,逗号隔开
|
//role id集合,逗号隔开
|
||||||
@ApiModelProperty(value = "role id集合,逗号隔开", name = "roleIds")
|
@ApiModelProperty(value = "role id集合,逗号隔开", name = "roleIds")
|
||||||
private Long roleIds;
|
private String roleIds;
|
||||||
//步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)
|
//步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)
|
||||||
@ApiModelProperty(value = "步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)", name = "stepType")
|
@ApiModelProperty(value = "步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)", name = "stepType")
|
||||||
private Integer stepType;
|
private Integer stepType;
|
||||||
|
//第几步从0开始,按照有小到排序
|
||||||
|
@ApiModelProperty(value = "第几步从0开始,按照有小到排序", name = "stepIndex")
|
||||||
|
private Integer stepIndex;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @return
|
* @return
|
||||||
@ -96,20 +103,6 @@ public class FlowChartDetailRecordDto {
|
|||||||
this.status = status;
|
this.status = status;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
public Long getOptIds() {
|
|
||||||
return optIds;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
|
||||||
* @param optIds
|
|
||||||
*/
|
|
||||||
public void setOptIds(Long optIds) {
|
|
||||||
this.optIds = optIds;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* -1考核人员自己,0人员id,1一级主管,2二级主管....
|
* -1考核人员自己,0人员id,1一级主管,2二级主管....
|
||||||
@ -130,14 +123,14 @@ public class FlowChartDetailRecordDto {
|
|||||||
* role id集合,逗号隔开
|
* role id集合,逗号隔开
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public Long getRoleIds() {
|
public String getRoleIds() {
|
||||||
return roleIds;
|
return roleIds;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* role id集合,逗号隔开
|
* role id集合,逗号隔开
|
||||||
* @param roleIds
|
* @param roleIds
|
||||||
*/
|
*/
|
||||||
public void setRoleIds(Long roleIds) {
|
public void setRoleIds(String roleIds) {
|
||||||
this.roleIds = roleIds;
|
this.roleIds = roleIds;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -156,6 +149,21 @@ public class FlowChartDetailRecordDto {
|
|||||||
this.stepType = stepType;
|
this.stepType = stepType;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 第几步从0开始,按照有小到排序
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public Integer getStepIndex() {
|
||||||
|
return stepIndex;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 第几步从0开始,按照有小到排序
|
||||||
|
* @param stepIndex
|
||||||
|
*/
|
||||||
|
public void setStepIndex(Integer stepIndex) {
|
||||||
|
this.stepIndex = stepIndex;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return "FlowChartDetailRecordDto{" +
|
return "FlowChartDetailRecordDto{" +
|
||||||
@ -163,10 +171,11 @@ public class FlowChartDetailRecordDto {
|
|||||||
",chartId=" + chartId +
|
",chartId=" + chartId +
|
||||||
",evaluationGroupId=" + evaluationGroupId +
|
",evaluationGroupId=" + evaluationGroupId +
|
||||||
",status=" + status +
|
",status=" + status +
|
||||||
",optIds=" + optIds +
|
",staffs=" + staffs +
|
||||||
",optType=" + optType +
|
",optType=" + optType +
|
||||||
",roleIds=" + roleIds +
|
",roleIds=" + roleIds +
|
||||||
",stepType=" + stepType +
|
",stepType=" + stepType +
|
||||||
|
",stepIndex=" + stepIndex +
|
||||||
"}";
|
"}";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -49,16 +49,19 @@ public class FlowChartDetailRecordReq implements java.io.Serializable {
|
|||||||
private Integer status;
|
private Integer status;
|
||||||
//操作者id集合,逗号隔开,当opt_type为0时才有值
|
//操作者id集合,逗号隔开,当opt_type为0时才有值
|
||||||
@ApiModelProperty(value = "操作者id集合,逗号隔开,当opt_type为0时才有值", name = "optIds")
|
@ApiModelProperty(value = "操作者id集合,逗号隔开,当opt_type为0时才有值", name = "optIds")
|
||||||
private Long optIds;
|
private String optIds;
|
||||||
//-1考核人员自己,0人员id,1一级主管,2二级主管....
|
//-1考核人员自己,0人员id,1一级主管,2二级主管....
|
||||||
@ApiModelProperty(value = "-1考核人员自己,0人员id,1一级主管,2二级主管....", name = "optType")
|
@ApiModelProperty(value = "-1考核人员自己,0人员id,1一级主管,2二级主管....", name = "optType")
|
||||||
private Integer optType;
|
private Integer optType;
|
||||||
//role id集合,逗号隔开
|
//role id集合,逗号隔开
|
||||||
@ApiModelProperty(value = "role id集合,逗号隔开", name = "roleIds")
|
@ApiModelProperty(value = "role id集合,逗号隔开", name = "roleIds")
|
||||||
private Long roleIds;
|
private String roleIds;
|
||||||
//步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)
|
//步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)
|
||||||
@ApiModelProperty(value = "步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)", name = "stepType")
|
@ApiModelProperty(value = "步骤类型0:依次,1或签(同时通知,一人通过或拒绝即可),2会签(同时通知,所有人同意才可以)", name = "stepType")
|
||||||
private Integer stepType;
|
private Integer stepType;
|
||||||
|
//第几步从0开始,按照有小到排序
|
||||||
|
@ApiModelProperty(value = "第几步从0开始,按照有小到排序", name = "stepIndex")
|
||||||
|
private Integer stepIndex;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @return
|
* @return
|
||||||
@ -168,14 +171,14 @@ public class FlowChartDetailRecordReq implements java.io.Serializable {
|
|||||||
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public Long getOptIds() {
|
public String getOptIds() {
|
||||||
return optIds;
|
return optIds;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
* 操作者id集合,逗号隔开,当opt_type为0时才有值
|
||||||
* @param optIds
|
* @param optIds
|
||||||
*/
|
*/
|
||||||
public void setOptIds(Long optIds) {
|
public void setOptIds(String optIds) {
|
||||||
this.optIds = optIds;
|
this.optIds = optIds;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -198,14 +201,14 @@ public class FlowChartDetailRecordReq implements java.io.Serializable {
|
|||||||
* role id集合,逗号隔开
|
* role id集合,逗号隔开
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public Long getRoleIds() {
|
public String getRoleIds() {
|
||||||
return roleIds;
|
return roleIds;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* role id集合,逗号隔开
|
* role id集合,逗号隔开
|
||||||
* @param roleIds
|
* @param roleIds
|
||||||
*/
|
*/
|
||||||
public void setRoleIds(Long roleIds) {
|
public void setRoleIds(String roleIds) {
|
||||||
this.roleIds = roleIds;
|
this.roleIds = roleIds;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -224,6 +227,21 @@ public class FlowChartDetailRecordReq implements java.io.Serializable {
|
|||||||
this.stepType = stepType;
|
this.stepType = stepType;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 第几步从0开始,按照有小到排序
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public Integer getStepIndex() {
|
||||||
|
return stepIndex;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 第几步从0开始,按照有小到排序
|
||||||
|
* @param stepIndex
|
||||||
|
*/
|
||||||
|
public void setStepIndex(Integer stepIndex) {
|
||||||
|
this.stepIndex = stepIndex;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return "FlowChartDetailRecordReq{" +
|
return "FlowChartDetailRecordReq{" +
|
||||||
@ -238,6 +256,7 @@ public class FlowChartDetailRecordReq implements java.io.Serializable {
|
|||||||
",optType=" + optType +
|
",optType=" + optType +
|
||||||
",roleIds=" + roleIds +
|
",roleIds=" + roleIds +
|
||||||
",stepType=" + stepType +
|
",stepType=" + stepType +
|
||||||
|
",stepIndex=" + stepIndex +
|
||||||
"}";
|
"}";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2,6 +2,9 @@ package com.lz.modules.flow.service;
|
|||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
import com.lz.modules.flow.entity.FlowChartDetailRecord;
|
import com.lz.modules.flow.entity.FlowChartDetailRecord;
|
||||||
|
import com.lz.modules.flow.model.FlowChartDetailRecordDto;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <p>
|
* <p>
|
||||||
@ -30,4 +33,5 @@ public interface FlowChartDetailRecordService extends IService<FlowChartDetailRe
|
|||||||
int deleteFlowChartDetailRecordById(Long id);
|
int deleteFlowChartDetailRecordById(Long id);
|
||||||
|
|
||||||
|
|
||||||
|
List<FlowChartDetailRecord> selectFlowChartDetailRecordByGroupIdAndChartId(Long groupId, Long chartId);
|
||||||
}
|
}
|
||||||
@ -3,10 +3,13 @@ package com.lz.modules.flow.service.impl;
|
|||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
import com.lz.modules.flow.dao.FlowChartDetailRecordMapper;
|
import com.lz.modules.flow.dao.FlowChartDetailRecordMapper;
|
||||||
import com.lz.modules.flow.entity.FlowChartDetailRecord;
|
import com.lz.modules.flow.entity.FlowChartDetailRecord;
|
||||||
|
import com.lz.modules.flow.model.FlowChartDetailRecordDto;
|
||||||
import com.lz.modules.flow.service.FlowChartDetailRecordService;
|
import com.lz.modules.flow.service.FlowChartDetailRecordService;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <p>
|
* <p>
|
||||||
* 考核模板流程记录表 服务类
|
* 考核模板流程记录表 服务类
|
||||||
@ -58,6 +61,11 @@ public class FlowChartDetailRecordServiceImpl extends ServiceImpl<FlowChartDetai
|
|||||||
return flowChartDetailRecordMapper.deleteFlowChartDetailRecordById(id);
|
return flowChartDetailRecordMapper.deleteFlowChartDetailRecordById(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<FlowChartDetailRecord> selectFlowChartDetailRecordByGroupIdAndChartId(Long groupId, Long chartId){
|
||||||
|
return flowChartDetailRecordMapper.selectFlowChartDetailRecordByGroupIdAndChartId(groupId, chartId);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -1,19 +1,30 @@
|
|||||||
package com.lz.modules.performance.controller;
|
package com.lz.modules.performance.controller;
|
||||||
|
|
||||||
|
|
||||||
|
import com.lz.common.emun.ChartOptType;
|
||||||
import com.lz.common.utils.R;
|
import com.lz.common.utils.R;
|
||||||
|
import com.lz.modules.app.dto.StaffSimpleDto;
|
||||||
|
import com.lz.modules.app.service.StaffService;
|
||||||
import com.lz.modules.flow.entity.FlowChart;
|
import com.lz.modules.flow.entity.FlowChart;
|
||||||
import com.lz.modules.flow.entity.FlowChartDetailRecord;
|
import com.lz.modules.flow.entity.FlowChartDetailRecord;
|
||||||
import com.lz.modules.flow.entity.FlowManager;
|
import com.lz.modules.flow.entity.FlowManager;
|
||||||
|
import com.lz.modules.flow.model.FlowChartDetailRecordDto;
|
||||||
import com.lz.modules.flow.model.FlowChartRoleDto;
|
import com.lz.modules.flow.model.FlowChartRoleDto;
|
||||||
import com.lz.modules.flow.service.FlowChartDetailRecordService;
|
import com.lz.modules.flow.service.FlowChartDetailRecordService;
|
||||||
import com.lz.modules.flow.service.FlowChartService;
|
import com.lz.modules.flow.service.FlowChartService;
|
||||||
import com.lz.modules.flow.service.FlowManagerService;
|
import com.lz.modules.flow.service.FlowManagerService;
|
||||||
import io.swagger.annotations.*;
|
import io.swagger.annotations.*;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.function.Consumer;
|
||||||
|
import java.util.function.Function;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.util.stream.Stream;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/flowChart")
|
@RequestMapping("/flowChart")
|
||||||
@ -30,6 +41,9 @@ public class FlowChartController {
|
|||||||
@Autowired
|
@Autowired
|
||||||
private FlowChartDetailRecordService flowChartDetailRecordService;
|
private FlowChartDetailRecordService flowChartDetailRecordService;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private StaffService staffService;
|
||||||
|
|
||||||
@GetMapping("/getByFlowManagerId")
|
@GetMapping("/getByFlowManagerId")
|
||||||
@ApiOperation("根据Manager Id获取大流程节点")
|
@ApiOperation("根据Manager Id获取大流程节点")
|
||||||
@ApiImplicitParam(name = "id",value = "流程id,绩效请传1", required = true, dataType = "String",paramType = "query")
|
@ApiImplicitParam(name = "id",value = "流程id,绩效请传1", required = true, dataType = "String",paramType = "query")
|
||||||
@ -71,11 +85,40 @@ public class FlowChartController {
|
|||||||
@PostMapping("/saveDetailProc")
|
@PostMapping("/saveDetailProc")
|
||||||
@ApiOperation("保存流程节点小流程")
|
@ApiOperation("保存流程节点小流程")
|
||||||
@ApiResponses({@ApiResponse(code = 200, message = "成功", response = FlowChartDetailRecord.class)})
|
@ApiResponses({@ApiResponse(code = 200, message = "成功", response = FlowChartDetailRecord.class)})
|
||||||
public R saveDetailProc(@RequestBody @ApiParam FlowChartDetailRecord flowChartDetailProc) {
|
public R saveDetailProc(@RequestBody @ApiParam FlowChartDetailRecord flowChartDetailRecord) {
|
||||||
flowChartDetailRecordService.insertFlowChartDetailRecord(flowChartDetailProc);
|
flowChartDetailRecordService.insertFlowChartDetailRecord(flowChartDetailRecord);
|
||||||
return R.ok().put("data", flowChartDetailProc);
|
return R.ok().put("data", flowChartDetailRecord);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GetMapping("/getDetailProc")
|
||||||
|
@ApiOperation("获取已保存的考核节点详情")
|
||||||
|
@ApiResponses({@ApiResponse(code = 200, message = "成功", response = FlowChartDetailRecordDto.class)})
|
||||||
|
public R getDetailProc(@RequestParam @ApiParam("考核组id") Long groupId, @RequestParam @ApiParam("节点id") Long chartId) {
|
||||||
|
List<FlowChartDetailRecord> flowChartDetailRecords = flowChartDetailRecordService.selectFlowChartDetailRecordByGroupIdAndChartId(groupId, chartId);
|
||||||
|
List<FlowChartDetailRecordDto> flowChartDetailRecordDtos = new ArrayList<>();
|
||||||
|
for (FlowChartDetailRecord record:flowChartDetailRecords
|
||||||
|
) {
|
||||||
|
FlowChartDetailRecordDto dto = new FlowChartDetailRecordDto();
|
||||||
|
BeanUtils.copyProperties(record, dto);
|
||||||
|
if(record.getOptType().intValue() == ChartOptType.APPOINT.getCode()
|
||||||
|
&& record.getOptIds() != null
|
||||||
|
&& record.getOptIds().length() > 0){
|
||||||
|
List<Long> ids = Arrays.stream(record.getOptIds().split(",")).map(new Function<String, Long>() {
|
||||||
|
@Override
|
||||||
|
public Long apply(String s) {
|
||||||
|
return Long.parseLong(s);
|
||||||
|
}
|
||||||
|
}).collect(Collectors.toList());
|
||||||
|
|
||||||
|
//指定人员,搜索人员信息
|
||||||
|
List<StaffSimpleDto> staffSimpleDtos = staffService.selectStaffSimpleInfoByIds(ids);
|
||||||
|
dto.setStaffs(staffSimpleDtos);
|
||||||
|
}
|
||||||
|
flowChartDetailRecordDtos.add(dto);
|
||||||
|
}
|
||||||
|
return R.ok().put("data", flowChartDetailRecordDtos);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@RequestMapping("/delete")
|
@RequestMapping("/delete")
|
||||||
public R list(@RequestBody Long id) {
|
public R list(@RequestBody Long id) {
|
||||||
|
|||||||
@ -15,12 +15,13 @@
|
|||||||
<result column="opt_type" property="optType"/>
|
<result column="opt_type" property="optType"/>
|
||||||
<result column="role_ids" property="roleIds"/>
|
<result column="role_ids" property="roleIds"/>
|
||||||
<result column="step_type" property="stepType"/>
|
<result column="step_type" property="stepType"/>
|
||||||
|
<result column="step_index" property="stepIndex"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
|
|
||||||
<!-- 通用查询结果列 -->
|
<!-- 通用查询结果列 -->
|
||||||
<sql id="Base_Column_List">
|
<sql id="Base_Column_List">
|
||||||
id AS id, is_delete AS isDelete, gmt_create AS gmtCreate, gmt_modified AS gmtModified, chart_id AS chartId, evaluation_group_id AS evaluationGroupId, status AS status, opt_ids AS optIds, opt_type AS optType, role_ids AS roleIds, step_type AS stepType
|
id AS id, is_delete AS isDelete, gmt_create AS gmtCreate, gmt_modified AS gmtModified, chart_id AS chartId, evaluation_group_id AS evaluationGroupId, status AS status, opt_ids AS optIds, opt_type AS optType, role_ids AS roleIds, step_type AS stepType, step_index AS stepIndex
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
|
|
||||||
@ -40,6 +41,7 @@
|
|||||||
<if test="optType != null">opt_type, </if>
|
<if test="optType != null">opt_type, </if>
|
||||||
<if test="roleIds != null">role_ids, </if>
|
<if test="roleIds != null">role_ids, </if>
|
||||||
<if test="stepType != null">step_type, </if>
|
<if test="stepType != null">step_type, </if>
|
||||||
|
<if test="stepIndex != null">step_index, </if>
|
||||||
is_delete,
|
is_delete,
|
||||||
gmt_create,
|
gmt_create,
|
||||||
gmt_modified
|
gmt_modified
|
||||||
@ -51,6 +53,7 @@
|
|||||||
<if test="optType != null">#{ optType}, </if>
|
<if test="optType != null">#{ optType}, </if>
|
||||||
<if test="roleIds != null">#{ roleIds}, </if>
|
<if test="roleIds != null">#{ roleIds}, </if>
|
||||||
<if test="stepType != null">#{ stepType}, </if>
|
<if test="stepType != null">#{ stepType}, </if>
|
||||||
|
<if test="stepIndex != null">#{ stepIndex}, </if>
|
||||||
0,
|
0,
|
||||||
now(),
|
now(),
|
||||||
now()
|
now()
|
||||||
@ -70,7 +73,8 @@
|
|||||||
<if test="optIds != null">opt_ids = #{optIds},</if>
|
<if test="optIds != null">opt_ids = #{optIds},</if>
|
||||||
<if test="optType != null">opt_type = #{optType},</if>
|
<if test="optType != null">opt_type = #{optType},</if>
|
||||||
<if test="roleIds != null">role_ids = #{roleIds},</if>
|
<if test="roleIds != null">role_ids = #{roleIds},</if>
|
||||||
<if test="stepType != null">step_type = #{stepType}</if>
|
<if test="stepType != null">step_type = #{stepType},</if>
|
||||||
|
<if test="stepIndex != null">step_index = #{stepIndex}</if>
|
||||||
</trim>
|
</trim>
|
||||||
,gmt_modified = now()
|
,gmt_modified = now()
|
||||||
where id = #{id}
|
where id = #{id}
|
||||||
@ -89,7 +93,8 @@
|
|||||||
opt_ids = #{optIds},
|
opt_ids = #{optIds},
|
||||||
opt_type = #{optType},
|
opt_type = #{optType},
|
||||||
role_ids = #{roleIds},
|
role_ids = #{roleIds},
|
||||||
step_type = #{stepType}
|
step_type = #{stepType},
|
||||||
|
step_index = #{stepIndex}
|
||||||
,gmt_modified = now()
|
,gmt_modified = now()
|
||||||
where id = #{id}
|
where id = #{id}
|
||||||
</update>
|
</update>
|
||||||
@ -99,5 +104,9 @@
|
|||||||
update lz_flow_chart_detail_record set is_delete = 1 where id=#{id} limit 1
|
update lz_flow_chart_detail_record set is_delete = 1 where id=#{id} limit 1
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
<select id="selectFlowChartDetailRecordByGroupIdAndChartId" resultType="FlowChartDetailRecord" >
|
||||||
|
select * from lz_flow_chart_detail_record where evaluation_group_id=#{groupId} and chart_id = #{chartId} and is_delete = 0 order by step_index desc
|
||||||
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
||||||
|
|||||||
@ -461,4 +461,12 @@
|
|||||||
and name LIKE CONCAT('%',#{req.staffName},'%')
|
and name LIKE CONCAT('%',#{req.staffName},'%')
|
||||||
</if>
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="selectStaffSimpleInfoByIds" resultType="com.lz.modules.app.dto.StaffSimpleDto">
|
||||||
|
select staff.id as id, staff.name as name, occupation.position as position from lz_staff staff join lz_staff_occupation occupation on staff.id=occupation.staff_id where staff.id in (
|
||||||
|
<foreach collection="ids" item="id" separator=",">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
) and occupation.staff_status=0
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user