package com.ningdatech.carapi.car.rpt.model.dto;

import com.ningdatech.basic.model.PagePo;
import com.ningdatech.basic.util.NdDateUtils;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

/**
 * @Classname RptDailyOverspeedSpecialVehiclesParamDTO
 * @Description
 * @Date 2022/11/8 17:06
 * @Created by PoffyZhang
 */
@Data
public class RptTendaysOfflineWeekSpecialParamDTO extends PagePo implements Serializable {

    @ApiModelProperty("月份")
    @NotNull(message = "请选择月份")
    @DateTimeFormat(pattern = "yyyy-MM")
    private String month;

    @ApiModelProperty("类型 1上旬 2中旬 3下旬")
    @NotNull(message = "请选择旬")
    private Integer type;

    private LocalDateTime startTime;
    private LocalDateTime endTime;
    private LocalDateTime lastStartTime;
    private LocalDateTime lastEndTime;
    private String dataScopeSql;

    private String tableName = "nd_vehicle_online_status_hour_" + NdDateUtils.format(new Date(),"yyyy_MM");
}
