自动化立体仓库 - WMS系统
#
1
2 天以前 c90f42702b056664dbb3502a14041ba902273665
src/main/java/com/zy/asrs/controller/MobileController.java
@@ -137,65 +137,88 @@
    @ManagerAuth
    public R orderSearchByBarcode(@RequestParam String orderNo){
        if (Cools.isEmpty(orderNo)){
            orderNo=null;
            orderNo = null;
        }
//        List<Order> orders = orderService.selectorderNoL(orderNo);
        List<Order> orders = OrderInAndOutUtil.selectOrderNoL(null, orderNo);
        if (Cools.isEmpty(orders)){
            return R.ok();
            return R.ok().add(new LinkedList<>());
        }
        LinkedList<CombParam> combParams = new LinkedList<>();
        if (!Cools.isEmpty(orders)){
            for (Order order:orders){
                CombParam combParam=new CombParam();
                if (order == null) {
                    continue;
                }
                DocType docType = docTypeService.selectById(order.getDocType());
                if (docType.getPakin() == null || docType.getPakin() != 1) {
                    continue;
                }
                if (order.getSettle() > 2) {
                    continue;
                }
//                List<OrderDetl> orderDetls = orderService.selectWorkingDetls(order.getId());
                List<OrderDetl> orderDetls = OrderInAndOutUtil.selectWorkingDetls(order.getPakinPakoutStatus$(), order.getId());
                if (!Cools.isEmpty(orderDetls)) {
                    LinkedList<CombParam.CombMat> combMats = new LinkedList<>();
                    for (OrderDetl orderDetl:orderDetls){
                        CombParam.CombMat combMat = new CombParam.CombMat();
                        combMat.setMatnr(orderDetl.getMatnr());
                        combMat.setBatch(orderDetl.getBatch());
                        combMat.setAnfme(orderDetl.getAnfme()-orderDetl.getWorkQty());
                        combMat.setMaktx(orderDetl.getMaktx());
                        combMat.setSpecs(orderDetl.getSpecs());
                        combMat.setBrand(orderDetl.getBrand());
                        combMat.setSku(orderDetl.getSku());
                        combMat.setMemo(orderDetl.getMemo());
                        combMat.setBoxType1(orderDetl.getBoxType1());
                        combMat.setBoxType2(orderDetl.getBoxType2());
                        combMat.setBoxType3(orderDetl.getBoxType3());
                        combMat.setStandby1(orderDetl.getStandby1());
                        combMat.setStandby2(orderDetl.getStandby2());
                        combMat.setStandby3(orderDetl.getStandby3());
                        combMats.add(combMat);
                    }
                    combParam.setCombMats(combMats);
                }
                combParam.setOrderNo(order.getOrderNo());
                return R.ok().add(combParam);
//                combParams.add(combParam);
        LinkedList<CombParam> combParams = new LinkedList<>();
        for (Order order : orders) {
            if (order == null) {
                continue;
            }
            DocType docType = docTypeService.selectById(order.getDocType());
            if (docType.getPakin() == null || docType.getPakin() != 1) {
                continue;
            }
            if (order.getSettle() > 2) {
                continue;
            }
            List<OrderDetl> orderDetls =
                    OrderInAndOutUtil.selectWorkingDetls(order.getPakinPakoutStatus$(), order.getId());
            CombParam combParam = new CombParam();
            if (!Cools.isEmpty(orderDetls)) {
                LinkedList<CombParam.CombMat> combMats = new LinkedList<>();
                for (OrderDetl od : orderDetls) {
                    CombParam.CombMat mat = new CombParam.CombMat();
                    mat.setMatnr(od.getMatnr());
                    mat.setBatch(od.getBatch());
                    mat.setAnfme(od.getAnfme() - od.getWorkQty());
                    mat.setMaktx(od.getMaktx());
                    mat.setSpecs(od.getSpecs());
                    mat.setBrand(od.getBrand());
                    mat.setSku(od.getSku());
                    mat.setMemo(od.getMemo());
                    mat.setSupp(od.getSupp());
                    mat.setBoxType1(od.getBoxType1());
                    mat.setBoxType2(od.getBoxType2());
                    mat.setBoxType3(od.getBoxType3());
                    mat.setStandby1(od.getStandby1());
                    mat.setStandby2(od.getStandby2());
                    mat.setStandby3(od.getStandby3());
                    combMats.add(mat);
                }
                combParam.setCombMats(combMats);
            }
            combParam.setOrderNo(order.getOrderNo());
            combParams.add(combParam);
        }
        return R.ok().add(combParams);
    }
    @RequestMapping("/comb/auth")
    @ManagerAuth(memo = "组托")
    public R comb(@RequestBody CombParam combParam){
//        mobileService.comb(combParam, getUserId());
        mobileService.comb(combParam, getUserId());
        return R.ok("组托成功");
    }
    @RequestMapping("/combAuto/auth")
    @ManagerAuth(memo = "组托")
    public R combAuto(@RequestBody CombParam combParam){
//        mobileService.comb(combParam, getUserId());
        mobileService.comb(combParam, getUserId());
        return R.ok("组托成功");
    }
    @RequestMapping("/combAuto/wcs/auth")
//    @ManagerAuth(memo = "组托")
    public R combAutoWcs(@RequestBody CombParam combParam){
//        mobileService.comb(combParam, getUserId());
        mobileService.combAuto(combParam, 7777L);
        return R.ok("组托成功");
    }
@@ -218,7 +241,7 @@
        return R.ok("齐套入库呼叫成功");
    }
    @RequestMapping("/kitting/call/all/auth")
    @RequestMapping("/kitting/call/all/auth")//寄  前端改不了一点
    @ManagerAuth(memo = "齐套入库呼叫")
    public R kittingCall(@RequestBody CombParam combParam){
        List<CombParam.CombMat> combMats = combParam.getCombMats();
@@ -227,6 +250,17 @@
        }
        return R.ok("齐套入库呼叫成功");
    }
    @RequestMapping("/loc/origin/query/auth")
    @ManagerAuth(memo = "库存查询")
    public R locOriginQuery(@RequestParam("barcode") String barcode){
        List<LocDetl> locDetlList = locDetlService.selectList(new EntityWrapper<LocDetl>().eq("zpallet", barcode));
        return R.ok("在库标记修改成功").add(locDetlList);
    }
    @RequestMapping("/loc/origin/in/out/auth")
    @ManagerAuth(memo = "在库标记修改")
    public R locOriginInOut(@RequestBody LocDetl locDetl){
        return mobileService.locOriginInOut(locDetl, getUserId());
    }
    @RequestMapping("/pack/get/auth")
    @ManagerAuth