You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
5.0 KiB
5.0 KiB
WMS仓储模块
hwmom-wms核心关注base_measurement_unit_info、base_supplier_info1、base_material_category、base_material_type、base_material_info_copy1 / base_material_info、wms_base_customer、wms_base_area、wms_base_location、wms_base_warehouse、wms_allocate_order、wms_allocate_order_detail、wms_allocate_task、wms_check_task、wms_purchase_order、wms_purchase_order_detail、wms_instock_detail、wms_instock_order、wms_instock_print、wms_instock_record、wms_inventory、wms_inventory_check、wms_inventory_check_record、wms_outstock_detail、wms_outstock_order、wms_outstock_record!
核心数据表
基础数据表(除外)
base_measurement_unit_info- 计量单位base_supplier_info1- 供应商base_material_category- 物料分类base_material_type- 物料类型base_material_info_copy1/base_material_info- 物料信息(通过@TableName决定使用哪个)
WMS核心关注表
wms_base_customer- 客户wms_base_area- 仓库区域wms_base_location- 库位wms_base_warehouse- 仓库wms_allocate_order- 调拨单主表wms_allocate_order_detail- 调拨单明细wms_allocate_task- 调拨任务(AGV)wms_check_task- 盘点任务配置wms_purchase_order- 采购订单wms_purchase_order_detail- 采购订单明细wms_instock_detail- 入库单明细wms_instock_order- 入库单主表wms_instock_print- 入库打印配置wms_instock_record- 入库记录(PDA扫描)wms_inventory- 实时库存wms_inventory_check- 盘点单主表wms_outstock_detail- 出库单明细wms_outstock_order- 出库单主表wms_outstock_record- 出库记录(PDA扫描)
主子表关系详解
【仓库层级结构】
wms_base_warehouse (仓库)
↓
wms_base_area (仓库区域)
↓
wms_base_location (库位)
【采购入库流程】
wms_purchase_order (采购订单)
↓
wms_purchase_order_detail (采购明细)
↓
wms_instock_order (入库单)
↓
wms_instock_detail (入库明细) → 打印标签 → wms_instock_record (PDA扫描入库)
↓
更新 wms_inventory (库存+)
【调拨流程】
wms_allocate_order (调拨单)
↓
wms_allocate_order_detail (调拨明细)
├─→ wms_outstock_order (出库单) → wms_outstock_record → 库存-
├─→ wms_instock_order (入库单) → wms_instock_record → 库存+
└─→ wms_allocate_task (AGV搬运任务)
【销售出库流程】
销售订单(ERP) → wms_outstock_order (出库单)
↓
wms_outstock_detail (出库明细) → wms_outstock_record (扫描出库)
↓
更新 wms_inventory (库存-)
【盘点流程】
wms_check_task (定时任务) → wms_inventory_check (盘点单)
↓
wms_inventory_check_record (盘点记录) → 差异审核 → 更新 wms_inventory
主子表对
| 主表 | 子表 | 关联字段 | 说明 |
|---|---|---|---|
wms_purchase_order |
wms_purchase_order_detail |
po_no |
采购订单包含多个采购明细 |
wms_instock_order |
wms_instock_detail |
instock_id / instock_code |
入库单包含多个入库明细 |
wms_outstock_order |
wms_outstock_detail |
outstock_id / outstock_code |
出库单包含多个出库明细 |
wms_allocate_order |
wms_allocate_order_detail |
allocate_code |
调拨单包含多个调拨明细 |
wms_inventory_check |
wms_inventory_check_record |
check_code |
盘点单包含多个盘点记录 |
基础数据关联
| 表 | 关联表 | 关联字段 | 说明 |
|---|---|---|---|
wms_base_area |
wms_base_warehouse |
warehouse_id |
区域归属仓库 |
wms_base_location |
wms_base_area |
area_id |
库位归属区域 |
wms_instock_detail |
wms_purchase_order_detail |
po_d_id |
入库明细追溯采购明细 |
wms_allocate_task |
wms_allocate_order_detail |
ao_d_id |
调拨任务关联调拨明细 |
关键设计特点
- 仓库层级: 仓库 → 区域 → 库位,三级层级结构
- 单据驱动: 所有库存变动都通过单据(入库/出库/调拨/盘点)触发
- 主子分离: 主表记录总体信息(单号、仓库、供应商/客户),子表记录明细(物料、数量、批次)
- 实时库存:
wms_inventory表实时更新,所有入库/出库记录汇总 - AGV集成: 支持
instock_methond和is_agv字段控制AGV任务生成
核心业务字段说明
| 字段 | 说明 |
|---|---|
instock_type |
入库类型 (1采购订单, 2生产订单, 3手工, 4系统生成) |
outstock_type |
出库类型 (1销售出库, 2生产领料, 3调拨出库, 4其他) |
special_type |
特殊标识 (0调拨, 1退库) |
audit_status |
审核状态 (0待审核, 1审核通过, 2审核未通过) |
inspection_request |
质检要求 (0必检, 1免检) - 必检则需经QC流程后入库 |
instock_methond |
入库方式 (0PDA, 1AGV, 2质检后PDA, 3质检后AGV) |