package cn.iocoder.yudao.module.trade.controller.admin.domestic.vo;
|
|
import io.swagger.v3.oas.annotations.media.Schema;
|
import jakarta.validation.constraints.NotEmpty;
|
import jakarta.validation.constraints.NotNull;
|
import lombok.AllArgsConstructor;
|
import lombok.Data;
|
import lombok.NoArgsConstructor;
|
import org.springframework.format.annotation.DateTimeFormat;
|
|
import java.math.BigDecimal;
|
import java.time.LocalDateTime;
|
import java.util.List;
|
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
|
@Schema(description = "管理后台 - 内贸订单创建/更新 Request VO")
|
@Data
|
public class TradeDomesticOrderSaveReqVO {
|
|
@Schema(description = "编号", example = "1024")
|
private Long id;
|
|
@Schema(description = "客户编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "18336")
|
@NotNull(message = "客户不能为空")
|
private Long customerId;
|
|
@Schema(description = "业务员用户编号", example = "17144")
|
private Long saleUserId;
|
|
@Schema(description = "订单日期")
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
private LocalDateTime orderTime;
|
|
@Schema(description = "交货地址", example = "新疆乌鲁木齐市...")
|
private String deliveryAddress;
|
|
@Schema(description = "备注", example = "备注信息")
|
private String remark;
|
|
@Schema(description = "附件 blobId 列表", example = "[1,2,3]")
|
private List<Long> blobIds;
|
|
@Schema(description = "明细列表", requiredMode = Schema.RequiredMode.REQUIRED)
|
@NotEmpty(message = "明细不能为空")
|
private List<Item> items;
|
|
@Schema(description = "内贸订单明细")
|
@Data
|
@NoArgsConstructor
|
@AllArgsConstructor
|
public static class Item {
|
|
@Schema(description = "编号", example = "888")
|
private Long id;
|
|
@Schema(description = "MDM 物料编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "20529")
|
@NotNull(message = "物料编号不能为空")
|
private Long itemId;
|
|
@Schema(description = "单价(元)", requiredMode = Schema.RequiredMode.REQUIRED, example = "123.00")
|
@NotNull(message = "单价不能为空")
|
private BigDecimal itemPrice;
|
|
@Schema(description = "数量", requiredMode = Schema.RequiredMode.REQUIRED, example = "10")
|
@NotNull(message = "数量不能为空")
|
private BigDecimal count;
|
|
@Schema(description = "税率(%)", example = "13.00")
|
private BigDecimal taxPercent;
|
|
@Schema(description = "上游原料车次批次(预留)", example = "PC20260916000001")
|
private String batchCode;
|
|
@Schema(description = "备注", example = "备注")
|
private String remark;
|
|
}
|
|
}
|