1、员工信息变更审核流程

2、员工-机构入住流程bug修复
This commit is contained in:
1378012178@qq.com 2025-09-26 09:29:48 +08:00
parent 18a791f6fd
commit b343a7e0b7
22 changed files with 396 additions and 154 deletions

View File

@ -1,7 +1,7 @@
package com.nu.modules.EmployessInfo.api;
import com.nu.entity.EmployeesApplyEntity;
import com.nu.modules.EmployessInfo.entity.EmployeesOrgApiEntity;
import com.nu.entity.EmployeesOrgApiEntity;
import java.util.List;

View File

@ -1,7 +1,6 @@
package com.nu.modules.EmployessInfo.api;
import com.nu.modules.EmployessInfo.entity.EmployeesAdvisoryInfoEntity;
import com.nu.modules.orgapplyinfo.entity.OrgApplyInfoApiEntity;
import com.nu.entity.EmployeesAdvisoryInfoEntity;
import java.util.List;
@ -11,7 +10,7 @@ public interface IEmployessAdvisioryInfoApi {
int updateById(EmployeesAdvisoryInfoEntity eployeesAdvisoryInfoEntity);
List<EmployeesAdvisoryInfoEntity> queryAuditInfo(String openId);
List<EmployeesAdvisoryInfoEntity> queryAuditInfo(String openId, String orgCode);
int updateByTel(EmployeesAdvisoryInfoEntity employeesAdvisoryInfoEntity);

View File

@ -14,6 +14,6 @@ public class EmployeesApiEntity {
private java.lang.String izOnline;
/**冻结状态 0未冻结 1冻结*/
private java.lang.String izFreeze;
/**是否为被邀请 0被邀请 1主动申请*/
private java.lang.String isInvited;
/**申请类型 0被邀请 1主动申请 */
private java.lang.String applyType;
}

View File

@ -261,9 +261,9 @@ public class OrgAllInfoApiEntity implements Serializable {
*/
private String izFreeze;
/**
* 是否为被邀请 0被邀请 1主动申请
* 申请类型 0被邀请 1主动申请
*/
private java.lang.String isInvited;
private java.lang.String applyType;
/**
* 入职时间
*/
@ -305,5 +305,9 @@ public class OrgAllInfoApiEntity implements Serializable {
* 护理单元名称
*/
private String nuName;
/**
* 信息修改状态 没提交过修改 1修改申请中 2通过 3驳回
*/
private String modifyState;
}

View File

@ -92,8 +92,12 @@ public class EmployeesOrg implements Serializable {
@Excel(name = "是否历史数据", width = 15)
@ApiModelProperty(value = "是否历史数据")
private java.lang.String izHistory;
/**是否为被邀请 0被邀请 1主动申请*/
@Excel(name = "是否为被邀请", width = 15)
@ApiModelProperty(value = "是否为被邀请")
private java.lang.String isInvited;
/**申请类型 0被邀请 1主动申请 */
@Excel(name = "申请类型", width = 15)
@ApiModelProperty(value = "申请类型")
private java.lang.String applyType;
/**修改状态 1修改申请中 2通过 3驳回 */
@Excel(name = "修改状态", width = 15)
@ApiModelProperty(value = "修改状态")
private java.lang.String modifyStatus;
}

View File

@ -3,6 +3,7 @@ package com.nu.modules.employees.entity;
import java.io.Serializable;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
@ -18,178 +19,259 @@ import lombok.experimental.Accessors;
/**
* @Description: 员工咨询信息
* @Author: jeecg-boot
* @Date: 2025-06-09
* @Date: 2025-06-09
* @Version: V1.0
*/
@Data
@TableName("nu_employees_advisory_info")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="nu_employees_advisory_info对象", description="员工咨询信息")
@ApiModel(value = "nu_employees_advisory_info对象", description = "员工咨询信息")
public class NuEmployeesAdvisoryInfo implements Serializable {
private static final long serialVersionUID = 1L;
/**id*/
@TableId(type = IdType.ASSIGN_ID)
/**
* id
*/
@TableId(type = IdType.ASSIGN_ID)
@ApiModelProperty(value = "id")
private java.lang.String id;
/**微信id*/
@Excel(name = "微信id", width = 15)
/**
* 微信id
*/
@Excel(name = "微信id", width = 15)
@ApiModelProperty(value = "微信id")
private java.lang.String openId;
/**微信名称*/
@Excel(name = "微信名称", width = 15)
/**
* 微信名称
*/
@Excel(name = "微信名称", width = 15)
@ApiModelProperty(value = "微信名称")
private java.lang.String wechatName;
/**联系电话*/
@Excel(name = "联系电话", width = 15)
/**
* 联系电话
*/
@Excel(name = "联系电话", width = 15)
@ApiModelProperty(value = "联系电话")
private java.lang.String tel;
/**状态 1审核中 2审核完成 3驳回 */
@Excel(name = "状态 1审核中 2审核完成 3驳回 ", width = 15)
/**
* 状态 1审核中 2审核完成 3驳回
*/
@Excel(name = "状态 1审核中 2审核完成 3驳回 ", width = 15)
@ApiModelProperty(value = "状态 1审核中 2审核完成 3驳回 ")
@Dict(dicCode = "org_apply_status")
private java.lang.String status;
/**审核备注*/
@Excel(name = "审核备注", width = 15)
/**
* 审核备注
*/
@Excel(name = "审核备注", width = 15)
@ApiModelProperty(value = "审核备注")
private java.lang.String content;
/**创建人*/
/**
* 创建人
*/
@ApiModelProperty(value = "创建人")
private java.lang.String createBy;
/**创建日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 创建日期
*/
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "创建日期")
private java.util.Date createTime;
/**更新人*/
/**
* 更新人
*/
@ApiModelProperty(value = "更新人")
private java.lang.String updateBy;
/**更新日期*/
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
/**
* 更新日期
*/
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private java.util.Date updateTime;
/**机构是否入驻0否 1是(是否入驻过)*/
@Excel(name = "机构是否入驻0否 1是(是否入驻过)", width = 15)
/**
* 机构是否入驻0否 1是(是否入驻过
*/
@Excel(name = "机构是否入驻0否 1是(是否入驻过)", width = 15)
@ApiModelProperty(value = "机构是否入驻0否 1是(是否入驻过)")
private java.lang.String izEntry;
/**咨询人姓名*/
@Excel(name = "咨询人姓名", width = 15)
/**
* 咨询人姓名
*/
@Excel(name = "咨询人姓名", width = 15)
@ApiModelProperty(value = "咨询人姓名")
private java.lang.String name;
/**性别*/
@Excel(name = "性别", width = 15)
/**
* 性别
*/
@Excel(name = "性别", width = 15)
@ApiModelProperty(value = "性别")
private java.lang.String sex;
/**民族*/
@Excel(name = "民族", width = 15)
/**
* 民族
*/
@Excel(name = "民族", width = 15)
@ApiModelProperty(value = "民族")
private java.lang.String national;
/**出生日期*/
@Excel(name = "出生日期", width = 15, format = "yyyy-MM-dd")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
@DateTimeFormat(pattern="yyyy-MM-dd")
/**
* 出生日期
*/
@Excel(name = "出生日期", width = 15, format = "yyyy-MM-dd")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
@DateTimeFormat(pattern = "yyyy-MM-dd")
@ApiModelProperty(value = "出生日期")
private java.util.Date birthDate;
/**住址(身份证上)*/
@Excel(name = "住址(身份证上)", width = 15)
/**
* 住址身份证上
*/
@Excel(name = "住址(身份证上)", width = 15)
@ApiModelProperty(value = "住址(身份证上)")
private java.lang.String idCardAddress;
/**身份证号*/
@Excel(name = "身份证号", width = 15)
/**
* 身份证号
*/
@Excel(name = "身份证号", width = 15)
@ApiModelProperty(value = "身份证号")
private java.lang.String idCard;
/**签发机关*/
@Excel(name = "签发机关", width = 15)
/**
* 签发机关
*/
@Excel(name = "签发机关", width = 15)
@ApiModelProperty(value = "签发机关")
private java.lang.String issuingAuthority;
/**有效开始日期*/
@Excel(name = "有效开始日期", width = 15, format = "yyyy-MM-dd")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
@DateTimeFormat(pattern="yyyy-MM-dd")
/**
* 有效开始日期
*/
@Excel(name = "有效开始日期", width = 15, format = "yyyy-MM-dd")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
@DateTimeFormat(pattern = "yyyy-MM-dd")
@ApiModelProperty(value = "有效开始日期")
private java.util.Date startTime;
/**有效结束日期*/
@Excel(name = "有效结束日期", width = 15, format = "yyyy-MM-dd")
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
@DateTimeFormat(pattern="yyyy-MM-dd")
/**
* 有效结束日期
*/
@Excel(name = "有效结束日期", width = 15, format = "yyyy-MM-dd")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
@DateTimeFormat(pattern = "yyyy-MM-dd")
@ApiModelProperty(value = "有效结束日期")
private java.util.Date endTime;
/**身份证正面*/
@Excel(name = "身份证正面", width = 15)
/**
* 身份证正面
*/
@Excel(name = "身份证正面", width = 15)
@ApiModelProperty(value = "身份证正面")
private java.lang.String cardZmPath;
/**身份证反面*/
@Excel(name = "身份证反面", width = 15)
/**
* 身份证反面
*/
@Excel(name = "身份证反面", width = 15)
@ApiModelProperty(value = "身份证反面")
private java.lang.String cardFmPath;
/**婚否0未婚 1已婚*/
@Excel(name = "婚否0未婚 1已婚", width = 15)
/**
* 婚否0未婚 1已婚
*/
@Excel(name = "婚否0未婚 1已婚", width = 15)
@ApiModelProperty(value = "婚否0未婚 1已婚")
private java.lang.String maritalStatus;
/**身高*/
@Excel(name = "身高", width = 15)
/**
* 身高
*/
@Excel(name = "身高", width = 15)
@ApiModelProperty(value = "身高")
private java.lang.String height;
/**体重*/
@Excel(name = "体重", width = 15)
private String height;
/**
* 体重
*/
@Excel(name = "体重", width = 15)
@ApiModelProperty(value = "体重")
private java.lang.String weight;
/**健康状况0健康 1患病*/
@Excel(name = "健康状况0健康 1患病", width = 15)
private String weight;
/**
* 健康状况0健康 1患病
*/
@Excel(name = "健康状况0健康 1患病", width = 15)
@ApiModelProperty(value = "健康状况0健康 1患病")
private java.lang.String healthStatus;
/**政治面貌0共产党员 1民主党 2国民党 3无党派*/
@Excel(name = "政治面貌0共产党员 1民主党 2国民党 3无党派", width = 15)
/**
* 政治面貌0共产党员 1民主党 2国民党 3无党派
*/
@Excel(name = "政治面貌0共产党员 1民主党 2国民党 3无党派", width = 15)
@ApiModelProperty(value = "政治面貌0共产党员 1民主党 2国民党 3无党派")
private java.lang.String politicalAppearance;
/**紧急联系人姓名*/
@Excel(name = "紧急联系人姓名", width = 15)
/**
* 紧急联系人姓名
*/
@Excel(name = "紧急联系人姓名", width = 15)
@ApiModelProperty(value = "紧急联系人姓名")
private java.lang.String contactName;
/**紧急联系人电话*/
@Excel(name = "紧急联系人电话", width = 15)
/**
* 紧急联系人电话
*/
@Excel(name = "紧急联系人电话", width = 15)
@ApiModelProperty(value = "紧急联系人电话")
private java.lang.String contactTel;
/**紧急联系人与本人关系*/
@Excel(name = "紧急联系人与本人关系", width = 15)
/**
* 紧急联系人与本人关系
*/
@Excel(name = "紧急联系人与本人关系", width = 15)
@ApiModelProperty(value = "紧急联系人与本人关系")
private java.lang.String contactRelationship;
/**户口性质0农业 1非农业*/
@Excel(name = "户口性质0农业 1非农业", width = 15)
/**
* 户口性质0农业 1非农业
*/
@Excel(name = "户口性质0农业 1非农业", width = 15)
@ApiModelProperty(value = "户口性质0农业 1非农业")
private java.lang.String hukouType;
/**银行卡正面*/
@Excel(name = "银行卡正面", width = 15)
/**
* 银行卡正面
*/
@Excel(name = "银行卡正面", width = 15)
@ApiModelProperty(value = "银行卡正面")
private java.lang.String bankZmPath;
/**银行卡反面*/
@Excel(name = "银行卡反面", width = 15)
/**
* 银行卡反面
*/
@Excel(name = "银行卡反面", width = 15)
@ApiModelProperty(value = "银行卡反面")
private java.lang.String bankFmPath;
/**开户行*/
@Excel(name = "开户行", width = 15)
/**
* 开户行
*/
@Excel(name = "开户行", width = 15)
@ApiModelProperty(value = "开户行")
private java.lang.String openingBank;
/**银行卡号*/
@Excel(name = "银行卡号", width = 15)
/**
* 银行卡号
*/
@Excel(name = "银行卡号", width = 15)
@ApiModelProperty(value = "银行卡号")
private java.lang.String bankCard;
/**健康证正面*/
@Excel(name = "健康证正面", width = 15)
/**
* 健康证正面
*/
@Excel(name = "健康证正面", width = 15)
@ApiModelProperty(value = "健康证正面")
private java.lang.String healthZmPath;
/**健康证反面*/
@Excel(name = "健康证反面", width = 15)
/**
* 健康证反面
*/
@Excel(name = "健康证反面", width = 15)
@ApiModelProperty(value = "健康证反面")
private java.lang.String healthFmPath;
/**资质证(可多张)*/
@Excel(name = "资质证(可多张)", width = 15)
/**
* 资质证(可多张)
*/
@Excel(name = "资质证(可多张)", width = 15)
@ApiModelProperty(value = "资质证(可多张)")
private java.lang.String qualificationPath;
/**无犯罪正面*/
@Excel(name = "无犯罪正面", width = 15)
/**
* 无犯罪正面
*/
@Excel(name = "无犯罪正面", width = 15)
@ApiModelProperty(value = "无犯罪正面")
private java.lang.String noCrimeCertificate;
//信息修改状态 没提交过修改 1修改申请中 2通过 3驳回*/
@TableField(exist = false)
private String modifyState;
}

View File

@ -1,13 +1,16 @@
package com.nu.modules.employees.mapper;
import com.nu.modules.EmployessInfo.entity.EmployeesAdvisoryInfoEntity;
import com.nu.entity.EmployeesAdvisoryInfoEntity;
import com.nu.modules.employees.entity.NuEmployeesAdvisoryInfo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;
/**
* @Description: 员工咨询信息
* @Author: jeecg-boot
* @Date: 2025-06-09
* @Date: 2025-06-09
* @Version: V1.0
*/
public interface NuEmployeesAdvisoryInfoMapper extends BaseMapper<NuEmployeesAdvisoryInfo> {
@ -15,4 +18,6 @@ public interface NuEmployeesAdvisoryInfoMapper extends BaseMapper<NuEmployeesAdv
void updateByTel(EmployeesAdvisoryInfoEntity employeesAdvisoryInfoEntity);
int updateByOpenId(EmployeesAdvisoryInfoEntity employeesAdvisoryInfoEntity);
List<NuEmployeesAdvisoryInfo> queryEmployeeInfo(@Param("openId") String openId, @Param("orgCode") String orgCode);
}

View File

@ -39,5 +39,18 @@
</set>
where open_id = #{openId}
</update>
<select id="queryEmployeeInfo" resultType="com.nu.modules.employees.entity.NuEmployeesAdvisoryInfo">
SELECT
adinfo.*,
eo.modify_status AS modifyState
FROM nu_employees_advisory_info adinfo
LEFT JOIN nu_biz_employees_org eo
ON adinfo.open_id = eo.open_id
<if test="orgCode != null and orgCode != ''">
AND eo.org_code = #{orgCode}
AND eo.iz_history = '1'
</if>
WHERE adinfo.open_id = #{openId}
</select>
</mapper>

View File

@ -5,7 +5,7 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.nu.entity.EmployeesApplyEntity;
import com.nu.modules.EmployessInfo.api.EmployeesOrgLocalApi;
import com.nu.modules.EmployessInfo.entity.EmployeesOrgApiEntity;
import com.nu.entity.EmployeesOrgApiEntity;
import com.nu.modules.employees.entity.EmployeesOrg;
import com.nu.modules.employees.entity.NuEmployeesAdvisoryInfo;
import com.nu.modules.employees.mapper.EmployeesOrgMapper;
@ -48,7 +48,7 @@ public class EmployeesOrgServiceImpl extends ServiceImpl<EmployeesOrgMapper, Emp
employeesOrg.setStatus("1");
employeesOrg.setIzOnline("1");
employeesOrg.setIzFreeze("0");
employeesOrg.setIsInvited("1");
employeesOrg.setApplyType("1");
baseMapper.insert(employeesOrg);
return employeesOrg.getId();
}
@ -88,7 +88,7 @@ public class EmployeesOrgServiceImpl extends ServiceImpl<EmployeesOrgMapper, Emp
uw.eq("employees_id", dto.getEmployeeId());
uw.eq("org_code", dto.getOrgCode());
uw.eq("iz_history", "1");
uw.eq("is_invited", "0");
uw.eq("apply_type", "0");
EmployeesOrg udto = new EmployeesOrg();
udto.setStatus(dto.getStatus());
if ("2".equals(dto.getStatus())) {

View File

@ -3,14 +3,16 @@ package com.nu.modules.employees.service.impl;
import cn.hutool.json.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.nu.dto.EmployeesApplyMQDto;
import com.nu.dto.EmployeesStatusMQDto;
import com.nu.modules.EmployessInfo.api.IEmployessAdvisioryInfoApi;
import com.nu.modules.EmployessInfo.entity.EmployeesAdvisoryInfoEntity;
import com.nu.entity.EmployeesAdvisoryInfoEntity;
import com.nu.modules.employees.entity.NuEmployeesAdvisoryInfo;
import com.nu.modules.employees.mapper.NuEmployeesAdvisoryInfoMapper;
import com.nu.modules.employees.service.INuEmployeesAdvisoryInfoService;
import com.nu.modules.weixin.utils.TemplateMessageSender;
import com.nu.modules.weixin.utils.WechatMiniProgramUtils;
import com.nu.utils.RabbitMQUtil;
import org.apache.commons.compress.utils.Lists;
import org.apache.commons.lang.StringUtils;
import org.jeecg.common.constant.CommonConstant;
@ -29,7 +31,7 @@ import java.util.stream.Collectors;
/**
* @Description: 员工咨询信息
* @Author: jeecg-boot
* @Date: 2025-06-09
* @Date: 2025-06-09
* @Version: V1.0
*/
@Service
@ -37,32 +39,52 @@ public class NuEmployeesAdvisoryInfoServiceImpl extends ServiceImpl<NuEmployeesA
@Autowired
private BaseCommonService baseCommonService;
@Autowired
private ISysBaseAPI sysBaseAPI;
@Autowired
private RabbitMQUtil rabbitMQUtil;
@Override
public EmployeesAdvisoryInfoEntity insert(EmployeesAdvisoryInfoEntity EmployeesAdvisoryInfoEntity) {
NuEmployeesAdvisoryInfo NuEmployeesAdvisoryInfo = new NuEmployeesAdvisoryInfo();
BeanUtils.copyProperties(EmployeesAdvisoryInfoEntity,NuEmployeesAdvisoryInfo);
BeanUtils.copyProperties(EmployeesAdvisoryInfoEntity, NuEmployeesAdvisoryInfo);
baseMapper.insert(NuEmployeesAdvisoryInfo);
EmployeesAdvisoryInfoEntity.setId(NuEmployeesAdvisoryInfo.getId());
return EmployeesAdvisoryInfoEntity;
}
@Override
public int updateById(EmployeesAdvisoryInfoEntity EmployeesAdvisoryInfoEntity) {
NuEmployeesAdvisoryInfo NuEmployeesAdvisoryInfo = new NuEmployeesAdvisoryInfo();
BeanUtils.copyProperties(EmployeesAdvisoryInfoEntity,NuEmployeesAdvisoryInfo);
return baseMapper.updateById(NuEmployeesAdvisoryInfo);
public int updateById(EmployeesAdvisoryInfoEntity dto) {
// NuEmployeesAdvisoryInfo NuEmployeesAdvisoryInfo = new NuEmployeesAdvisoryInfo();
// BeanUtils.copyProperties(dto,NuEmployeesAdvisoryInfo);
// baseMapper.updateById(NuEmployeesAdvisoryInfo);
//更新员工信息需要有审核流程 审核通过后才修改正式数据
//通知业务平台有员工信息变更
EmployeesApplyMQDto mqdto = new EmployeesApplyMQDto();
BeanUtils.copyProperties(dto, mqdto);
mqdto.setDateOfBirth(dto.getBirthDate());
mqdto.setMarriedOrNot(dto.getMaritalStatus());
mqdto.setEmergencyContact(dto.getContactName());
mqdto.setEmergencyTel(dto.getContactTel());
mqdto.setEmergencyRelationship(dto.getContactRelationship());
mqdto.setHukouNature(dto.getHukouType());
mqdto.setIdCardPositive(dto.getCardZmPath());
mqdto.setIdCardNegative(dto.getCardFmPath());
mqdto.setHealthCertificatePositive(dto.getHealthZmPath());
mqdto.setHealthCertificateNegative(dto.getHealthFmPath());
mqdto.setBankPositive(dto.getBankZmPath());
mqdto.setBankNegative(dto.getBankFmPath());
mqdto.setQualification(dto.getQualificationPath());
mqdto.setNoCrimeCertificate(dto.getNoCrimeCertificate());
mqdto.setHouseAddress(dto.getIdCardAddress());
mqdto.setEmployeeId(dto.getId());
rabbitMQUtil.sendToExchange("hldy.employee", dto.getOrgCode() + ".employee.infoUpdate.audit", mqdto);
return 1;
}
@Override
public List<EmployeesAdvisoryInfoEntity> queryAuditInfo(String openId) {
QueryWrapper<NuEmployeesAdvisoryInfo> qw = new QueryWrapper<>();
qw.eq("open_id",openId);
// qw.in("status",new String[]{"1","3"});//审核状态为审核中驳回的
qw.orderByDesc("create_time");
List<NuEmployeesAdvisoryInfo> list = baseMapper.selectList(qw);
public List<EmployeesAdvisoryInfoEntity> queryAuditInfo(String openId, String orgCode) {
List<NuEmployeesAdvisoryInfo> list = baseMapper.queryEmployeeInfo(openId, orgCode);
List<EmployeesAdvisoryInfoEntity> result = Lists.newArrayList();
result = list.stream()
.map(item -> {

View File

@ -182,12 +182,14 @@ public class OrgAllInfo implements Serializable {
private String izOnline;
/** 是否冻结 0是1否*/
private String izFreeze;
/**是否为被邀请 0被邀请 1主动申请*/
private java.lang.String isInvited;
/**申请类型 0被邀请 1主动申请 */
private java.lang.String applyType;
/** 入职时间*/
private String entryTime;
/**申请日期*/
private String applyTime;
/**审核日期*/
private String auditTime;
/**信息修改状态 空:没提交过修改 1修改申请中 2通过 3驳回*/
private String modifyState;
}

View File

@ -88,10 +88,11 @@
eo.audit_content,
eo.iz_online,
eo.iz_freeze,
eo.is_invited,
eo.apply_type,
eo.entry_time,
eo.create_time AS apply_time,
eo.update_time AS audit_time
eo.update_time AS audit_time,
eo.modify_status AS modify_state
from sys_depart d
inner join nu_org_apply_info o on d.id = o.pk_id
inner join nu_biz_employees_org eo on d.org_code = eo.org_code
@ -107,7 +108,7 @@
</foreach>
</if>
<if test="invited !=null and invited != ''">
and eo.is_invited = #{invited}
and eo.apply_type = #{invited}
</if>
<if test="id !=null and id != ''">
and eo.id = #{id}

View File

@ -95,7 +95,7 @@ public class WxNoticeServiceImpl extends ServiceImpl<WxNoticeMapper, WxNotice> i
// 2. 准备模板消息数据
// String templateId = "CJ6NDNV4mTTyOdYhbksyA_YjDORVemJRmzEVAUZMBis";
String templateId = "yvvhlRft1CAdtU-dWlCW8U63VnTwRU8w3gR0BUdqcWw";
String page = "pages/oldmanindex/companyyaoqing"; // 点击消息跳转的页面
String page = "pages/yuangongindex/index"; // 点击消息跳转的页面
com.alibaba.fastjson.JSONObject orgInfo = sysBaseAPI.getOrgInfo(wxNoticeEntity.getOrgCode());
String companyName = orgInfo.getString("departName");

View File

@ -1,6 +1,7 @@
package com.nu.mq.employees.listener;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.google.common.collect.Maps;
@ -21,9 +22,11 @@ import org.springframework.amqp.rabbit.annotation.Exchange;
import org.springframework.amqp.rabbit.annotation.Queue;
import org.springframework.amqp.rabbit.annotation.QueueBinding;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import java.util.List;
import java.util.Map;
@Slf4j
@ -125,7 +128,7 @@ public class EmployeesMQListener {
qw.eq("org_code", dto.getOrgCode());
qw.eq("status", "1");
qw.eq("iz_history", "1");
qw.eq("is_invited", "1");
qw.eq("apply_type", "1");
EmployeesOrg one = employeesOrgService.getOne(qw);
if (one != null) {
rabbitMQUtil.sendToExchange("hldy.employees", dto.getOrgCode() + "employees.cannotinvided", dto);
@ -149,7 +152,7 @@ public class EmployeesMQListener {
employeesOrg.setStatus("1");
employeesOrg.setIzOnline("1");
employeesOrg.setIzFreeze("0");
employeesOrg.setIsInvited("0");
employeesOrg.setApplyType("0");
employeesOrg.setIzHistory("1");
employeesOrgService.save(employeesOrg);
@ -172,4 +175,91 @@ public class EmployeesMQListener {
wxNoticeApi.sendWechartMinMessage(wxNoticeEntity);
}
/**
* 员工-机构关系状态调整
* 只修改审核状态审核备注
*
* @param dto
*/
@RabbitListener(bindings = @QueueBinding(value = @Queue(name = "hldy.employee.infoUp.result", durable = "true"),
exchange = @Exchange(name = "hldy.employee", type = ExchangeTypes.DIRECT),
key = "hldy.employee.infoUp.result"), errorHandler = "employeesMQErrorHandler")
public void handleInfoUpResult(EmployeesApplyMQDto dto) {
if ("2".equals(dto.getModifyStatus())) {
//审批通过需要修改员工-机构中间表结果
UpdateWrapper<EmployeesOrg> uw = new UpdateWrapper<>();
uw.eq("employees_id", dto.getEmployeeId());
uw.eq("org_code", dto.getOrgCode());
uw.eq("iz_history", "1");
EmployeesOrg eo = new EmployeesOrg();
eo.setModifyStatus("2");
employeesOrgService.update(eo, uw);
//修改员工咨询表信息
NuEmployeesAdvisoryInfo employeeInfo = new NuEmployeesAdvisoryInfo();
BeanUtils.copyProperties(dto, employeeInfo);
employeeInfo.setBirthDate(dto.getDateOfBirth());
employeeInfo.setMaritalStatus(dto.getMarriedOrNot());
employeeInfo.setContactName(dto.getEmergencyContact());
employeeInfo.setContactTel(dto.getEmergencyTel());
employeeInfo.setContactRelationship(dto.getEmergencyRelationship());
employeeInfo.setHukouType(dto.getHukouNature());
employeeInfo.setCardZmPath(dto.getIdCardPositive());
employeeInfo.setCardFmPath(dto.getIdCardNegative());
employeeInfo.setHealthZmPath(dto.getHealthCertificatePositive());
employeeInfo.setHealthFmPath(dto.getHealthCertificateNegative());
employeeInfo.setBankZmPath(dto.getBankPositive());
employeeInfo.setBankFmPath(dto.getBankNegative());
employeeInfo.setQualificationPath(dto.getQualification());
employeeInfo.setNoCrimeCertificate(dto.getNoCrimeCertificate());
employeeInfo.setIdCardAddress(dto.getHouseAddress());
employeeInfo.setId(dto.getEmployeeId());
employeesAdvisoryInfoService.updateById(employeeInfo);
//通知其余机构修改此员工信息 并拉取资源文件
LambdaQueryWrapper<EmployeesOrg> qw = new LambdaQueryWrapper<>();
qw.select(EmployeesOrg::getOrgCode);
qw.eq(EmployeesOrg::getOpenId, dto.getOpenId());
qw.ne(EmployeesOrg::getOrgCode, dto.getOrgCode());
qw.groupBy(EmployeesOrg::getOrgCode);
List<EmployeesOrg> orgCodeList = employeesOrgService.list(qw);
if (orgCodeList != null && orgCodeList.size() > 0) {
orgCodeList.stream().forEach(c -> {
String orgCode = c.getOrgCode();
rabbitMQUtil.sendToExchange("hldy.employee", orgCode + ".employee.infoup.updata", dto);
});
}
}
if ("3".equals(dto.getModifyStatus())) {
//审批不通过只需要修改员工-机构中间表结果
UpdateWrapper<EmployeesOrg> uw = new UpdateWrapper<>();
uw.eq("employees_id", dto.getEmployeeId());
uw.eq("org_code", dto.getOrgCode());
uw.eq("iz_history", "1");
EmployeesOrg eo = new EmployeesOrg();
eo.setModifyStatus("3");
employeesOrgService.update(eo, uw);
}
//增加机构邀请员工的消息通知
WxNoticeEntity wxNoticeEntity = new WxNoticeEntity();
wxNoticeEntity.setOpenId(dto.getOpenId());
wxNoticeEntity.setIzRead("1");
wxNoticeEntity.setOrgCode(dto.getOrgCode());
wxNoticeEntity.setTitle("员工信息变更审批");
if ("2".equals(dto.getModifyStatus())) {
wxNoticeEntity.setContent("您好,您提交的员工信息变更申请已通过");
}
if ("3".equals(dto.getModifyStatus())) {
wxNoticeEntity.setContent("您好,您提交的员工信息变更申请未通过");
}
wxNoticeEntity.setType("emp_info_update_list");
Map<String, Object> extend = Maps.newHashMap();
extend.put("orgCode", dto.getOrgCode());
extend.put("dataId", dto.getId());
wxNoticeEntity.setExtend(JSONObject.toJSONString(extend));
wxNoticeEntity.setClientType(WxClientType.EMPLOYEE.getCode());
wxNoticeApi.addNotice(wxNoticeEntity);
wxNoticeApi.sendWechartMinMessage(wxNoticeEntity);
}
}

View File

@ -5,7 +5,7 @@ import com.google.common.collect.Maps;
import com.nu.dto.EmployeesApplyMQDto;
import com.nu.entity.EmployeesApplyEntity;
import com.nu.modules.EmployessInfo.api.EmployeesOrgLocalApi;
import com.nu.modules.EmployessInfo.entity.EmployeesOrgApiEntity;
import com.nu.entity.EmployeesOrgApiEntity;
import com.nu.modules.orgapplyinfo.api.IOrgApplyInfoApi;
import com.nu.modules.orgapplyinfo.entity.EmployeesApiEntity;
import com.nu.modules.orgapplyinfo.entity.OrgAllInfoApiEntity;
@ -94,7 +94,7 @@ public class EmployessApplyApi {
en.setAuditContent(eo.getAuditContent());
en.setIzOnline(eo.getIzOnline());
en.setIzFreeze(eo.getIzFreeze());
en.setIsInvited(eo.getIsInvited());
en.setApplyType(eo.getApplyType());
sourceRecords.get(indexMap.get(eo.getOrgCode())).setEmployeesApiEntity(en);
});
result.setRecords(sourceRecords);

View File

@ -1,7 +1,7 @@
package com.nu.modules.wechat.employess.api;
import com.nu.modules.EmployessInfo.api.IEmployessAdvisioryInfoApi;
import com.nu.modules.EmployessInfo.entity.EmployeesAdvisoryInfoEntity;
import com.nu.entity.EmployeesAdvisoryInfoEntity;
import org.apache.commons.lang.StringUtils;
import org.jeecg.common.api.vo.Result;
import org.jeecg.common.aspect.annotation.AutoLog;
@ -19,20 +19,22 @@ public class EmployessInfoApi {
/**
* 新增/编辑员工入驻申请信息
*
* @param EmployeesAdvisoryInfoEntity
* @return
*/
@AutoLog(value = "员工咨询信息-新增或修改")
@PostMapping("/saveApiEmployess")
public Result<Object> saveApiEmployess(@RequestBody EmployeesAdvisoryInfoEntity EmployeesAdvisoryInfoEntity) {
if (StringUtils.isNotBlank(EmployeesAdvisoryInfoEntity.getOpenId())) {
EmployeesAdvisoryInfoEntity employeesAdvisoryInfoEntity = new EmployeesAdvisoryInfoEntity();
employeesAdvisoryInfoEntity.setOpenId(EmployeesAdvisoryInfoEntity.getOpenId());
employeesAdvisoryInfoEntity.setAdvisoryType("2");
employeesAdvisoryInfoEntity.setIzYg("1");
employessAdvisioryInfoApi.updateByOpenId(employeesAdvisoryInfoEntity);
}
System.out.println("-----------新增/编辑员工入驻申请信息--------getId------------"+EmployeesAdvisoryInfoEntity.getId());
//新增员工信息
// if (StringUtils.isNotBlank(EmployeesAdvisoryInfoEntity.getOpenId())) {
// EmployeesAdvisoryInfoEntity employeesAdvisoryInfoEntity = new EmployeesAdvisoryInfoEntity();
// employeesAdvisoryInfoEntity.setOpenId(EmployeesAdvisoryInfoEntity.getOpenId());
// employeesAdvisoryInfoEntity.setAdvisoryType("2");
// employeesAdvisoryInfoEntity.setIzYg("1");
// employessAdvisioryInfoApi.updateByOpenId(employeesAdvisoryInfoEntity);
// }
System.out.println("-----------新增/编辑员工入驻申请信息--------getId------------" + EmployeesAdvisoryInfoEntity.getId());
if (StringUtils.isNotBlank(EmployeesAdvisoryInfoEntity.getId())) {
employessAdvisioryInfoApi.updateById(EmployeesAdvisoryInfoEntity);
return Result.ok("保存成功!");
@ -48,10 +50,11 @@ public class EmployessInfoApi {
* @return
*/
@GetMapping("/queryApiEmployessInfo")
public Result<List<EmployeesAdvisoryInfoEntity>> queryApiEmployessInfo(@RequestParam("openId") String openId){
if(StringUtils.isBlank(openId)){
public Result<List<EmployeesAdvisoryInfoEntity>> queryApiEmployessInfo(@RequestParam("openId") String openId,
@RequestParam(value = "orgCode", required = false) String orgCode) {
if (StringUtils.isBlank(openId)) {
return Result.error("手机号码错误");
}
return Result.ok(employessAdvisioryInfoApi.queryAuditInfo(openId));
return Result.ok(employessAdvisioryInfoApi.queryAuditInfo(openId, orgCode));
}
}

View File

@ -1,7 +1,7 @@
package com.nu.modules.wechat.orgapplyinfo.api;
import com.nu.modules.EmployessInfo.api.IEmployessAdvisioryInfoApi;
import com.nu.modules.EmployessInfo.entity.EmployeesAdvisoryInfoEntity;
import com.nu.entity.EmployeesAdvisoryInfoEntity;
import com.nu.modules.orgapplyinfo.api.IOrgApplyInfoApi;
import com.nu.modules.orgapplyinfo.entity.OrgApplyInfoApiEntity;
import org.apache.commons.lang.StringUtils;

View File

@ -36,9 +36,9 @@ public class EmployeesApplyMQDto implements Serializable {
/**婚否*/
private String marriedOrNot;
/**身高*/
private Double height;
private String height;
/**体重*/
private Double weight;
private String weight;
/**家庭住址*/
private String address;
/**是否吸烟*/
@ -69,6 +69,10 @@ public class EmployeesApplyMQDto implements Serializable {
private String bankPositive;
/**银行卡反面*/
private String bankNegative;
/**开户行*/
private String openingBank;
/**银行卡号*/
private String bankCard;
/**资质证*/
private String qualification;
/**无犯罪证明*/
@ -91,4 +95,6 @@ public class EmployeesApplyMQDto implements Serializable {
private String orgCode;
/**操作时间*/
private Date opeTime;
/**修改状态 1修改申请中 2通过 3驳回 */
private java.lang.String modifyStatus;
}

View File

@ -1,6 +1,7 @@
package com.nu.modules.EmployessInfo.entity;
package com.nu.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
@ -120,4 +121,8 @@ public class EmployeesAdvisoryInfoEntity implements Serializable {
private String izJs;
private String izJg;
private String orgCode;
//信息修改状态 没提交过修改 1修改申请中 2通过 3驳回*/
private String modifyState;
}

View File

@ -40,9 +40,9 @@ public class EmployeesApplyEntity implements Serializable {
/**婚否*/
private String marriedOrNot;
/**身高*/
private Double height;
private String height;
/**体重*/
private Double weight;
private String weight;
/**家庭住址*/
private String address;
/**是否吸烟*/
@ -73,6 +73,10 @@ public class EmployeesApplyEntity implements Serializable {
private String bankPositive;
/**银行卡反面*/
private String bankNegative;
/**开户行*/
private String openingBank;
/**银行卡号*/
private String bankCard;
/**资质证*/
private String qualification;
/**无犯罪证明*/

View File

@ -1,4 +1,4 @@
package com.nu.modules.EmployessInfo.entity;
package com.nu.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
@ -49,6 +49,6 @@ public class EmployeesOrgApiEntity implements Serializable {
private String status;
/**审核备注*/
private String auditContent;
/**是否为被邀请 0被邀请 1主动申请*/
private java.lang.String isInvited;
/**申请类型 0被邀请 1主动申请 */
private java.lang.String applyType;
}

View File

@ -370,10 +370,12 @@ justauth:
#zmy
aliyun:
ocr:
# accessKeyId: LTAI5tMoCTt4sb9VQrcnZFsb
# accessKeySecret: pQBMT6TlUWgRfvvDnOu0IKVYXCfKee
accessKeyId: LTAI5tJxmaqyXSG1T8Q6PSE9
accessKeySecret: baBJyQOvph6dVugiSnx3tsiEuJeMy3
# 滕
accessKeyId: LTAI5tBREjXcTV54bhZu2eXx
accessKeySecret: ETmm0DE6kI6FM5B5wpUwxfNapv4Fr8
# 君
# accessKeyId: LTAI5tJxmaqyXSG1T8Q6PSE9
# accessKeySecret: baBJyQOvph6dVugiSnx3tsiEuJeMy3
#文件传输秘钥
downloadkey: hP2K9Z!WLuj"M#8,