Commit 346cb351 authored by fangxinjiang's avatar fangxinjiang

common 调优

parent ee83f8aa
......@@ -69,22 +69,22 @@ public class TCertRecordServiceImpl extends ServiceImpl<TCertRecordMapper, TCert
if (!Common.isNotNull(employeeInfo)){
return R.failed(CommonConstants.PARAM_IS_NOT_ERROR);
}
// 取值最早的合同
// 取值最新审核的合同 2022-10-13 倩倩确认 最早取值审核通过的 最早合同开始时间
TEmployeeContractInfo last = contractInfoMapper.selectOne(Wrappers.<TEmployeeContractInfo>query().lambda()
.eq(TEmployeeContractInfo::getDeleteFlag,CommonConstants.ZERO_STRING)
.eq(TEmployeeContractInfo::getAuditStatus,CommonConstants.TWO_STRING)
.eq(TEmployeeContractInfo::getIsObsolete,CommonConstants.ZERO_STRING)
.eq(TEmployeeContractInfo::getEmpIdcard,employeeInfo.getEmpIdcard())
.orderByDesc(TEmployeeContractInfo::getAuditTimeLast)
.orderByAsc(TEmployeeContractInfo::getContractStart)
.last(CommonConstants.LAST_ONE_SQL));
// 取值最早的合同
// 取值最早审核的合同
TEmployeeContractInfo first = contractInfoMapper.selectOne(Wrappers.<TEmployeeContractInfo>query().lambda()
.eq(TEmployeeContractInfo::getDeleteFlag,CommonConstants.ZERO_STRING)
.eq(TEmployeeContractInfo::getAuditStatus,CommonConstants.TWO_STRING)
.eq(TEmployeeContractInfo::getIsObsolete,CommonConstants.ZERO_STRING)
.eq(TEmployeeContractInfo::getEmpIdcard,employeeInfo.getEmpIdcard())
.orderByAsc(TEmployeeContractInfo::getAuditTimeLast)
.orderByDesc(TEmployeeContractInfo::getContractEnd)
.last(CommonConstants.LAST_ONE_SQL));
TCertRecordVo vo = new TCertRecordVo();
vo.setEmpIdcard(project.getEmpIdcard());
......
......@@ -16,6 +16,7 @@
*/
package com.yifu.cloud.plus.v1.yifu.social.entity;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.baomidou.mybatisplus.annotation.IdType;
......@@ -511,6 +512,14 @@ public class TDispatchInfo extends BaseEntity {
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("审核人" )
private String auditUser;
/**
* 审核人姓名
*/
@Length(max = 32, message = "审核人姓名 不能超过32个字符" )
@Schema(description = "审核人姓名" )
@ExcelIgnore
private String auditUserName;
/**
* 审核时间
*/
......@@ -519,6 +528,7 @@ public class TDispatchInfo extends BaseEntity {
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("审核时间" )
private Date auditTime;
/**
* 工时制:1标准工时 2 综合工时 3不定时工时制
*/
......
package com.yifu.cloud.plus.v1.yifu.social.vo;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.baomidou.mybatisplus.annotation.TableField;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import com.yifu.cloud.plus.v1.yifu.social.entity.TDispatchInfo;
......@@ -51,4 +52,19 @@ public class SocialHandleSearchVo extends TDispatchInfo {
private int limitEnd;
private String idStr;
/**
* 审核时间开始时间
*/
@TableField(exist = false)
@Schema(description = "审核时间开始时间" )
@ExcelIgnore
private String auditTimeStart;
/**
* 审核时间截止时间
*/
@TableField(exist = false)
@Schema(description = "审核时间截止时间" )
@ExcelIgnore
private String auditTimeEnd;
}
......@@ -16,6 +16,7 @@
*/
package com.yifu.cloud.plus.v1.yifu.social.vo;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.baomidou.mybatisplus.annotation.TableField;
......@@ -25,6 +26,7 @@ import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;
import java.util.Set;
......@@ -93,4 +95,19 @@ public class TDispatchInfoSearchVo extends TDispatchInfo {
@ExcelProperty("公积金户名称" )
private String providentHouseholdName;
/**
* 审核时间开始时间
*/
@TableField(exist = false)
@Schema(description = "审核时间开始时间" )
@ExcelIgnore
private String auditTimeStart;
/**
* 审核时间截止时间
*/
@TableField(exist = false)
@Schema(description = "审核时间截止时间" )
@ExcelIgnore
private String auditTimeEnd;
}
......@@ -604,17 +604,28 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
vo.setDepartNo(socialFund.getSettleDomainCodeFund());
}
// 有一个办理成功重新派单的 即为办理中
if (Common.isNotNull(socialFund) &&
(CommonConstants.ONE_STRING.equals(socialFund.getPensionHandle())
|| CommonConstants.ONE_STRING.equals(socialFund.getMedicalHandle())
|| CommonConstants.ONE_STRING.equals(socialFund.getWorkInjuryHandle())
|| CommonConstants.ONE_STRING.equals(socialFund.getBirthHandle())
|| CommonConstants.ONE_STRING.equals(socialFund.getUnemployHandle())
|| (CommonConstants.ONE_STRING.equals(socialFund.getBigailmentHandle())
&& CommonConstants.ZERO_STRING.equals(socialFund.getIsIllness())))
){
vo.setSocialStatus(CommonConstants.ONE_STRING);
boolean flagTemp = Common.isNotNull(socialFund) && Common.isNotNull(socialFund.getSocialId())
&& (CommonConstants.ONE_STRING.equals(socialFund.getPensionHandle())
|| CommonConstants.ONE_STRING.equals(socialFund.getMedicalHandle())
|| CommonConstants.ONE_STRING.equals(socialFund.getWorkInjuryHandle())
|| CommonConstants.ONE_STRING.equals(socialFund.getBirthHandle())
|| CommonConstants.ONE_STRING.equals(socialFund.getUnemployHandle())
|| (CommonConstants.ONE_STRING.equals(socialFund.getBigailmentHandle())
&& CommonConstants.ZERO_STRING.equals(socialFund.getIsIllness())))
&& !(CommonConstants.ONE_STRING.equals(socialFund.getPensionHandle())
&& CommonConstants.ONE_STRING.equals(socialFund.getMedicalHandle())
&& CommonConstants.ONE_STRING.equals(socialFund.getWorkInjuryHandle())
&& CommonConstants.ONE_STRING.equals(socialFund.getBirthHandle())
&& CommonConstants.ONE_STRING.equals(socialFund.getUnemployHandle())
&& (
(CommonConstants.ONE_STRING.equals(socialFund.getBigailmentHandle())
&& CommonConstants.ZERO_STRING.equals(socialFund.getIsIllness()))
||(CommonConstants.ONE_STRING.equals(socialFund.getIsIllness()))
));
if (Common.isNotNull(socialFund) && flagTemp){
vo.setSocialStatus(CommonConstants.TWO_STRING);
}
vo.setEmpIdCard(socialFund.getEmpIdcard());
R<Boolean> resUp = archivesDaprUtil.updateProjectSocialFund(vo);
if (Common.isEmpty(resUp) || !(CommonConstants.SUCCESS.intValue() == resUp.getCode()) || !resUp.getData().booleanValue()){
......@@ -2904,6 +2915,7 @@ public class TDispatchInfoServiceImpl extends ServiceImpl<TDispatchInfoMapper, T
auditInfo.setDispatchInfoId(dis.getId());
auditInfoMapper.insert(auditInfo);
dis.setAuditUser(user.getId());
dis.setAuditUserName(user.getNickname());
dis.setAuditTime(now);
baseMapper.updateById(dis);
......
......@@ -72,6 +72,7 @@
<result property="fundCity" column="FUND_CITY"/>
<result property="fundTown" column="FUND_TOWN"/>
<result property="auditUser" column="AUDIT_USER"/>
<result property="auditUserName" column="AUDIT_USER_NAME"/>
<result property="auditTime" column="AUDIT_TIME"/>
<result property="workingHours" column="WORKING_HOURS"/>
<result property="createBy" column="CREATE_BY"/>
......@@ -194,6 +195,7 @@
a.FUND_CITY,
a.FUND_TOWN,
a.AUDIT_USER,
a.AUDIT_USER_NAME,
a.AUDIT_TIME,
a.WORKING_HOURS,
a.CREATE_BY,
......@@ -380,9 +382,19 @@
<if test="tDispatchInfo.auditUser != null and tDispatchInfo.auditUser.trim() != ''">
AND a.AUDIT_USER = #{tDispatchInfo.auditUser}
</if>
<if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''">
AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%')
</if>
<if test="tDispatchInfo.auditTime != null">
AND a.AUDIT_TIME = #{tDispatchInfo.auditTime}
</if>
<if test="tDispatchInfo.auditTimeStart != null">
AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart}
</if>
<if test="tDispatchInfo.auditTimeEnd != null">
AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd}
</if>
<if test="tDispatchInfo.workingHours != null and tDispatchInfo.workingHours.trim() != ''">
AND a.WORKING_HOURS = #{tDispatchInfo.workingHours}
</if>
......@@ -770,6 +782,15 @@
<if test="tDispatchInfo.createTimeStart != null">
AND a.CREATE_TIME <![CDATA[>=]]> #{tDispatchInfo.createTimeStart}
</if>
<if test="tDispatchInfo.auditTimeStart != null">
AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart}
</if>
<if test="tDispatchInfo.auditTimeEnd != null">
AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd}
</if>
<if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''">
AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%')
</if>
<if test="tDispatchInfo.socialHouseholdName != null and tDispatchInfo.socialHouseholdName.trim() != ''">
AND a.SOCIAL_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.socialHouseholdName}), '%')
</if>
......@@ -874,6 +895,15 @@
<if test="tDispatchInfo.createTimeStart != null">
AND a.CREATE_TIME <![CDATA[>=]]> #{tDispatchInfo.createTimeStart}
</if>
<if test="tDispatchInfo.auditTimeStart != null">
AND a.AUDIT_TIME <![CDATA[>=]]> #{tDispatchInfo.auditTimeStart}
</if>
<if test="tDispatchInfo.auditTimeEnd != null">
AND a.AUDIT_TIME <![CDATA[<=]]> #{tDispatchInfo.auditTimeEnd}
</if>
<if test="tDispatchInfo.auditUserName != null and tDispatchInfo.auditUserName.trim() != ''">
AND a.AUDIT_USER_NAME like concat('%',#{tDispatchInfo.auditUserName},'%')
</if>
<if test="tDispatchInfo.providentHouseholdName != null and tDispatchInfo.providentHouseholdName.trim() != ''">
AND a.PROVIDENT_HOUSEHOLD_NAME like CONCAT(CONCAT(#{tDispatchInfo.providentHouseholdName}), '%')
</if>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment