Commit e43dcf374a61fda72e22b37f0c30f5c2c0257000

Authored by YunaiV
1 parent c0b222e3

✨ feat(mes): 新增库存物资记录编号字段及相关逻辑

yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/productreceipt/vo/line/MesWmProductReceiptLineRespVO.java
@@ -19,6 +19,9 @@ public class MesWmProductReceiptLineRespVO { @@ -19,6 +19,9 @@ public class MesWmProductReceiptLineRespVO {
19 @Schema(description = "物料编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") 19 @Schema(description = "物料编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
20 private Long itemId; 20 private Long itemId;
21 21
  22 + @Schema(description = "库存物资记录编号", example = "1")
  23 + private Long materialStockId;
  24 +
22 @Schema(description = "物料编码", example = "P001") 25 @Schema(description = "物料编码", example = "P001")
23 private String itemCode; 26 private String itemCode;
24 27
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/productreceipt/vo/line/MesWmProductReceiptLineSaveReqVO.java
@@ -22,6 +22,9 @@ public class MesWmProductReceiptLineSaveReqVO { @@ -22,6 +22,9 @@ public class MesWmProductReceiptLineSaveReqVO {
22 @NotNull(message = "物料编号不能为空") 22 @NotNull(message = "物料编号不能为空")
23 private Long itemId; 23 private Long itemId;
24 24
  25 + @Schema(description = "库存物资记录编号", example = "1")
  26 + private Long materialStockId;
  27 +
25 @Schema(description = "收货数量", requiredMode = Schema.RequiredMode.REQUIRED, example = "100.00") 28 @Schema(description = "收货数量", requiredMode = Schema.RequiredMode.REQUIRED, example = "100.00")
26 @NotNull(message = "收货数量不能为空") 29 @NotNull(message = "收货数量不能为空")
27 @Positive(message = "收货数量必须大于 0") 30 @Positive(message = "收货数量必须大于 0")
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/dal/dataobject/wm/productreceipt/MesWmProductReceiptLineDO.java
@@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.mes.dal.dataobject.wm.productreceipt; @@ -2,6 +2,7 @@ package cn.iocoder.yudao.module.mes.dal.dataobject.wm.productreceipt;
2 2
3 import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; 3 import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO;
4 import cn.iocoder.yudao.module.mes.dal.dataobject.md.item.MesMdItemDO; 4 import cn.iocoder.yudao.module.mes.dal.dataobject.md.item.MesMdItemDO;
  5 +import cn.iocoder.yudao.module.mes.dal.dataobject.wm.batch.MesWmBatchDO;
5 import com.baomidou.mybatisplus.annotation.KeySequence; 6 import com.baomidou.mybatisplus.annotation.KeySequence;
6 import com.baomidou.mybatisplus.annotation.TableId; 7 import com.baomidou.mybatisplus.annotation.TableId;
7 import com.baomidou.mybatisplus.annotation.TableName; 8 import com.baomidou.mybatisplus.annotation.TableName;
@@ -40,17 +41,25 @@ public class MesWmProductReceiptLineDO extends BaseDO { @@ -40,17 +41,25 @@ public class MesWmProductReceiptLineDO extends BaseDO {
40 */ 41 */
41 private Long itemId; 42 private Long itemId;
42 /** 43 /**
  44 + * 库存物资记录编号
  45 + *
  46 + * 关联 {@link cn.iocoder.yudao.module.mes.dal.dataobject.wm.materialstock.MesWmMaterialStockDO#getId()}
  47 + */
  48 + private Long materialStockId;
  49 + /**
43 * 收货数量 50 * 收货数量
44 */ 51 */
45 private BigDecimal quantity; 52 private BigDecimal quantity;
46 /** 53 /**
47 * 批次编号 54 * 批次编号
48 * 55 *
49 - * TODO DONE @芋艿:保留。待 mes_wm_batch 模块迁移后补充 @link 关联 56 + * 关联 {@link MesWmBatchDO#getId()}
50 */ 57 */
51 private Long batchId; 58 private Long batchId;
52 /** 59 /**
53 * 批次号 60 * 批次号
  61 + *
  62 + * 关联 {@link MesWmBatchDO#getCode()}
54 */ 63 */
55 private String batchCode; 64 private String batchCode;
56 /** 65 /**