package com.yida.data.attendance.dto;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import java.time.LocalDateTime;
import java.time.LocalTime;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * 考勤-打卡时段 Entity
 *
 * @date 2023-08-09 11:37:25
 */
@Builder
@Data
@AllArgsConstructor
@NoArgsConstructor
public class AddAttendanceRuleTimeDTO {

    /**
     *
     */
    @ApiModelProperty(value = "")
    private Long id;
    /**
     * 考勤规则id
     */
    @ApiModelProperty(value = "考勤规则id")
    private Long ruleId;

    /**
     * 上班时间
     */
    @ApiModelProperty(value = "上班时间")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "HH:mm:ss")
    private LocalTime startTime;

    /**
     * 下班时间
     */
    @ApiModelProperty(value = "下班时间")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "HH:mm:ss")
    private LocalTime endTime;

    /**
     * 最晚时间-针对宿舍考勤晚归情况
     */
    @ApiModelProperty(value = "最晚时间-针对宿舍考勤晚归情况")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "HH:mm:ss")
    private LocalTime lastTime;

    /**
     * 上班打卡时段开始时间
     */
    @ApiModelProperty(value = "上班打卡时段开始时间")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "HH:mm:ss")
    private LocalTime startEffectiveStartTime;

    /**
     * 上班打卡时段结束时间
     */
    @ApiModelProperty(value = "上班打卡时段结束时间")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "HH:mm:ss")
    private LocalTime startEffectiveEndTime;

    /**
     * 下班打卡时段开始时间
     */
    @ApiModelProperty(value = "下班打卡时段开始时间")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "HH:mm:ss")
    private LocalTime endEffectiveStartTime;

    /**
     * 下班打卡时段结束时间
     */
    @ApiModelProperty(value = "下班打卡时段结束时间")
    @DateTimeFormat(pattern = "HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "HH:mm:ss")
    private LocalTime endEffectiveEndTime;


    /**
     * 结束时间是否为次日，1=是，0=否
     */
    @ApiModelProperty(value = "结束时间是否为次日，1=是，0=否")
    private Integer endNextDay;
}