package cn.newfeifan.mall.module.trade.controller.admin.order.vo.detailvo;

import cn.newfeifan.mall.framework.common.validation.InEnum;
import cn.newfeifan.mall.module.trade.enums.delivery.DeliveryTypeEnum;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;

@Schema(description = "管理后台 - 订单发货 Request VO")
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class TradeOrderDeliveryVO {

    @Schema(description = "订单编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024")
    @NotNull(message = "订单编号不能为空")
    private Long id;

    @Schema(description = "发货物流公司编号", example = "1")
    @NotNull(message = "发货物流公司不能为空")
    private Long logisticsId;

    @Schema(description = "发货物流单号", example = "SF123456789")
    private String logisticsNo;

    @Schema(description = "运费 单位分", example = "10")
    private Integer deliveryPrice;

    @Schema(description = "配送方式", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @InEnum(value = DeliveryTypeEnum.class, message = "配送方式不正确")
    private String deliveryType;

    @Schema(description = "商家备注", example = "你好")
    private String remark;


}
