package com.ruoyi.warehouse.domain; import java.math.BigDecimal; import java.util.Date; import com.fasterxml.jackson.annotation.JsonFormat; import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.core.domain.BaseEntity; import jakarta.validation.constraints.DecimalMin; import jakarta.validation.constraints.NotBlank; import jakarta.validation.constraints.NotNull; public class PurchaseRequest extends BaseEntity { private static final long serialVersionUID = 1L; private Long id; private String requestNo; private Long productId; private Long purchaseBatchId; @Excel(name = "关联物料编码", prompt = "已有物料建议填写准确编码;留空时按名称、品牌、类别、参数规格匹配") private String productCode; @Excel(name = "物料名称", prompt = "必填;无匹配物料时将自动新增产品信息") private String materialName; @Excel(name = "品牌") private String materialBrand; @Excel(name = "类别") private String category; @Excel(name = "参数规格") private String materialParams; @Excel(name = "采购链接") private String purchaseLink; @Excel(name = "需求数量") private BigDecimal quantity; @Excel(name = "单位") private String unit; @JsonFormat(pattern = "yyyy-MM-dd") @Excel(name = "期望到货日期", width = 20, dateFormat = "yyyy-MM-dd") private Date expectedDate; private Long applicantId; @Excel(name = "申请人", type = Excel.Type.EXPORT) private String applicantName; @Excel(name = "采购状态", readConverterExp = "0=待采购,1=已下单,2=采购中,3=部分到货,4=已到齐,5=已取消", type = Excel.Type.EXPORT) private Integer purchaseStatus; @Excel(name = "采购批次", type = Excel.Type.EXPORT) private String purchaseBatchNo; @Excel(name = "进度说明", type = Excel.Type.EXPORT) private String progressRemark; @Excel(name = "产品备注") private String productRemark; @Excel(name = "申请备注") private String requestRemark; private String productName; private String productBrand; private String productCategory; private String productSpec; @Excel(name = "已验收数量", type = Excel.Type.EXPORT) private BigDecimal acceptedQuantity; @Excel(name = "待验收数量", type = Excel.Type.EXPORT) private BigDecimal pendingArrivalQuantity; private BigDecimal remainingQuantity; public Long getId() { return id; } public void setId(Long id) { this.id = id; } public String getRequestNo() { return requestNo; } public void setRequestNo(String requestNo) { this.requestNo = requestNo; } public Long getProductId() { return productId; } public void setProductId(Long productId) { this.productId = productId; } public Long getPurchaseBatchId() { return purchaseBatchId; } public void setPurchaseBatchId(Long purchaseBatchId) { this.purchaseBatchId = purchaseBatchId; } public String getProductCode() { return productCode; } public void setProductCode(String productCode) { this.productCode = productCode; } @NotBlank(message = "物料名称不能为空") public String getMaterialName() { return materialName; } public void setMaterialName(String materialName) { this.materialName = materialName; } public String getMaterialBrand() { return materialBrand; } public void setMaterialBrand(String materialBrand) { this.materialBrand = materialBrand; } public String getCategory() { return category; } public void setCategory(String category) { this.category = category; } public String getMaterialParams() { return materialParams; } public void setMaterialParams(String materialParams) { this.materialParams = materialParams; } public String getPurchaseLink() { return purchaseLink; } public void setPurchaseLink(String purchaseLink) { this.purchaseLink = purchaseLink; } @NotNull(message = "需求数量不能为空") @DecimalMin(value = "0.001", message = "需求数量必须大于0") public BigDecimal getQuantity() { return quantity; } public void setQuantity(BigDecimal quantity) { this.quantity = quantity; } public String getUnit() { return unit; } public void setUnit(String unit) { this.unit = unit; } public Date getExpectedDate() { return expectedDate; } public void setExpectedDate(Date expectedDate) { this.expectedDate = expectedDate; } public Long getApplicantId() { return applicantId; } public void setApplicantId(Long applicantId) { this.applicantId = applicantId; } public String getApplicantName() { return applicantName; } public void setApplicantName(String applicantName) { this.applicantName = applicantName; } public Integer getPurchaseStatus() { return purchaseStatus; } public void setPurchaseStatus(Integer purchaseStatus) { this.purchaseStatus = purchaseStatus; } public String getPurchaseBatchNo() { return purchaseBatchNo; } public void setPurchaseBatchNo(String purchaseBatchNo) { this.purchaseBatchNo = purchaseBatchNo; } public String getProgressRemark() { return progressRemark; } public void setProgressRemark(String progressRemark) { this.progressRemark = progressRemark; } public String getProductRemark() { return productRemark; } public void setProductRemark(String productRemark) { this.productRemark = productRemark; } public String getRequestRemark() { return requestRemark; } public void setRequestRemark(String requestRemark) { this.requestRemark = requestRemark; } public String getProductName() { return productName; } public void setProductName(String productName) { this.productName = productName; } public String getProductBrand() { return productBrand; } public void setProductBrand(String productBrand) { this.productBrand = productBrand; } public String getProductCategory() { return productCategory; } public void setProductCategory(String productCategory) { this.productCategory = productCategory; } public String getProductSpec() { return productSpec; } public void setProductSpec(String productSpec) { this.productSpec = productSpec; } public BigDecimal getAcceptedQuantity() { return acceptedQuantity; } public void setAcceptedQuantity(BigDecimal acceptedQuantity) { this.acceptedQuantity = acceptedQuantity; } public BigDecimal getPendingArrivalQuantity() { return pendingArrivalQuantity; } public void setPendingArrivalQuantity(BigDecimal pendingArrivalQuantity) { this.pendingArrivalQuantity = pendingArrivalQuantity; } public BigDecimal getRemainingQuantity() { return remainingQuantity; } public void setRemainingQuantity(BigDecimal remainingQuantity) { this.remainingQuantity = remainingQuantity; } }