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 1/2] =?UTF-8?q?=E5=90=88=E5=90=8C=E6=A1=A3=E6=A1=88?= =?UTF-8?q?=E6=97=A5=E6=9C=9F=E6=B7=BB=E5=8A=A0@JsonFormat=E6=B3=A8?= =?UTF-8?q?=E8=A7=A3/=E5=91=98=E5=B7=A5=E6=A1=A3=E6=A1=88=E5=AE=9E?= =?UTF-8?q?=E4=BD=93=E7=B1=BB=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; + } From a5b896a76a1d122e3dd8e0435933b79bcd6943c4 Mon Sep 17 00:00:00 2001 From: JiilingLee <462362@qq.com> Date: Mon, 9 Oct 2023 17:29:58 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E9=9D=9E=E7=A9=BA=E6=A0=A1=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/admin/voucher/vo/VoucherCreateReqVO.java | 8 ++++++++ .../controller/admin/depot/vo/DepotCreateReqVO.java | 7 +++++++ .../admin/depotcabinet/vo/DepotCabinetCreateReqVO.java | 6 ++++++ .../admin/organization/vo/OrganizationCreateReqVO.java | 7 +++++++ 4 files changed, 28 insertions(+) diff --git a/yudao-module-accounting/yudao-module-accounting-biz/src/main/java/cn/iocoder/yudao/module/accounting/controller/admin/voucher/vo/VoucherCreateReqVO.java b/yudao-module-accounting/yudao-module-accounting-biz/src/main/java/cn/iocoder/yudao/module/accounting/controller/admin/voucher/vo/VoucherCreateReqVO.java index 7e0d26b3..9235f1e5 100644 --- a/yudao-module-accounting/yudao-module-accounting-biz/src/main/java/cn/iocoder/yudao/module/accounting/controller/admin/voucher/vo/VoucherCreateReqVO.java +++ b/yudao-module-accounting/yudao-module-accounting-biz/src/main/java/cn/iocoder/yudao/module/accounting/controller/admin/voucher/vo/VoucherCreateReqVO.java @@ -11,4 +11,12 @@ import javax.validation.constraints.*; @ToString(callSuper = true) public class VoucherCreateReqVO extends VoucherBaseVO { + @NotNull(message = "凭证号不能为空") + private String voucherNum; + + @NotNull(message = "年度不能为空") + private String year; + + @NotNull(message = "会计期间不能为空") + private String period; } diff --git a/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/depot/vo/DepotCreateReqVO.java b/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/depot/vo/DepotCreateReqVO.java index 9475af5a..698adfb6 100644 --- a/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/depot/vo/DepotCreateReqVO.java +++ b/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/depot/vo/DepotCreateReqVO.java @@ -11,4 +11,11 @@ import javax.validation.constraints.*; @ToString(callSuper = true) public class DepotCreateReqVO extends DepotBaseVO { + @NotNull(message = "库房名称不能为空") + private String name; + + @NotNull(message = "所属立档单位名称不能为空") + private Long organizationId; + + } diff --git a/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/depotcabinet/vo/DepotCabinetCreateReqVO.java b/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/depotcabinet/vo/DepotCabinetCreateReqVO.java index 6608f67e..b039c1d5 100644 --- a/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/depotcabinet/vo/DepotCabinetCreateReqVO.java +++ b/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/depotcabinet/vo/DepotCabinetCreateReqVO.java @@ -11,4 +11,10 @@ import javax.validation.constraints.*; @ToString(callSuper = true) public class DepotCabinetCreateReqVO extends DepotCabinetBaseVO { + @NotNull(message = "所属库房不能为空") + private Long depotId; + + @NotNull(message = "档案柜名称不能为空") + private String name; + } diff --git a/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/organization/vo/OrganizationCreateReqVO.java b/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/organization/vo/OrganizationCreateReqVO.java index 46312416..61ce1860 100644 --- a/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/organization/vo/OrganizationCreateReqVO.java +++ b/yudao-module-setting/yudao-module-setting-biz/src/main/java/cn/iocoder/yudao/module/setting/controller/admin/organization/vo/OrganizationCreateReqVO.java @@ -11,4 +11,11 @@ import javax.validation.constraints.*; @ToString(callSuper = true) public class OrganizationCreateReqVO extends OrganizationBaseVO { + @NotNull(message = "立档单位名称不能为空") + private String organizationName; + + @NotNull(message = "全宗号不能为空") + private String caseNum; + + }