From 048caaf49140a15d24bf16fb51d5493cc745fea7 Mon Sep 17 00:00:00 2001 From: liwen Date: Mon, 15 Jan 2024 10:36:09 +0800 Subject: [PATCH] =?UTF-8?q?update:=20=E8=BD=A6=E8=BE=86=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E6=A8=A1=E5=9D=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../safeproduct/constants/SafeProductConstant.java | 9 +++ .../dto/CarMaintenanceConfirmationDTO.java | 4 ++ .../safeproduct/entity/CarCheckItemEntity.java | 1 - .../safeproduct/vo/CarCheckRecordDetailVO.java | 4 ++ .../safeproduct/vo/CarUsedRecordDetailVO.java | 3 + .../safeproduct/mapper/CarUsedRecordMapper.xml | 2 +- .../service/impl/CarCheckRecordServiceImpl.java | 12 ++-- .../service/impl/CarMaintenanceServiceImpl.java | 11 ++-- .../service/impl/CarUsedRecordServiceImpl.java | 14 ++--- .../com/hnac/hzims/safeproduct/utils/BaseUtil.java | 70 ++++++++++++--------- .../safeproduct/src/main/resources/db/1.0.1.sql | 5 +- .../main/resources/template/用车记录单.docx | Bin 0 -> 11366 bytes .../main/resources/template/车辆检查表.docx | Bin 0 -> 11695 bytes 13 files changed, 84 insertions(+), 51 deletions(-) create mode 100644 hzims-service/safeproduct/src/main/resources/template/用车记录单.docx create mode 100644 hzims-service/safeproduct/src/main/resources/template/车辆检查表.docx diff --git a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/constants/SafeProductConstant.java b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/constants/SafeProductConstant.java index bcfb2fb..3a4e9b9 100644 --- a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/constants/SafeProductConstant.java +++ b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/constants/SafeProductConstant.java @@ -13,6 +13,15 @@ public interface SafeProductConstant { int SUCCESS = 1; int FAILURE = 0; + /** + * 文件后缀 + */ + String DOCX_SUFFIX = ".docx"; + String PDF_SUFFIX = ".pdf"; + + /** + * 培训管理 + */ int TRAIN_PLAN_HAS_TEST = 1; int TRAIN_PLAN_HAS_NO_TEST = 0; } diff --git a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/dto/CarMaintenanceConfirmationDTO.java b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/dto/CarMaintenanceConfirmationDTO.java index 9bfbcf7..13b943f 100644 --- a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/dto/CarMaintenanceConfirmationDTO.java +++ b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/dto/CarMaintenanceConfirmationDTO.java @@ -1,10 +1,12 @@ package com.hnac.hzims.safeproduct.dto; +import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; import java.math.BigDecimal; import java.util.Date; @@ -21,10 +23,12 @@ public class CarMaintenanceConfirmationDTO { private Long carMaintenanceId; @NotNull + @Size(max = 500, message = "车辆管理人意见长度不能超过500") @ApiModelProperty("车辆管理人意见") private String managerAdvice; @NotNull + @JsonFormat(pattern = "yyyy-MM-dd") @ApiModelProperty("下次维保时间") private Date maintenanceNextTime; diff --git a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/entity/CarCheckItemEntity.java b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/entity/CarCheckItemEntity.java index 3461c52..cd02dc3 100644 --- a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/entity/CarCheckItemEntity.java +++ b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/entity/CarCheckItemEntity.java @@ -1,6 +1,5 @@ package com.hnac.hzims.safeproduct.entity; -import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableName; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; diff --git a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/vo/CarCheckRecordDetailVO.java b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/vo/CarCheckRecordDetailVO.java index 2c1ff91..4aa745b 100644 --- a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/vo/CarCheckRecordDetailVO.java +++ b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/vo/CarCheckRecordDetailVO.java @@ -6,6 +6,7 @@ import io.swagger.annotations.ApiModelProperty; import lombok.Data; import java.math.BigDecimal; +import java.util.Date; import java.util.List; /** @@ -19,6 +20,9 @@ public class CarCheckRecordDetailVO { @ApiModelProperty("检查人") private String checker; + @ApiModelProperty("检查时间") + private Date checkTime; + @ApiModelProperty("品牌") private String carBrand; diff --git a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/vo/CarUsedRecordDetailVO.java b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/vo/CarUsedRecordDetailVO.java index 06cdf91..b415ff1 100644 --- a/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/vo/CarUsedRecordDetailVO.java +++ b/hzims-service-api/safeproduct-api/src/main/java/com/hnac/hzims/safeproduct/vo/CarUsedRecordDetailVO.java @@ -27,6 +27,9 @@ public class CarUsedRecordDetailVO { @ApiModelProperty("品牌") private String carBrand; + @ApiModelProperty("车辆类型") + private String carType; + @ApiModelProperty("车牌号") private String plateNumber; diff --git a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CarUsedRecordMapper.xml b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CarUsedRecordMapper.xml index 0150cb2..ad456ed 100644 --- a/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CarUsedRecordMapper.xml +++ b/hzims-service/safeproduct/src/main/java/com/hnac/hzims/safeproduct/mapper/CarUsedRecordMapper.xml @@ -5,7 +5,7 @@