Merge branch 'master' of http://122.51.230.86:3000/dianliang/lanan-system
This commit is contained in:
commit
4d3d510a7f
@ -25,6 +25,12 @@ public class BaseConstants {
|
||||
public static final String PASSWORD_DEFAULT = "123456";
|
||||
/**租户下部门名称*/
|
||||
public static final String DEPT_NAME_CORP_NAME = "政企客户";
|
||||
/**计算下次保险时间*/
|
||||
public static final String COMPUTE_TYPE_BX = "bx";
|
||||
/**计算下次保养时间*/
|
||||
public static final String COMPUTE_TYPE_BY = "by";
|
||||
/**计算下次检测时间*/
|
||||
public static final String COMPUTE_TYPE_JC = "jc";
|
||||
/**企业管理-员工管理表名称*/
|
||||
public static final String COMPANY_STAFF = "company_staff";
|
||||
/**员工标识*/
|
||||
|
@ -2,6 +2,8 @@ package cn.iocoder.yudao.module.custom.entity;
|
||||
|
||||
import cn.iocoder.yudao.framework.tenant.core.db.TenantBaseDO;
|
||||
import lombok.*;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.*;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.LocalDateTime;
|
||||
@ -16,6 +18,9 @@ import java.time.LocalDateTime;
|
||||
import java.time.LocalDateTime;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY;
|
||||
|
||||
/**
|
||||
* 车辆信息 DO
|
||||
@ -51,42 +56,50 @@ public class CarMain extends TenantBaseDO {
|
||||
/**
|
||||
* 保养日期
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime maintenanceDate;
|
||||
/**
|
||||
* 保养里程
|
||||
*/
|
||||
private String maintenanceMileage;
|
||||
private BigDecimal maintenanceMileage;
|
||||
/**
|
||||
* 年检日期
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime inspectionDate;
|
||||
/**
|
||||
* 保险日期
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime insuranceDate;
|
||||
/**
|
||||
* 二级维护时间
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime checkDate;
|
||||
/**
|
||||
* 下次保养日期
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime nextMaintenanceDate;
|
||||
/**
|
||||
* 下次保养里程
|
||||
*/
|
||||
private Integer nextMaintenanceMileage;
|
||||
private BigDecimal nextMaintenanceMileage;
|
||||
/**
|
||||
* 下次年检日期
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime nextInspectionDate;
|
||||
/**
|
||||
* 保险到期日期
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime insuranceExpiryDate;
|
||||
/**
|
||||
* 下次二级维护时间
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime nextCheckDate;
|
||||
/**
|
||||
* 车辆品牌
|
||||
@ -103,6 +116,7 @@ public class CarMain extends TenantBaseDO {
|
||||
/**
|
||||
* 车辆注册日期
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime carRegisterDate;
|
||||
/**
|
||||
* 行驶证图片
|
||||
@ -115,6 +129,7 @@ public class CarMain extends TenantBaseDO {
|
||||
/**
|
||||
* 最近办理业务的时间
|
||||
*/
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime recentlyHandleBusinessTime;
|
||||
|
||||
|
||||
|
@ -5,12 +5,14 @@ import javax.validation.*;
|
||||
|
||||
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||
import cn.iocoder.yudao.module.custom.entity.CarMain;
|
||||
import cn.iocoder.yudao.module.custom.vo.CarBrandRespVO;
|
||||
import cn.iocoder.yudao.module.custom.vo.CarMainReqVO;
|
||||
import cn.iocoder.yudao.module.custom.vo.CarMainRespVO;
|
||||
import cn.iocoder.yudao.module.custom.vo.CustomerMainSaveReqVO;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@ -66,4 +68,15 @@ public interface CarMainService extends IService<CarMain> {
|
||||
* @return void
|
||||
**/
|
||||
void bindCustomAndCar(CarMainReqVO saveReqVO);
|
||||
|
||||
/**
|
||||
* 测算车辆下一次保养/检测/保险时间
|
||||
* @author PQZ
|
||||
* @date 7:45 2024/8/9
|
||||
* @param reqVO TODO
|
||||
* @return java.time.LocalDateTime
|
||||
**/
|
||||
LocalDateTime compute(CarMainReqVO reqVO);
|
||||
|
||||
|
||||
}
|
@ -20,9 +20,12 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import static cn.iocoder.yudao.common.BaseConstants.COMPUTE_TYPE_BX;
|
||||
import static cn.iocoder.yudao.common.BaseConstants.CUS_SIGN_CAR;
|
||||
|
||||
/**
|
||||
@ -195,6 +198,20 @@ public class CarMainServiceImpl extends ServiceImpl<CarMainMapper, CarMain> impl
|
||||
customerCarService.bindCustomerCar(saveReqVO.getId(),CUS_SIGN_CAR,customerCars);
|
||||
}
|
||||
|
||||
/**
|
||||
* 测算车辆下一次保养/检测/保险时间
|
||||
* @author PQZ
|
||||
* @date 7:45 2024/8/9
|
||||
* @param reqVO CarMainReqVO
|
||||
* @return java.time.LocalDateTime
|
||||
**/
|
||||
@Override
|
||||
public LocalDateTime compute(CarMainReqVO reqVO) {
|
||||
LocalDateTime resultTime;
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 车牌号,车架号,发动机号码 查重
|
||||
* @param reqVO
|
||||
|
@ -1,10 +1,16 @@
|
||||
package cn.iocoder.yudao.module.custom.vo;
|
||||
|
||||
import cn.iocoder.yudao.module.custom.entity.CarMain;
|
||||
import cn.iocoder.yudao.module.label.entity.BusiLabel;
|
||||
import lombok.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import javax.validation.constraints.Max;
|
||||
import javax.validation.constraints.Min;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
@ -15,75 +21,23 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ToString(callSuper = true)
|
||||
public class CarMainReqVO extends PageParam {
|
||||
@Schema(description = "主键ID")
|
||||
private String id;
|
||||
public class CarMainReqVO extends CarMain {
|
||||
|
||||
@Schema(description = "发动机号码")
|
||||
private String engineNumber;
|
||||
@Schema(description = "页码,从 1 开始", requiredMode = Schema.RequiredMode.REQUIRED,example = "1")
|
||||
@NotNull(message = "页码不能为空")
|
||||
@Min(value = 1, message = "页码最小值为 1")
|
||||
private Integer pageNo = 1;
|
||||
|
||||
@Schema(description = "车架号")
|
||||
private String vin;
|
||||
@Schema(description = "每页条数,最大值为 100", requiredMode = Schema.RequiredMode.REQUIRED, example = "10")
|
||||
@NotNull(message = "每页条数不能为空")
|
||||
@Min(value = 1, message = "每页条数最小值为 1")
|
||||
@Max(value = 100, message = "每页条数最大值为 100")
|
||||
private Integer pageSize = 10;
|
||||
|
||||
@Schema(description = "车牌号")
|
||||
private String licenseNumber;
|
||||
|
||||
@Schema(description = "车辆型号")
|
||||
private String carModel;
|
||||
|
||||
@Schema(description = "保养日期")
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime maintenanceDate;
|
||||
|
||||
@Schema(description = "保养里程")
|
||||
private String maintenanceMileage;
|
||||
|
||||
@Schema(description = "年检日期")
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime inspectionDate;
|
||||
|
||||
@Schema(description = "保险日期")
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime insuranceDate;
|
||||
|
||||
@Schema(description = "二级维护时间")
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime checkDate;
|
||||
|
||||
@Schema(description = "车辆品牌")
|
||||
private String carBrand;
|
||||
|
||||
@Schema(description = "车辆性质:营运 非营运等")
|
||||
private String carNature;
|
||||
|
||||
@Schema(description = "车辆类别:私家车 货车 教练车 公务车 出租车")
|
||||
private String carCategory;
|
||||
|
||||
@Schema(description = "车辆注册日期")
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime carRegisterDate;
|
||||
|
||||
@Schema(description = "行驶证图片")
|
||||
private String carLicenseImg;
|
||||
|
||||
@Schema(description = "最近办理业务")
|
||||
private String recentlyHandledBusiness;
|
||||
|
||||
@Schema(description = "最近办理业务的时间")
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime recentlyHandleBusinessTime;
|
||||
|
||||
@Schema(description = "创建时间")
|
||||
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY)
|
||||
private LocalDateTime createTime;
|
||||
|
||||
@Schema(description = "租户ID")
|
||||
private String tenantId;
|
||||
|
||||
@Schema(description = "车辆绑定客户信息")
|
||||
/**车辆绑定客户信息*/
|
||||
private List<CustomerMainRespVO> cusList;
|
||||
|
||||
@Schema(description = "车辆绑定标签信息")
|
||||
/**车辆绑定标签信息*/
|
||||
List<BusiLabel> labelList;
|
||||
/**车辆品牌型号数组*/
|
||||
List<String> brandAndModel;
|
||||
|
@ -18,9 +18,7 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_
|
||||
public class CarMainRespVO extends CarMain {
|
||||
|
||||
|
||||
@Schema(description = "创建时间")
|
||||
@ExcelProperty("创建时间")
|
||||
private LocalDateTime createTime;
|
||||
|
||||
|
||||
/**是否车主(0否1是)*/
|
||||
@Schema(description = "是否车主(0否1是)")
|
||||
|
Loading…
Reference in New Issue
Block a user