package com.bonus.canteen.core.order.domain.param;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

@Data
public class DeviceOrderInfoAddParam {
    @NotNull(message = "食堂ID不能为空")
    private Long canteenId;
    private String canteenName;
    @NotNull(message = "档口ID不能为空")
    private Long stallId;
    @NotNull(message = "用户ID不能为空")
    @NotNull(message = "餐次类型不能为空")
    private Integer mealtimeType;
    private String mealtimeName;
    @NotNull(message = "订单日期不能为空")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date orderDate;
    @NotNull(message = "订单类型不能为空")
    private Integer orderType;
    @NotNull(message = "设备订单ID不能为空")
    private String deviceOrderId;
    @NotNull(message = "设备SN不能为空")
    private String deviceSn;
    @NotNull(message = "设备编号不能为空")
    private String deviceNum;
    @NotNull(message = "核身方式不能为空")
    private Integer identityVerification;
    @Valid
    @NotNull(message = "订单列表详情不能为空")
    private List<DeviceOrderDetailInfoAddParam> orderDetailList;
}
