Commit 3d07de94 by 崔彦峰

Merge remote-tracking branch 'origin/v5.6.0' into v5.6.0

2 parents 943519c4 380f8929
Showing 23 changed files with 510 additions and 44 deletions
...@@ -4,6 +4,7 @@ import cn.com.glsx.dj.staff.model.StaffSalaryAppealApplyRecord; ...@@ -4,6 +4,7 @@ import cn.com.glsx.dj.staff.model.StaffSalaryAppealApplyRecord;
import lombok.Data; import lombok.Data;
import lombok.EqualsAndHashCode; import lombok.EqualsAndHashCode;
import java.util.List;
/** /**
* 员工工资申诉记录表 * 员工工资申诉记录表
...@@ -13,4 +14,18 @@ import lombok.EqualsAndHashCode; ...@@ -13,4 +14,18 @@ import lombok.EqualsAndHashCode;
public class StaffSalaryAppealApplyRecordDTO extends StaffSalaryAppealApplyRecord { public class StaffSalaryAppealApplyRecordDTO extends StaffSalaryAppealApplyRecord {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
/**
* 附件列表
*/
private List<SalaryAppealApplyAttachmentDTO> attachmentList;
/**
* 查询条件:申诉开始时间
*/
private String applyStartTime;
/**
* 查询条件:申诉结束时间
*/
private String applyEndTime;
} }
\ No newline at end of file \ No newline at end of file
package cn.com.glsx.dj.staff.dto.perfSalary; package cn.com.glsx.dj.staff.dto.perfSalary;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Data; import lombok.Data;
...@@ -8,7 +7,6 @@ import lombok.NoArgsConstructor; ...@@ -8,7 +7,6 @@ import lombok.NoArgsConstructor;
import java.io.Serializable; import java.io.Serializable;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.Date;
/** /**
* 员工绩效 * 员工绩效
...@@ -37,14 +35,7 @@ public class AppraisalInfoDTO implements Serializable { ...@@ -37,14 +35,7 @@ public class AppraisalInfoDTO implements Serializable {
* 评分月份(yyyy-mm) * 评分月份(yyyy-mm)
*/ */
@ApiModelProperty(notes = "评分月份(yyyy-mm)") @ApiModelProperty(notes = "评分月份(yyyy-mm)")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") private String evaluationMonth;
private Date evaluationMonth;
/**
* 门店id
*/
@ApiModelProperty(notes = "门店id")
private Integer merchantId;
/** /**
* 门店名称 * 门店名称
...@@ -53,6 +44,12 @@ public class AppraisalInfoDTO implements Serializable { ...@@ -53,6 +44,12 @@ public class AppraisalInfoDTO implements Serializable {
private String merchantName; private String merchantName;
/** /**
* 绩效等级-系统自动设置
*/
@ApiModelProperty(notes = "绩效等级-系统自动设置")
private String autoGradeCode;
/**
* 奖励系数-系统自动设置 * 奖励系数-系统自动设置
*/ */
@ApiModelProperty(notes = "奖励系数-系统自动设置") @ApiModelProperty(notes = "奖励系数-系统自动设置")
...@@ -86,8 +83,7 @@ public class AppraisalInfoDTO implements Serializable { ...@@ -86,8 +83,7 @@ public class AppraisalInfoDTO implements Serializable {
* 入职日期 * 入职日期
*/ */
@ApiModelProperty(notes = "入职日期") @ApiModelProperty(notes = "入职日期")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") private String entryDate;
private Date entryDate;
/** /**
* 自动绩效配置id * 自动绩效配置id
......
package cn.com.glsx.dj.staff.dto.perfSalary; package cn.com.glsx.dj.staff.dto.perfSalary;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Data; import lombok.Data;
import lombok.NoArgsConstructor; import lombok.NoArgsConstructor;
import java.io.Serializable; import java.io.Serializable;
import java.util.Date;
/** /**
* 自动评绩效规则配置表 * 自动评绩效规则配置表
...@@ -113,9 +111,8 @@ public class AutoPerformRuleUpdateDTO implements Serializable { ...@@ -113,9 +111,8 @@ public class AutoPerformRuleUpdateDTO implements Serializable {
/** /**
* 生效月份(yyyy-mm格式) * 生效月份(yyyy-mm格式)
*/ */
@ApiModelProperty(notes = "生效月份-传参格式:yyyy-MM-dd") @ApiModelProperty(notes = "生效月份-传参格式:yyyy-MM")
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") private String effectiveMonth;
private Date effectiveMonth;
/** /**
* 生效状态:1-生效中,2-待生效 * 生效状态:1-生效中,2-待生效
......
package cn.com.glsx.dj.staff.dto.perfSalary; package cn.com.glsx.dj.staff.dto.perfSalary;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Data; import lombok.Data;
...@@ -8,7 +7,6 @@ import lombok.NoArgsConstructor; ...@@ -8,7 +7,6 @@ import lombok.NoArgsConstructor;
import lombok.ToString; import lombok.ToString;
import java.io.Serializable; import java.io.Serializable;
import java.util.Date;
@Data @Data
@AllArgsConstructor @AllArgsConstructor
...@@ -20,9 +18,8 @@ public class PerfRuleReqDTO implements Serializable { ...@@ -20,9 +18,8 @@ public class PerfRuleReqDTO implements Serializable {
/** /**
* 查询月份 * 查询月份
*/ */
@ApiModelProperty(notes = "查询月份-传参格式:yyyy-MM-dd") @ApiModelProperty(notes = "查询月份-传参格式:yyyy-MM")
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") private String queryMonth;
private Date queryMonth;
/** /**
* 区域经理手机号 * 区域经理手机号
...@@ -40,7 +37,7 @@ public class PerfRuleReqDTO implements Serializable { ...@@ -40,7 +37,7 @@ public class PerfRuleReqDTO implements Serializable {
* 门店id * 门店id
*/ */
@ApiModelProperty(notes = "门店id") @ApiModelProperty(notes = "门店id")
private String merchantId; private Integer merchantId;
/** /**
* 绩效等级 * 绩效等级
......
...@@ -8,7 +8,7 @@ import lombok.Getter; ...@@ -8,7 +8,7 @@ import lombok.Getter;
*/ */
@AllArgsConstructor @AllArgsConstructor
@Getter @Getter
public enum CommissionBaseEnum implements BaseEnum<Integer, String> { public enum CommissionBaseEnum implements BaseEnum<String, String> {
GMV("GMV", "GMV产值"), GMV("GMV", "GMV产值"),
SJDDS("SJDDS", "升级订单数"), SJDDS("SJDDS", "升级订单数"),
DDTC("DDTC", "单店提成"); DDTC("DDTC", "单店提成");
......
...@@ -8,7 +8,7 @@ import lombok.Getter; ...@@ -8,7 +8,7 @@ import lombok.Getter;
*/ */
@AllArgsConstructor @AllArgsConstructor
@Getter @Getter
public enum CommissionMethodEnum implements BaseEnum<Integer, String> { public enum CommissionMethodEnum implements BaseEnum<String, String> {
BL("BL", "比例"), BL("BL", "比例"),
XS("XS", "系数"), XS("XS", "系数"),
GDJE("GDJE", "固定金额"); GDJE("GDJE", "固定金额");
......
...@@ -70,6 +70,13 @@ public class StaffSalaryAppealApplyRecord implements Serializable { ...@@ -70,6 +70,13 @@ public class StaffSalaryAppealApplyRecord implements Serializable {
private Integer sceneType; private Integer sceneType;
/** /**
* 发起时选择的4s店
*/
@ApiModelProperty(notes = "发起时选择的4s店")
@Column(name = "merchant_id")
private Integer merchantId;
/**
* 实际出勤天数 * 实际出勤天数
*/ */
@ApiModelProperty(notes = "实际出勤天数") @ApiModelProperty(notes = "实际出勤天数")
...@@ -154,6 +161,14 @@ public class StaffSalaryAppealApplyRecord implements Serializable { ...@@ -154,6 +161,14 @@ public class StaffSalaryAppealApplyRecord implements Serializable {
private String replyContent; private String replyContent;
/** /**
* 答复时间
*/
@ApiModelProperty(notes = "答复时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
@Column(name = "reply_date")
private Date replyDate;
/**
* 其他异常留言 * 其他异常留言
*/ */
@ApiModelProperty(notes = "其他异常留言") @ApiModelProperty(notes = "其他异常留言")
......
...@@ -63,4 +63,14 @@ public interface PerfRuleRemote { ...@@ -63,4 +63,14 @@ public interface PerfRuleRemote {
* 打卡数据 * 打卡数据
*/ */
RpcResponse<Boolean> clockInCompleteAnalysisStaff(); RpcResponse<Boolean> clockInCompleteAnalysisStaff();
/**
* 定时任务-绩效配置设置
*/
RpcResponse<Boolean> syncQwClockInDetailData(String clockInDateStr);
/**
* 每月自动评绩效
*/
RpcResponse<Boolean> autoPerfEvaluation();
} }
package cn.com.glsx.dj.staff.remote.salaryappealapply;
import cn.com.glsx.dj.staff.dto.StaffSalaryAppealApplyRecordDTO;
import cn.com.glsx.framework.core.annotation.ApiService;
import cn.com.glsx.framework.core.beans.rpc.RpcPagination;
import cn.com.glsx.framework.core.beans.rpc.RpcResponse;
import java.util.List;
@ApiService(value = "员工工资绩效申诉管理", owner = "linchong", protocol = ApiService.ProtocolEnum.dubbo, version = "1.0.0")
public interface StaffSalaryAppealApplyRecordRemote {
/**
* 新增申诉
*/
RpcResponse<Boolean> createAppeal(StaffSalaryAppealApplyRecordDTO dto);
/**
* 分页查询申诉记录
*/
RpcResponse<RpcPagination<StaffSalaryAppealApplyRecordDTO>> pageList(RpcPagination<StaffSalaryAppealApplyRecordDTO> pagination);
/**
* 根据id查询详情
*/
RpcResponse<StaffSalaryAppealApplyRecordDTO> detail(StaffSalaryAppealApplyRecordDTO dto);
/**
* 查询最新申诉记录
*/
RpcResponse<StaffSalaryAppealApplyRecordDTO> queryLatest(StaffSalaryAppealApplyRecordDTO dto);
/**
* 查询复议记录列表
*/
RpcResponse<List<StaffSalaryAppealApplyRecordDTO>> replyRecordList(StaffSalaryAppealApplyRecordDTO dto);
}
...@@ -20,7 +20,8 @@ public class AutoPerfEvaluationJob implements SimpleJob { ...@@ -20,7 +20,8 @@ public class AutoPerfEvaluationJob implements SimpleJob {
public void execute(ShardingContext shardingContext) { public void execute(ShardingContext shardingContext) {
log.info("----------------每月自动评绩效开始-----------------"); log.info("----------------每月自动评绩效开始-----------------");
try { try {
autoPerfEvaluationService.autoPerfEvaluation(); log.info("分片参数:{}", shardingContext.getJobParameter());
autoPerfEvaluationService.autoPerfEvaluation(shardingContext.getJobParameter());
} catch (Exception e) { } catch (Exception e) {
log.error(e.getMessage(), e); log.error(e.getMessage(), e);
} }
......
...@@ -20,7 +20,7 @@ public class PerfRuleSettingJob implements SimpleJob { ...@@ -20,7 +20,7 @@ public class PerfRuleSettingJob implements SimpleJob {
public void execute(ShardingContext shardingContext) { public void execute(ShardingContext shardingContext) {
log.info("----------------绩效配置设置开始-----------------"); log.info("----------------绩效配置设置开始-----------------");
try { try {
perfRuleRemoteService.perfRuleSettingJob(); perfRuleRemoteService.perfRuleSettingJob(shardingContext.getJobParameter());
} catch (Exception e) { } catch (Exception e) {
log.error(e.getMessage(), e); log.error(e.getMessage(), e);
} }
......
package cn.com.glsx.dj.staff.mapper; package cn.com.glsx.dj.staff.mapper;
import cn.com.glsx.dj.staff.dto.StaffSalaryAppealApplyRecordDTO;
import cn.com.glsx.dj.staff.model.StaffSalaryAppealApplyRecord; import cn.com.glsx.dj.staff.model.StaffSalaryAppealApplyRecord;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.oreframework.datasource.mybatis.mapper.OreMapper; import org.oreframework.datasource.mybatis.mapper.OreMapper;
import java.util.List;
@Mapper @Mapper
public interface StaffSalaryAppealApplyRecordMapper extends OreMapper<StaffSalaryAppealApplyRecord> { public interface StaffSalaryAppealApplyRecordMapper extends OreMapper<StaffSalaryAppealApplyRecord> {
/**
* 分页查询申诉记录
*/
List<StaffSalaryAppealApplyRecordDTO> pageList(StaffSalaryAppealApplyRecordDTO condition);
} }
\ No newline at end of file \ No newline at end of file
package cn.com.glsx.dj.staff.mapper.perfSalary; package cn.com.glsx.dj.staff.mapper.perfSalary;
import cn.com.glsx.dj.staff.dto.perfSalary.AppraisalInfoDTO;
import cn.com.glsx.dj.staff.dto.perfSalary.PerfAppraisalStatisticsCardDTO;
import cn.com.glsx.dj.staff.dto.perfSalary.PerfRuleReqDTO;
import cn.com.glsx.dj.staff.model.perfSalary.PerformanceEvaluation; import cn.com.glsx.dj.staff.model.perfSalary.PerformanceEvaluation;
import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
...@@ -13,4 +16,8 @@ public interface PerformanceEvaluationMapper extends OreMapper<PerformanceEvalua ...@@ -13,4 +16,8 @@ public interface PerformanceEvaluationMapper extends OreMapper<PerformanceEvalua
void insertOrUpdate(PerformanceEvaluation performanceEvaluation); void insertOrUpdate(PerformanceEvaluation performanceEvaluation);
void insertOrUpdateBatch(@Param("list") List<PerformanceEvaluation> performanceEvaluationList); void insertOrUpdateBatch(@Param("list") List<PerformanceEvaluation> performanceEvaluationList);
PerfAppraisalStatisticsCardDTO perfAppraisalStatisticsCard(PerfRuleReqDTO perfRuleReqDTO);
List<AppraisalInfoDTO> perfAppraisalList(PerfRuleReqDTO perfRuleReqDTO);
} }
\ No newline at end of file \ No newline at end of file
package cn.com.glsx.dj.staff.remote.perfSalary; package cn.com.glsx.dj.staff.remote.perfSalary;
import cn.com.glsx.dj.staff.dto.perfSalary.*; import cn.com.glsx.dj.staff.dto.perfSalary.*;
import cn.com.glsx.dj.staff.service.perfSalary.AttendanceDataCleansingService; import cn.com.glsx.dj.staff.service.perfSalary.*;
import cn.com.glsx.dj.staff.service.perfSalary.ClockInCompleteAnalysisStaffService;
import cn.com.glsx.dj.staff.service.perfSalary.PerfRuleRemoteService;
import cn.com.glsx.framework.core.beans.rpc.RpcResponse; import cn.com.glsx.framework.core.beans.rpc.RpcResponse;
import cn.com.glsx.framework.core.exception.RpcServiceException; import cn.com.glsx.framework.core.exception.RpcServiceException;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
...@@ -22,6 +20,10 @@ public class PerfRuleRemoteImpl implements PerfRuleRemote { ...@@ -22,6 +20,10 @@ public class PerfRuleRemoteImpl implements PerfRuleRemote {
private AttendanceDataCleansingService attendanceDataCleansingService; private AttendanceDataCleansingService attendanceDataCleansingService;
@Resource @Resource
private ClockInCompleteAnalysisStaffService clockInCompleteAnalysisStaffService; private ClockInCompleteAnalysisStaffService clockInCompleteAnalysisStaffService;
@Resource
private AutoPerfEvaluationService autoPerfEvaluationService;
@Resource
private PerformanceEvaluationService performanceEvaluationService;
...@@ -69,7 +71,12 @@ public class PerfRuleRemoteImpl implements PerfRuleRemote { ...@@ -69,7 +71,12 @@ public class PerfRuleRemoteImpl implements PerfRuleRemote {
*/ */
@Override @Override
public RpcResponse<PerfAppraisalStatisticsCardDTO> perfAppraisalStatisticsCard(PerfRuleReqDTO perfRuleReqDTO) { public RpcResponse<PerfAppraisalStatisticsCardDTO> perfAppraisalStatisticsCard(PerfRuleReqDTO perfRuleReqDTO) {
return null; try {
return RpcResponse.success(performanceEvaluationService.perfAppraisalStatisticsCard(perfRuleReqDTO));
} catch (RpcServiceException e) {
log.error(e.getMessage(), e);
return RpcResponse.error(e);
}
} }
/** /**
...@@ -77,7 +84,12 @@ public class PerfRuleRemoteImpl implements PerfRuleRemote { ...@@ -77,7 +84,12 @@ public class PerfRuleRemoteImpl implements PerfRuleRemote {
*/ */
@Override @Override
public RpcResponse<List<AppraisalInfoDTO>> perfAppraisalList(PerfRuleReqDTO perfRuleReqDTO) { public RpcResponse<List<AppraisalInfoDTO>> perfAppraisalList(PerfRuleReqDTO perfRuleReqDTO) {
return null; try {
return RpcResponse.success(performanceEvaluationService.perfAppraisalList(perfRuleReqDTO));
} catch (RpcServiceException e) {
log.error(e.getMessage(), e);
return RpcResponse.error(e);
}
} }
/** /**
...@@ -130,5 +142,23 @@ public class PerfRuleRemoteImpl implements PerfRuleRemote { ...@@ -130,5 +142,23 @@ public class PerfRuleRemoteImpl implements PerfRuleRemote {
return RpcResponse.success(true); return RpcResponse.success(true);
} }
/**
* 定时任务-绩效配置设置
*/
@Override
public RpcResponse<Boolean> syncQwClockInDetailData(String clockInDateStr) {
perfRuleRemoteService.perfRuleSettingJob("");
return RpcResponse.success(true);
}
/**
* 每月自动评绩效
*/
@Override
public RpcResponse<Boolean> autoPerfEvaluation() {
autoPerfEvaluationService.autoPerfEvaluation("");
return RpcResponse.success(true);
}
} }
package cn.com.glsx.dj.staff.remote.salaryappealapply;
import cn.com.glsx.dj.staff.dto.StaffSalaryAppealApplyRecordDTO;
import cn.com.glsx.dj.staff.service.StaffSalaryAppealApplyRecordService;
import cn.com.glsx.framework.core.beans.rpc.RpcPagination;
import cn.com.glsx.framework.core.beans.rpc.RpcResponse;
import lombok.extern.slf4j.Slf4j;
import org.apache.dubbo.config.annotation.DubboService;
import javax.annotation.Resource;
import java.util.List;
@Slf4j
@DubboService(version = "1.0.0", validation = "true")
public class StaffSalaryAppealApplyRecordRemoteImpl implements StaffSalaryAppealApplyRecordRemote {
@Resource
private StaffSalaryAppealApplyRecordService staffSalaryAppealApplyRecordService;
@Override
public RpcResponse<Boolean> createAppeal(StaffSalaryAppealApplyRecordDTO dto) {
try {
log.info("createAppeal start, dto:{}", dto);
Boolean result = staffSalaryAppealApplyRecordService.createAppeal(dto);
return RpcResponse.success(result);
} catch (Exception e) {
log.error(e.getMessage(),e);
return RpcResponse.error(e);
}
}
@Override
public RpcResponse<RpcPagination<StaffSalaryAppealApplyRecordDTO>> pageList(RpcPagination<StaffSalaryAppealApplyRecordDTO> pagination) {
try{
pagination = RpcPagination.copyPage(staffSalaryAppealApplyRecordService.pageList(pagination));
return RpcResponse.success(pagination);
}catch(Exception e){
log.error(e.getMessage(), e);
return RpcResponse.error(e);
}
}
@Override
public RpcResponse<StaffSalaryAppealApplyRecordDTO> detail(StaffSalaryAppealApplyRecordDTO dto) {
try {
log.info("detail start, dto:{}", dto);
StaffSalaryAppealApplyRecordDTO result = staffSalaryAppealApplyRecordService.detail(dto.getId());
return RpcResponse.success(result);
} catch (Exception e) {
log.error(e.getMessage(),e);
return RpcResponse.error(e);
}
}
@Override
public RpcResponse<StaffSalaryAppealApplyRecordDTO> queryLatest(StaffSalaryAppealApplyRecordDTO dto) {
try {
log.info("queryLatest start, dto:{}", dto);
StaffSalaryAppealApplyRecordDTO result = staffSalaryAppealApplyRecordService.queryLatest(dto);
return RpcResponse.success(result);
} catch (Exception e) {
log.error(e.getMessage(),e);
return RpcResponse.error(e);
}
}
@Override
public RpcResponse<List<StaffSalaryAppealApplyRecordDTO>> replyRecordList(StaffSalaryAppealApplyRecordDTO dto) {
try {
log.info("replyRecordList start, dto:{}", dto);
List<StaffSalaryAppealApplyRecordDTO> result = staffSalaryAppealApplyRecordService.replyRecordList(dto);
return RpcResponse.success(result);
} catch (Exception e) {
log.error(e.getMessage(),e);
return RpcResponse.error(e);
}
}
}
package cn.com.glsx.dj.staff.service; package cn.com.glsx.dj.staff.service;
import cn.com.glsx.dj.staff.dto.SalaryAppealApplyAttachmentDTO;
import cn.com.glsx.dj.staff.dto.StaffSalaryAppealApplyRecordDTO;
import cn.com.glsx.dj.staff.mapper.SalaryAppealApplyAttachmentMapper;
import cn.com.glsx.dj.staff.mapper.StaffSalaryAppealApplyRecordMapper; import cn.com.glsx.dj.staff.mapper.StaffSalaryAppealApplyRecordMapper;
import cn.com.glsx.dj.staff.model.SalaryAppealApplyAttachment;
import cn.com.glsx.dj.staff.model.StaffSalaryAppealApplyRecord;
import cn.com.glsx.framework.core.beans.rpc.RpcPagination;
import cn.com.glsx.framework.core.exception.RpcServiceException; import cn.com.glsx.framework.core.exception.RpcServiceException;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import tk.mybatis.mapper.entity.Example;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.stream.Collectors;
@Slf4j @Slf4j
...@@ -18,9 +33,150 @@ public class StaffSalaryAppealApplyRecordService { ...@@ -18,9 +33,150 @@ public class StaffSalaryAppealApplyRecordService {
@Resource @Resource
private StaffSalaryAppealApplyRecordMapper staffSalaryAppealApplyRecordMapper; private StaffSalaryAppealApplyRecordMapper staffSalaryAppealApplyRecordMapper;
@Resource
private SalaryAppealApplyAttachmentMapper salaryAppealApplyAttachmentMapper;
/**
* 新增申诉
*/
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = RpcServiceException.class) @Transactional(propagation = Propagation.REQUIRED, rollbackFor = RpcServiceException.class)
public void test(String test) { public Boolean createAppeal(StaffSalaryAppealApplyRecordDTO dto) {
log.info("createAppeal start, dto:{}", dto);
// 保存主表
StaffSalaryAppealApplyRecord record = new StaffSalaryAppealApplyRecord();
BeanUtils.copyProperties(dto, record);
record.setCreatedDate(new Date());
record.setUpdatedDate(new Date());
record.setDeletedFlag("N");
int result = staffSalaryAppealApplyRecordMapper.insertSelective(record);
if (result > 0) {
// 保存附件
if (CollectionUtils.isNotEmpty(dto.getAttachmentList())) {
for (SalaryAppealApplyAttachmentDTO attachmentDTO : dto.getAttachmentList()) {
SalaryAppealApplyAttachment attachment = new SalaryAppealApplyAttachment();
BeanUtils.copyProperties(attachmentDTO, attachment);
attachment.setSalaryAppealApplyRecordId(record.getId());
attachment.setCreatedBy(dto.getCreatedBy());
attachment.setUpdatedBy(dto.getUpdatedBy());
attachment.setCreatedDate(new Date());
attachment.setUpdatedDate(new Date());
attachment.setDeletedFlag("N");
salaryAppealApplyAttachmentMapper.insertSelective(attachment);
}
}
return true;
}
return false;
}
/**
* 分页查询
*/
public Page<StaffSalaryAppealApplyRecordDTO> pageList(RpcPagination<StaffSalaryAppealApplyRecordDTO> pagination) {
log.info("pageList start, pagination:{}", pagination);
try {
Page<StaffSalaryAppealApplyRecordDTO> page = PageHelper.startPage(pagination.getPageNum(), pagination.getPageSize(), pagination.isNeedCount());
staffSalaryAppealApplyRecordMapper.pageList(pagination.getCondition());
return page;
} catch (Exception e) {
log.error("pageList error", e);
throw new RpcServiceException("分页查询失败:" + e.getMessage());
}
} }
/**
* 查询详情
*/
public StaffSalaryAppealApplyRecordDTO detail(Integer id) {
log.info("detail start, id:{}", id);
StaffSalaryAppealApplyRecord record = staffSalaryAppealApplyRecordMapper.selectByPrimaryKey(id);
if (record == null) {
return null;
}
StaffSalaryAppealApplyRecordDTO dto = new StaffSalaryAppealApplyRecordDTO();
BeanUtils.copyProperties(record, dto);
// 查询附件
dto.setAttachmentList(getAttachmentList(id));
return dto;
}
/**
* 查询最新申诉记录
*/
public StaffSalaryAppealApplyRecordDTO queryLatest(StaffSalaryAppealApplyRecordDTO condition) {
log.info("queryLatest start, condition:{}", condition);
Example example = new Example(StaffSalaryAppealApplyRecord.class);
Example.Criteria criteria = example.createCriteria();
criteria.andEqualTo("deletedFlag", "N");
criteria.andEqualTo("staffPhone", condition.getStaffPhone());
criteria.andEqualTo("appealMonth", condition.getAppealMonth());
criteria.andEqualTo("appealType", condition.getAppealType());
example.orderBy("createdDate").desc();
List<StaffSalaryAppealApplyRecord> list = staffSalaryAppealApplyRecordMapper.selectByExample(example);
if (CollectionUtils.isEmpty(list)) {
return null;
}
StaffSalaryAppealApplyRecord record = list.get(0);
StaffSalaryAppealApplyRecordDTO dto = new StaffSalaryAppealApplyRecordDTO();
BeanUtils.copyProperties(record, dto);
// 查询附件
dto.setAttachmentList(getAttachmentList(record.getId()));
return dto;
}
/**
* 查询复议记录列表(根据人、申诉月份拿到最新的回复记录,按照回复时间倒序,最多两条)
*/
public List<StaffSalaryAppealApplyRecordDTO> replyRecordList(StaffSalaryAppealApplyRecordDTO condition) {
log.info("replyRecordList start, condition:{}", condition);
Example example = new Example(StaffSalaryAppealApplyRecord.class);
Example.Criteria criteria = example.createCriteria();
criteria.andEqualTo("deletedFlag", "N");
criteria.andEqualTo("staffPhone", condition.getStaffPhone());
criteria.andEqualTo("appealMonth", condition.getAppealMonth());
criteria.andIsNotNull("replyDate"); // 只查询已回复的记录
// 按照回复时间倒序
example.orderBy("replyDate").desc();
List<StaffSalaryAppealApplyRecord> list = staffSalaryAppealApplyRecordMapper.selectByExample(example);
if (CollectionUtils.isEmpty(list)) {
return new ArrayList<>();
}
// 最多只返回两条
List<StaffSalaryAppealApplyRecord> resultList = list.size() > 2 ? list.subList(0, 2) : list;
return resultList.stream().map(record -> {
StaffSalaryAppealApplyRecordDTO dto = new StaffSalaryAppealApplyRecordDTO();
BeanUtils.copyProperties(record, dto);
return dto;
}).collect(Collectors.toList());
}
/**
* 查询附件列表
*/
private List<SalaryAppealApplyAttachmentDTO> getAttachmentList(Integer recordId) {
Example example = new Example(SalaryAppealApplyAttachment.class);
Example.Criteria criteria = example.createCriteria();
criteria.andEqualTo("salaryAppealApplyRecordId", recordId);
criteria.andEqualTo("deletedFlag", "N");
List<SalaryAppealApplyAttachment> attachments = salaryAppealApplyAttachmentMapper.selectByExample(example);
if (CollectionUtils.isEmpty(attachments)) {
return new ArrayList<>();
}
return attachments.stream().map(attachment -> {
SalaryAppealApplyAttachmentDTO dto = new SalaryAppealApplyAttachmentDTO();
BeanUtils.copyProperties(attachment, dto);
return dto;
}).collect(Collectors.toList());
}
} }
\ No newline at end of file \ No newline at end of file
...@@ -64,7 +64,7 @@ public class AutoPerfEvaluationService { ...@@ -64,7 +64,7 @@ public class AutoPerfEvaluationService {
/** /**
* 每月自动评绩效 * 每月自动评绩效
*/ */
public void autoPerfEvaluation() { public void autoPerfEvaluation(String monthDate) {
// 查询生效中的自动绩效配置 // 查询生效中的自动绩效配置
Example autoPerformRuleExample = new Example(AutoPerformRule.class); Example autoPerformRuleExample = new Example(AutoPerformRule.class);
autoPerformRuleExample.createCriteria().andEqualTo("deletedFlag", 'N') autoPerformRuleExample.createCriteria().andEqualTo("deletedFlag", 'N')
...@@ -77,7 +77,7 @@ public class AutoPerfEvaluationService { ...@@ -77,7 +77,7 @@ public class AutoPerfEvaluationService {
// 查询北森同步表 获取该月在职或该月离职的员工 // 查询北森同步表 获取该月在职或该月离职的员工
Example staffBeisenBaseExample = new Example(StaffBeisenBaseInfo.class); Example staffBeisenBaseExample = new Example(StaffBeisenBaseInfo.class);
// 上个月 // 上个月
DateTime lastMonthDate = DateUtil.offsetMonth(new Date(), -1); DateTime lastMonthDate = StrUtil.isNotBlank(monthDate) ? DateUtil.parse(monthDate) : DateUtil.offsetMonth(new Date(), -1);
DateTime lastMonthFirstYMD = DateUtil.beginOfMonth(lastMonthDate); DateTime lastMonthFirstYMD = DateUtil.beginOfMonth(lastMonthDate);
DateTime lastMonthLastYMD = DateUtil.endOfMonth(lastMonthDate); DateTime lastMonthLastYMD = DateUtil.endOfMonth(lastMonthDate);
String lastMonth = DateUtil.format(lastMonthDate, DatePattern.NORM_MONTH_PATTERN); String lastMonth = DateUtil.format(lastMonthDate, DatePattern.NORM_MONTH_PATTERN);
......
...@@ -4,6 +4,7 @@ import cn.com.glsx.dj.staff.dto.perfSalary.*; ...@@ -4,6 +4,7 @@ import cn.com.glsx.dj.staff.dto.perfSalary.*;
import cn.com.glsx.dj.staff.enums.perfSalary.EffectiveStatusEnum; import cn.com.glsx.dj.staff.enums.perfSalary.EffectiveStatusEnum;
import cn.com.glsx.dj.staff.enums.perfSalary.PerfRuleConfigStarEnum; import cn.com.glsx.dj.staff.enums.perfSalary.PerfRuleConfigStarEnum;
import cn.com.glsx.dj.staff.mapper.perfSalary.AutoPerformRuleMapper; import cn.com.glsx.dj.staff.mapper.perfSalary.AutoPerformRuleMapper;
import cn.com.glsx.dj.staff.mapper.perfSalary.PerformanceEvaluationMapper;
import cn.com.glsx.dj.staff.mapper.perfSalary.PerformanceLevelMapper; import cn.com.glsx.dj.staff.mapper.perfSalary.PerformanceLevelMapper;
import cn.com.glsx.dj.staff.mapper.perfSalary.PerformanceMonthlyMapper; import cn.com.glsx.dj.staff.mapper.perfSalary.PerformanceMonthlyMapper;
import cn.com.glsx.dj.staff.model.perfSalary.AutoPerformRule; import cn.com.glsx.dj.staff.model.perfSalary.AutoPerformRule;
...@@ -45,6 +46,9 @@ public class PerfRuleRemoteService { ...@@ -45,6 +46,9 @@ public class PerfRuleRemoteService {
@Resource @Resource
private PerformanceMonthlyMapper performanceMonthlyMapper; private PerformanceMonthlyMapper performanceMonthlyMapper;
@Resource
private PerformanceEvaluationMapper performanceEvaluationMapper;
// 当月入职新员工-规则外的默认等级编码 // 当月入职新员工-规则外的默认等级编码
String monthOnboardDefaultLevelCode = OrePropertyConfigurer.getProperty("month_onboard_default_level_code", String.class, "B"); String monthOnboardDefaultLevelCode = OrePropertyConfigurer.getProperty("month_onboard_default_level_code", String.class, "B");
...@@ -79,8 +83,8 @@ public class PerfRuleRemoteService { ...@@ -79,8 +83,8 @@ public class PerfRuleRemoteService {
AutoPerformRuleUpdateDTO autoPerformRuleUpdateDTO = perfRuleConfigUpdateDTO.getAutoPerformRuleUpdateDTO(); AutoPerformRuleUpdateDTO autoPerformRuleUpdateDTO = perfRuleConfigUpdateDTO.getAutoPerformRuleUpdateDTO();
List<PerformanceLevelUpdateDTO> performanceLevelUpdateDTOS = perfRuleConfigUpdateDTO.getPerformanceLevelUpdateDTOS(); List<PerformanceLevelUpdateDTO> performanceLevelUpdateDTOS = perfRuleConfigUpdateDTO.getPerformanceLevelUpdateDTOS();
// hutool判断生效月份是当月或未来月份 如果不是则抛异常 // hutool判断生效月份是当月或未来月份 如果不是则抛异常
Date effectiveMonth = autoPerformRuleUpdateDTO.getEffectiveMonth(); String effectiveMonth = autoPerformRuleUpdateDTO.getEffectiveMonth() + "-01";
if (!isCurrentAndFutureMonth(DateUtil.formatDate(effectiveMonth))) { if (!isCurrentAndFutureMonth(effectiveMonth)) {
throw new RpcServiceException("生效时间应大于等于当前月"); throw new RpcServiceException("生效时间应大于等于当前月");
} }
// 删除最新的配置 // 删除最新的配置
...@@ -132,9 +136,9 @@ public class PerfRuleRemoteService { ...@@ -132,9 +136,9 @@ public class PerfRuleRemoteService {
*/ */
public PerfRuleConfigDetailDTO perfRuleConfigGet(PerfRuleReqDTO perfRuleReqDTO) { public PerfRuleConfigDetailDTO perfRuleConfigGet(PerfRuleReqDTO perfRuleReqDTO) {
PerfRuleConfigDetailDTO result = new PerfRuleConfigDetailDTO(); PerfRuleConfigDetailDTO result = new PerfRuleConfigDetailDTO();
Date queryMonth = perfRuleReqDTO.getQueryMonth(); String queryMonth = perfRuleReqDTO.getQueryMonth();
// 通过月份查询 sal_performance_monthly // 通过月份查询 sal_performance_monthly
PerformanceMonthly salPerformanceMonthly = performanceMonthlyMapper.findByYearMonth(DateUtil.formatDate(queryMonth)); PerformanceMonthly salPerformanceMonthly = performanceMonthlyMapper.findByYearMonth(queryMonth);
if (ObjectUtil.isEmpty(salPerformanceMonthly)) { if (ObjectUtil.isEmpty(salPerformanceMonthly)) {
return result; return result;
} }
...@@ -151,14 +155,15 @@ public class PerfRuleRemoteService { ...@@ -151,14 +155,15 @@ public class PerfRuleRemoteService {
return result; return result;
} }
/** /**
* 定时任务-绩效配置设置 * 定时任务-绩效配置设置
*/ */
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = RpcServiceException.class) @Transactional(propagation = Propagation.REQUIRED, rollbackFor = RpcServiceException.class)
public void perfRuleSettingJob() { public void perfRuleSettingJob(String monthDate) {
// 查询是否存在 待生效且生效时间等于上个月的配置 // 查询是否存在 待生效且生效时间等于上个月的配置
// 上个月 // 上个月
DateTime lastMonthDate = DateUtil.offsetMonth(new Date(), -1); DateTime lastMonthDate = StrUtil.isNotBlank(monthDate) ? DateUtil.parse(monthDate) : DateUtil.offsetMonth(new Date(), -1);
String lastMonth = DateUtil.format(lastMonthDate, DatePattern.NORM_MONTH_PATTERN); String lastMonth = DateUtil.format(lastMonthDate, DatePattern.NORM_MONTH_PATTERN);
String queryLastMonthPendingCondition = "(DATE_FORMAT(effective_month, '%Y-%m') = '{}')"; String queryLastMonthPendingCondition = "(DATE_FORMAT(effective_month, '%Y-%m') = '{}')";
queryLastMonthPendingCondition = StrUtil.format(queryLastMonthPendingCondition, lastMonth); queryLastMonthPendingCondition = StrUtil.format(queryLastMonthPendingCondition, lastMonth);
...@@ -229,4 +234,5 @@ public class PerfRuleRemoteService { ...@@ -229,4 +234,5 @@ public class PerfRuleRemoteService {
} }
} }
\ No newline at end of file \ No newline at end of file
package cn.com.glsx.dj.staff.service.perfSalary; package cn.com.glsx.dj.staff.service.perfSalary;
import cn.com.glsx.dj.staff.dto.perfSalary.AppraisalInfoDTO;
import cn.com.glsx.dj.staff.dto.perfSalary.PerfAppraisalStatisticsCardDTO;
import cn.com.glsx.dj.staff.dto.perfSalary.PerfRuleReqDTO;
import cn.com.glsx.dj.staff.mapper.perfSalary.PerformanceEvaluationMapper; import cn.com.glsx.dj.staff.mapper.perfSalary.PerformanceEvaluationMapper;
import cn.com.glsx.framework.core.exception.RpcServiceException; import cn.com.glsx.framework.core.exception.RpcServiceException;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
...@@ -8,6 +11,7 @@ import org.springframework.transaction.annotation.Propagation; ...@@ -8,6 +11,7 @@ import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.util.List;
@Slf4j @Slf4j
...@@ -23,4 +27,18 @@ public class PerformanceEvaluationService { ...@@ -23,4 +27,18 @@ public class PerformanceEvaluationService {
} }
/**
* 绩效考核-统计卡片
*/
public PerfAppraisalStatisticsCardDTO perfAppraisalStatisticsCard(PerfRuleReqDTO perfRuleReqDTO) {
return performanceEvaluationMapper.perfAppraisalStatisticsCard(perfRuleReqDTO);
}
/**
* 绩效考核列表
*/
public List<AppraisalInfoDTO> perfAppraisalList(PerfRuleReqDTO perfRuleReqDTO) {
List<AppraisalInfoDTO> result = performanceEvaluationMapper.perfAppraisalList(perfRuleReqDTO);
return null;
}
} }
\ No newline at end of file \ No newline at end of file
...@@ -99,7 +99,7 @@ ...@@ -99,7 +99,7 @@
WHERE WHERE
superior_leader_mobile_phone = #{regionManagerMobilePhone} superior_leader_mobile_phone = #{regionManagerMobilePhone}
<if test="attendanceMonth != null and attendanceMonth != ''"> <if test="attendanceMonth != null and attendanceMonth != ''">
AND DATE_FORMAT(attendance_month, '%Y-%m') = #{attendanceMonth} AND attendance_month = #{attendanceMonth}
</if> </if>
<if test="name != null and name != ''"> <if test="name != null and name != ''">
AND name LIKE CONCAT('%', #{name}, '%') AND name LIKE CONCAT('%', #{name}, '%')
...@@ -122,6 +122,6 @@ ...@@ -122,6 +122,6 @@
and sbbi.deleted_flag = 'N' and sbbi.deleted_flag = 'N'
where sas.deleted_flag = 'N' where sas.deleted_flag = 'N'
and sas.mobile_phone = #{mobilePhone} and sas.mobile_phone = #{mobilePhone}
and DATE_FORMAT(sas.attendance_month, '%Y-%m') = #{attendanceMonth} and sas.attendance_month = #{attendanceMonth}
</select> </select>
</mapper> </mapper>
\ No newline at end of file \ No newline at end of file
...@@ -258,4 +258,43 @@ ...@@ -258,4 +258,43 @@
updated_date = current_timestamp updated_date = current_timestamp
</insert> </insert>
<select id="perfAppraisalStatisticsCard" resultType="cn.com.glsx.dj.staff.dto.perfSalary.PerfAppraisalStatisticsCardDTO">
SELECT
COALESCE(SUM(CASE WHEN grade = 'S' THEN 1 ELSE 0 END), 0) AS sCount,
COALESCE(SUM(CASE WHEN grade = 'A' THEN 1 ELSE 0 END), 0) AS aCount,
COALESCE(SUM(CASE WHEN grade = 'B+' THEN 1 ELSE 0 END), 0) AS bPlusCount,
COALESCE(SUM(CASE WHEN grade = 'B' THEN 1 ELSE 0 END), 0) AS bCount,
COALESCE(SUM(CASE WHEN grade = 'B-' THEN 1 ELSE 0 END), 0) AS bMinusCount,
COALESCE(SUM(CASE WHEN grade = 'C' THEN 1 ELSE 0 END), 0) AS cCount,
COALESCE(SUM(CASE WHEN grade = 'D' THEN 1 ELSE 0 END), 0) AS dCount,
(SELECT COUNT(*) FROM sal_performance_evaluation
WHERE evaluation_month = #{queryMonth}
AND deleted_flag = 'N'
AND superior_leader_mobile_phone = #{regionManagerMobilePhone}) AS totalCount,
(SELECT COUNT(*) FROM sal_performance_evaluation
WHERE evaluation_month = #{queryMonth}
AND deleted_flag = 'N'
AND superior_leader_mobile_phone = #{regionManagerMobilePhone}
AND is_entry = 1) AS entryCount
FROM (
SELECT
CASE
WHEN adopt_type = 1 AND auto_grade_code IS NOT NULL THEN auto_grade_code
WHEN adopt_type = 2 AND manual_grade_code IS NOT NULL THEN manual_grade_code
ELSE NULL
END AS grade
FROM sal_performance_evaluation
WHERE deleted_flag = 'N'
AND evaluation_month = #{queryMonth}
AND superior_leader_mobile_phone = #{regionManagerMobilePhone}
AND adopt_type IN (1, 2)
) t
</select>
<select id="perfAppraisalList" resultType="cn.com.glsx.dj.staff.dto.perfSalary.AppraisalInfoDTO">
</select>
</mapper> </mapper>
\ No newline at end of file \ No newline at end of file
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
auto_perform_rule_id AS autoPerformRuleId, auto_perform_rule_id AS autoPerformRuleId,
performance_level_uuid AS performanceLevelUuid performance_level_uuid AS performanceLevelUuid
FROM sal_performance_monthly FROM sal_performance_monthly
WHERE Date(month_date) = #{monthDate} WHERE month_date = #{monthDate}
</select> </select>
......
...@@ -3,5 +3,62 @@ ...@@ -3,5 +3,62 @@
<mapper namespace="cn.com.glsx.dj.staff.mapper.StaffSalaryAppealApplyRecordMapper"> <mapper namespace="cn.com.glsx.dj.staff.mapper.StaffSalaryAppealApplyRecordMapper">
<resultMap id="BaseResultMap" type="cn.com.glsx.dj.staff.model.StaffSalaryAppealApplyRecord">
<id column="id" property="id" jdbcType="INTEGER" />
<result column="staff_name" property="staffName" jdbcType="VARCHAR" />
<result column="staff_phone" property="staffPhone" jdbcType="VARCHAR" />
<result column="appeal_type" property="appealType" jdbcType="TINYINT" />
<result column="deal_status" property="dealStatus" jdbcType="TINYINT" />
<result column="appeal_month" property="appealMonth" jdbcType="CHAR" />
<result column="scene_type" property="sceneType" jdbcType="TINYINT" />
<result column="merchant_id" property="merchantId" jdbcType="INTEGER" />
<result column="actual_attendance_days" property="actualAttendanceDays" jdbcType="DECIMAL" />
<result column="apply_actual_attendance_days" property="applyActualAttendanceDays" jdbcType="DECIMAL" />
<result column="confirm_actual_attendance_days" property="confirmActualAttendanceDays" jdbcType="DECIMAL" />
<result column="pad_record_num" property="padRecordNum" jdbcType="INTEGER" />
<result column="apply_pad_record_num" property="applyPadRecordNum" jdbcType="INTEGER" />
<result column="confirm_pad_record_num" property="confirmPadRecordNum" jdbcType="INTEGER" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="direct_leader_name" property="directLeaderName" jdbcType="VARCHAR" />
<result column="direct_leader_phone" property="directLeaderPhone" jdbcType="VARCHAR" />
<result column="reply_phone" property="replyPhone" jdbcType="VARCHAR" />
<result column="reply_name" property="replyName" jdbcType="VARCHAR" />
<result column="reply_content" property="replyContent" jdbcType="VARCHAR" />
<result column="reply_date" property="replyDate" jdbcType="TIMESTAMP" />
<result column="other_abnormal_message" property="otherAbnormalMessage" jdbcType="VARCHAR" />
<result column="created_by" property="createdBy" jdbcType="VARCHAR" />
<result column="created_date" property="createdDate" jdbcType="TIMESTAMP" />
<result column="updated_by" property="updatedBy" jdbcType="VARCHAR" />
<result column="updated_date" property="updatedDate" jdbcType="TIMESTAMP" />
<result column="deleted_flag" property="deletedFlag" jdbcType="CHAR" />
</resultMap>
<resultMap id="DTOResultMap" type="cn.com.glsx.dj.staff.dto.StaffSalaryAppealApplyRecordDTO" extends="BaseResultMap">
</resultMap>
<sql id="Base_Column_List">
id, staff_name, staff_phone, appeal_type, deal_status, appeal_month, scene_type, merchant_id,
actual_attendance_days, apply_actual_attendance_days, confirm_actual_attendance_days,
pad_record_num, apply_pad_record_num, confirm_pad_record_num, remark,
direct_leader_name, direct_leader_phone, reply_phone, reply_name, reply_content, reply_date,
other_abnormal_message, created_by, created_date, updated_by, updated_date, deleted_flag
</sql>
<select id="pageList" resultMap="DTOResultMap">
SELECT
<include refid="Base_Column_List"/>
FROM dj_car_life_staff_salary_appeal_apply_record
WHERE deleted_flag = 'N'
<if test="staffName != null and staffName != ''">
AND staff_name LIKE CONCAT('%', #{staffName}, '%')
</if>
<if test="applyStartTime != null and applyStartTime != ''">
AND created_date &gt;= #{applyStartTime}
</if>
<if test="applyEndTime != null and applyEndTime != ''">
AND created_date &lt;= #{applyEndTime}
</if>
ORDER BY created_date DESC
</select>
</mapper> </mapper>
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!