package com.tofly.pojo.car.dto;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

/**
 * @author wujianjun
 * @date 2023/12/11 10:14
 */
@Data
public class CarOilSaveDTO {

    @ApiModelProperty(value = "ID 修改的时候必须穿")
    private Long Id = 0L;

    @ApiModelProperty(value = "车辆ID")
    @NotNull(message = "车辆ID必须填写")
    private Long vehicleId;

    @ApiModelProperty(value = "联系电话")
    @NotBlank(message = "联系电话必须填写")
    private String contactNumber;

    @ApiModelProperty(value = "加油地址")
    @NotBlank(message = "加油地址必须填写")
    private String refuelLocation;

    @ApiModelProperty(value = "支付方式 1 微信 2支付 3现金 4银行卡")
    @NotNull(message = "支付方式不能为空")
    private Integer paymentMethod;

    @ApiModelProperty(value = "加油人ID")
    @NotNull(message = "加油人ID必须填写")
    private Long responsibleId;


    @ApiModelProperty(value = "油料标号")
    @NotBlank(message = "油料标号必须填写")
    private String fuelGrade;

    @ApiModelProperty(value = "公里数")
    @NotNull(message = "公里数必须填写")
    private Double mileage;

    @ApiModelProperty(value = "单价")
    @NotNull(message = "单价必须填写")
    private Double unitPrice;

    @ApiModelProperty(value = "加油量")
    @NotNull(message = "加油量须填写")
    private Double fuelQuantity;

    @ApiModelProperty(value = "总费用")
    @NotNull(message = "总费用必须填写")
    private Double totalCost;

    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date refuelDate;

    @ApiModelProperty(value = "附件列表")
    private List<String> filePath;


    @ApiModelProperty(value = "备注")
    private String remark;

}
