diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/FifthWmsBorderController.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/FifthWmsBorderController.java new file mode 100644 index 0000000..13606d5 --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/FifthWmsBorderController.java @@ -0,0 +1,34 @@ +package com.hw.wms.board.controller; + + +import com.hw.common.core.web.domain.AjaxResult; +import com.hw.wms.board.service.FifthWmsBorderService; +import com.hw.wms.board.service.SecondWmsBorderService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +@RestController +@RequestMapping("/FifthWmsBorder") +public class FifthWmsBorderController { + @Autowired + private FifthWmsBorderService fifthWmsBorderService; + + /** + * 五楼库存数量 + */ + @GetMapping("/locationCount") + public AjaxResult locationCount(){ + return AjaxResult.success(fifthWmsBorderService.locationCount()); + } + /** + * 库存饼状图 + */ + @GetMapping("fifthPanake") + public AjaxResult fifthPanake(){ + return AjaxResult.success(fifthWmsBorderService.fifthPanake()); + } + + +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/SecondWmsBorderController.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/SecondWmsBorderController.java new file mode 100644 index 0000000..f3df0b6 --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/SecondWmsBorderController.java @@ -0,0 +1,64 @@ +package com.hw.wms.board.controller; + + +import com.hw.common.core.web.domain.AjaxResult; +import com.hw.wms.board.service.SecondWmsBorderService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +@RestController +@RequestMapping("/SecondWmsBorder") +public class SecondWmsBorderController { + @Autowired + private SecondWmsBorderService secondWmsBorderService; + + /** + * 库存总量统计 + * @return + */ + @GetMapping("/totalStock") + public AjaxResult totalStock(){ + return AjaxResult.success(secondWmsBorderService.totalStock()); + } + /** + * 库位原理统计 + */ + @GetMapping("/locationCount") + public AjaxResult locationCount(){ + return AjaxResult.success(secondWmsBorderService.locationCount()); + } + /** + * 任务编号 + */ + @GetMapping("/tableInfo") + public AjaxResult tableInfo(){ + return AjaxResult.success(secondWmsBorderService.tableInfo()); + } + /** + * 库存变化折线图 + */ + @GetMapping("/inAndOutStockInfo") + public AjaxResult inAndOutStockInfo(){ + return AjaxResult.success(secondWmsBorderService.inAndOutStockInfo()); + } + + /** + * 入库时段统计 + * @return + */ + @GetMapping("/instockTimeCount") + public AjaxResult instockTimeCount(){ + return AjaxResult.success(secondWmsBorderService.instockTimeCount()); + } + + /** + * 当日入库量 + * @return + */ + @GetMapping("/todayInstockAmount") + public AjaxResult todayInstockAmount(){ + return AjaxResult.success(secondWmsBorderService.todayInstockAmount()); + } +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/ThirdWmsBorderController.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/ThirdWmsBorderController.java new file mode 100644 index 0000000..d1ad3de --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/controller/ThirdWmsBorderController.java @@ -0,0 +1,41 @@ +package com.hw.wms.board.controller; + + +import com.hw.common.core.web.domain.AjaxResult; +import com.hw.wms.board.service.SecondWmsBorderService; +import com.hw.wms.board.service.ThirdWmsBorderService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +@RestController +@RequestMapping("/ThirdWmsBorder") +public class ThirdWmsBorderController { + + @Autowired + private ThirdWmsBorderService thirdWmsBorderService; + + /** + * 单月原材料出入库统计 + */ + @GetMapping("/monthRawAmount") + public AjaxResult monthRawAmount(){ + return AjaxResult.success(thirdWmsBorderService.monthRawAmount()); + } + /** + * 三楼仓库库位状态 + */ + @GetMapping("/locationStatus") + public AjaxResult locationStatus(){ + return AjaxResult.success(thirdWmsBorderService.locationStatus()); + } + /** + * 生产计划 + */ + @GetMapping("/productPlan") + public AjaxResult productPlan(){ + return AjaxResult.success(thirdWmsBorderService.productPlan()); + } + +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/domain/RecordIotenvInstant.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/domain/RecordIotenvInstant.java new file mode 100644 index 0000000..6e12d2d --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/domain/RecordIotenvInstant.java @@ -0,0 +1,24 @@ +package com.hw.wms.board.domain; + +import lombok.Data; + +import java.math.BigDecimal; +import java.util.Date; + +@Data +public class RecordIotenvInstant { + private Long objId; + private String monitorId; + private BigDecimal tempreture; + private BigDecimal humidity; + private BigDecimal illuminance; + private BigDecimal noise; + private BigDecimal concentration; + private BigDecimal pm1; + private BigDecimal pm2; + private BigDecimal pm10; + private BigDecimal standBy; + private Date collectTime; + private Date recodeTime; + +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/FifthWmsBorderService.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/FifthWmsBorderService.java new file mode 100644 index 0000000..9320815 --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/FifthWmsBorderService.java @@ -0,0 +1,18 @@ +package com.hw.wms.board.service; + + +import com.hw.wms.domain.WmsProductInstock; +import com.hw.wms.domain.WmsProductOutstockDetail; +import com.hw.wms.domain.WmsProductStock; + +import java.math.BigDecimal; +import java.util.List; +import java.util.Map; + +public interface FifthWmsBorderService { + + + Map locationCount(); + + Map fifthPanake(); +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/SecondWmsBorderService.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/SecondWmsBorderService.java new file mode 100644 index 0000000..36f8e47 --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/SecondWmsBorderService.java @@ -0,0 +1,26 @@ +package com.hw.wms.board.service; + + +import com.hw.wms.domain.WmsProductInstock; +import com.hw.wms.domain.WmsProductOutstock; +import com.hw.wms.domain.WmsProductOutstockDetail; +import com.hw.wms.domain.WmsProductStock; + +import java.math.BigDecimal; +import java.util.List; +import java.util.Map; + +public interface SecondWmsBorderService { + + List totalStock(); + + Map locationCount(); + + List tableInfo(); + + List inAndOutStockInfo(); + + Map instockTimeCount(); + + BigDecimal todayInstockAmount(); +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/ThirdWmsBorderService.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/ThirdWmsBorderService.java new file mode 100644 index 0000000..712e5d5 --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/ThirdWmsBorderService.java @@ -0,0 +1,15 @@ +package com.hw.wms.board.service; + +import com.hw.wms.domain.WmsBaseLocation; +import com.hw.wms.domain.WmsRawOutstock; + +import java.util.List; +import java.util.Map; + +public interface ThirdWmsBorderService { + Map monthRawAmount(); + + List locationStatus(); + + List productPlan(); +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/FifthWmsBoardServiceImpl.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/FifthWmsBoardServiceImpl.java new file mode 100644 index 0000000..cec2f26 --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/FifthWmsBoardServiceImpl.java @@ -0,0 +1,71 @@ +package com.hw.wms.board.service.impl; + +import com.hw.wms.board.service.FifthWmsBorderService; +import com.hw.wms.board.service.SecondWmsBorderService; +import com.hw.wms.domain.*; +import com.hw.wms.mapper.*; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.math.BigDecimal; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +@Service +public class FifthWmsBoardServiceImpl implements FifthWmsBorderService { + @Autowired + private WmsProductStockMapper wmsProductStockMapper; + @Autowired + private WmsRawInstockMapper wmsRawInstockMapper; + @Autowired + private WmsRawOutstockMapper wmsRawOutstockMapper; + @Autowired + private WmsProductInstockMapper wmsProductInstockMapper; + @Autowired + private WmsProductOutstockMapper wmsProductOutstockMapper; + @Autowired + private WmsRawStockMapper wmsRawStockMapper; + @Autowired + private WmsBaseLocationMapper wmsBaseLocationMapper; + + + @Override + public Map locationCount() { + HashMap map = new HashMap<>(); + List list = wmsRawInstockMapper.locationCount(); + List list1 = wmsRawOutstockMapper.locationCount(); + List list2 = wmsProductInstockMapper.locationCount(); + List list3 = wmsProductOutstockMapper.locationCount(); + for (WmsProductInstock wmsProductInstock : list) { + if (wmsProductInstock.getWarehouseId()==511){ + map.put("rawInStock",wmsProductInstock.getInstockAmount()); + } + if (wmsProductInstock.getWarehouseId()==512){ + map.put("furawInStock",wmsProductInstock.getInstockAmount()); + } + } + map.put("rawOutStock",list1.get(0).getOutstockAmount()); + map.put("productInStock",list2.get(0).getInstockAmount()); + map.put("productOutStock",list3.get(0).getOutstockQty()); + return map; + } + + @Override + public Map fifthPanake() { + List wmsRawStocks = wmsRawStockMapper.selectRawLocationPercentage(); + List productStocks = wmsProductStockMapper.selectProductStockPercentage(); + Integer emptyLocationCount = wmsBaseLocationMapper.selectEmptyLocation(); + Integer allLocation = wmsBaseLocationMapper.selectAllLocation(); + BigDecimal emptyLocationPercentage = new BigDecimal(emptyLocationCount).divide(new BigDecimal(allLocation), 2, BigDecimal.ROUND_HALF_UP); + Integer oppylLocation = allLocation - emptyLocationCount; + BigDecimal opplyLocationPercentage = new BigDecimal(oppylLocation).divide(new BigDecimal(allLocation), 2, BigDecimal.ROUND_HALF_UP); + HashMap map = new HashMap<>(); + map.put("wmsRawStocks",wmsRawStocks); + map.put("productStocks",productStocks); + map.put("emptyLocationPercentage",emptyLocationPercentage); + map.put("opplyLocationPercentage",opplyLocationPercentage); + return map; + } +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/SecondWmsBoardServiceImpl.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/SecondWmsBoardServiceImpl.java new file mode 100644 index 0000000..d801a8e --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/SecondWmsBoardServiceImpl.java @@ -0,0 +1,79 @@ +package com.hw.wms.board.service.impl; + +import com.hw.wms.board.service.SecondWmsBorderService; +import com.hw.wms.domain.WmsProductInstock; +import com.hw.wms.domain.WmsProductOutstock; +import com.hw.wms.domain.WmsProductOutstockDetail; +import com.hw.wms.domain.WmsProductStock; +import com.hw.wms.mapper.WmsProductStockMapper; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.math.BigDecimal; +import java.util.Date; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.stream.Collectors; + +@Service +public class SecondWmsBoardServiceImpl implements SecondWmsBorderService { + @Autowired + private WmsProductStockMapper wmsProductStockMapper; + + @Override + public List totalStock() { + return wmsProductStockMapper.totalStock(); + } + + @Override + public BigDecimal todayInstockAmount() { + BigDecimal result = wmsProductStockMapper.todayInstockAmount(); + return result; + } + + @Override + public Map instockTimeCount() { + HashMap result = new HashMap<>(); + int oneWeekCount = wmsProductStockMapper.selectOneWeek(); + int twoWeekCount = wmsProductStockMapper.selectTwoWeek(); + int oneMonthCount = wmsProductStockMapper.selectOneMonth(); + int halfYearCount = wmsProductStockMapper.selectHalfYear(); + result.put("oneWeekCount",oneWeekCount); + result.put("twoWeekCount",twoWeekCount); + result.put("oneMonthCount",oneMonthCount); + result.put("halfYearCount",halfYearCount); + return result; + } + + @Override + public List inAndOutStockInfo() { + List instocks = wmsProductStockMapper.selectInStock(); + List outstocks = wmsProductStockMapper.selectOutStock(); + Map> map = outstocks.stream().collect(Collectors.groupingBy(WmsProductOutstock::getProductId)); + for (WmsProductInstock instock : instocks) { + WmsProductOutstock wmsProductOutstock = map.get(instock.getProductId()).get(0); + instock.setOutStockAmount(wmsProductOutstock.getOutstockQty()); + } + return instocks; + } + + @Override + public List tableInfo() { + return wmsProductStockMapper.tableInfo(); + } + + @Override + public Map locationCount() { + int availibleLocation = wmsProductStockMapper.selectAvailibleLocation(); + int toatlLocation = wmsProductStockMapper.selectTotalLocation(); + int opplyLocation = wmsProductStockMapper.selectOpplyLocation(); + HashMap result = new HashMap<>(); + BigDecimal bigDecimal = new BigDecimal(toatlLocation); + BigDecimal availibleRate = new BigDecimal(availibleLocation).divide(bigDecimal, 2, BigDecimal.ROUND_HALF_UP); + BigDecimal opplyRate = new BigDecimal(opplyLocation).divide(bigDecimal, 2, BigDecimal.ROUND_HALF_UP); + result.put("availibleRate",availibleRate); + result.put("opplyRate",opplyRate); + return result; + } +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/ThirdWmsBorderServiceImpl.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/ThirdWmsBorderServiceImpl.java new file mode 100644 index 0000000..70f1762 --- /dev/null +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/board/service/impl/ThirdWmsBorderServiceImpl.java @@ -0,0 +1,46 @@ +package com.hw.wms.board.service.impl; + +import com.hw.wms.board.service.ThirdWmsBorderService; +import com.hw.wms.domain.WmsBaseLocation; +import com.hw.wms.domain.WmsRawOutstock; +import com.hw.wms.mapper.WmsBaseLocationMapper; +import com.hw.wms.mapper.WmsRawInstockMapper; +import com.hw.wms.mapper.WmsRawOutstockMapper; +import org.springframework.beans.factory.annotation.Autowired; + +import java.math.BigDecimal; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +public class ThirdWmsBorderServiceImpl implements ThirdWmsBorderService { + @Autowired + private WmsRawInstockMapper wmsRawInstockMapper; + @Autowired + private WmsRawOutstockMapper wmsRawOutstockMapper; + @Autowired + private WmsBaseLocationMapper wmsBaseLocationMapper; + + @Override + public Map monthRawAmount() { + BigDecimal monthRawInAmount = wmsRawInstockMapper.monthRawInAmount(); + BigDecimal monthRawOutAmount = wmsRawOutstockMapper.monthRawOutAmount(); + HashMap hashMap = new HashMap(); + hashMap.put("monthRawInAmount",monthRawInAmount); + hashMap.put("monthRawOutAmount",monthRawOutAmount); + return hashMap; + } + + @Override + public List productPlan() { + return wmsRawOutstockMapper.productPlan(); + + } + + @Override + public List locationStatus() { + List list = wmsBaseLocationMapper.locationStatus(); + return list; + } + +} diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/domain/WmsProductInstock.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/domain/WmsProductInstock.java index e713c56..ab3c54f 100644 --- a/hw-modules/hw-wms/src/main/java/com/hw/wms/domain/WmsProductInstock.java +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/domain/WmsProductInstock.java @@ -172,6 +172,8 @@ public class WmsProductInstock extends BaseEntity { @Excel(name = "同步给ERP的数量") private BigDecimal erpAmount; + private BigDecimal outStockAmount; + /** * 成品入库记录明细信息 */ @@ -189,7 +191,13 @@ public class WmsProductInstock extends BaseEntity { private String materialSpec; + public BigDecimal getOutStockAmount() { + return outStockAmount; + } + public void setOutStockAmount(BigDecimal outStockAmount) { + this.outStockAmount = outStockAmount; + } public BigDecimal getPrice() { return price; } diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsBaseLocationMapper.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsBaseLocationMapper.java index cdf2ef8..15feba8 100644 --- a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsBaseLocationMapper.java +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsBaseLocationMapper.java @@ -92,4 +92,9 @@ public interface WmsBaseLocationMapper */ public int selectCountOfWmsBaseLocation(WmsBaseLocation wmsBaseLocation); + int selectEmptyLocation(); + + int selectAllLocation(); + + List locationStatus(); } diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductInstockMapper.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductInstockMapper.java index dfd1392..e898821 100644 --- a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductInstockMapper.java +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductInstockMapper.java @@ -99,4 +99,5 @@ public interface WmsProductInstockMapper */ List selectWmsProductInstockJoinList(WmsProductInstock wmsProductInstock); + List locationCount(); } diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductOutstockMapper.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductOutstockMapper.java index 7a8ecaa..af4356d 100644 --- a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductOutstockMapper.java +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductOutstockMapper.java @@ -141,4 +141,6 @@ public interface WmsProductOutstockMapper * @return */ WmsProductOutstock selectGetProductOutstockAuditByProductOutstockId(Long productOutstockId); + + List locationCount(); } diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductStockMapper.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductStockMapper.java index 8fad0d3..64e8d50 100644 --- a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductStockMapper.java +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsProductStockMapper.java @@ -2,8 +2,8 @@ package com.hw.wms.mapper; import java.math.BigDecimal; import java.util.List; -import com.hw.wms.domain.WmsProductStock; -import com.hw.wms.domain.WmsRawStock; + +import com.hw.wms.domain.*; import org.apache.ibatis.annotations.Param; /** @@ -132,4 +132,29 @@ public interface WmsProductStockMapper public List selectWmsProductStocks4Transfer(WmsProductStock wmsProductStock); + List selectProductStockPercentage(); + + List totalStock(); + + BigDecimal todayInstockAmount(); + + int selectOneWeek(); + + int selectTwoWeek(); + + int selectOneMonth(); + + int selectHalfYear(); + + List selectInStock(); + + List selectOutStock(); + + List tableInfo(); + + int selectAvailibleLocation(); + + int selectTotalLocation(); + + int selectOpplyLocation(); } diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawInstockMapper.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawInstockMapper.java index d7e1f54..63e0d08 100644 --- a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawInstockMapper.java +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawInstockMapper.java @@ -1,6 +1,9 @@ package com.hw.wms.mapper; +import java.math.BigDecimal; import java.util.List; + +import com.hw.wms.domain.WmsProductInstock; import com.hw.wms.domain.WmsRawInstock; /** @@ -84,4 +87,9 @@ public interface WmsRawInstockMapper * @return */ public List selectWmsRawInstockERPNotSynchronized(WmsRawInstock wmsRawInstock); + + List locationCount(); + + + BigDecimal monthRawInAmount(); } diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawOutstockMapper.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawOutstockMapper.java index 57c3386..4c171af 100644 --- a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawOutstockMapper.java +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawOutstockMapper.java @@ -1,5 +1,6 @@ package com.hw.wms.mapper; +import java.math.BigDecimal; import java.util.List; import com.hw.wms.domain.WmsRawOutstock; import com.hw.wms.domain.WmsRawOutstockDetail; @@ -153,4 +154,10 @@ public interface WmsRawOutstockMapper * @return */ List selectWmsRawOutstockERPNotSynchronized(WmsRawOutstock rawOutstock); + + List locationCount(); + + BigDecimal monthRawOutAmount(); + + List productPlan(); } diff --git a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawStockMapper.java b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawStockMapper.java index 585c634..77cff8b 100644 --- a/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawStockMapper.java +++ b/hw-modules/hw-wms/src/main/java/com/hw/wms/mapper/WmsRawStockMapper.java @@ -127,4 +127,5 @@ public interface WmsRawStockMapper { */ public List selectAutoOutstockRawStockList(@Param("materialId") Long materialId, @Param("poNo") String poNo); + List selectRawLocationPercentage(); } diff --git a/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsBaseLocationMapper.xml b/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsBaseLocationMapper.xml index b5d1f1f..492469a 100644 --- a/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsBaseLocationMapper.xml +++ b/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsBaseLocationMapper.xml @@ -299,6 +299,25 @@ order by location_code + + + diff --git a/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductInstockMapper.xml b/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductInstockMapper.xml index 6022709..03367eb 100644 --- a/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductInstockMapper.xml +++ b/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductInstockMapper.xml @@ -296,4 +296,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" order by wpi.apply_date desc + diff --git a/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductOutstockMapper.xml b/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductOutstockMapper.xml index 7a82777..565238e 100644 --- a/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductOutstockMapper.xml +++ b/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductOutstockMapper.xml @@ -398,6 +398,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" left join mes_base_material_info mbmi on wro.product_id = mbmi.material_id where wro.product_outstock_id = #{productOutstockId} + update wms_product_outstock diff --git a/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductStockMapper.xml b/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductStockMapper.xml index bfa9bd0..0b54963 100644 --- a/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductStockMapper.xml +++ b/hw-modules/hw-wms/src/main/resources/mapper/wms/WmsProductStockMapper.xml @@ -340,6 +340,68 @@ order by wbl.loc_column asc, wbl.loc_deep desc limit #{params.limit} + + + + + + + + + + + + +