| | |
| | | if (!Cools.isEmpty(locMast) && locMast.getCrnNo()<5){ |
| | | int wrkMastsC0 = wrkMastService.selectCount(new EntityWrapper<WrkMast>().eq("crn_no", locMast.getCrnNo()).eq("io_type",1)); |
| | | if (wrkMastsC0>3 && times < rowCount){ |
| | | int locO1 = locMastService.selectCount(new EntityWrapper<LocMast>().eq("loc_sts", "O").eq("crn_no", 1)); |
| | | BasCrnp basCrnp1 = basCrnpService.selectById(1); |
| | | if (basCrnp1.getInEnable().equals("Y") && basCrnp1.getCrnSts().equals(3)){ |
| | | if (!Cools.isEmpty(locO1) && basCrnp1.getInEnable().equals("Y") && basCrnp1.getCrnSts().equals(3)){ |
| | | int wrkMastsC1 = wrkMastService.selectCount(new EntityWrapper<WrkMast>().eq("crn_no", 1).eq("io_type",1)); |
| | | if (wrkMastsC0>wrkMastsC1){ |
| | | locMast=null; |
| | | } |
| | | } |
| | | if (!Cools.isEmpty(locMast)){ |
| | | locO1=locMastService.selectCount(new EntityWrapper<LocMast>().eq("loc_sts", "O").eq("crn_no", 2)); |
| | | BasCrnp basCrnp2 = basCrnpService.selectById(2); |
| | | if (basCrnp2.getInEnable().equals("Y") && basCrnp2.getCrnSts().equals(3)){ |
| | | if (!Cools.isEmpty(locO1) && basCrnp2.getInEnable().equals("Y") && basCrnp2.getCrnSts().equals(3)){ |
| | | int wrkMastsC2 = wrkMastService.selectCount(new EntityWrapper<WrkMast>().eq("crn_no", 2).eq("io_type",1)); |
| | | if (wrkMastsC0>wrkMastsC2){ |
| | | locMast=null; |
| | |
| | | } |
| | | } |
| | | if (!Cools.isEmpty(locMast)){ |
| | | locO1=locMastService.selectCount(new EntityWrapper<LocMast>().eq("loc_sts", "O").eq("crn_no", 2)); |
| | | BasCrnp basCrnp3 = basCrnpService.selectById(3); |
| | | if (basCrnp3.getInEnable().equals("Y") && basCrnp3.getCrnSts().equals(3)){ |
| | | if (!Cools.isEmpty(locO1) && basCrnp3.getInEnable().equals("Y") && basCrnp3.getCrnSts().equals(3)){ |
| | | int wrkMastsC3 = wrkMastService.selectCount(new EntityWrapper<WrkMast>().eq("crn_no", 3).eq("io_type",1)); |
| | | if (wrkMastsC0>wrkMastsC3){ |
| | | locMast=null; |
| | |
| | | } |
| | | } |
| | | if (!Cools.isEmpty(locMast)){ |
| | | locO1=locMastService.selectCount(new EntityWrapper<LocMast>().eq("loc_sts", "O").eq("crn_no", 2)); |
| | | BasCrnp basCrnp4 = basCrnpService.selectById(4); |
| | | if (basCrnp4.getInEnable().equals("Y") && basCrnp4.getCrnSts().equals(3)){ |
| | | if (!Cools.isEmpty(locO1) && basCrnp4.getInEnable().equals("Y") && basCrnp4.getCrnSts().equals(3)){ |
| | | int wrkMastsC4 = wrkMastService.selectCount(new EntityWrapper<WrkMast>().eq("crn_no", 4).eq("io_type",1)); |
| | | if (wrkMastsC0>wrkMastsC4){ |
| | | locMast=null; |