修改部份表的字段
This commit is contained in:
parent
fbfb9a4ade
commit
ff273e0d03
@ -24,7 +24,7 @@ public class R extends HashMap<String, Object> {
|
||||
private boolean isSuccess;
|
||||
|
||||
public R() {
|
||||
put("code", 0);
|
||||
put("code", 200);
|
||||
put("msg", "success");
|
||||
this.isSuccess = true ;
|
||||
}
|
||||
|
||||
@ -8,7 +8,9 @@ package com.lz.modules.flow.dao;
|
||||
* @since 2020-10-13
|
||||
*/
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.lz.modules.flow.entity.EvaluationGroup;
|
||||
import com.lz.modules.flow.req.EvaluationGroupReq;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
@ -33,4 +35,5 @@ public interface EvaluationGroupMapper extends BaseMapper<EvaluationGroup> {
|
||||
int deleteEvaluationGroupById(@Param("id")Long id);
|
||||
|
||||
|
||||
List<EvaluationGroup> seleteEvaluationGroupByReq(@Param("page") IPage page, @Param("req") EvaluationGroupReq req);
|
||||
}
|
||||
@ -9,6 +9,7 @@ package com.lz.modules.flow.dao;
|
||||
*/
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.lz.modules.flow.entity.ResultModel;
|
||||
import com.lz.modules.flow.model.ResultModelDto;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
@ -34,4 +35,8 @@ public interface ResultModelMapper extends BaseMapper<ResultModel> {
|
||||
|
||||
|
||||
List<ResultModel> selectResultModelByGroupId(@Param("id") Long id);
|
||||
|
||||
List<ResultModelDto> selectResultDtoByGroupId(Long id);
|
||||
|
||||
int deleteResultModelByGroupId(Long id);
|
||||
}
|
||||
@ -8,9 +8,15 @@ package com.lz.modules.flow.dao;
|
||||
* @since 2020-10-16
|
||||
*/
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.lz.modules.flow.entity.ResultTagetLib;
|
||||
import com.lz.modules.flow.model.ResultTagetLibDto;
|
||||
import com.lz.modules.flow.req.ResultTagetLibSearchReq;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Mapper
|
||||
public interface ResultTagetLibMapper extends BaseMapper<ResultTagetLib> {
|
||||
|
||||
@ -30,4 +36,9 @@ public interface ResultTagetLibMapper extends BaseMapper<ResultTagetLib> {
|
||||
int deleteResultTagetLibById(@Param("id")Long id);
|
||||
|
||||
|
||||
List<ResultTagetLibDto> selectResultTagetLibByModelId(Long id);
|
||||
|
||||
List<ResultTagetLibDto> selectByCondition(@Param("page") IPage page, @Param("req") ResultTagetLibSearchReq req);
|
||||
|
||||
int deleteResultTagetLibByModelId(Long id);
|
||||
}
|
||||
@ -34,7 +34,7 @@ public class EvaluationGroup implements java.io.Serializable {
|
||||
private String name;
|
||||
//绩效管理员ID,system_user,id,逗号隔开
|
||||
@ApiModelProperty(value = "绩效管理员ID,system_user,id,逗号隔开", name = "managerIds")
|
||||
private Long managerIds;
|
||||
private String managerIds;
|
||||
//参与部门id,逗号隔开
|
||||
@ApiModelProperty(value = "参与部门id,逗号隔开", name = "depIds")
|
||||
private String depIds;
|
||||
@ -123,14 +123,14 @@ public class EvaluationGroup implements java.io.Serializable {
|
||||
* 绩效管理员ID,system_user,id,逗号隔开
|
||||
* @return
|
||||
*/
|
||||
public Long getManagerIds() {
|
||||
public String getManagerIds() {
|
||||
return managerIds;
|
||||
}
|
||||
/**
|
||||
* 绩效管理员ID,system_user,id,逗号隔开
|
||||
* @param managerIds
|
||||
*/
|
||||
public void setManagerIds(Long managerIds) {
|
||||
public void setManagerIds(String managerIds) {
|
||||
this.managerIds = managerIds;
|
||||
}
|
||||
|
||||
|
||||
@ -10,7 +10,7 @@ import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
/**
|
||||
* <p>
|
||||
* </p>*考核模板表
|
||||
* </p>*考核维度表
|
||||
* @author quyixiao
|
||||
* @since 2020-10-16
|
||||
*/
|
||||
@ -40,13 +40,13 @@ public class ResultModel implements java.io.Serializable {
|
||||
//1:业绩 2:文化价值观
|
||||
@ApiModelProperty(value = "1:业绩 2:文化价值观", name = "type")
|
||||
private Integer type;
|
||||
//权重
|
||||
@ApiModelProperty(value = "权重", name = "weight")
|
||||
//权重 0不限权重
|
||||
@ApiModelProperty(value = "权重 0不限权重", name = "weight")
|
||||
private BigDecimal weight;
|
||||
//考核子项目个数最大限制
|
||||
@ApiModelProperty(value = "考核子项目个数最大限制", name = "maxCount")
|
||||
private Integer maxCount;
|
||||
//lz_result_calculate 的id
|
||||
//lz_result_calculate 的id,计算法方法id
|
||||
@ApiModelProperty(value = "lz_result_calculate 的id,计算法方法id", name = "calculateId")
|
||||
private Long calculateId;
|
||||
//等级开关0关闭,1开启
|
||||
@ -55,6 +55,9 @@ public class ResultModel implements java.io.Serializable {
|
||||
//使用的哪个等级。等级组id,lz_result_grade的group_id
|
||||
@ApiModelProperty(value = "使用的哪个等级。等级组id,lz_result_grade的group_id", name = "gradeGroupId")
|
||||
private Long gradeGroupId;
|
||||
//排序
|
||||
@ApiModelProperty(value = "排序", name = "order")
|
||||
private Integer order;
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
@ -161,14 +164,14 @@ public class ResultModel implements java.io.Serializable {
|
||||
}
|
||||
|
||||
/**
|
||||
* 权重
|
||||
* 权重 0不限权重
|
||||
* @return
|
||||
*/
|
||||
public BigDecimal getWeight() {
|
||||
return weight;
|
||||
}
|
||||
/**
|
||||
* 权重
|
||||
* 权重 0不限权重
|
||||
* @param weight
|
||||
*/
|
||||
public void setWeight(BigDecimal weight) {
|
||||
@ -191,14 +194,14 @@ public class ResultModel implements java.io.Serializable {
|
||||
}
|
||||
|
||||
/**
|
||||
* lz_result_calculate 的id
|
||||
* lz_result_calculate 的id,计算法方法id
|
||||
* @return
|
||||
*/
|
||||
public Long getCalculateId() {
|
||||
return calculateId;
|
||||
}
|
||||
/**
|
||||
* lz_result_calculate 的id
|
||||
* lz_result_calculate 的id,计算法方法id
|
||||
* @param calculateId
|
||||
*/
|
||||
public void setCalculateId(Long calculateId) {
|
||||
@ -235,6 +238,21 @@ public class ResultModel implements java.io.Serializable {
|
||||
this.gradeGroupId = gradeGroupId;
|
||||
}
|
||||
|
||||
/**
|
||||
* 排序
|
||||
* @return
|
||||
*/
|
||||
public Integer getOrder() {
|
||||
return order;
|
||||
}
|
||||
/**
|
||||
* 排序
|
||||
* @param order
|
||||
*/
|
||||
public void setOrder(Integer order) {
|
||||
this.order = order;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ResultModel{" +
|
||||
@ -250,6 +268,7 @@ public class ResultModel implements java.io.Serializable {
|
||||
",calculateId=" + calculateId +
|
||||
",gradeStatus=" + gradeStatus +
|
||||
",gradeGroupId=" + gradeGroupId +
|
||||
",order=" + order +
|
||||
"}";
|
||||
}
|
||||
}
|
||||
@ -43,6 +43,9 @@ public class ResultTagetLib implements java.io.Serializable {
|
||||
//考核标准,关键结果
|
||||
@ApiModelProperty(value = "考核标准,关键结果", name = "keyResult")
|
||||
private String keyResult;
|
||||
//排序
|
||||
@ApiModelProperty(value = "排序", name = "order")
|
||||
private Integer order;
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
@ -163,6 +166,21 @@ public class ResultTagetLib implements java.io.Serializable {
|
||||
this.keyResult = keyResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* 排序
|
||||
* @return
|
||||
*/
|
||||
public Integer getOrder() {
|
||||
return order;
|
||||
}
|
||||
/**
|
||||
* 排序
|
||||
* @param order
|
||||
*/
|
||||
public void setOrder(Integer order) {
|
||||
this.order = order;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ResultTagetLib{" +
|
||||
@ -174,6 +192,7 @@ public class ResultTagetLib implements java.io.Serializable {
|
||||
",modelId=" + modelId +
|
||||
",weight=" + weight +
|
||||
",keyResult=" + keyResult +
|
||||
",order=" + order +
|
||||
"}";
|
||||
}
|
||||
}
|
||||
@ -10,7 +10,7 @@ import lombok.Data;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "考评组表")
|
||||
@ApiModel(value = "考评组Dto")
|
||||
public class EvaluationGroupDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -10,7 +10,7 @@ import lombok.Data;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "发起考核考,核组人员对应关系表")
|
||||
@ApiModel(value = "发起考核考,核组人员对应关系Dto")
|
||||
public class EvaluationStartStaffDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -10,7 +10,7 @@ import lombok.Data;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "流程审批表")
|
||||
@ApiModel(value = "流程审批Dto")
|
||||
public class FlowApprovalRoleDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -10,7 +10,7 @@ import lombok.Data;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "变动记录表")
|
||||
@ApiModel(value = "变动记录Dto")
|
||||
public class FlowChangeDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -10,7 +10,7 @@ import lombok.Data;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "流程图,lz_flow的父")
|
||||
@ApiModel(value = "流程图Dto")
|
||||
public class FlowChartDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -10,7 +10,7 @@ import lombok.Data;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "流程节点权限对应关系表")
|
||||
@ApiModel(value = "流程节点权限对应关系Dto")
|
||||
public class FlowChartRoleDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -11,7 +11,7 @@ import java.util.Date;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "发起考核表")
|
||||
@ApiModel(value = "发起考核Dto")
|
||||
public class FlowStartDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -18,7 +18,7 @@ import java.util.Date;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "考核维度")
|
||||
@ApiModel(value = "考核维度Dto")
|
||||
public class ResultDimensionDto implements java.io.Serializable {
|
||||
//
|
||||
@TableId(value = "id", type = IdType.AUTO)
|
||||
|
||||
@ -13,7 +13,7 @@ import java.math.BigDecimal;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "等级表")
|
||||
@ApiModel(value = "等级Dto")
|
||||
public class ResultGradeDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -4,16 +4,17 @@ import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* </p>*考核模板表
|
||||
* </p>*考核维度表
|
||||
* @author quyixiao
|
||||
* @since 2020-10-16
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "考核维度表")
|
||||
@ApiModel(value = "考核维度表Dto")
|
||||
public class ResultModelDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
@ -27,13 +28,13 @@ public class ResultModelDto {
|
||||
//1:业绩 2:文化价值观
|
||||
@ApiModelProperty(value = "1:业绩 2:文化价值观", name = "type")
|
||||
private Integer type;
|
||||
//权重
|
||||
@ApiModelProperty(value = "权重", name = "weight")
|
||||
//权重 0不限权重
|
||||
@ApiModelProperty(value = "权重 0不限权重", name = "weight")
|
||||
private BigDecimal weight;
|
||||
//考核子项目个数最大限制
|
||||
@ApiModelProperty(value = "考核子项目个数最大限制", name = "maxCount")
|
||||
private Integer maxCount;
|
||||
//lz_result_calculate 的id
|
||||
//lz_result_calculate 的id,计算法方法id
|
||||
@ApiModelProperty(value = "lz_result_calculate 的id,计算法方法id", name = "calculateId")
|
||||
private Long calculateId;
|
||||
//等级开关0关闭,1开启
|
||||
@ -42,6 +43,11 @@ public class ResultModelDto {
|
||||
//使用的哪个等级。等级组id,lz_result_grade的group_id
|
||||
@ApiModelProperty(value = "使用的哪个等级。等级组id,lz_result_grade的group_id", name = "gradeGroupId")
|
||||
private Long gradeGroupId;
|
||||
//排序
|
||||
@ApiModelProperty(value = "排序", name = "order")
|
||||
private Integer order;
|
||||
@ApiModelProperty(value = "已添加的指标", name = "tagetLibs")
|
||||
private List<ResultTagetLibDto> tagetLibs;
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
@ -103,14 +109,14 @@ public class ResultModelDto {
|
||||
}
|
||||
|
||||
/**
|
||||
* 权重
|
||||
* 权重 0不限权重
|
||||
* @return
|
||||
*/
|
||||
public BigDecimal getWeight() {
|
||||
return weight;
|
||||
}
|
||||
/**
|
||||
* 权重
|
||||
* 权重 0不限权重
|
||||
* @param weight
|
||||
*/
|
||||
public void setWeight(BigDecimal weight) {
|
||||
@ -133,14 +139,14 @@ public class ResultModelDto {
|
||||
}
|
||||
|
||||
/**
|
||||
* lz_result_calculate 的id
|
||||
* lz_result_calculate 的id,计算法方法id
|
||||
* @return
|
||||
*/
|
||||
public Long getCalculateId() {
|
||||
return calculateId;
|
||||
}
|
||||
/**
|
||||
* lz_result_calculate 的id
|
||||
* lz_result_calculate 的id,计算法方法id
|
||||
* @param calculateId
|
||||
*/
|
||||
public void setCalculateId(Long calculateId) {
|
||||
@ -177,6 +183,21 @@ public class ResultModelDto {
|
||||
this.gradeGroupId = gradeGroupId;
|
||||
}
|
||||
|
||||
/**
|
||||
* 排序
|
||||
* @return
|
||||
*/
|
||||
public Integer getOrder() {
|
||||
return order;
|
||||
}
|
||||
/**
|
||||
* 排序
|
||||
* @param order
|
||||
*/
|
||||
public void setOrder(Integer order) {
|
||||
this.order = order;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ResultModel{" +
|
||||
@ -189,6 +210,7 @@ public class ResultModelDto {
|
||||
",calculateId=" + calculateId +
|
||||
",gradeStatus=" + gradeStatus +
|
||||
",gradeGroupId=" + gradeGroupId +
|
||||
",order=" + order +
|
||||
"}";
|
||||
}
|
||||
}
|
||||
@ -13,7 +13,7 @@ import java.math.BigDecimal;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "业绩详情评分表")
|
||||
@ApiModel(value = "业绩详情评分Dto")
|
||||
public class ResultScoreDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
|
||||
@ -13,7 +13,7 @@ import java.math.BigDecimal;
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "考核指标库表")
|
||||
@ApiModel(value = "考核指标库表Dto")
|
||||
public class ResultTagetLibDto {
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "id")
|
||||
@ -30,6 +30,11 @@ public class ResultTagetLibDto {
|
||||
//考核标准,关键结果
|
||||
@ApiModelProperty(value = "考核标准,关键结果", name = "keyResult")
|
||||
private String keyResult;
|
||||
//排序
|
||||
@ApiModelProperty(value = "排序", name = "order")
|
||||
private Integer order;
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
@ -105,6 +110,21 @@ public class ResultTagetLibDto {
|
||||
this.keyResult = keyResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* 排序
|
||||
* @return
|
||||
*/
|
||||
public Integer getOrder() {
|
||||
return order;
|
||||
}
|
||||
/**
|
||||
* 排序
|
||||
* @param order
|
||||
*/
|
||||
public void setOrder(Integer order) {
|
||||
this.order = order;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ResultTagetLib{" +
|
||||
@ -113,6 +133,7 @@ public class ResultTagetLibDto {
|
||||
",modelId=" + modelId +
|
||||
",weight=" + weight +
|
||||
",keyResult=" + keyResult +
|
||||
",order=" + order +
|
||||
"}";
|
||||
}
|
||||
}
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "考评组表")
|
||||
@ApiModel(value = "考评组搜索Req")
|
||||
public class EvaluationGroupReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
@ -30,29 +30,16 @@ public class EvaluationGroupReq implements java.io.Serializable {
|
||||
//
|
||||
private Long id;
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "isDelete")
|
||||
private Integer isDelete;
|
||||
@ApiModelProperty(value = "起始时间", name = "startTime")
|
||||
private String startTime;
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "gmtCreate")
|
||||
private Date gmtCreate;
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "gmtModified")
|
||||
private Date gmtModified;
|
||||
@ApiModelProperty(value = "结束时间", name = "endTime")
|
||||
private String endTime;
|
||||
//
|
||||
@ApiModelProperty(value = "", name = "name")
|
||||
private String name;
|
||||
//绩效管理员ID,system_user,id,逗号隔开
|
||||
@ApiModelProperty(value = "绩效管理员ID,system_user,id,逗号隔开", name = "managerIds")
|
||||
private Long managerIds;
|
||||
//参与部门id,逗号隔开
|
||||
@ApiModelProperty(value = "参与部门id,逗号隔开", name = "depIds")
|
||||
private Long depIds;
|
||||
//参与考核员工staff_id,逗号隔开
|
||||
@ApiModelProperty(value = "参与考核员工staff_id,逗号隔开", name = "staffIds")
|
||||
private Long staffIds;
|
||||
//排除人员ids,逗号隔开
|
||||
@ApiModelProperty(value = "排除人员ids,逗号隔开", name = "outIds")
|
||||
private Long outIds;
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
@ -68,50 +55,7 @@ public class EvaluationGroupReq implements java.io.Serializable {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public Integer getIsDelete() {
|
||||
return isDelete;
|
||||
}
|
||||
/**
|
||||
*
|
||||
* @param isDelete
|
||||
*/
|
||||
public void setIsDelete(Integer isDelete) {
|
||||
this.isDelete = isDelete;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public Date getGmtCreate() {
|
||||
return gmtCreate;
|
||||
}
|
||||
/**
|
||||
*
|
||||
* @param gmtCreate
|
||||
*/
|
||||
public void setGmtCreate(Date gmtCreate) {
|
||||
this.gmtCreate = gmtCreate;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public Date getGmtModified() {
|
||||
return gmtModified;
|
||||
}
|
||||
/**
|
||||
*
|
||||
* @param gmtModified
|
||||
*/
|
||||
public void setGmtModified(Date gmtModified) {
|
||||
this.gmtModified = gmtModified;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
@ -128,78 +72,15 @@ public class EvaluationGroupReq implements java.io.Serializable {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
/**
|
||||
* 绩效管理员ID,system_user,id,逗号隔开
|
||||
* @return
|
||||
*/
|
||||
public Long getManagerIds() {
|
||||
return managerIds;
|
||||
}
|
||||
/**
|
||||
* 绩效管理员ID,system_user,id,逗号隔开
|
||||
* @param managerIds
|
||||
*/
|
||||
public void setManagerIds(Long managerIds) {
|
||||
this.managerIds = managerIds;
|
||||
}
|
||||
|
||||
/**
|
||||
* 参与部门id,逗号隔开
|
||||
* @return
|
||||
*/
|
||||
public Long getDepIds() {
|
||||
return depIds;
|
||||
}
|
||||
/**
|
||||
* 参与部门id,逗号隔开
|
||||
* @param depIds
|
||||
*/
|
||||
public void setDepIds(Long depIds) {
|
||||
this.depIds = depIds;
|
||||
}
|
||||
|
||||
/**
|
||||
* 参与考核员工staff_id,逗号隔开
|
||||
* @return
|
||||
*/
|
||||
public Long getStaffIds() {
|
||||
return staffIds;
|
||||
}
|
||||
/**
|
||||
* 参与考核员工staff_id,逗号隔开
|
||||
* @param staffIds
|
||||
*/
|
||||
public void setStaffIds(Long staffIds) {
|
||||
this.staffIds = staffIds;
|
||||
}
|
||||
|
||||
/**
|
||||
* 排除人员ids,逗号隔开
|
||||
* @return
|
||||
*/
|
||||
public Long getOutIds() {
|
||||
return outIds;
|
||||
}
|
||||
/**
|
||||
* 排除人员ids,逗号隔开
|
||||
* @param outIds
|
||||
*/
|
||||
public void setOutIds(Long outIds) {
|
||||
this.outIds = outIds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "EvaluationGroup{" +
|
||||
",id=" + id +
|
||||
",isDelete=" + isDelete +
|
||||
",gmtCreate=" + gmtCreate +
|
||||
",gmtModified=" + gmtModified +
|
||||
",startTime=" + startTime +
|
||||
",endTime=" + endTime +
|
||||
",name=" + name +
|
||||
",managerIds=" + managerIds +
|
||||
",depIds=" + depIds +
|
||||
",staffIds=" + staffIds +
|
||||
",outIds=" + outIds +
|
||||
"}";
|
||||
}
|
||||
}
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "发起考核考,核组人员对应关系表")
|
||||
@ApiModel(value = "发起考核考,核组人员对应关系Req")
|
||||
public class EvaluationStartStaffReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "流程审批表")
|
||||
@ApiModel(value = "流程审批Req")
|
||||
public class FlowApprovalRoleReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "变动记录表")
|
||||
@ApiModel(value = "变动记录Req")
|
||||
public class FlowChangeReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "流程图,lz_flow的父")
|
||||
@ApiModel(value = "流程图Req")
|
||||
public class FlowChartReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "流程节点权限对应关系表")
|
||||
@ApiModel(value = "流程节点权限对应关系Req")
|
||||
public class FlowChartRoleReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "发起考核表")
|
||||
@ApiModel(value = "发起考核Req")
|
||||
public class FlowStartReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "模板计算公式")
|
||||
@ApiModel(value = "模板计算公式Req")
|
||||
public class ResultCalculateReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -16,7 +16,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "考核维度表")
|
||||
@ApiModel(value = "考核维度Req")
|
||||
public class ResultDimensionReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -18,7 +18,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "等级表")
|
||||
@ApiModel(value = "等级Req")
|
||||
public class ResultGradeReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -18,7 +18,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "考核维度表")
|
||||
@ApiModel(value = "考核维度Req")
|
||||
public class ResultModelReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
@ -50,7 +50,7 @@ public class ResultModelReq implements java.io.Serializable {
|
||||
@ApiModelProperty(value = "1:业绩 2:文化价值观", name = "type")
|
||||
private Integer type;
|
||||
//权重
|
||||
@ApiModelProperty(value = "权重", name = "weight")
|
||||
@ApiModelProperty(value = "权重 0不限权重", name = "weight")
|
||||
private BigDecimal weight;
|
||||
//考核子项目个数最大限制
|
||||
@ApiModelProperty(value = "考核子项目个数最大限制", name = "maxCount")
|
||||
|
||||
@ -18,7 +18,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "业绩详情评分表")
|
||||
@ApiModel(value = "业绩详情评分Req")
|
||||
public class ResultScoreReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -18,7 +18,7 @@ import java.util.Date;
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "考核指标库表")
|
||||
@ApiModel(value = "考核指标库Req")
|
||||
public class ResultTagetLibReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
|
||||
@ -0,0 +1,114 @@
|
||||
package com.lz.modules.flow.req;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 菜单权限表
|
||||
* </p>*考核指标库表
|
||||
* @author quyixiao
|
||||
* @since 2020-10-16
|
||||
*/
|
||||
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "搜索指标Req")
|
||||
public class ResultTagetLibSearchReq implements java.io.Serializable {
|
||||
|
||||
@ApiModelProperty(value = "currPage", name = "当前页码")
|
||||
private int currPage = 1;
|
||||
@ApiModelProperty(value = "pageSize", name = "每页返回条数")
|
||||
private int pageSize = 10;
|
||||
|
||||
//
|
||||
private Long id;
|
||||
//
|
||||
|
||||
//指标名称
|
||||
@ApiModelProperty(value = "指标名称", name = "name")
|
||||
private String name;
|
||||
//考核维度ID,result_model。如果id为0表示为指标库数据,其他地方可选
|
||||
@ApiModelProperty(value = "考核维度ID,result_model。如果id为0表示为指标库数据,其他地方可选", name = "modelId")
|
||||
private Long modelId;
|
||||
//权重
|
||||
@ApiModelProperty(value = "权重", name = "weight")
|
||||
private BigDecimal weight;
|
||||
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
/**
|
||||
*
|
||||
* @param id
|
||||
*/
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 指标名称
|
||||
* @return
|
||||
*/
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
/**
|
||||
* 指标名称
|
||||
* @param name
|
||||
*/
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
/**
|
||||
* 考核维度ID,result_model。如果id为0表示为指标库数据,其他地方可选
|
||||
* @return
|
||||
*/
|
||||
public Long getModelId() {
|
||||
return modelId;
|
||||
}
|
||||
/**
|
||||
* 考核维度ID,result_model。如果id为0表示为指标库数据,其他地方可选
|
||||
* @param modelId
|
||||
*/
|
||||
public void setModelId(Long modelId) {
|
||||
this.modelId = modelId;
|
||||
}
|
||||
|
||||
/**
|
||||
* 权重
|
||||
* @return
|
||||
*/
|
||||
public BigDecimal getWeight() {
|
||||
return weight;
|
||||
}
|
||||
/**
|
||||
* 权重
|
||||
* @param weight
|
||||
*/
|
||||
public void setWeight(BigDecimal weight) {
|
||||
this.weight = weight;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ResultTagetLib{" +
|
||||
",id=" + id +
|
||||
",name=" + name +
|
||||
",modelId=" + modelId +
|
||||
",weight=" + weight +
|
||||
"}";
|
||||
}
|
||||
}
|
||||
@ -1,7 +1,10 @@
|
||||
package com.lz.modules.flow.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.lz.common.utils.PageUtils;
|
||||
import com.lz.common.utils.R;
|
||||
import com.lz.modules.flow.entity.EvaluationGroup;
|
||||
import com.lz.modules.flow.req.EvaluationGroupReq;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@ -29,7 +32,8 @@ public interface EvaluationGroupService extends IService<EvaluationGroup> {
|
||||
int updateCoverEvaluationGroupById(EvaluationGroup evaluationGroup);
|
||||
|
||||
|
||||
int deleteEvaluationGroupById(Long id);
|
||||
R deleteEvaluationGroupById(Long id);
|
||||
|
||||
|
||||
PageUtils selectEvaluationGroupByReq(EvaluationGroupReq req);
|
||||
}
|
||||
@ -1,7 +1,9 @@
|
||||
package com.lz.modules.flow.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.lz.common.utils.R;
|
||||
import com.lz.modules.flow.entity.ResultModel;
|
||||
import com.lz.modules.flow.model.ResultModelDto;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@ -29,8 +31,12 @@ public interface ResultModelService extends IService<ResultModel> {
|
||||
int updateCoverResultModelById(ResultModel resultModel);
|
||||
|
||||
|
||||
int deleteResultModelById(Long id);
|
||||
R deleteResultModelById(Long id);
|
||||
|
||||
|
||||
List<ResultModel> selectResultModelByGroupId(Long id);
|
||||
|
||||
List<ResultModelDto> selectResultDtoByGroupId(Long id);
|
||||
|
||||
R deleteResultModelByGroupId(Long id);
|
||||
}
|
||||
@ -1,8 +1,13 @@
|
||||
package com.lz.modules.flow.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.lz.common.utils.ISelect;
|
||||
import com.lz.common.utils.PageUtils;
|
||||
import com.lz.common.utils.R;
|
||||
import com.lz.modules.flow.dao.EvaluationGroupMapper;
|
||||
import com.lz.modules.flow.entity.EvaluationGroup;
|
||||
import com.lz.modules.flow.req.EvaluationGroupReq;
|
||||
import com.lz.modules.flow.service.EvaluationGroupService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
@ -56,11 +61,16 @@ public class EvaluationGroupServiceImpl extends ServiceImpl<EvaluationGroupMappe
|
||||
|
||||
|
||||
@Override
|
||||
public int deleteEvaluationGroupById(Long id){
|
||||
return evaluationGroupMapper.deleteEvaluationGroupById(id);
|
||||
public R deleteEvaluationGroupById(Long id){
|
||||
evaluationGroupMapper.deleteEvaluationGroupById(id);
|
||||
return R.ok();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public PageUtils selectEvaluationGroupByReq(EvaluationGroupReq req){
|
||||
PageUtils pageUtils = PageUtils.startPage(req.getCurrPage(), req.getPageSize())
|
||||
.doSelect(page -> evaluationGroupMapper.seleteEvaluationGroupByReq(page, req));
|
||||
return pageUtils;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -1,9 +1,13 @@
|
||||
package com.lz.modules.flow.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.lz.common.utils.R;
|
||||
import com.lz.modules.flow.dao.ResultModelMapper;
|
||||
import com.lz.modules.flow.entity.ResultModel;
|
||||
import com.lz.modules.flow.model.ResultModelDto;
|
||||
import com.lz.modules.flow.service.ResultModelService;
|
||||
import com.lz.modules.performance.service.ResultTagetLibService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@ -19,12 +23,16 @@ import java.util.List;
|
||||
*/
|
||||
|
||||
@Service
|
||||
@Slf4j
|
||||
public class ResultModelServiceImpl extends ServiceImpl<ResultModelMapper, ResultModel> implements ResultModelService {
|
||||
|
||||
|
||||
@Autowired
|
||||
private ResultModelMapper resultModelMapper;
|
||||
|
||||
@Autowired
|
||||
private ResultTagetLibService resultTargetLibService;
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
@ -56,8 +64,12 @@ public class ResultModelServiceImpl extends ServiceImpl<ResultModelMapper, Resul
|
||||
|
||||
|
||||
@Override
|
||||
public int deleteResultModelById(Long id){
|
||||
return resultModelMapper.deleteResultModelById(id);
|
||||
public R deleteResultModelById(Long id){
|
||||
//
|
||||
log.info("删除考核模板{}", id);
|
||||
resultTargetLibService.deleteResultTagetLibByModelId(id);
|
||||
resultModelMapper.deleteResultModelById(id);
|
||||
return R.ok();
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -65,6 +77,20 @@ public class ResultModelServiceImpl extends ServiceImpl<ResultModelMapper, Resul
|
||||
return resultModelMapper.selectResultModelByGroupId(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ResultModelDto> selectResultDtoByGroupId(Long id){
|
||||
return resultModelMapper.selectResultDtoByGroupId(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public R deleteResultModelByGroupId(Long id){
|
||||
List<ResultModel> resultModels = selectResultModelByGroupId(id);
|
||||
for (ResultModel model:resultModels
|
||||
) {
|
||||
deleteResultModelById(model.getId());
|
||||
}
|
||||
return R.ok();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -7,12 +7,12 @@ import com.lz.common.utils.R;
|
||||
import com.lz.common.utils.StringUtil;
|
||||
import com.lz.modules.flow.entity.EvaluationGroup;
|
||||
import com.lz.modules.flow.entity.FlowManager;
|
||||
import com.lz.modules.flow.entity.ResultModel;
|
||||
import com.lz.modules.flow.req.EvaluationGroupReq;
|
||||
import com.lz.modules.flow.service.EvaluationGroupService;
|
||||
import com.lz.modules.flow.service.FlowManagerService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import com.lz.modules.flow.service.ResultModelService;
|
||||
import io.swagger.annotations.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
@ -31,15 +31,19 @@ public class EvaluationGroupController {
|
||||
|
||||
|
||||
|
||||
@Autowired
|
||||
private ResultModelService resultModelService;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@RequestMapping("/getById")
|
||||
public R getById(@RequestBody EvaluationGroupReq evaluationGroupReq) {
|
||||
EvaluationGroup evaluationGroup = evaluationGroupService.selectEvaluationGroupById(evaluationGroupReq.getId());
|
||||
return R.ok().put("evaluationGroup",evaluationGroup);
|
||||
@PostMapping("/getById")
|
||||
@ApiOperation("获取考核组列表")
|
||||
@ApiResponses({@ApiResponse(code=200,message = "成功", response=EvaluationGroup.class)})
|
||||
public R getById(@RequestBody @ApiParam EvaluationGroupReq req) {
|
||||
PageUtils pageUtils = evaluationGroupService.selectEvaluationGroupByReq(req);
|
||||
return R.ok().put("data",pageUtils);
|
||||
}
|
||||
|
||||
|
||||
@ -58,9 +62,11 @@ public class EvaluationGroupController {
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping("/delete")
|
||||
public R list(@RequestBody Long id) {
|
||||
evaluationGroupService.deleteEvaluationGroupById(id);
|
||||
return R.ok();
|
||||
@GetMapping("/delete")
|
||||
@ApiOperation("删除考核组")
|
||||
public R delete(@RequestParam @ApiParam("组id") Long id) {
|
||||
resultModelService.deleteResultModelByGroupId(id);
|
||||
return evaluationGroupService.deleteEvaluationGroupById(id);
|
||||
//return R.ok();
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,38 +1,44 @@
|
||||
package com.lz.modules.performance.controller;
|
||||
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.lz.common.utils.PageUtils;
|
||||
import com.lz.common.utils.R;
|
||||
import com.lz.common.utils.StringUtil;
|
||||
import com.lz.modules.flow.entity.ResultModel;
|
||||
import com.lz.modules.flow.model.FlowChartRoleDto;
|
||||
import com.lz.modules.flow.model.ResultModelDto;
|
||||
import com.lz.modules.flow.model.ResultTagetLibDto;
|
||||
import com.lz.modules.flow.service.ResultModelService;
|
||||
import com.lz.modules.performance.service.ResultTagetLibService;
|
||||
import io.swagger.annotations.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/resultModel")
|
||||
@Api(tags = "模板相关")
|
||||
@Api(tags = "考核模板相关")
|
||||
public class ResultModelController {
|
||||
|
||||
|
||||
@Autowired
|
||||
private ResultModelService resultModelService;
|
||||
|
||||
@Autowired
|
||||
private ResultTagetLibService resultTagetLibService;
|
||||
|
||||
|
||||
@GetMapping("/getByGroupId")
|
||||
@ApiOperation(value="根据考核组id获取模板列表")
|
||||
@ApiResponses({@ApiResponse(code = 200,message = "成功",response = ResultModel.class)})
|
||||
@ApiResponses({@ApiResponse(code = 200,message = "成功",response = ResultModelDto.class)})
|
||||
public R getByGroupId(@RequestParam Long id) {
|
||||
|
||||
List<ResultModel> resultModels = resultModelService.selectResultModelByGroupId(id);
|
||||
return R.ok().put("data",resultModels);
|
||||
//List<ResultModel> resultModels = resultModelService.selectResultModelByGroupId(id);
|
||||
List<ResultModelDto> resultModelDtos = resultModelService.selectResultDtoByGroupId(id);
|
||||
for (ResultModelDto dto:resultModelDtos
|
||||
) {
|
||||
List<ResultTagetLibDto> libDtos = resultTagetLibService.selectResultTagetLibByModelId(dto.getId());
|
||||
dto.setTagetLibs(libDtos);
|
||||
}
|
||||
return R.ok().put("data",resultModelDtos);
|
||||
}
|
||||
|
||||
|
||||
@ -58,9 +64,10 @@ public class ResultModelController {
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping("/delete")
|
||||
public R delete(@RequestBody Long id) {
|
||||
resultModelService.deleteResultModelById(id);
|
||||
return R.ok();
|
||||
@GetMapping("/delete")
|
||||
@ApiOperation("删除模板")
|
||||
public R delete(@RequestParam @ApiParam("模板id") Long id) {
|
||||
return resultModelService.deleteResultModelById(id);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,22 +1,19 @@
|
||||
package com.lz.modules.performance.controller;
|
||||
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.lz.common.utils.PageUtils;
|
||||
import com.lz.common.utils.R;
|
||||
import com.lz.common.utils.StringUtil;
|
||||
import com.lz.modules.flow.entity.ResultTagetLib;
|
||||
import com.lz.modules.flow.model.ResultTagetLibDto;
|
||||
import com.lz.modules.flow.req.ResultTagetLibSearchReq;
|
||||
import com.lz.modules.performance.service.ResultTagetLibService;
|
||||
import io.swagger.annotations.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/resultTagetLib")
|
||||
@Api(tags = "考核指标相关")
|
||||
public class ResultTagetLibController {
|
||||
|
||||
|
||||
@ -27,6 +24,15 @@ public class ResultTagetLibController {
|
||||
|
||||
|
||||
|
||||
@PostMapping("/GetTargetLibs")
|
||||
@ApiOperation("搜索指标库")
|
||||
@ApiResponses({@ApiResponse(code = 200,message = "成功",response = ResultTagetLibDto.class)})
|
||||
public R GetTargetLibs(@RequestBody @ApiParam ResultTagetLibSearchReq req) {
|
||||
PageUtils pageUtils = resultTagetLibService.selectResultTagetLibByReq(req);
|
||||
return R.ok().put("data",pageUtils);
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping("/getById")
|
||||
public R getById(@RequestBody ResultTagetLib resultTagetLib) {
|
||||
resultTagetLib = resultTagetLibService.selectResultTagetLibById(resultTagetLib.getId());
|
||||
@ -41,15 +47,18 @@ public class ResultTagetLibController {
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping("/save")
|
||||
public R save(@RequestBody ResultTagetLib resultTagetLib) {
|
||||
resultTagetLibService.insertResultTagetLib(resultTagetLib);
|
||||
return R.ok();
|
||||
@PostMapping("/save")
|
||||
@ApiOperation("新增考核指标")
|
||||
public R save(@RequestBody @ApiParam ResultTagetLib resultTagetLib) {
|
||||
|
||||
return resultTagetLibService.insertResultTagetLib(resultTagetLib);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@RequestMapping("/delete")
|
||||
public R delete(@RequestBody Long id) {
|
||||
@GetMapping("/delete")
|
||||
@ApiOperation("删除指标")
|
||||
public R delete(@RequestParam @ApiParam("指标id") Long id) {
|
||||
resultTagetLibService.deleteResultTagetLibById(id);
|
||||
return R.ok();
|
||||
}
|
||||
|
||||
@ -1,7 +1,13 @@
|
||||
package com.lz.modules.performance.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.lz.common.utils.PageUtils;
|
||||
import com.lz.common.utils.R;
|
||||
import com.lz.modules.flow.entity.ResultTagetLib;
|
||||
import com.lz.modules.flow.model.ResultTagetLibDto;
|
||||
import com.lz.modules.flow.req.ResultTagetLibSearchReq;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
@ -18,7 +24,7 @@ public interface ResultTagetLibService extends IService<ResultTagetLib> {
|
||||
ResultTagetLib selectResultTagetLibById(Long id);
|
||||
|
||||
|
||||
Long insertResultTagetLib(ResultTagetLib resultTagetLib);
|
||||
R insertResultTagetLib(ResultTagetLib resultTagetLib);
|
||||
|
||||
|
||||
int updateResultTagetLibById(ResultTagetLib resultTagetLib);
|
||||
@ -30,4 +36,9 @@ public interface ResultTagetLibService extends IService<ResultTagetLib> {
|
||||
int deleteResultTagetLibById(Long id);
|
||||
|
||||
|
||||
List<ResultTagetLibDto> selectResultTagetLibByModelId(Long id);
|
||||
|
||||
PageUtils selectResultTagetLibByReq(ResultTagetLibSearchReq req);
|
||||
|
||||
int deleteResultTagetLibByModelId(Long id);
|
||||
}
|
||||
@ -1,12 +1,22 @@
|
||||
package com.lz.modules.performance.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.lz.common.utils.PageUtils;
|
||||
import com.lz.common.utils.R;
|
||||
import com.lz.modules.flow.dao.ResultTagetLibMapper;
|
||||
import com.lz.modules.flow.entity.ResultModel;
|
||||
import com.lz.modules.flow.entity.ResultTagetLib;
|
||||
import com.lz.modules.flow.model.ResultTagetLibDto;
|
||||
import com.lz.modules.flow.req.ResultTagetLibSearchReq;
|
||||
import com.lz.modules.flow.service.ResultModelService;
|
||||
import com.lz.modules.performance.service.ResultTagetLibService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 考核指标库表 服务类
|
||||
@ -17,12 +27,15 @@ import org.springframework.stereotype.Service;
|
||||
*/
|
||||
|
||||
@Service
|
||||
@Slf4j
|
||||
public class ResultTagetLibServiceImpl extends ServiceImpl<ResultTagetLibMapper, ResultTagetLib> implements ResultTagetLibService {
|
||||
|
||||
|
||||
@Autowired
|
||||
private ResultTagetLibMapper resultTagetLibMapper;
|
||||
|
||||
@Autowired
|
||||
private ResultModelService resultModelService;
|
||||
|
||||
|
||||
@Override
|
||||
@ -33,8 +46,27 @@ public class ResultTagetLibServiceImpl extends ServiceImpl<ResultTagetLibMapper,
|
||||
|
||||
|
||||
@Override
|
||||
public Long insertResultTagetLib(ResultTagetLib resultTagetLib){
|
||||
return resultTagetLibMapper.insertResultTagetLib(resultTagetLib);
|
||||
public R insertResultTagetLib(ResultTagetLib resultTagetLib){
|
||||
log.info("新增指标{}", resultTagetLib);
|
||||
if(resultTagetLib.getModelId().intValue() != 0){
|
||||
//判断当前添加的权重有没有可能超过限制公共指标不做限制
|
||||
ResultModel resultModel = resultModelService.selectResultModelById(resultTagetLib.getModelId());
|
||||
if(resultModel == null){
|
||||
return R.error("找不到相关考核模板");
|
||||
}
|
||||
List<ResultTagetLibDto> resultTagetLibDtos = selectResultTagetLibByModelId(resultModel.getId());
|
||||
BigDecimal weight = BigDecimal.ZERO;
|
||||
for(int i = 0; i < resultTagetLibDtos.size(); i++){
|
||||
ResultTagetLibDto dto = resultTagetLibDtos.get(i);
|
||||
weight = weight.add(dto.getWeight());
|
||||
}
|
||||
weight = weight.add(resultTagetLib.getWeight());
|
||||
if(weight.compareTo(resultModel.getWeight()) > 0){
|
||||
return R.error("权重之和不能超过" + (resultModel.getWeight().multiply(new BigDecimal(100)) + "%" ));
|
||||
}
|
||||
}
|
||||
resultTagetLibMapper.insertResultTagetLib(resultTagetLib);
|
||||
return R.ok().put("data", resultTagetLib);
|
||||
}
|
||||
|
||||
|
||||
@ -58,6 +90,25 @@ public class ResultTagetLibServiceImpl extends ServiceImpl<ResultTagetLibMapper,
|
||||
return resultTagetLibMapper.deleteResultTagetLibById(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ResultTagetLibDto> selectResultTagetLibByModelId(Long id){
|
||||
return resultTagetLibMapper.selectResultTagetLibByModelId(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageUtils selectResultTagetLibByReq(ResultTagetLibSearchReq req){
|
||||
PageUtils pageUtils = PageUtils.startPage(req.getCurrPage(), req.getPageSize()).doSelect(
|
||||
page -> resultTagetLibMapper.selectByCondition(page, req)
|
||||
);
|
||||
return pageUtils;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int deleteResultTagetLibByModelId(Long id){
|
||||
log.info("删除模板下面的指标,模板id={}", id);
|
||||
return resultTagetLibMapper.deleteResultTagetLibByModelId(id);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -89,6 +89,13 @@
|
||||
update lz_evaluation_group set is_delete = 1 where id=#{id} limit 1
|
||||
</update>
|
||||
|
||||
<select id="seleteEvaluationGroupByReq" resultType="EvaluationGroup" >
|
||||
select * from lz_evaluation_group where is_delete = 0
|
||||
<if test="req.startTime != null"><![CDATA[and gmt_create > #{req.startTime}]]></if>
|
||||
<if test="req.endTime != null"><![CDATA[and gmt_create < #{req.endTime}]]></if>
|
||||
<if test="req.name != null and req.name != ''">and name like concat('%', #{req.name} '%') </if>
|
||||
</select>
|
||||
|
||||
|
||||
</mapper>
|
||||
|
||||
|
||||
@ -108,5 +108,13 @@
|
||||
select * from lz_result_model where evaluation_group_id=#{id} and is_delete = 0
|
||||
</select>
|
||||
|
||||
<select id="selectResultDtoByGroupId" resultType="com.lz.modules.flow.model.ResultModelDto" >
|
||||
select * from lz_result_model where evaluation_group_id=#{id} and is_delete = 0
|
||||
</select>
|
||||
|
||||
<update id="deleteResultModelByGroupId" parameterType="java.lang.Long">
|
||||
update lz_result_model set is_delete = 1 where evaluation_group_id=#{id}
|
||||
</update>
|
||||
|
||||
</mapper>
|
||||
|
||||
|
||||
@ -84,5 +84,20 @@
|
||||
update lz_result_taget_lib set is_delete = 1 where id=#{id} limit 1
|
||||
</update>
|
||||
|
||||
<select id="selectResultTagetLibByModelId" resultType="com.lz.modules.flow.model.ResultTagetLibDto" >
|
||||
select * from lz_result_taget_lib where model_id=#{id} and is_delete = 0 limit 1
|
||||
</select>
|
||||
|
||||
<select id="selectByCondition" resultType="ResultTagetLib" >
|
||||
select * from lz_result_taget_lib where is_delete = 0
|
||||
<if test="req.name != null and req.name != ''">and name like CONCAT('%', req.name, '%')</if>
|
||||
<if test="req.modelId != null">and model_id = #{req.modelId} </if>
|
||||
<if test="req.weight != null">and weight = #{req.weight} </if>
|
||||
</select>
|
||||
|
||||
<update id="deleteResultTagetLibByModelId" parameterType="java.lang.Long">
|
||||
update lz_result_taget_lib set is_delete = 1 where model_id=#{id}
|
||||
</update>
|
||||
|
||||
</mapper>
|
||||
|
||||
|
||||
@ -75,7 +75,7 @@ public class MysqlMain {
|
||||
list.add(new TablesBean("lz_result_calculate"));
|
||||
list.add(new TablesBean("lz_result_dimension"));
|
||||
list.add(new TablesBean("lz_result_grade"));*/
|
||||
//list.add(new TablesBean("lz_result_model"));
|
||||
list.add(new TablesBean("lz_result_model"));
|
||||
//list.add(new TablesBean("lz_result_score"));
|
||||
list.add(new TablesBean("lz_result_taget_lib"));
|
||||
|
||||
@ -97,7 +97,7 @@ public class MysqlMain {
|
||||
}
|
||||
|
||||
|
||||
for (int i = 0; i < list2.size(); i++) {
|
||||
/* for (int i = 0; i < list2.size(); i++) {
|
||||
MysqlUtilTable2Contoller.printController(list2.get(i));
|
||||
}
|
||||
|
||||
@ -109,7 +109,7 @@ public class MysqlMain {
|
||||
for (int i = 0; i < list2.size(); i++) {
|
||||
MysqlUtilTable2Service.printService(list2.get(i));
|
||||
MysqlUtilTable2Service.printServiceImpl(list2.get(i));
|
||||
}
|
||||
}*/
|
||||
|
||||
for (int i = 0; i < list2.size(); i++) {
|
||||
MysqlUtilTable2XML.printXMLForMap(list2.get(i));
|
||||
|
||||
@ -148,7 +148,7 @@ public class MysqlUtilTable2Bean {
|
||||
|
||||
|
||||
content += "@Data\n";
|
||||
content += "@ApiModel(value = \"" + tableBean.getComment() + "\")\n";
|
||||
content += "@ApiModel(value = \"" + tableBean.getComment() + "Req\")\n";
|
||||
content += "public class " + realName + "Req implements java.io.Serializable {\n" + bf.toString();
|
||||
content += sb.toString();
|
||||
content += "}";
|
||||
@ -395,7 +395,7 @@ public class MysqlUtilTable2Bean {
|
||||
|
||||
content += "\n";
|
||||
content += "@Data\n";
|
||||
content += "@ApiModel(value = \"" + tableBean.getComment() + "\")\n";
|
||||
content += "@ApiModel(value = \"" + tableBean.getComment() + "Dto\")\n";
|
||||
content += "public class " + realName + "Dto {\n" + bf.toString();
|
||||
content += sb.toString();
|
||||
content += "}";
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user