diff --git a/ktg-mes/src/main/java/com/ktg/mes/md/service/impl/WmsOutPlanServiceImpl.java b/ktg-mes/src/main/java/com/ktg/mes/md/service/impl/WmsOutPlanServiceImpl.java index b0f8344..b15a8d0 100644 --- a/ktg-mes/src/main/java/com/ktg/mes/md/service/impl/WmsOutPlanServiceImpl.java +++ b/ktg-mes/src/main/java/com/ktg/mes/md/service/impl/WmsOutPlanServiceImpl.java @@ -6,6 +6,7 @@ import com.ktg.common.utils.StringUtils; import com.ktg.mes.md.domain.*; import com.ktg.mes.md.mapper.*; import com.ktg.mes.md.service.IWmsOutPlanService; +import com.ktg.mes.stl.mapper.InventoryAdjustmentMapper; import com.ktg.mes.wm.domain.WmStorageArea; import com.ktg.mes.wm.mapper.WmStorageAreaMapper; import com.ktg.mes.wm.mapper.WmStorageLocationMapper; @@ -57,6 +58,9 @@ public class WmsOutPlanServiceImpl implements IWmsOutPlanService { @Autowired private WmStorageAreaMapper wmStorageAreaMapper; + @Autowired + private InventoryAdjustmentMapper inventoryAdjustmentMapper; + /** * 查询出库计划管理 * diff --git a/ktg-mes/src/main/java/com/ktg/mes/stl/mapper/InventoryAdjustmentMapper.java b/ktg-mes/src/main/java/com/ktg/mes/stl/mapper/InventoryAdjustmentMapper.java index 709f763..0b18a09 100644 --- a/ktg-mes/src/main/java/com/ktg/mes/stl/mapper/InventoryAdjustmentMapper.java +++ b/ktg-mes/src/main/java/com/ktg/mes/stl/mapper/InventoryAdjustmentMapper.java @@ -1,7 +1,18 @@ package com.ktg.mes.stl.mapper; +import com.ktg.common.annotation.DataSource; +import com.ktg.common.enums.DataSourceType; +import com.ktg.mes.md.domain.AP0AD; +import com.ktg.mes.stl.domain.InventoryAdjustment; import org.apache.ibatis.annotations.Mapper; +import java.util.List; + @Mapper -public class InventoryAdjustmentMapper { +public interface InventoryAdjustmentMapper { + @DataSource(DataSourceType.SQLSERVER) + List selectOutNewData(); + + @DataSource(DataSourceType.SQLSERVER) + int updateOutDataToOld(InventoryAdjustment inventoryAdjustment); } diff --git a/ktg-mes/src/main/resources/mapper/stl/InventoryAdjustmentMapper.xml b/ktg-mes/src/main/resources/mapper/stl/InventoryAdjustmentMapper.xml index 3ccb357..5e2e8fa 100644 --- a/ktg-mes/src/main/resources/mapper/stl/InventoryAdjustmentMapper.xml +++ b/ktg-mes/src/main/resources/mapper/stl/InventoryAdjustmentMapper.xml @@ -68,11 +68,31 @@ USER01, USER02, DATE01, - DATE02, - from AP0AA + DATE02 + from AP0AD + + + + + update AP0AD + set UDF02 = 'ED' + where AD001 = #{singetsu} + AND AD002 = #{oddNumber} + AND AD003 = #{billDate} + AND AD004 = #{serialNumber} + \ No newline at end of file