From 5827015fe0076d067077a14f630da40d32830755 Mon Sep 17 00:00:00 2001 From: chiyilin <2449182606@qq.com> Date: Mon, 9 Oct 2023 15:35:43 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=88=E5=90=8C=E6=A1=A3=E6=A1=88=E6=97=A5?= =?UTF-8?q?=E6=9C=9F=E6=B7=BB=E5=8A=A0@JsonFormat=E6=B3=A8=E8=A7=A3/?= =?UTF-8?q?=E5=91=98=E5=B7=A5=E6=A1=A3=E6=A1=88=E5=AE=9E=E4=BD=93=E7=B1=BB?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ElectronicContractsController.java | 1 - .../vo/ElectronicContractsBaseVO.java | 10 +- .../ElectronicEmployeeController.java | 39 ++++---- .../vo/ElectronicEmployeeBaseVO.java | 92 +++++++++++++++++-- .../vo/ElectronicEmployeePageReqVO.java | 11 ++- 5 files changed, 117 insertions(+), 36 deletions(-) diff --git a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electroniccontracts/ElectronicContractsController.java b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electroniccontracts/ElectronicContractsController.java index 3a1b032e..0133120c 100644 --- a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electroniccontracts/ElectronicContractsController.java +++ b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electroniccontracts/ElectronicContractsController.java @@ -98,5 +98,4 @@ public class ElectronicContractsController { List datas = ElectronicContractsConvert.INSTANCE.convertList02(list); ExcelUtils.write(response, "合同档案.xls", "数据", ElectronicContractsExcelVO.class, datas); } - } diff --git a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electroniccontracts/vo/ElectronicContractsBaseVO.java b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electroniccontracts/vo/ElectronicContractsBaseVO.java index 22ba4be9..fb4c0555 100644 --- a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electroniccontracts/vo/ElectronicContractsBaseVO.java +++ b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electroniccontracts/vo/ElectronicContractsBaseVO.java @@ -1,13 +1,10 @@ package cn.iocoder.yudao.module.ea.controller.admin.electroniccontracts.vo; +import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.v3.oas.annotations.media.Schema; -import lombok.*; +import lombok.Data; import java.time.LocalDate; -import java.util.*; -import java.time.LocalDateTime; -import java.time.LocalDateTime; -import javax.validation.constraints.*; /** * 合同档案 Base VO,提供给添加、修改、详细的子 VO 使用 @@ -43,12 +40,15 @@ public class ElectronicContractsBaseVO { @Schema(description = "签署方") private String signatory; + @JsonFormat(pattern="yyyy-MM-dd") @Schema(description = "签署日期") private LocalDate signDate; + @JsonFormat(pattern="yyyy-MM-dd") @Schema(description = "生效日期") private LocalDate effectiveDate; + @JsonFormat(pattern="yyyy-MM-dd") @Schema(description = "截止日期") private LocalDate expiryDate; diff --git a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/ElectronicEmployeeController.java b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/ElectronicEmployeeController.java index 3b86c99c..9c5b2b1c 100644 --- a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/ElectronicEmployeeController.java +++ b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/ElectronicEmployeeController.java @@ -1,32 +1,29 @@ package cn.iocoder.yudao.module.ea.controller.admin.electronicemployee; -import org.springframework.web.bind.annotation.*; -import javax.annotation.Resource; -import org.springframework.validation.annotation.Validated; -import org.springframework.security.access.prepost.PreAuthorize; -import io.swagger.v3.oas.annotations.tags.Tag; -import io.swagger.v3.oas.annotations.Parameter; -import io.swagger.v3.oas.annotations.Operation; - -import javax.validation.constraints.*; -import javax.validation.*; -import javax.servlet.http.*; -import java.util.*; -import java.io.IOException; - -import cn.iocoder.yudao.framework.common.pojo.PageResult; import cn.iocoder.yudao.framework.common.pojo.CommonResult; -import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; - +import cn.iocoder.yudao.framework.common.pojo.PageResult; import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils; - import cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog; -import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.*; - import cn.iocoder.yudao.module.ea.controller.admin.electronicemployee.vo.*; -import cn.iocoder.yudao.module.ea.dal.dataobject.electronicemployee.ElectronicEmployeeDO; import cn.iocoder.yudao.module.ea.convert.electronicemployee.ElectronicEmployeeConvert; +import cn.iocoder.yudao.module.ea.dal.dataobject.electronicemployee.ElectronicEmployeeDO; import cn.iocoder.yudao.module.ea.service.electronicemployee.ElectronicEmployeeService; +import io.swagger.v3.oas.annotations.Operation; +import io.swagger.v3.oas.annotations.Parameter; +import io.swagger.v3.oas.annotations.tags.Tag; +import org.springframework.security.access.prepost.PreAuthorize; +import org.springframework.validation.annotation.Validated; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import javax.servlet.http.HttpServletResponse; +import javax.validation.Valid; +import java.io.IOException; +import java.util.Collection; +import java.util.List; + +import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; +import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT; @Tag(name = "管理后台 - 员工档案") @RestController diff --git a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/vo/ElectronicEmployeeBaseVO.java b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/vo/ElectronicEmployeeBaseVO.java index d3cd5c48..f614b9b0 100644 --- a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/vo/ElectronicEmployeeBaseVO.java +++ b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/vo/ElectronicEmployeeBaseVO.java @@ -1,11 +1,9 @@ package cn.iocoder.yudao.module.ea.controller.admin.electronicemployee.vo; import io.swagger.v3.oas.annotations.media.Schema; -import lombok.*; -import java.util.*; -import java.time.LocalDateTime; -import java.time.LocalDateTime; -import javax.validation.constraints.*; +import lombok.Data; + +import java.time.LocalDate; /** * 员工档案 Base VO,提供给添加、修改、详细的子 VO 使用 @@ -14,7 +12,7 @@ import javax.validation.constraints.*; @Data public class ElectronicEmployeeBaseVO { - @Schema(description = "id" ) + @Schema(description = "id") private Long id; @Schema(description = "制单人") @@ -62,4 +60,86 @@ public class ElectronicEmployeeBaseVO { @Schema(description = "归档状态", example = "2") private String fileStatus; + @Schema(description = "出生日期") + private LocalDate birthdate; + + @Schema(description = "地址") + private String address; + + @Schema(description = "护照号码") + private String passportNumber; + + @Schema(description = "毕业学校") + private String graduationSchool; + + @Schema(description = "专业") + private String major; + + @Schema(description = "学历") + private String education; + + @Schema(description = "教育经历") + private String educationExperience; + + @Schema(description = "工作经历") + private String workExperience; + + @Schema(description = "职位") + private String jobTitle; + + @Schema(description = "职位级别") + private String jobLevel; + + @Schema(description = "职位描述") + private String jobDescription; + + @Schema(description = "薪酬") + private Long salary; + + @Schema(description = "身体状况") + private String healthCondition; + + @Schema(description = "体检记录") + private String medicalRecords; + + @Schema(description = "疾病史") + private String diseaseHistory; + + @Schema(description = "社会保险") + private String socialInsurance; + + @Schema(description = "养老保险") + private Long pensionInsurance; + + @Schema(description = "医疗保险") + private Long medicalInsurance; + + @Schema(description = "失业保险") + private Long unemploymentInsurance; + + @Schema(description = "工伤保险") + private Long workInjuryInsurance; + + @Schema(description = "考核评价") + private String leaveRecords; + + @Schema(description = "奖惩记录") + private String overtimeRecords; + + @Schema(description = "培训计划") + private String welfareBenefits; + + @Schema(description = "培训成果") + private String performanceEvaluation; + + @Schema(description = "个人标签") + private String rewardsPunishments; + + @Schema(description = "兴趣爱好") + private String trainingRecords; + + @Schema(description = "特长") + private String personalDescription; + + } diff --git a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/vo/ElectronicEmployeePageReqVO.java b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/vo/ElectronicEmployeePageReqVO.java index 78d44f95..5d90567c 100644 --- a/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/vo/ElectronicEmployeePageReqVO.java +++ b/yudao-module-electronic/yudao-module-ea-biz/src/main/java/cn/iocoder/yudao/module/ea/controller/admin/electronicemployee/vo/ElectronicEmployeePageReqVO.java @@ -1,10 +1,12 @@ package cn.iocoder.yudao.module.ea.controller.admin.electronicemployee.vo; -import lombok.*; -import java.util.*; -import io.swagger.v3.oas.annotations.media.Schema; import cn.iocoder.yudao.framework.common.pojo.PageParam; +import io.swagger.v3.oas.annotations.media.Schema; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.ToString; import org.springframework.format.annotation.DateTimeFormat; + import java.time.LocalDateTime; import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; @@ -65,4 +67,7 @@ public class ElectronicEmployeePageReqVO extends PageParam { @Schema(description = "归档状态", example = "2") private String fileStatus; + @Schema(description = "薪酬") + private Long salary; + }