diff --git a/shkj-wms/src/main/java/com/shkj/wms/controller/business/BaseBarcodesController.java b/shkj-wms/src/main/java/com/shkj/wms/controller/business/BaseBarcodesController.java index 2e90000..6a91663 100644 --- a/shkj-wms/src/main/java/com/shkj/wms/controller/business/BaseBarcodesController.java +++ b/shkj-wms/src/main/java/com/shkj/wms/controller/business/BaseBarcodesController.java @@ -242,5 +242,55 @@ public class BaseBarcodesController extends BaseController { } + /** + * 手动控制是否暂停出库 + * stop 停止出库 + * start 启动出库 + * @param status + * @return + */ + @PostMapping("/handStartStopOutboundStatus") + @RepeatSubmit + public Result handStartStopOutboundStatus(@RequestParam("status") String status){ + return iBaseBarcodesOutService.handStartStopOutboundStatus(status); + } + + /** + * 获取是否停止出库 + * start 启动出库 + * stop 停止出库 + * @return + */ + @GetMapping("/getStartStopOutboundStatus") + @RepeatSubmit + public Result getStartStopOutboundStatus(){ + return iBaseBarcodesOutService.getStartStopOutboundStatus(); + } + + /** + * 手动控制是否越库 + * start 启动越库 + * stop 停止越库 + * @param status + * @return + */ + @PostMapping("/handOskipOverWareStatus") + @RepeatSubmit + public Result handOskipOverWareStatus(@RequestParam("status") String status){ + return iBaseBarcodesOutService.handOskipOverWareStatus(status); + } + + /** + * 获取是否是否越库的状态 + * start 启动越库 + * stop 停止越库 + * @return + */ + @GetMapping("/getOskipOverWareStatus") + @RepeatSubmit + public Result getOskipOverWareStatus(){ + return iBaseBarcodesOutService.getOskipOverWareStatus(); + } + } diff --git a/shkj-wms/src/main/java/com/shkj/wms/service/IBaseBarcodesOutService.java b/shkj-wms/src/main/java/com/shkj/wms/service/IBaseBarcodesOutService.java index 6511ce5..2eb1342 100644 --- a/shkj-wms/src/main/java/com/shkj/wms/service/IBaseBarcodesOutService.java +++ b/shkj-wms/src/main/java/com/shkj/wms/service/IBaseBarcodesOutService.java @@ -119,4 +119,14 @@ public interface IBaseBarcodesOutService extends IService { * @return java.util.List> */ List> getOutEmptyInfo(); + + + + Result handOskipOverWareStatus(String status); + + Result getStartStopOutboundStatus(); + + Result getOskipOverWareStatus(); + + Result handStartStopOutboundStatus(String status); } diff --git a/shkj-wms/src/main/java/com/shkj/wms/service/impl/BaseBarcodesOutServiceImpl.java b/shkj-wms/src/main/java/com/shkj/wms/service/impl/BaseBarcodesOutServiceImpl.java index 2798c14..672ed55 100644 --- a/shkj-wms/src/main/java/com/shkj/wms/service/impl/BaseBarcodesOutServiceImpl.java +++ b/shkj-wms/src/main/java/com/shkj/wms/service/impl/BaseBarcodesOutServiceImpl.java @@ -381,6 +381,69 @@ public class BaseBarcodesOutServiceImpl extends ServiceImpl handOskipOverWareStatus(String status) { + try { + redisTemplate.opsForValue().set(RedisConstant.redisSkipOverWare,status); + return Result.ok().msg("设置越库成功"); + }catch (Exception e){ + return Result.err().msg("设置越库成功"); + } + } + + /** + * 获取是否越库 start 启动越库 stop 不启动越库 + * @return + */ + @Override + public Result getOskipOverWareStatus() { + Object o = redisTemplate.opsForValue().get(RedisConstant.redisSkipOverWare); + if(o== null){ + return Result.ok().data("stop"); + } + return Result.ok().data(o.toString()); + } + + + + + /** + * 是否启动/或暂停出库 + * stop 停止出库 + * start 启动出库 + * @param status + * @return + */ + @Override + public Result handStartStopOutboundStatus(String status) { + try { + redisTemplate.opsForValue().set(RedisConstant.redisStartStopOutbound,status); + return Result.ok().msg("设置启动/停止出库成功"); + }catch (Exception e){ + return Result.err().msg("设置启动/停止出库成功"); + } + } + + /** + * 获取是否启动或暂停出库状态 + * @return + */ + @Override + public Result getStartStopOutboundStatus() { + Object o = redisTemplate.opsForValue().get(RedisConstant.redisStartStopOutbound); + if(o== null){ + return Result.ok().data("start"); + } + return Result.ok().data(o.toString()); + } + /** * 手动下发出库任务-恢复 :暂停 ,已取消是否是作废,不可恢复 ; 2出库中 给堆垛机下发命令成功,更改状态 * @param bo