获取是否越库,是否暂停出库按钮设置的状态

main
Comair 1 year ago
parent 4bc605c933
commit 0505d6ed35
  1. 23
      shkj-wms/src/main/java/com/shkj/wms/controller/business/BaseBarcodesController.java
  2. 36
      shkj-wms/src/main/java/com/shkj/wms/scheduled/ScheduledTasks.java
  3. 4
      shkj-wms/src/main/java/com/shkj/wms/service/IBaseBarcodesOutService.java
  4. 28
      shkj-wms/src/main/java/com/shkj/wms/service/impl/BaseBarcodesOutServiceImpl.java

@ -254,6 +254,18 @@ public class BaseBarcodesController extends BaseController {
return iBaseBarcodesOutService.handOskipOverWareStatus(status);
}
/**
* 获取是否停止出库
* start 启动出库
* stop 停止出库
* @return
*/
@GetMapping("/getStartStopOutboundStatus")
@RepeatSubmit
public Result<Boolean> getStartStopOutboundStatus(){
return iBaseBarcodesOutService.getStartStopOutboundStatus();
}
/**
* 手动控制是否越库
* start 启动越库
@ -267,6 +279,17 @@ public class BaseBarcodesController extends BaseController {
return iBaseBarcodesOutService.handOskipOverWareStatus(status);
}
/**
* 获取是否是否越库的状态
* start 启动越库
* stop 停止越库
* @return
*/
@GetMapping("/getOskipOverWareStatus")
@RepeatSubmit
public Result<Boolean> getOskipOverWareStatus(){
return iBaseBarcodesOutService.getOskipOverWareStatus();
}
}

@ -2124,7 +2124,7 @@ public class ScheduledTasks {
//立库输送线接驳点-入
String toLocation = "";
int agvTaskType = 0;
BusinTaskExeBo exeBo = new BusinTaskExeBo();
// BusinTaskExeBo exeBo = new BusinTaskExeBo();
Long plcId = null;
Long stkPlcId = null;
@ -2141,9 +2141,6 @@ public class ScheduledTasks {
//根据车型分配库位 先判断该任务是否已经分配了货位
Result<BaseLocationVo> locationVoResult = null;
if (ObjectUtils.isEmpty(businDataTaskVo.getToRow())) {
// locationVoResult = iBaseLocationService.assignEmptyLocation(vehicheModel, color,DateUtils.getDate(),businDataTaskGoodsVos);
// TODO: 2024/6/28 zjx
// locationVoResult = iBaseLocationService.assignEmptyLocationByStock(goodsNo, vehicheModel, DateUtils.getDate(), businDataTaskGoodsVos);
AssingEmptyLocBo emptyLocBo = new AssingEmptyLocBo();
emptyLocBo.setBatch(DateUtils.getDate());
@ -2186,13 +2183,6 @@ public class ScheduledTasks {
BaseDevicePlcVo baseDevicePlcVo = baseLocationPlcMapper.selectBaseDevicePlc(pointQueryBo);
stkPlcId = baseDevicePlcVo.getPlcId();
exeBo.setTaskCode(taskId);
exeBo.setBusinDataTaskGoodsVo(businDataTaskGoodsVos);
exeBo.setContainerId(containerId);
exeBo.setBaseLocationVo(locationVo);
exeBo.setTransNo("1");
exeBo.setTransQual("1");
//根据取货时的的点位拿到对应的交互点用作取货完成点
agvTaskType = Integer.valueOf(basePointDeviceVo.getIsDown());
if (businDataTaskVo.getTaskType().equals("7")) {
@ -2226,11 +2216,6 @@ public class ScheduledTasks {
BasePointDeviceVo pointDeviceout = basePointDeviceMapper.selectBasePointByGroupno(pointQueryBo);
toLocation = pointDeviceout.getPointNo();
agvTaskType = Integer.valueOf(pointDeviceout.getIsDown());
exeBo.setTaskCode(taskId);
exeBo.setBusinDataTaskGoodsVo(businDataTaskGoodsVos);
exeBo.setContainerId(containerId);
exeBo.setTransNo("1");
exeBo.setTransQual("1");
}
}
@ -2242,11 +2227,6 @@ public class ScheduledTasks {
BasePointDeviceVo pointDeviceout = basePointDeviceMapper.selectBasePointByGroupno(pointQueryBo);
toLocation = pointDeviceout.getPointNo();
agvTaskType = Integer.valueOf(pointDeviceout.getIsDown());
exeBo.setTaskCode(taskId);
exeBo.setBusinDataTaskGoodsVo(businDataTaskGoodsVos);
exeBo.setContainerId(containerId);
exeBo.setTransNo("1");
exeBo.setTransQual("1");
}
@ -2296,20 +2276,6 @@ public class ScheduledTasks {
if (booleanResult.getCode() == HttpStatus.SUCCESS.getCode()) {
businDataTaskVo.setTaskPath(toLocation);
businDataTaskVo.setTaskStatus(TaskStatusEnum.wait_callback.getValue());
//生成入库单
if (randome.equals("P01")) {
// Result<String> stringResult = iPutInOutStorageService.exeTaskPutinStorage(exeBo);
//生成入库单成功
// if (stringResult.getCode() == HttpStatus.SUCCESS.getCode()) {
// businDataTaskVo.setTransId(stringResult.getData());
// } else {
// businDataTaskVo.setTaskStatus(TaskStatusEnum.err.getValue());
// businDataTaskVo.setExceptionMsg("生成入库单失败");
// }
}
}
//立库输送线PLCID
businDataTaskVo.setDpsNoOne(plcId);

@ -125,5 +125,9 @@ public interface IBaseBarcodesOutService extends IService<BaseBarcodesOut> {
Result<Boolean> handOskipOverWareStatus(String status);
Result<Boolean> getStartStopOutboundStatus();
Result<Boolean> getOskipOverWareStatus();
Result<Boolean> handStartStopOutboundStatus(String status);
}

@ -397,6 +397,21 @@ public class BaseBarcodesOutServiceImpl extends ServiceImpl<BaseBarcodesOutMappe
}
}
/**
* 获取是否越库 start 启动越库 stop 不启动越库
* @return
*/
@Override
public Result<Boolean> getOskipOverWareStatus() {
Object o = redisTemplate.opsForValue().get(RedisConstant.redisSkipOverWare);
if(o== null){
return Result.ok().data("stop");
}
return Result.ok().data(o.toString());
}
/**
* 是否启动/或暂停出库
@ -415,6 +430,19 @@ public class BaseBarcodesOutServiceImpl extends ServiceImpl<BaseBarcodesOutMappe
}
}
/**
* 获取是否启动或暂停出库状态
* @return
*/
@Override
public Result<Boolean> getStartStopOutboundStatus() {
Object o = redisTemplate.opsForValue().get(RedisConstant.redisStartStopOutbound);
if(o== null){
return Result.ok().data("start");
}
return Result.ok().data(o.toString());
}
/**
* 手动下发出库任务-恢复 暂停 已取消是否是作废不可恢复 2出库中 给堆垛机下发命令成功更改状态

Loading…
Cancel
Save