package com.ruoyi.ss.store.domain;

import java.math.BigDecimal;
import java.time.LocalTime;
import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.domain.ValidGroup;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import org.springframework.validation.annotation.Validated;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

/**
 * 店铺对象 ss_store
 *
 * @author qzz
 * @date 2024-11-20
 */
@Data
public class Store extends BaseEntity{

    private static final long serialVersionUID = 1L;

    /** 店铺id */
    @ApiModelProperty("店铺id")
    @NotNull(message = "店铺id不允许为空", groups = {ValidGroup.Update.class})
    private Long storeId;

    @Excel(name = "店铺名称")
    @ApiModelProperty("店铺名称")
    @NotBlank(message = "店铺名称不允许为空", groups = {ValidGroup.Create.class})
    private String name;

    @Excel(name = "店铺类型：1-茶室；2-棋牌室；3-台球")
    @ApiModelProperty("店铺类型：1-茶室；2-棋牌室；3-台球")
//    @NotBlank(message = "店铺类型不允许为空", groups = {ValidGroup.Create.class})
    private String type;

    @Excel(name = "联系人")
    @ApiModelProperty("联系人")
    @NotBlank(message = "联系人不允许为空", groups = {ValidGroup.Create.class})
    private String contactName;

    @Excel(name = "联系电话")
    @ApiModelProperty("联系电话")
    @NotBlank(message = "联系电话不允许为空", groups = {ValidGroup.Create.class})
    private String contactMobile;

    @Excel(name = "身份证号")
    @ApiModelProperty("身份证号")
    private String idcard;

    @Excel(name = "商户图片")
    @ApiModelProperty("商户图片")
    private String picture;

    @Excel(name = "门店地址")
    @ApiModelProperty("门店地址")
    private String address;

    @Excel(name = "定位经度")
    @ApiModelProperty("定位经度")
    @NotNull(message = "经度不允许为空", groups = {ValidGroup.Create.class})
    private BigDecimal lng;

    @Excel(name = "定位纬度")
    @ApiModelProperty("定位纬度")
    @NotNull(message = "纬度不允许为空", groups = {ValidGroup.Create.class})
    private BigDecimal lat;

    @JsonFormat(pattern = "HH:mm", timezone = "GMT+8")
    @ApiModelProperty("营业起始时间")
    @NotNull(message = "营业起始时间不允许为空", groups = {ValidGroup.Create.class})
    private LocalTime businessTimeStart;

    @JsonFormat(pattern = "HH:mm", timezone = "GMT+8")
    @ApiModelProperty("营业结束时间")
    @NotNull(message = "营业结束时间不允许为空", groups = {ValidGroup.Create.class})
    private LocalTime businessTimeEnd;

    @Excel(name = "省")
    @ApiModelProperty("省")
    private String province;

    @Excel(name = "市")
    @ApiModelProperty("市")
    private String city;

    @Excel(name = "区县")
    @ApiModelProperty("区县")
    private String county;

    @Excel(name = "客服电话")
    @ApiModelProperty("客服电话")
    private String serverPhone;

    @Excel(name = "地址")
    @ApiModelProperty("地址")
    private String simpleAddress;

    @Excel(name = "商户id")
    @ApiModelProperty("商户id")
    private Long merchantId;

    @Excel(name = "状态")
    @ApiModelProperty("状态")
    private String status;

    @Excel(name = "店铺码")
    @ApiModelProperty("店铺码")
    private String code;

    @Excel(name = "大门sn(用于控制大门锁)")
    @ApiModelProperty("大门sn(用于控制大门锁)")
    private String gateSn;

    @Excel(name = "大门id(用于控制大门锁)")
    @ApiModelProperty("大门id(用于控制大门锁)")
    private Long gateId;

    @Excel(name = "店长id")
    @ApiModelProperty("店长id")
    private Long managerId;

    @Excel(name = "店长名称")
    @ApiModelProperty("店长名称")
    private String managerName;

    @Excel(name = "店长电话")
    @ApiModelProperty("店长电话")
    private String managerPhone;

    @Excel(name = "城市id")
    @ApiModelProperty("城市id")
    private Long cityId;

    @Excel(name = "标签列表")
    @ApiModelProperty("标签列表")
    @Size(min = 1, message = "至少需要一个标签", groups = {ValidGroup.Create.class})
    private List<String> tags;

    /** 房间类型标签（该店铺下有哪些类型的房间）用逗号分隔，房间类型：1-茶室；2-棋牌室；3-台球室 */
    @Excel(name = "房间类型标签")
    @ApiModelProperty("房间类型标签")
    private List<String> typeTags;

    @Excel(name = "店铺图片")
    @ApiModelProperty("店铺图片")
    private List<String> pictures;

    @Excel(name = "起订时间")
    @ApiModelProperty("起订时间")
    private String minimumTime;

    @ApiModelProperty("开锁方式: 1-通电开锁；2-断电开锁")
    private String unlockMode;

    @ApiModelProperty("开锁条件：1-有当前订单可进入；2-有历史订单可恶进入；3-无条件")
    private String unlockCondition;

    @ApiModelProperty("开锁时长")
    private Integer unlockTime;

}
