package com.liquidnet.service.goblin.dto.manage.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.liquidnet.commons.lang.util.DateUtil;
import com.liquidnet.service.goblin.dto.vo.GoblinNftGoodsSkuListVo;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigInteger;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;

/**
 * <p>
 * 预约关联sku和spu表
 * </p>
 *
 * @author liquidnet
 * @since 2022-04-08
 */
@Data
public class AnticipateValueVo implements Cloneable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "预约开始时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
    private LocalDateTime aboutStartDate;
    @ApiModelProperty(value = "预约结束时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = DateUtil.DATE_FULL_STR)
    private LocalDateTime aboutEndDate;
    @ApiModelProperty("预约状态(0:未开始，1:可预约，3:已结束)")
    private Integer state;
    @ApiModelProperty("预约规则")
    private String rule;
    @ApiModelProperty("预约人数")
    private BigInteger aboutPeople;
    @ApiModelProperty("前三预约头像")
    private List<String> aboutAvatarList;

    private static final AnticipateValueVo obj = new AnticipateValueVo();

    public static AnticipateValueVo getNew() {
        try {
            return (AnticipateValueVo) obj.clone();
        } catch (CloneNotSupportedException e) {
            return new AnticipateValueVo();
        }
    }

    public AnticipateValueVo copy(GoblinGoodsAnticipateValueVo source) {
        this.setRule(source.getRule());
        this.setAboutPeople(source.getAboutPeople());
        this.setAboutStartDate(source.getAboutStartDate());
        this.setAboutEndDate(source.getAboutEndDate());
        this.setState(source.getState());
        return this;
    }

}
