package com.yueqian.xingyun.chart.vo;

import com.lframework.starter.web.core.components.validation.IsEnum;
import com.lframework.starter.web.core.vo.BaseVo;
import com.yueqian.xingyun.chart.enums.OrderChartBizType;
import io.swagger.v3.oas.annotations.media.Schema;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

@Data
public class CreateOrderChartVo implements BaseVo, Serializable {

  private static final long serialVersionUID = 1L;

  /**
   * 单据总金额
   */
  @Schema(description = "单据总金额", requiredMode = Schema.RequiredMode.REQUIRED)
  @NotNull(message = "单据总金额不能为空！")
  private BigDecimal totalAmount;

  /**
   * 创建时间
   */
  @Schema(description = "创建时间")
  private LocalDateTime createTime;

  /**
   * 业务类型
   */
  @Schema(description = "业务类型", requiredMode = Schema.RequiredMode.REQUIRED)
  @NotNull(message = "业务类型不能为空！")
  @IsEnum(message = "业务类型不存在！", enumClass = OrderChartBizType.class)
  private Integer bizType;
}
