Commit d6df9519 authored by fangxinjiang's avatar fangxinjiang

Merge remote-tracking branch 'origin/develop' into develop

# Conflicts:
#	yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/vo/EmpEducationExcelVO.java
#	yifu-archives/yifu-archives-api/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/vo/EmpEducationUpdateExcelVo.java
#	yifu-archives/yifu-archives-biz/src/main/java/com/yifu/cloud/plus/v1/yifu/archives/service/impl/TEmployeeInfoServiceImpl.java
parents 71d52d2c 15eebdbe
......@@ -24,6 +24,9 @@ import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
/**
* 电子档案信息表
*
......@@ -37,28 +40,34 @@ import lombok.EqualsAndHashCode;
public class TElecEmployeeInfo extends BaseEntity {
/**
* id
* 主键
*/
@TableId(type = IdType.ASSIGN_ID)
@Schema(description ="id")
private Long id;
@Schema(description ="主键")
private String id;
/**
* 员工姓名
*/
@Schema(description ="员工姓名")
@NotNull(message = "员工姓名不能为空")
@Size(max = 20, message = "员工姓名不可超过20位")
private String empName;
/**
* 身份证号
* 身份证号码
*/
@Schema(description ="身份证号")
@Schema(description ="身份证号码")
@NotNull(message = "身份证号码不能为空")
@Size(max = 20, message = "身份证号码不可超过20位")
private String empIdcard;
/**
* 员工编码
*/
@Schema(description ="员工编码")
@NotNull(message = "员工编码不能为空")
@Size(max = 20, message = "员工编码不可超过20位")
private String empNo;
/**
......@@ -91,5 +100,10 @@ public class TElecEmployeeInfo extends BaseEntity {
@Schema(description ="附件")
private String attaInfo;
/**
* 是否删除 0否/1是
*/
@Schema(description ="是否删除 0否/1是")
private String deleteFlag;
}
......@@ -38,11 +38,11 @@ import lombok.EqualsAndHashCode;
public class TEmpChangeInfo extends BaseEntity {
/**
* id
* 主键
*/
@TableId(type = IdType.ASSIGN_ID)
@Schema(description ="id")
private Long id;
@Schema(description ="主键")
private String id;
/**
* 员工姓名
......@@ -75,10 +75,10 @@ public class TEmpChangeInfo extends BaseEntity {
private String newSettle;
/**
* 员工id
* 项目档案id
*/
@Schema(description ="员工id")
private Long empId;
@Schema(description ="项目档案id")
private Long proId;
/**
* 未结算费用 0:划转 1:不划转
......@@ -112,4 +112,31 @@ public class TEmpChangeInfo extends BaseEntity {
@Schema(description ="身份证号码")
private String empIdcard;
/**
* 客户id
*/
@Schema(description ="客户id")
@TableField(exist = false)
private String unitId;
/**
* 客户编码
*/
@Schema(description ="客户编码")
@TableField(exist = false)
private String unitNo;
/**
* 项目id
*/
@Schema(description ="项目id")
@TableField(exist = false)
private String deptId;
/**
* 项目编码
*/
@Schema(description ="项目编码")
@TableField(exist = false)
private String deptNo;
}
......@@ -22,7 +22,7 @@ import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.time.LocalDateTime;
import java.time.LocalDate;
/**
* 员工学历信息表
......@@ -40,110 +40,110 @@ public class TEmpEducation extends BaseEntity {
* 主键
*/
@TableId(type = IdType.ASSIGN_ID)
@Schema(description ="主键")
@Schema(description = "主键")
private String id;
/**
* 员工ID
*/
@Schema(description ="员工ID")
@Schema(description = "员工ID")
private String empId;
/**
* 员工姓名
*/
@Schema(description ="员工姓名")
@Schema(description = "员工姓名")
private String empName;
/**
* 员工编码
*/
@Schema(description ="员工编码")
@Schema(description = "员工编码")
private String empCode;
/**
* 身份证号
*/
@Schema(description ="身份证号")
@Schema(description = "身份证号")
private String empIdcard;
/**
* 入学时间
*/
@Schema(description ="入学时间")
private LocalDateTime entryDate;
@Schema(description = "入学时间")
private LocalDate entryDate;
/**
* 学历名称
*/
@Schema(description ="学历名称")
@Schema(description = "学历名称")
private String educationName;
/**
* 结业日期
*/
@Schema(description ="结业日期")
private LocalDateTime gradutionDate;
@Schema(description = "结业日期")
private LocalDate gradutionDate;
/**
* 学校名称
*/
@Schema(description ="学校名称")
@Schema(description = "学校名称")
private String school;
/**
* 学制类型
*/
@Schema(description ="学制类型")
@Schema(description = "学制类型")
private String educationSystem;
/**
* 最高学历标识0是/1否
*/
@Schema(description ="最高学历标识0是/1否")
@Schema(description = "最高学历标识0是/1否")
private String highIdentification;
/**
* 学历类型:全日制、自考、函授等
*/
@Schema(description ="学历类型:全日制、自考、函授等")
@Schema(description = "学历类型:全日制、自考、函授等")
private String type;
/**
* 院系名称
*/
@Schema(description ="院系名称")
@Schema(description = "院系名称")
private String collageSystem;
/**
* 是否删除 0未删除/1删除
*/
@TableLogic
@Schema(description ="是否删除 0未删除/1删除")
@Schema(description = "是否删除 0未删除/1删除")
private String deleteFlag;
/**
* 派单标识 1 代表派单生成, 派单审核通过后清空标识 专门用于派单作废
*/
@Schema(description ="派单标识 1 代表派单生成, 派单审核通过后清空标识 专门用于派单作废")
@Schema(description = "派单标识 1 代表派单生成, 派单审核通过后清空标识 专门用于派单作废")
private String dispatchFlag;
/**
* 证书名称
*/
@Schema(description ="证书名称")
@Schema(description = "证书名称")
private String certificationName;
/**
* 备注
*/
@Schema(description ="备注")
@Schema(description = "备注")
private String remark;
/**
* 专业
*/
@Schema(description ="专业")
@Schema(description = "专业")
private String major;
......
......@@ -26,6 +26,8 @@ import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.Max;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.time.LocalDate;
import java.time.LocalDateTime;
......@@ -58,6 +60,7 @@ public class TEmployeeInfo extends BaseEntity {
* 员工类型(字典值,0外包1派遣2代理)
*/
@Schema(description = "员工类型(字典值,0外包1派遣2代理)")
@NotNull( message = "员工类型不可为空")
@Max(value = 1, message = "员工类型不可超过1位")
private String empNatrue;
......@@ -65,14 +68,16 @@ public class TEmployeeInfo extends BaseEntity {
* 员工姓名
*/
@Schema(description = "员工姓名")
@Max(value = 20, message = "员工姓名不可超过20位")
@NotNull( message = "员工姓名不可为空")
@Size(max = 20, message = "员工姓名不可超过20位")
private String empName;
/**
* 身份证号码
*/
@Schema(description = "身份证号码")
@Max(value = 20, message = "身份证号码不可超过20位")
@NotNull( message = "身份证号码不可为空")
@Size(max = 20, message = "身份证号码不可超过20位")
private String empIdcard;
/**
......@@ -103,7 +108,7 @@ public class TEmployeeInfo extends BaseEntity {
* 年龄
*/
@Schema(description = "年龄")
@Max(value = 11, message = "年龄不可超过11位")
@Max(value = 200, message = "年龄不可超过200")
private Integer empAge;
/**
......@@ -122,21 +127,22 @@ public class TEmployeeInfo extends BaseEntity {
* 政治面貌
*/
@Schema(description = "政治面貌")
@Max(value = 32, message = "政治面貌不可超过32位")
@Size(max = 32, message = "政治面貌不可超过32位")
private String politicalStatus;
/**
* 邮箱
*/
@Schema(description = "邮箱")
@Max(value = 32, message = "邮箱不可超过32位")
@Size(max = 32, message = "邮箱不可超过32位")
private String empEmail;
/**
* 手机号码
*/
@Schema(description = "手机号码")
@Max(value = 11, message = "手机号码不可超过11位")
@NotNull( message = "手机号码不可为空")
@Size(max = 11,min = 11, message = "手机号码只能11位")
private String empPhone;
/**
......
......@@ -25,7 +25,10 @@ import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.time.LocalDateTime;
import java.util.Date;
/**
* 项目档案表
......@@ -50,30 +53,40 @@ public class TEmployeeProject extends BaseEntity {
* 人员档案主表id
*/
@Schema(description ="人员档案主表id")
@NotNull(message = "人员档案主表id不能为空")
@Size(max = 32, message = "人员档案主表id不可超过32位")
private String empId;
/**
* 员工主码(系统自动生成:ZM+年月日+5位数字)
*/
@Schema(description ="员工主码(系统自动生成:ZM+年月日+5位数字)")
@NotNull(message = "员工主码不能为空")
@Size(max = 16, message = "员工主码不可超过16位")
private String empCode;
/**
* 员工类型(字典值,0外包1派遣2代理)
*/
@Schema(description ="员工类型(字典值,0外包1派遣2代理)")
@NotNull(message = "员工类型不能为空")
@Size(max = 1, message = "员工类型不可超过1位")
private String empNatrue;
/**
* 员工姓名
*/
@Schema(description ="员工姓名")
@NotNull(message = "员工姓名不能为空")
@Size(max = 20, message = "员工姓名不可超过20位")
private String empName;
/**
* 身份证号码
*/
@Schema(description ="身份证号码")
@NotNull(message = "身份证号码不能为空")
@Size(max = 20, message = "身份证号码不可超过20位")
private String empIdcard;
/**
......@@ -128,6 +141,8 @@ public class TEmployeeProject extends BaseEntity {
* 员工编码
*/
@Schema(description ="员工编码")
@NotNull(message = "员工编码不能为空")
@Size(max = 20, message = "员工编码不可超过20位")
private String empNo;
/**
......@@ -188,6 +203,8 @@ public class TEmployeeProject extends BaseEntity {
* 合同类型(字典值)
*/
@Schema(description ="合同类型(字典值)")
@NotNull(message = "合同类型不能为空")
@Size(max = 1, message = "合同类型不可超过1位")
private String contractType;
/**
......@@ -206,7 +223,7 @@ public class TEmployeeProject extends BaseEntity {
* 入职日期
*/
@Schema(description ="入职日期")
private LocalDateTime enjoinDate;
private Date enjoinDate;
/**
* 试用期(单位月)
......
......@@ -7,6 +7,7 @@ import lombok.Data;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.Date;
......
/*
* Copyright (c) 2018-2025, lengleng All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* Neither the name of the yifu4cloud.com developer nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
* Author: lengleng (wangiegie@gmail.com)
*/
package com.yifu.cloud.plus.v1.yifu.archives.vo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo;
import lombok.Data;
import java.io.Serializable;
/**
* 档案更新记录需要的信息
*
* @author huyc
* @date 2022-06-20 17:54:40
*/
@Data
public class EmployeeNewOldVO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 变更前的档案
*/
private TEmployeeInfo oldEmployee;
/**
* 变更后的档案
*/
private TEmployeeInfo newEmployee;
}
......@@ -20,9 +20,9 @@ import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import lombok.Data;
import javax.validation.constraints.Max;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Past;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.time.LocalDateTime;
......@@ -42,7 +42,7 @@ public class EmployeeProjectVO implements Serializable {
* 员工类型(字典值,0外包1派遣2代理)
*/
@NotNull(message = "员工类型不能为空")
@Max(value = 1,message = "员工类型不可超过1位")
@Size(max = 1, message = "员工类型不可超过1位")
@ExcelProperty(value ="员工类型")
private String empNatrue;
......@@ -50,7 +50,7 @@ public class EmployeeProjectVO implements Serializable {
* 员工姓名
*/
@NotNull(message = "员工姓名不能为空")
@Max(value = 32,message = "员工姓名不可超过32位")
@Size(max = 20,message = "员工姓名不可超过20位")
@ExcelProperty(value ="员工姓名")
private String empName;
......@@ -58,7 +58,7 @@ public class EmployeeProjectVO implements Serializable {
* 身份证号码
*/
@NotNull(message = "身份证号不能为空")
@Max(value = 32,message = "身份证号不可超过32位")
@Size(max = 20,message = "身份证号不可超过20位")
@ExcelProperty(value ="身份证号")
private String empIdcard;
......
......@@ -20,8 +20,8 @@ import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import lombok.Data;
import javax.validation.constraints.Max;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.time.LocalDate;
......@@ -48,28 +48,28 @@ public class EmployeeVO implements Serializable {
* 姓名
*/
@ExcelProperty(value = "姓名")
@Max(value = 20, message = "姓名不可超过20位")
@Size(max = 20, message = "姓名不可超过20位")
private String empName;
/**
* 身份证号
*/
@ExcelProperty(value = "身份证号")
@Max(value = 20, message = "身份证号不可超过20位")
@Size(max = 20, message = "身份证号不可超过20位")
private String empIdcard;
/**
* 项目编码
*/
@ExcelProperty(value = "项目编码")
@Max(value = 32, message = "项目编码不可超过32位")
@Size(max = 32, message = "项目编码不可超过32位")
private String deptNo;
/**
* 就职岗位
*/
@ExcelProperty(value = "就职岗位")
@Max(value = 50, message = "就职岗位不可超过50位")
@Size(max = 50, message = "就职岗位不可超过50位")
private String post;
/**
......@@ -88,35 +88,35 @@ public class EmployeeVO implements Serializable {
* 婚姻状况
*/
@ExcelProperty(value = "婚姻状况")
@Max(value = 32, message = "婚姻状况不可超过32位")
@Size(max = 32, message = "婚姻状况不可超过32位")
private String empMarriStatus;
/**
* 民族
*/
@ExcelProperty(value = "民族")
@Max(value = 32, message = "民族不可超过32位")
@Size(max = 32, message = "民族不可超过32位")
private String empNational;
/**
* 政治面貌
*/
@ExcelProperty(value = "政治面貌")
@Max(value = 32, message = "政治面貌不可超过32位")
@Size(max = 32, message = "政治面貌不可超过32位")
private String politicalStatus;
/**
* 手机号码
*/
@ExcelProperty(value = "手机号码")
@Max(value = 11, message = "手机号码不可超过11位")
@Size(max = 11, message = "手机号码不可超过11位")
private String empPhone;
/**
* 邮箱
*/
@ExcelProperty(value = "邮箱")
@Max(value = 32, message = "邮箱不可超过32位")
@Size(max = 32, message = "邮箱不可超过32位")
private String empEmail;
/**
......
......@@ -29,6 +29,8 @@ import lombok.RequiredArgsConstructor;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;
import javax.validation.Valid;
/**
* 电子档案信息表
......@@ -79,7 +81,7 @@ public class TElecEmployeeInfoController {
@SysLog("新增电子档案信息表" )
@PostMapping
@PreAuthorize("@pms.hasPermission('archives_telecemployeeinfo_add')" )
public R save(@RequestBody TElecEmployeeInfo tElecEmployeeInfo) {
public R save(@Valid @RequestBody TElecEmployeeInfo tElecEmployeeInfo) {
return R.ok(tElecEmployeeInfoService.save(tElecEmployeeInfo));
}
......
......@@ -24,11 +24,8 @@ import com.pig4cloud.plugin.excel.vo.ErrorMessage;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TCustomerInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmpChangeInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TSettleDomain;
import com.yifu.cloud.plus.v1.yifu.archives.service.TCustomerInfoService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmpChangeInfoService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TSettleDomainService;
import com.yifu.cloud.plus.v1.yifu.archives.vo.TEmpChangeInfoVO;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import com.yifu.cloud.plus.v1.yifu.common.log.annotation.SysLog;
import io.swagger.v3.oas.annotations.Operation;
......@@ -55,10 +52,6 @@ public class TEmpChangeInfoController {
private final TEmpChangeInfoService tEmpChangeInfoService;
private final TCustomerInfoService tCustomerInfoService;
private final TSettleDomainService tSettleDomainService;
/**
* 分页查询
* @param page 分页对象
......@@ -134,8 +127,7 @@ public class TEmpChangeInfoController {
@SysLog("获取所有项目名称" )
@GetMapping("/getAllDept" )
public R<List<TSettleDomain>> getAllDept() {
List<TSettleDomain> list = tSettleDomainService.list(Wrappers.<TSettleDomain>query().lambda().eq(TSettleDomain::getDeleteFlag, CommonConstants.STATUS_NORMAL));
return R.ok(list);
return tEmpChangeInfoService.getAllDept();
}
......@@ -149,8 +141,7 @@ public class TEmpChangeInfoController {
@SysLog("获取所有单位名称" )
@GetMapping("/getAllUint" )
public R<List<TCustomerInfo>> getAllUint() {
List<TCustomerInfo> list = tCustomerInfoService.list(Wrappers.<TCustomerInfo>query().lambda().eq(TCustomerInfo::getDeleteFlag, CommonConstants.STATUS_NORMAL));
return R.ok(list);
return tEmpChangeInfoService.getAllUint();
}
/**
......
......@@ -231,12 +231,12 @@ public class TEmployeeInfoController {
* @Date: 2022/6/21 19:42
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/
@Operation(summary = "通过ids删除人员档案表", description = "通过ids删除人员档案表")
@SysLog("通过ids删除人员档案表")
@Operation(summary = "通过ids批量删除人员档案表", description = "通过ids批量删除人员档案表")
@SysLog("通过ids批量删除人员档案表")
@GetMapping("/batchDeleteEmployee")
@PreAuthorize("@pms.hasPermission('temployeeinfo_batch_del')")
public R<String> batchDeleteEmployee(@RequestParam String ids) {
return tEmployeeInfoService.deleteEmployee(ids);
public R<List<ErrorMessage>> batchDeleteEmployee(@RequestParam String ids) {
return tEmployeeInfoService.batchDeleteEmployee(ids);
}
/**
......@@ -254,6 +254,37 @@ public class TEmployeeInfoController {
return tEmployeeInfoService.minusEmployee(id);
}
/**
* @param ids
* @Description: 通过ids批量减档人员档案表
* @Author: hgw
* @Date: 2022/6/21 19:42
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/
@Operation(summary = "通过ids批量减档人员档案表", description = "通过ids批量减档人员档案表")
@SysLog("通过ids批量减档人员档案表")
@GetMapping("/batchMinusEmployee")
@PreAuthorize("@pms.hasPermission('temployeeinfo_batch_minus')")
public R<List<ErrorMessage>> batchMinusEmployee(@RequestParam String ids) {
return tEmployeeInfoService.batchMinusEmployee(ids);
}
/**
* @param id 离职档案id
* @param projectIds 需要复项的项目ids
* @Description: 档案复档
* @Author: hgw
* @Date: 2022/6/23 17:40
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/
@Operation(summary = "档案复档", description = "档案复档 projectIds:项目档案ids")
@SysLog("档案复档")
@GetMapping("/restoreEmployee")
@PreAuthorize("@pms.hasPermission('temployeeinfo_restore')")
public R<String> restoreEmployee(@RequestParam String id, String projectIds) {
return tEmployeeInfoService.restoreEmployee(id, projectIds);
}
/**
* @param excelList
* @param bindingResult
......
......@@ -37,6 +37,7 @@ import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.validation.BindingResult;
import org.springframework.web.bind.annotation.*;
import javax.validation.Valid;
import java.util.List;
......@@ -75,7 +76,6 @@ public class TEmployeeProjectController {
*/
@Operation(summary = "分页查询", description = "分页查询")
@GetMapping("/page" )
// @PreAuthorize("@pms.hasPermission('archives_temployeeproject_get')" )
public R<IPage<TEmployeeProject>> getTEmployeeProjectPage(Page page, TEmployeeProject tEmployeeProject) {
return R.ok(tEmployeeProjectService.getTEmployeeProjectInfoPage(page,tEmployeeProject));
}
......@@ -102,7 +102,7 @@ public class TEmployeeProjectController {
@SysLog("新增项目档案表" )
@PostMapping
@PreAuthorize("@pms.hasPermission('archives_temployeeproject_add')" )
public R save(@RequestBody TEmployeeProject tEmployeeProject) {
public R save(@Valid @RequestBody TEmployeeProject tEmployeeProject) {
return R.ok(tEmployeeProjectService.save(tEmployeeProject));
}
......@@ -143,7 +143,7 @@ public class TEmployeeProjectController {
@SysLog("新增项目档案校验" )
@PostMapping("/check")
@PreAuthorize("@pms.hasPermission('archives_temployeeproject_addcheck')" )
public R addCheck(@RequestBody TEmployeeProject tEmployeeProject) {
public R addCheck(@Valid @RequestBody TEmployeeProject tEmployeeProject) {
return R.ok(tEmployeeProjectService.addCheck(tEmployeeProject));
}
......@@ -237,4 +237,14 @@ public class TEmployeeProjectController {
tEmployeeProjectService.listExportProject(projectDTO,idstr,exportFields);
}
/**
* 通过项目编码查询项目信息
* @param empNo
* @return R
*/
@Operation(summary = "通过项目编码查询项目信息", description = "通过项目编码查询项目信息")
@PostMapping("/getItemInfo" )
public R getItemByEmpNo(@RequestParam String empIdcard,@RequestParam String empNo) {
return tEmployeeProjectService.getItemByEmpNo(empIdcard,empNo);
}
}
......@@ -19,7 +19,9 @@ package com.yifu.cloud.plus.v1.yifu.archives.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.pig4cloud.plugin.excel.vo.ErrorMessage;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TCustomerInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmpChangeInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TSettleDomain;
import com.yifu.cloud.plus.v1.yifu.archives.vo.TEmpChangeInfoVO;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import org.springframework.validation.BindingResult;
......@@ -48,4 +50,20 @@ public interface TEmpChangeInfoService extends IService<TEmpChangeInfo> {
**/
R<List<ErrorMessage>> batchChangeArc(List<TEmpChangeInfoVO> excelVOList, BindingResult bindingResult);
/**
* 获取所有项目名称
* @return R
* @Author huyc
* @Date 2022-06-22
*/
R<List<TSettleDomain>> getAllDept();
/**
* 获取所有单位名称
* @return R
* @Author huyc
* @Date 2022-06-22
*/
R<List<TCustomerInfo>> getAllUint();
}
......@@ -93,15 +93,42 @@ public interface TEmployeeInfoService extends IService<TEmployeeInfo> {
**/
R<String> deleteEmployee(String id);
/**
* @param ids
* @Description: 批量删除
* @Author: hgw
* @Date: 2022/6/23 16:45
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/
R<List<ErrorMessage>> batchDeleteEmployee(String ids);
/**
* @param id
* @Description: 减
* @Description: 减
* @Author: hgw
* @Date: 2022/6/21 19:50
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/
R<String> minusEmployee(String id);
/**
* @param id
* @Description: 恢复档案
* @Author: hgw
* @Date: 2022/6/23 17:31
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.lang.String>
**/
R<String> restoreEmployee(String id, String projectIds);
/**
* @param ids
* @Description: 批量减档
* @Author: hgw
* @Date: 2022/6/23 17:12
* @return: com.yifu.cloud.plus.v1.yifu.common.core.util.R<java.util.List < com.pig4cloud.plugin.excel.vo.ErrorMessage>>
**/
R<List<ErrorMessage>> batchMinusEmployee(String ids);
/**
* @param employeeInfo 档案信息
* @param fileSource 人员档案来源(4人员档案新建、5项目档案新建、1社保/公积金、3商险、2薪酬)
......
......@@ -22,12 +22,13 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.pig4cloud.plugin.excel.vo.ErrorMessage;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectVO;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import org.springframework.validation.BindingResult;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;
import java.util.List;
......@@ -108,4 +109,13 @@ public interface TEmployeeProjectService extends IService<TEmployeeProject> {
**/
void listExportProject(EmployeeProjectExportVO projectDTO,String idstr,
List<String> exportFields);
/**
* @param employeeInfo
* @Description: 新增项目档案
* @Author: huyc
* @Date: 2022/6/23 18:06
**/
void saveEmployeeProjectInfo(TEmployeeInfo employeeInfo);
R getItemByEmpNo(String empIdcard, String empNo);
}
......@@ -20,17 +20,22 @@ import cn.hutool.core.collection.CollUtil;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.pig4cloud.plugin.excel.vo.ErrorMessage;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TCustomerInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmpChangeInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TSettleDomain;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmpChangeInfoMapper;
import com.yifu.cloud.plus.v1.yifu.archives.service.TCustomerInfoService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmpChangeInfoService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeProjectService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TSettleDomainService;
import com.yifu.cloud.plus.v1.yifu.archives.vo.TEmpChangeInfoVO;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.exception.ErrorCodes;
import com.yifu.cloud.plus.v1.yifu.common.core.util.Common;
import com.yifu.cloud.plus.v1.yifu.common.core.util.MsgUtils;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
import org.springframework.validation.BindingResult;
......@@ -43,9 +48,14 @@ import java.util.*;
* @date 2022-06-18 09:39:46
*/
@Service
@RequiredArgsConstructor
public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper, TEmpChangeInfo> implements TEmpChangeInfoService {
private TEmployeeProjectService tEmployeeProjectService;
private final TEmployeeProjectService tEmployeeProjectService;
private final TCustomerInfoService tCustomerInfoService;
private final TSettleDomainService tSettleDomainService;
/**
* @Author huyc
......@@ -67,6 +77,17 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
//社保公积金派单处需要直接修改为最新的项目
//社保预估库、缴费库、对比库、代理差额库,需要同步修改未结算(并且满足这个条件:数据 生成月≥此处划转起始月)的数据,已结算数据不变更;
//划转,更新项目信息
TEmployeeProject updateTEmployeeProject = tEmployeeProjectService.getById(tEmpChangeInfo.getProId());
if (Common.isNotNull(updateTEmployeeProject)) {
updateTEmployeeProject.setDeptNo(tEmpChangeInfo.getDeptNo());
updateTEmployeeProject.setDeptId(tEmpChangeInfo.getDeptId());
updateTEmployeeProject.setDeptName(tEmpChangeInfo.getNewDept());
updateTEmployeeProject.setUnitId(tEmpChangeInfo.getUnitId());
updateTEmployeeProject.setUnitNo(tEmpChangeInfo.getUnitNo());
updateTEmployeeProject.setUnitName(tEmpChangeInfo.getNewDept());
tEmployeeProjectService.updateById(updateTEmployeeProject);
}
//保存档案划转记录
this.save(tEmpChangeInfo);
return R.ok();
......@@ -100,7 +121,26 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
}
// 数据合法情况
if (CollUtil.isEmpty(errorMsg)) {
//划转,更新项目信息
TEmployeeProject updateTEmployeePro = tEmployeeProjectService.getOne(Wrappers.<TEmployeeProject>query().lambda()
.eq(TEmployeeProject::getEmpIdcard, excel.getEmpIdcard()).eq(TEmployeeProject::getDeptNo,excel.getOldSettleCode())
.eq(TEmployeeProject::getDeleteFlag,CommonConstants.STATUS_NORMAL));
if (Common.isNotNull(updateTEmployeePro)) {
TSettleDomain tSettleDomain = tSettleDomainService.getOne(Wrappers.<TSettleDomain>query().lambda()
.eq(TSettleDomain::getDepartNo,updateTEmployeePro.getDeptNo()).eq(TSettleDomain::getDeleteFlag,CommonConstants.STATUS_NORMAL));
if (Common.isNotNull(tSettleDomain)) {
updateTEmployeePro.setDeptNo(tSettleDomain.getDepartNo());
updateTEmployeePro.setDeptId(tSettleDomain.getId());
updateTEmployeePro.setDeptName(tSettleDomain.getDepartName());
TCustomerInfo tCustomerInfo = tCustomerInfoService.getById(tSettleDomain.getCustomerId());
if(Common.isNotNull(tCustomerInfo)) {;
updateTEmployeePro.setUnitId(tCustomerInfo.getId());
updateTEmployeePro.setUnitNo(tCustomerInfo.getCustomerCode());
updateTEmployeePro.setUnitName(tCustomerInfo.getCustomerName());
}
tEmployeeProjectService.updateById(updateTEmployeePro);
}
}
} else {
// 数据不合法
errorMessageList.add(new ErrorMessage((long) (i + 2), errorMsg));
......@@ -111,4 +151,28 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
}
return R.ok();
}
/**
* 获取所有项目名称
* @return R
* @Author huyc
* @Date 2022-06-22
*/
@Override
public R<List<TSettleDomain>> getAllDept() {
List<TSettleDomain> list = tSettleDomainService.list(Wrappers.<TSettleDomain>query().lambda().eq(TSettleDomain::getDeleteFlag, CommonConstants.STATUS_NORMAL));
return R.ok(list);
}
/**
* 获取所有单位名称
* @return R
* @Author huyc
* @Date 2022-06-22
*/
@Override
public R<List<TCustomerInfo>> getAllUint() {
List<TCustomerInfo> list = tCustomerInfoService.list(Wrappers.<TCustomerInfo>query().lambda().eq(TCustomerInfo::getDeleteFlag, CommonConstants.STATUS_NORMAL));
return R.ok(list);
}
}
......@@ -275,11 +275,11 @@ public class TEmpEducationServiceImpl extends ServiceImpl<TEmpEducationMapper, T
TEmpEducation exist = baseMapper.selectOne(Wrappers.<TEmpEducation>query().lambda()
.eq(TEmpEducation::getEducationName,education.getEducationName())
.eq(TEmpEducation::getDeleteFlag,CommonConstants.ZERO_STRING)
.eq(TEmpEducation::getEmpIdcard,education.getEducationName())
.eq(TEmpEducation::getEmpIdcard,education.getEmpIdcard())
.last(CommonConstants.LAST_ONE_SQL));
if (Common.isNotNull(exist)){
exist.setHighIdentification(education.getHighIdentification());
exist.setSchool(education.getType());
exist.setSchool(education.getSchool());
exist.setMajor(education.getMajor());
exist.setEntryDate(education.getEntryDate());
exist.setGradutionDate(education.getGradutionDate());
......
......@@ -26,9 +26,14 @@ import com.yifu.cloud.plus.v1.check.entity.TCheckMobile;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmployeeInfoMapper;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmpEducationService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeInfoService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeLogService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeProjectService;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmpEducationUpdateVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmpEducationUpdateVo;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmpFamilyExcelVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeNewOldVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeVO;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CacheConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
......@@ -42,6 +47,7 @@ import com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprCheckProperties;
import com.yifu.cloud.plus.v1.yifu.common.dapr.config.DaprUpmsProperties;
import com.yifu.cloud.plus.v1.yifu.common.dapr.util.HttpDaprUtil;
import lombok.RequiredArgsConstructor;
import org.checkerframework.checker.units.qual.C;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.cache.Cache;
import org.springframework.cache.CacheManager;
......@@ -66,6 +72,8 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
private final TEmployeeProjectService tEmployeeProjectService;
private final DaprCheckProperties daprCheckProperties;
private final DaprUpmsProperties daprUpmsProperties;
private final TEmployeeLogService tEmployeeLogService;
private final TEmpEducationService tEmpEducationService;
@Override
public IPage<TEmployeeInfo> getPage(Page<TEmployeeInfo> page, TEmployeeInfo employeeInfo, String sql) {
......@@ -125,10 +133,20 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
@Override
public R<Boolean> updateEmployee(TEmployeeInfo employeeInfo) {
// TODO-更新学历-房
if (Common.isEmpty(employeeInfo) || Common.isEmpty(employeeInfo.getId())) {
return R.failed("请传ID");
}
TEmployeeInfo old = this.getById(employeeInfo.getId());
if (old == null || Common.isEmpty(old.getId())) {
return R.failed("根据id未找到档案!" + employeeInfo.getId());
}
// TODO - 记录变更日志
// 更新学历-房
TEmpEducation education = new TEmpEducation();
this.doUpdateEducationCore(education, employeeInfo);
// 记录变更日志
tEmployeeLogService.saveModificationRecord(CommonConstants.dingleDigitIntArray[0], old.getId(),"", old, employeeInfo);
return R.ok(this.updateById(employeeInfo));
}
......@@ -139,6 +157,21 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
if (employee.getStatus() != CommonConstants.ZERO_INT) {
return R.failed("非草稿状态,无法删除!");
}
if (employee.getContractStatus() != CommonConstants.ZERO_INT) {
return R.failed("合同状态非初始,无法删除!");
}
if (employee.getInsuranceStatus() != CommonConstants.ZERO_INT) {
return R.failed("商险状态非初始,无法删除!");
}
if (employee.getSocialStatus() != CommonConstants.ZERO_INT) {
return R.failed("社保状态非初始,无法删除!");
}
if (employee.getFundStatus() != CommonConstants.ZERO_INT) {
return R.failed("公积金状态非初始,无法删除!");
}
if (employee.getSalaryStatus() != CommonConstants.ZERO_INT) {
return R.failed("工资状态非初始,无法删除!");
}
employee.setDeleteFlag(CommonConstants.STATUS_DEL);
// 获取项目档案,传参1,不过滤项目状态
List<TEmployeeProject> projectList = tEmployeeProjectService.getListByEmpId(id, CommonConstants.ONE_INT);
......@@ -155,6 +188,143 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
}
}
@Override
public R<List<ErrorMessage>> batchDeleteEmployee(String ids) {
if (Common.isEmpty(ids)) {
return R.failed("请选择!");
}
List<ErrorMessage> errorMessageList = new ArrayList<>();
String[] idArr = ids.split(",");
TEmployeeInfo employee;
String id;
List<TEmployeeInfo> canDeleteList = new ArrayList<>();
Set<String> errorMsg;
for (int i = 0; i < idArr.length; i++) {
errorMsg = new HashSet<>();
id = idArr[i];
employee = this.getById(id);
if (employee != null) {
if (employee.getStatus() != CommonConstants.ZERO_INT) {
errorMsg.add("身份证【"+employee.getEmpIdcard()+"】的人员:非草稿状态,无法删除");
}
if (employee.getContractStatus() != CommonConstants.ZERO_INT) {
errorMsg.add("身份证【"+employee.getEmpIdcard()+"】的人员:合同状态非初始,无法删除");
}
if (employee.getInsuranceStatus() != CommonConstants.ZERO_INT) {
errorMsg.add("身份证【"+employee.getEmpIdcard()+"】的人员:商险状态非初始,无法删除");
}
if (employee.getSocialStatus() != CommonConstants.ZERO_INT) {
errorMsg.add("身份证【"+employee.getEmpIdcard()+"】的人员:社保状态非初始,无法删除");
}
if (employee.getFundStatus() != CommonConstants.ZERO_INT) {
errorMsg.add("身份证【"+employee.getEmpIdcard()+"】的人员:公积金状态非初始,无法删除");
}
if (employee.getSalaryStatus() != CommonConstants.ZERO_INT) {
errorMsg.add("身份证【"+employee.getEmpIdcard()+"】的人员:工资状态非初始,无法删除");
}
// 数据合法情况
if (!CollUtil.isEmpty(errorMsg)) {
// 数据不合法
errorMessageList.add(new ErrorMessage((i + 1L), errorMsg));
} else {
canDeleteList.add(employee);
}
} else {
errorMessageList.add(new ErrorMessage((i + 1L), errorMsg));
}
}
if (CollUtil.isNotEmpty(errorMessageList)) {
return R.failed(errorMessageList);
} else {
List<TEmployeeProject> projectList;
for (TEmployeeInfo employeeInfo : canDeleteList) {
employeeInfo.setDeleteFlag(CommonConstants.STATUS_DEL);
// 获取项目档案,传参1,不过滤项目状态
projectList = tEmployeeProjectService.getListByEmpId(employeeInfo.getId(), CommonConstants.ONE_INT);
if (projectList != null && !projectList.isEmpty()) {
for (TEmployeeProject project : projectList) {
project.setDeleteFlag(CommonConstants.STATUS_DEL);
}
tEmployeeProjectService.updateBatchById(projectList);
}
this.updateById(employeeInfo);
}
return R.ok();
}
}
@Override
public R<String> restoreEmployee(String id, String projectIds) {
TEmployeeInfo employee = this.getById(id);
if (employee != null) {
if (employee.getFileStatus() != CommonConstants.ONE_INT) {
return R.failed("该人员已不在离职档案中!");
}
TEmployeeInfo old = this.getById(id);
if (Common.isNotNull(projectIds)) {
String[] idArr = projectIds.split(",");
// 获取项目档案,传参1,不过滤项目状态
List<TEmployeeProject> projectList = tEmployeeProjectService.getListByEmpId(id, CommonConstants.ONE_INT);
if (projectList != null && !projectList.isEmpty()) {
for (String pid : idArr) {
for (TEmployeeProject project : projectList) {
if (project.getId().equals(pid)) {
project.setProjectStatus(CommonConstants.ZERO_INT);
tEmployeeProjectService.updateById(project);
}
}
}
}
}
employee.setFileStatus(CommonConstants.ZERO_INT);
this.updateById(employee);
// 记录变更日志
tEmployeeLogService.saveModificationRecord(CommonConstants.dingleDigitIntArray[0], old.getId(),"", old, employee);
return R.ok("已复档");
} else {
return R.failed("未找到离职档案信息");
}
}
@Override
public R<List<ErrorMessage>> batchMinusEmployee(String ids) {
if (Common.isEmpty(ids)) {
return R.failed("请选择!");
}
List<ErrorMessage> errorMessageList = new ArrayList<>();
String[] idArr = ids.split(",");
TEmployeeInfo employee;
String id;
List<TEmployeeInfo> canDeleteList = new ArrayList<>();
Set<String> errorMsg;
List<TEmployeeProject> projectList;
for (int i = 0; i<idArr.length; i++) {
errorMsg = new HashSet<>();
id = idArr[i];
employee = this.getById(id);
if (employee != null) {
projectList = tEmployeeProjectService.getListByEmpId(id, CommonConstants.ZERO_INT);
if (projectList != null && !projectList.isEmpty()) {
errorMsg.add("身份证【"+employee.getEmpIdcard()+"】的人员:还有【" + projectList.size() + "】条项目未减项,请先去减项");
errorMessageList.add(new ErrorMessage((i + 1L), errorMsg));
} else {
employee.setFileStatus(CommonConstants.ONE_INT);
canDeleteList.add(employee);
}
} else {
errorMessageList.add(new ErrorMessage((i + 1L), errorMsg));
}
}
if (CollUtil.isNotEmpty(errorMessageList)) {
return R.failed(errorMessageList);
} else {
this.updateBatchById(canDeleteList);
return R.ok();
}
}
@Override
public R<String> minusEmployee(String id) {
TEmployeeInfo employee = this.getById(id);
......@@ -162,7 +332,7 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
// 获取项目档案,传参0,过滤项目状态
List<TEmployeeProject> projectList = tEmployeeProjectService.getListByEmpId(id, CommonConstants.ZERO_INT);
if (projectList != null && !projectList.isEmpty()) {
return R.failed("还有[" + projectList + "]条项目未减项,请先去减项!");
return R.failed("还有【" + projectList.size() + "】条项目未减项,请先去减项!");
}
employee.setFileStatus(CommonConstants.ONE_INT);
this.updateById(employee);
......@@ -180,8 +350,12 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
R<TEmployeeInfo> checks = this.saveNewEmpLoyee(employeeInfo, CommonConstants.dingleDigitStrArray[4]);
if (checks != null && checks.getCode() != CommonConstants.SUCCESS) return R.failed(checks.getMsg());
// TODO-新建项目-胡雨辰
// TODO-新建学历-房
// 新建项目-雨辰
tEmployeeProjectService.saveEmployeeProjectInfo(employeeInfo);
// 新建学历-房
TEmpEducation education = new TEmpEducation();
this.doUpdateEducationCore(education, employeeInfo);
return R.ok();
}
......@@ -233,7 +407,7 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
}
// 字典:4人员档案新建、5项目档案新建、1社保/公积金、3商险、2薪酬
employeeInfo.setFileSource(fileSource);
employeeInfo.setStatus(CommonConstants.ONE_INT);
employeeInfo.setStatus(CommonConstants.ZERO_INT);
employeeInfo.setFileStatus(CommonConstants.ZERO_INT);
employeeInfo.setProjectNum(CommonConstants.ONE_INT);
employeeInfo.setDeleteFlag(CommonConstants.STATUS_NORMAL);
......@@ -585,10 +759,9 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
} else {
// 仅更新自己与学历即可
this.updateBatchById(saveList);
// TODO - 更新学历
// TODO - 记录变更日志
// 更新学历-房
this.saveOrUpdateEducation(saveList);
}
return R.ok();
}
......@@ -602,7 +775,7 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
private void setBaseData(TEmployeeInfo employeeInfo, List<TEmployeeInfo> saveList) {
// 新增档案
employeeInfo.setFileSource(CommonConstants.dingleDigitStrArray[4]);
employeeInfo.setStatus(CommonConstants.ONE_INT);
employeeInfo.setStatus(CommonConstants.ZERO_INT);
employeeInfo.setFileStatus(CommonConstants.ZERO_INT);
employeeInfo.setProjectNum(CommonConstants.ONE_INT);
employeeInfo.setDeleteFlag(CommonConstants.STATUS_NORMAL);
......@@ -617,6 +790,7 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
* @return: void
**/
private void saveOrUpdateData(List<TEmployeeInfo> saveList) {
TEmpEducation education;
for (TEmployeeInfo employeeInfo : saveList) {
// 新增档案
if (Common.isEmpty(employeeInfo.getId())) {
......@@ -625,11 +799,12 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
employeeInfo.setEmpCode(this.getCode());
}
this.save(employeeInfo);
// TODO-新增项目档案
// TODO-新增学历
// 新增项目档案
tEmployeeProjectService.saveEmployeeProjectInfo(employeeInfo);
// 更新学历-房
education = new TEmpEducation();
this.doUpdateEducationCore(education, employeeInfo);
} else {
// 复档复项
employeeInfo.setFileStatus(CommonConstants.ZERO_INT);
......@@ -717,10 +892,16 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
EmployeeVO excel;
// 需要保存的档案信息
TEmployeeInfo saveEmp;
// 原先的档案信息
TEmployeeInfo oldEmp;
// 已存在的档案
TEmployeeInfo existEmp;
// 存储可保存的档案信息
List<TEmployeeInfo> saveList = new ArrayList<>();
// 新老档案vo
EmployeeNewOldVO newOld;
// 新老档案List
List<EmployeeNewOldVO> updateList = new ArrayList<>();
// 调用字典服务,渲染字典值
R<Map<String, Map<String, String>>> dictR = HttpDaprUtil.invokeMethodPost(daprUpmsProperties.getAppUrl(), daprUpmsProperties.getAppId()
......@@ -753,7 +934,7 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
// 调用区域服务,渲染区域值
R<Map<String, String>> areaR = HttpDaprUtil.invokeMethodPost(daprUpmsProperties.getAppUrl(), daprUpmsProperties.getAppId()
, "/area/inner/getAreaToName", null, Map.class, SecurityConstants.FROM_IN);
Map<String, String> areaMap = new HashMap<>();
Map<String, String> areaMap;
if (areaR == null ) {
return R.failed("获取区域失败!");
} else {
......@@ -775,6 +956,8 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
if (saveEmp.getFileStatus() == CommonConstants.ZERO_INT) {
// 可以更新
oldEmp = existEmpMap.get(excel.getEmpIdcard());
// 校验身份证实名
if (Common.isNotNull(excel.getEmpName())) {
saveEmp.setEmpName(excel.getEmpName());
......@@ -922,6 +1105,10 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
saveEmp.setRemark(excel.getRemark());
}
// 更新时,不需要更新其余信息
newOld = new EmployeeNewOldVO();
newOld.setNewEmployee(saveEmp);
newOld.setOldEmployee(oldEmp);
updateList.add(newOld);
saveList.add(saveEmp);
} else if (saveEmp.getFileStatus() == CommonConstants.ONE_INT) {
errorMsg.add(MsgUtils.getMessage(ErrorCodes.ARCHIVES_IMPORT_EMP_IDCARD_LEAVE_EXISTING, excel.getEmpIdcard()));
......@@ -940,7 +1127,38 @@ public class TEmployeeInfoServiceImpl extends ServiceImpl<TEmployeeInfoMapper, T
return R.failed(errorMessageList);
} else {
this.saveOrUpdateData(saveList);
// 更新学历-房
this.saveOrUpdateEducation(saveList);
// 记录变更日志
for (EmployeeNewOldVO newOldInfo : updateList) {
tEmployeeLogService.saveModificationRecord(CommonConstants.dingleDigitIntArray[0]
, newOldInfo.getOldEmployee().getId(),""
, newOldInfo.getOldEmployee(), newOldInfo.getNewEmployee());
}
}
return R.ok();
}
// 更新学历-房
private void saveOrUpdateEducation(List<TEmployeeInfo> saveList) {
TEmpEducation education;
for (TEmployeeInfo employeeInfo : saveList) {
education = new TEmpEducation();
this.doUpdateEducationCore(education, employeeInfo);
}
}
// 更新学历-核心
private void doUpdateEducationCore(TEmpEducation education, TEmployeeInfo employeeInfo) {
education.setEmpIdcard(employeeInfo.getEmpIdcard());
education.setEducationName(employeeInfo.getHignEducation());
education.setHighIdentification(CommonConstants.ZERO_STRING);
education.setSchool(employeeInfo.getSchool());
education.setMajor(employeeInfo.getMajor());
education.setEntryDate(employeeInfo.getAdmissionDate());
education.setGradutionDate(employeeInfo.getGradutionDate());
tEmpEducationService.insertEducationOfEmp(education);
}
}
......@@ -25,27 +25,30 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.pig4cloud.plugin.excel.vo.ErrorMessage;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TCustomerInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeInfo;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TEmployeeProject;
import com.yifu.cloud.plus.v1.yifu.archives.entity.TSettleDomain;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TCustomerInfoMapper;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmployeeInfoMapper;
import com.yifu.cloud.plus.v1.yifu.archives.mapper.TEmployeeProjectMapper;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeLogService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TEmployeeProjectService;
import com.yifu.cloud.plus.v1.yifu.archives.service.TSettleDomainService;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportVO;
import com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectVO;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CacheConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.exception.ErrorCodes;
import com.yifu.cloud.plus.v1.yifu.common.core.util.Common;
import com.yifu.cloud.plus.v1.yifu.common.core.util.MsgUtils;
import com.yifu.cloud.plus.v1.yifu.common.core.util.NoUtil;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import com.yifu.cloud.plus.v1.yifu.common.core.util.*;
import com.yifu.cloud.plus.v1.yifu.common.core.vo.YifuUser;
import com.yifu.cloud.plus.v1.yifu.common.security.util.SecurityUtils;
import lombok.RequiredArgsConstructor;
import org.springframework.cache.Cache;
import org.springframework.cache.CacheManager;
import org.springframework.stereotype.Service;
import org.springframework.validation.BindingResult;
import java.io.IOException;
import java.time.LocalDateTime;
import java.util.*;
import java.util.stream.Collectors;
......@@ -64,7 +67,12 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
private final TEmployeeInfoMapper tEmployeeInfoMapper;
private final TEmployeeProjectMapper tEmployeeProjectMapper;
private final TSettleDomainService tSettleDomainService;
private final TCustomerInfoMapper tCustomerInfoMapper;
// 缓存信息
private final CacheManager cacheManager;
@Override
public R addCheck(TEmployeeProject tEmployeeProject) {
......@@ -96,6 +104,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
if (CommonConstants.STATUS_NORMAL.equals(tEmployeeInfo.getFileStatus())) {
return R.ok(map, "该人员已减项,是否“复项”");
} else {
map.put("code","202");
map.put("employeeId", tEmployeeInfo.getId());
return R.ok(map, "该人员已减档减项,是否“复档复项”");
}
......@@ -113,7 +122,8 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
//判断是否已经减档
if (CommonConstants.ONE_STRING.equals(tEmployeeInfo.getFileStatus())) {
map.put("employeeId", tEmployeeInfo.getId());
return R.ok(null,"该人员在离职库已存在,是否“恢复档案”");
map.put("code","203");
return R.ok(map,"该人员在离职库已存在,是否“恢复档案”");
}
}
return R.ok();
......@@ -285,13 +295,13 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
tEmployeeInfoMapper.updateExcelEmployeeInfo(updateList);
}
if (proInsList.size() > CommonConstants.dingleDigitIntArray[0]) {
tEmployeeProjectMapper.insertExcelEmpProject(proInsList);
baseMapper.insertExcelEmpProject(proInsList);
List<String> idList = proInsList.stream().map(TEmployeeProject::getEmpIdcard).collect(Collectors.toList());
List<TEmployeeInfo> updList = tEmployeeInfoMapper.selectList(Wrappers.<TEmployeeInfo>query().lambda().in(TEmployeeInfo::getEmpIdcard,idList));
tEmployeeProjectMapper.updateEmpIdById(updList);
baseMapper.updateEmpIdById(updList);
}
if (proupdateList.size() > CommonConstants.dingleDigitIntArray[0]) {
tEmployeeProjectMapper.updateExcelEmpProject(proupdateList);
baseMapper.updateExcelEmpProject(proupdateList);
}
} catch (Exception e) {
log.error("数据更新异常",e);
......@@ -357,7 +367,7 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
}
try {
if (updateList.size() > CommonConstants.dingleDigitIntArray[0]) {
tEmployeeProjectMapper.updateExcelEmpProject(updateList);
baseMapper.updateExcelEmpProject(updateList);
}
} catch (Exception e) {
log.error("数据更新异常",e);
......@@ -398,21 +408,56 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
insTEmployeePro.setEmpId(CommonConstants.EMPTY_STRING);
String str = "";
String EmpNo = tEmployeeProjectMapper.findEmployeeMaxOnlyNoByDepId(insTEmployeePro.getDeptNo());
String EmpNo = baseMapper.findEmployeeMaxOnlyNoByDepId(insTEmployeePro.getDeptNo());
if (!Common.isEmpty(EmpNo)) {
str = NoUtil.productionNo(EmpNo, CommonConstants.EMPLOYEE_INIT_NO_START);
} else {
str = insTEmployeePro.getDeptNo() + CommonConstants.EMPLOYEE_INIT_NO;
}
insTEmployeePro.setEmpNo(str);
//TODO HUYC 员工编码生成规则
insTEmployeePro.setEmpCode("");
//员工编码生成规则
insTEmployeePro.setEmpCode(this.getCode());
YifuUser user = SecurityUtils.getUser();
insTEmployeePro.setCreateBy(user.getId());
insTEmployeePro.setCreateName(user.getNickname());
proInsList.add(insTEmployeePro);
}
/**
* @param
* @Description: 获取员工主码
* @Author: hgw
* @Date: 2022/6/22 17:52
* @return: java.lang.String
**/
private synchronized String getCode() {
String nowDay = DateUtil.getThisDay();
Cache cache = cacheManager.getCache(CacheConstants.EVERYDAY_EMP_CODE);
Object nowNumObj = cache.get(nowDay);
int nowNums = 1;
if (!Common.isEmpty(nowNumObj)) {
nowNums = (Integer) nowNumObj + 1;
}
cache.put(nowDay, nowNums);
return this.getFiveNum(String.valueOf(nowNums));
}
/**
* @param nowNums 数字
* @Description: 获取五位字符型数字
* @Author: hgw
* @Date: 2022/6/21 17:35
* @return: 五位字符型数字
**/
private String getFiveNum(String nowNums) {
if (nowNums.length() >= 5) {
return nowNums.substring(0, 5);
}
String[] zeroArr = {"0", "00", "000", "0000"};
int num = 4 - nowNums.length();
return zeroArr[num] + nowNums;
}
@Override
public R<List<ErrorMessage>> batchRemoveByIds(String ids) {
List<ErrorMessage> errorList = new ArrayList<ErrorMessage>();
......@@ -489,6 +534,46 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
}
}
/**
* @param employeeInfo
* @Description: 新增项目档案
* @Author: huyc
* @Date: 2022/6/23 18:06
**/
@Override
public void saveEmployeeProjectInfo(TEmployeeInfo employeeInfo) {
TEmployeeProject tEmployeeProject = new TEmployeeProject();
tEmployeeProject.setEmpId(employeeInfo.getId());
tEmployeeProject.setEmpCode(this.getCode());
tEmployeeProject.setEmpNatrue(employeeInfo.getEmpNatrue());
tEmployeeProject.setEmpName(employeeInfo.getEmpName());
tEmployeeProject.setEmpIdcard(employeeInfo.getEmpIdcard());
tEmployeeProject.setPost(employeeInfo.getPost());
String str = "";
String EmpNo = baseMapper.findEmployeeMaxOnlyNoByDepId(employeeInfo.getDeptNo());
if (!Common.isEmpty(EmpNo)) {
str = NoUtil.productionNo(EmpNo, CommonConstants.EMPLOYEE_INIT_NO_START);
} else {
str = employeeInfo.getDeptNo() + CommonConstants.EMPLOYEE_INIT_NO;
}
tEmployeeProject.setEmpNo(str);
tEmployeeProject.setDeptNo(employeeInfo.getDeptNo());
TSettleDomain tSettleDomain = tSettleDomainService.getOne(Wrappers.<TSettleDomain>query().lambda()
.eq(TSettleDomain::getDepartNo,employeeInfo.getDeptNo()).eq(TSettleDomain::getDeleteFlag,CommonConstants.STATUS_NORMAL));
if (Common.isNotNull(tSettleDomain)) {
tEmployeeProject.setDeptId(tSettleDomain.getId());
tEmployeeProject.setDeptName(tSettleDomain.getDepartName());
TCustomerInfo tCustomerInfo = tCustomerInfoMapper.selectById(tSettleDomain.getCustomerId());
if(Common.isNotNull(tCustomerInfo)) {;
tEmployeeProject.setUnitId(tCustomerInfo.getId());
tEmployeeProject.setUnitNo(tCustomerInfo.getCustomerCode());
tEmployeeProject.setUnitName(tCustomerInfo.getCustomerName());
}
}
baseMapper.insert(tEmployeeProject);
}
/**
* 获取导出的项目档案列表
*/
......@@ -540,4 +625,30 @@ public class TEmployeeProjectServiceImpl extends ServiceImpl<TEmployeeProjectMap
project.setDeleteFlag(CommonConstants.STATUS_NORMAL);
return this.list(Wrappers.query(project));
}
@Override
public R getItemByEmpNo(String empIdcard, String empNo) {
TSettleDomain tSettleDomain = tSettleDomainService.getOne(Wrappers.<TSettleDomain>query().lambda()
.eq(TSettleDomain::getDepartNo,empNo));
TEmployeeInfo tEmployeeInfo = tEmployeeInfoMapper.selectOne(Wrappers.<TEmployeeInfo>query().lambda()
.eq(TEmployeeInfo::getEmpIdcard,empIdcard));
Map<String,Object> map = new HashMap<>();
String empCode = "";
if (Common.isNotNull(tEmployeeInfo)) {
empCode = tEmployeeInfo.getEmpCode();
}
String customerName = "";
if (Common.isNotNull(tSettleDomain)) {
TCustomerInfo tCustomerInfo = tCustomerInfoMapper.selectOne(Wrappers.<TCustomerInfo>query().lambda()
.eq(TCustomerInfo::getId,tSettleDomain.getCustomerId()));
if (Common.isNotNull(tCustomerInfo)) {
customerName = tCustomerInfo.getCustomerName();
}
}
map.put("empCode",empCode);
map.put("itemInfo",tSettleDomain);
map.put("customerName",customerName);
return R.ok(map);
}
}
......@@ -33,10 +33,87 @@
<result property="itemCode" column="ITEM_CODE"/>
<result property="dataType" column="DATA_TYPE"/>
<result property="attaInfo" column="ATTA_INFO"/>
<result property="deleteFlag" column="DELETE_FLAG"/>
<result property="createBy" column="CREATE_BY"/>
<result property="updateBy" column="UPDATE_BY"/>
<result property="createName" column="CREATE_NAME"/>
<result property="createTime" column="CREATE_TIME"/>
<result property="updateTime" column="UPDATE_TIME"/>
</resultMap>
<sql id="Base_Column_List">
a.ID,
a.EMP_NAME,
a.EMP_IDCARD,
a.EMP_NO,
a.BELONG_UNIT,
a.ITEM_NAME,
a.ITEM_CODE,
a.DATA_TYPE,
a.ATTA_INFO,
a.DELETE_FLAG,
a.UPDATE_BY,
a.CREATE_BY,
a.CREATE_NAME,
a.CREATE_TIME,
a.UPDATE_TIME
</sql>
<sql id="tElecEmployeeInfo_where">
<if test="tElecEmployeeInfo != null">
<if test="tElecEmployeeInfo.id != null and tElecEmployeeInfo.id.trim() != ''">
AND a.ID = #{tElecEmployeeInfo.id}
</if>
<if test="tElecEmployeeInfo.empName != null and tElecEmployeeInfo.empName.trim() != ''">
AND a.EMP_NAME = #{tElecEmployeeInfo.empName}
</if>
<if test="tElecEmployeeInfo.empIdcard != null and tElecEmployeeInfo.empIdcard.trim() != ''">
AND a.EMP_IDCARD = #{tElecEmployeeInfo.empIdcard}
</if>
<if test="tElecEmployeeInfo.empNo != null and tElecEmployeeInfo.empNo.trim() != ''">
AND a.EMP_NO = #{tElecEmployeeInfo.empNo}
</if>
<if test="tElecEmployeeInfo.belongUnit != null and tElecEmployeeInfo.belongUnit.trim() != ''">
AND a.BELONG_UNIT like concat('%',#{tElecEmployeeInfo.belongUnit},'%')
</if>
<if test="tElecEmployeeInfo.itemName != null and tElecEmployeeInfo.itemName.trim() != ''">
AND a.ITEM_NAME like concat('%',#{tElecEmployeeInfo.itemName},'%')
</if>
<if test="tElecEmployeeInfo.itemCode != null and tElecEmployeeInfo.itemCode.trim() != ''">
AND a.ITEM_CODE like concat('%',#{tElecEmployeeInfo.itemCode},'%')
</if>
<if test="tElecEmployeeInfo.dataType != null and tElecEmployeeInfo.dataType.trim() != ''">
AND a.DATA_TYPE = #{tElecEmployeeInfo.dataType}
</if>
<if test="tElecEmployeeInfo.attaInfo != null and tElecEmployeeInfo.attaInfo.trim() != ''">
AND a.ATTA_INFO = #{tElecEmployeeInfo.attaInfo}
</if>
<if test="tElecEmployeeInfo.createBy != null and tElecEmployeeInfo.createBy.trim() != ''">
AND a.CREATE_BY = #{tElecEmployeeInfo.createBy}
</if>
<if test="tElecEmployeeInfo.createName != null and tElecEmployeeInfo.createName.trim() != ''">
AND a.CREATE_NAME = #{tElecEmployeeInfo.createName}
</if>
<if test="tElecEmployeeInfo.createTime != null">
AND a.CREATE_TIME = #{tElecEmployeeInfo.createTime}
</if>
<if test="tElecEmployeeInfo.updateBy != null and tElecEmployeeInfo.updateBy.trim() != ''">
AND a.UPDATE_BY = #{tElecEmployeeInfo.updateBy}
</if>
<if test="tElecEmployeeInfo.updateTime != null">
AND a.UPDATE_TIME = #{tElecEmployeeInfo.updateTime}
</if>
</if>
</sql>
<!--tElecEmployeeInfo简单分页查询-->
<select id="getTElecEmployeeInfoPage" resultMap="tElecEmployeeInfoMap">
SELECT
<include refid="Base_Column_List"/>
FROM t_elec_employee_info a
<where>
1=1 AND a.DELETE_FLAG = 0
<include refid="tElecEmployeeInfo_where"/>
</where>
</select>
</mapper>
......@@ -31,7 +31,7 @@
<result property="newDept" column="NEW_DEPT"/>
<result property="oldSettle" column="OLD_SETTLE"/>
<result property="newSettle" column="NEW_SETTLE"/>
<result property="empId" column="EMP_ID"/>
<result property="proId" column="PRO_ID"/>
<result property="unsettleDeal" column="UNSETTLE_DEAL"/>
<result property="changeStartMonth" column="CHANGE_START_MONTH"/>
<result property="createBy" column="CREATE_BY"/>
......
......@@ -149,7 +149,7 @@
AND a.EMP_CODE = #{tEmployeeInfo.empCode}
</if>
<if test="tEmployeeInfo.empNatrue != null and tEmployeeInfo.empNatrue.trim() != ''">
AND a.EMP_NATRUE = #{tEmployeeInfo.empNatrue}
AND a.EMP_NATRUE in in concat('(',${tEmployeeInfo.empNatrue},')')
</if>
<if test="tEmployeeInfo.empName != null and tEmployeeInfo.empName.trim() != ''">
AND a.EMP_NAME = #{tEmployeeInfo.empName}
......@@ -247,16 +247,16 @@
</if>
</if>
<if test="tEmployeeInfo.contractStatus != null">
AND a.CONTRACT_STATUS = #{tEmployeeInfo.contractStatus}
AND a.CONTRACT_STATUS in concat('(',${tEmployeeInfo.contractStatus},')')
</if>
<if test="tEmployeeInfo.insuranceStatus != null">
AND a.INSURANCE_STATUS = #{tEmployeeInfo.insuranceStatus}
AND a.INSURANCE_STATUS in concat('(',${tEmployeeInfo.insuranceStatus},')')
</if>
<if test="tEmployeeInfo.socialStatus != null">
AND a.SOCIAL_STATUS = #{tEmployeeInfo.socialStatus}
AND a.SOCIAL_STATUS in concat('(',${tEmployeeInfo.socialStatus},')')
</if>
<if test="tEmployeeInfo.fundStatus != null">
AND a.FUND_STATUS = #{tEmployeeInfo.fundStatus}
AND a.FUND_STATUS in concat('(',${tEmployeeInfo.fundStatus},')')
</if>
<if test="tEmployeeInfo.salaryStatus != null">
AND a.SALARY_STATUS = #{tEmployeeInfo.salaryStatus}
......
......@@ -181,7 +181,7 @@
a.DEPT_ID,
a.DEPT_NAME,
a.DEPT_NO,
concat(a.BUSINESS_PRIMARY_TYPE,'-',BUSINESS_SECOND_TYPE,'-',a.BUSINESS_THIRD_TYPE) AS BUSINESS_TYPE,
concat(a.BUSINESS_PRIMARY_TYPE,'/',BUSINESS_SECOND_TYPE,'/',a.BUSINESS_THIRD_TYPE) AS BUSINESS_TYPE,
a.CONTRACT_TYPE,
a.WORKING_HOURS,
a.POST,
......@@ -481,6 +481,12 @@
<if test="tEmployeeProject.fileTown != null">
AND b.FILE_TOWN = #{tEmployeeProject.fileTown}
</if>
<if test="tEmployeeInfo.idList != null">
AND a.id in
<foreach item="idStr" index="index" collection="tEmployeeInfo.idList" open="(" separator="," close=")">
#{idStr}
</foreach>
</if>
</if>
</sql>
......@@ -667,8 +673,7 @@
<!--tEmployeeInfo简单分页查询-->
<select id="getTEmployeeProjectInfoPage" resultMap="tEmployeeProjectMap">
SELECT
<include refid="Base_Column_List"/>,
b.
<include refid="Base_Column_List"/>
FROM t_employee_project a
left join t_employee_info b on a.EMP_ID = b.id
<where>
......@@ -684,13 +689,7 @@
left join t_employee_info b on a.EMP_ID = b.id
<where>
1=1 AND a.DELETE_FLAG = 0
<include refid="tEmployeeProject_where"/>
<if test="tEmployeeInfo.idList != null">
AND a.id in
<foreach item="idStr" index="index" collection="tEmployeeInfo.idList" open="(" separator="," close=")">
#{idStr}
</foreach>
</if>
<include refid="exportTEmployeeProject_where"/>
</where>
</select>
</mapper>
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