package shop.alien.entity.store;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

/**
 * 预订服务营业时间表
 *
 * @author system
 * @since 2025-01-XX
 */
@Data
@JsonInclude
@TableName("store_booking_business_hours")
@ApiModel(value = "StoreBookingBusinessHours对象", description = "预订服务营业时间表")
public class StoreBookingBusinessHours {

    @ApiModelProperty(value = "主键ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;


    @ApiModelProperty(value = "关联store_booking_settings表 id")
    @TableField("settings_id")
    private Integer settingsId;

    @ApiModelProperty(value = "营业类型（1:正常营业时间, 2:特殊营业时间）")
    @TableField("business_type")
    private Integer businessType;

    @ApiModelProperty(value = "节假日类型（当business_type=2时使用，如：春节、元旦、国庆节等，为空表示正常营业）")
    @TableField("holiday_type")
    private String holidayType;

    @ApiModelProperty(value = "节假日日期（当business_type=2时使用，用于指定具体日期，可选，格式：yyyy-MM-dd）")
    @TableField("holiday_date")
    private String holidayDate;

    @ApiModelProperty(value = "预订时间类型（0:非全天, 1:全天）")
    @TableField("booking_time_type")
    private Integer bookingTimeType;

    @ApiModelProperty(value = "开始时间（HH:mm格式，非全天时必填）")
    @TableField("start_time")
    private String startTime;

    @ApiModelProperty(value = "结束时间（HH:mm格式，非全天时必填）")
    @TableField("end_time")
    private String endTime;

    @ApiModelProperty(value = "排序（用于同一门店多条记录的排序）")
    @TableField("sort")
    private Integer sort;

    @ApiModelProperty(value = "删除标记, 0:未删除, 1:已删除")
    @TableField("delete_flag")
    @TableLogic
    private Integer deleteFlag;

    @ApiModelProperty(value = "创建时间")
    @TableField(value = "created_time", fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createdTime;

    @ApiModelProperty(value = "创建人ID")
    @TableField("created_user_id")
    private Integer createdUserId;

    @ApiModelProperty(value = "修改时间")
    @TableField(value = "updated_time", fill = FieldFill.INSERT_UPDATE)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updatedTime;

    @ApiModelProperty(value = "修改人ID")
    @TableField("updated_user_id")
    private Integer updatedUserId;

    @ApiModelProperty(value = "关联essential_holiday_comparison id")
    @TableField("essential_id")
    private Integer essentialId;

    @ApiModelProperty(value = "预约 0免费 1付费")
    @TableField("reservation")
    private String reservation;

    @ApiModelProperty(value = "预订金额")
    @TableField("reservation_money")
    private Double reservationMoney;
}
