Commit 058be7d7 zshaohui

1.获取同一个库位 bug修改

1 个父辈 4986cb79
......@@ -230,7 +230,7 @@ public class RobotBoxHandler extends BaseDeviceHandler {
@PostMapping(value = "/service/store/robotBox/emptyPosForPutin")
@ResponseBody
@AnonymousAccess
public Map<String, Object> emptyPosForPutin(HttpServletRequest request) {
public synchronized Map<String, Object> emptyPosForPutin(HttpServletRequest request) {
String code = request.getParameter("code");
String cids = request.getParameter("cids");
......@@ -262,7 +262,7 @@ public class RobotBoxHandler extends BaseDeviceHandler {
List<String> cidList=new ArrayList<>();
//if (Strings.isNullOrEmpty(cids)) {
//自动获取在线的料仓列表
cidList=dataCache.getAvailableStorageIds(this.getDeviceType());
cidList=dataCache.getAvailableStorageCids(this.getDeviceType());
//} else {
//cidList = Lists.newArrayList(cids.split(","));
//}
......
......@@ -660,7 +660,7 @@ public class DataCache {
}
return availableStorageIds;
}
public List<String> getAvailableStorageIds(DeviceType deviceType){
public List<String> getAvailableStorageCids(DeviceType deviceType){
List<String> availableStorageIds = new ArrayList<>();
for (Storage storage : getAllStorage().values()) {
......@@ -670,7 +670,7 @@ public class DataCache {
continue;
}
//if (bean.getStatus() == 1) {
availableStorageIds.add(storage.getId());
availableStorageIds.add(storage.getCid());
//}
}
}
......
......@@ -502,7 +502,7 @@ public class TaskService {
*/
public Collection<String> excludePosIds() {
//排除掉正在执行的仓位
Collection<DataLog> allTasks = taskMap.values();
Collection<DataLog> allTasks = getAllTasks();
Collection<String> operatingPosIds = ReelLockPosUtil.getAllLockPosIds();
for (DataLog task : allTasks) {
String posId = task.getPosId();
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!