自动化立体仓库 - WCS系统
*
lsh
2025-04-03 18f1c7abcea6f2eca1967141e7b5e408893c31a9
src/main/java/com/zy/asrs/service/impl/OpenServiceImpl.java
@@ -8,10 +8,7 @@
import com.core.exception.CoolException;
import com.zy.asrs.domain.enums.TaskStatusType;
import com.zy.asrs.domain.enums.WorkNoType;
import com.zy.asrs.entity.LocMast;
import com.zy.asrs.entity.StaDesc;
import com.zy.asrs.entity.TaskWrk;
import com.zy.asrs.entity.ToWmsDTO;
import com.zy.asrs.entity.*;
import com.zy.asrs.entity.param.TaskOverParam;
import com.zy.asrs.entity.param.WMSAndAGVInterfaceParam;
import com.zy.asrs.entity.param.TaskCreateParam;
@@ -50,6 +47,8 @@
    private CommonService commonService;
    @Autowired
    private LocMastService locMastService;
    @Autowired
    private BasDevpService basDevpService;
@@ -80,6 +79,17 @@
        taskWrk.setWrkNo(workNo1);
        taskWrk.setStatus(TaskStatusType.RECEIVE.id);//任务状态:接收
        taskWrk.setCreateTime(now);
        taskWrk.setModiTime(now);
        taskWrk.setAssignTime(new Date());
        taskWrk.setModiUser(6666L);
        try{
            if (param.getIoType()>1){
                if (Utils.locNoRowBoolean(locMast.getRow1())){
                    param.setTaskPriority(11);
                }
            }
        }catch (Exception e){
        }
        taskWrk.setIoType(param.getIoType());//任务类型
        taskWrk.setIoPri(param.getTaskPriority());//优先级
        taskWrk.setBarcode(param.getBarcode());//条码
@@ -102,7 +112,7 @@
            taskWrk.setWrkSts(11);
            if (!Cools.isEmpty(param.getStartPoint())) {
                taskWrk.setStartPoint(param.getStartPoint());//起点
                taskWrk.setOriginStartPoint(param.getStartPoint());
                taskWrk.setTargetPoint(param.getTargetPoint());
            }
        }
@@ -255,6 +265,40 @@
    }
//    @Override
//    public R getAgvPickAndPlaceV1(TaskOverParam param) {
//        BasDevp basDevp = basDevpService.selectById(param.getStaNo());
//        if (Cools.isEmpty(basDevp)){
//            return R.error("站点号有误"+param.getStaNo());
//        }
//        if (param.getType()==0 && basDevp.getAgvStartPick()==1){
//            return R.ok();
//        }else if (param.getType()==1 && basDevp.getAgvStartPlace()==1){
//            return R.ok();
//        }else {
//            return R.error("不允许");
//        }
//    }
//    @Override
//    public R getAgvPickAndPlaceV2(TaskOverParam param) {
//        BasDevp basDevp = basDevpService.selectById(param.getStaNo());
//        if (Cools.isEmpty(basDevp)){
//            return R.error("站点号有误"+param.getStaNo());
//        }
//        if (param.getType()==0){
//            basDevp.setAgvTargetPick(1);
//            basDevpService.updateById(basDevp);
//            return R.ok();
//        }else if (param.getType()==1){
//            basDevp.setAgvTargetPlace(1);
//            basDevpService.updateById(basDevp);
//            return R.ok();
//        }else {
//            return R.error("请求类型异常"+param.getType());
//        }
//    }
    public List<Integer> getInEnableRoadway(){
        int[] roadway = null;
        List<Integer> list = new ArrayList<>();