自动化立体仓库 - WMS系统
zjj
2023-06-17 61d28206585b8746a9f1982cfe1dfc5deabde91a
src/main/java/com/zy/asrs/controller/MapController.java
@@ -55,18 +55,11 @@
                    mapFilename = "DTDnode.json";
                    locMasts = locMastService.selectNodeDLocByLev(lev);
                    break;
                case 32:
                    mapFilename = "DTBnode.json";
                    locMasts = locMastService.selectNodeB2LocByLev(lev);
                case 6:
                    mapFilename = "DTEnode.json";
                    locMasts = locMastService.selectNodeELocByLev(lev);
                    break;
                case 42:
                    mapFilename = "DTCnode.json";
                    locMasts = locMastService.selectNodeC2LocByLev(lev);
                    break;
                case 52:
                    mapFilename = "DTDnode.json";
                    locMasts = locMastService.selectNodeD2LocByLev(lev);
                    break;
            }
            String fileName = this.getClass().getClassLoader().getResource(mapFilename).getPath();//获取文件路径
@@ -104,6 +97,7 @@
                for (LocMast locMast : locMasts) {
                    Integer row = locMast.getRow1();
                    Integer bay = locMast.getBay1();
@@ -118,7 +112,6 @@
                            break;
                        case 2:
                        case 3:
                        case 32:
                            if (row<=3 || row>=5){
                                if (row%1==0){
                                    row=row+(row/1)-1;
@@ -132,21 +125,46 @@
                                    row=row+((row-1)/2);
                                }
                            }
                            if (row == 9){
                                row= row -1;
                            }
                            if (bay % 6 == 0) {
                                bay=bay+1;
                            if (bay ==7) {
                                bay=bay+2;
                            }else{
                                if (bay>6){
                                    bay=bay+locMast.getCrnNo();
                                if (bay>7){
                                    bay=bay+locMast.getCrnNo()+1;
                                }else {
                                    bay=bay+locMast.getCrnNo()-1;
                                }
                            }
                            break;
                        case 4:
                            if (row<=11){
                                if (row%2==0){
                                    row=row+(row/2)-1;
                                }else {
                                    row=row+((row+1)/2)-1;
                                }
                            }else {
                                if (row%2==0){
                                    row=row+(row/2);
                                }else {
                                    row=row+((row-1)/2);
                                }
                            }
                            if (bay % 10 == 0) {
                                bay=bay+1;
                            }else{
                                if (bay>10){
                                    bay=bay+locMast.getCrnNo();
                                }else {
                                    bay=bay+locMast.getCrnNo()-1;
                                }
                            }
                            break;
                        case 5:
                        case 42:
                        case 52:
                            if (row<=11){
                                if (row%2==0){
                                    row=row+(row/2)-1;
@@ -176,7 +194,7 @@
                    }
                    if (area == 1){
                    if (area == 1 || area == 6){
                        ArrayList rowData = arrayLists.get(row);
                        Object o = rowData.get(bay);
                        JSONObject jsonObject = JSON.parseObject(o.toString());