package com.younike.system.param;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;

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

/**
 * 团购服务订单核销参数
 *
 * @author Dail
 */
@Data
public class GroupOrderVerifyParam implements Serializable {

    private static final long serialVersionUID = 1L;


    /** 订单id */
    @NotNull(message = "订单id不能为空")
    @JsonSerialize(using= ToStringSerializer.class)
    private Long orderId;

    /** 会员id */
    private Long memberId;

    /** 服务人员id */
    private Long serverId;

    /** 预约时间 */
    @NotNull(message = "预约时间不能为空")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime appointmentTime;

    /** 订单核销码 */
    @NotBlank(message = "订单核销码不能为空")
    private String orderVerificationCode;

    /** 备注 */
    private String remark;

}
