| | |
| | | public int compare(north_glass_buffer1 n1, north_glass_buffer1 n2) {//对查询到的铝框对应的玻璃数据进行排序,将离出片位置近的,靠近笼子出片侧的玻璃排在前面 |
| | | if (n1.getstorageCage() != null) { |
| | | if (n2.getstorageCage() != null) { |
| | | int cageComparison = n2.getstorageCage().getCage().compareTo(n1.getstorageCage().getCage()); |
| | | int cageComparison = n2.getstorageCage().getCage().compareTo(n1.getstorageCage().getCage());//靠出片口近的笼子优先 |
| | | if (cageComparison != 0) { |
| | | return cageComparison; |
| | | } else { |
| | | int cellComparison = n2.getstorageCage().getCell().compareTo(n1.getstorageCage().getCell()); |
| | | int cellComparison = n2.getstorageCage().getCell().compareTo(n1.getstorageCage().getCell());//靠出片口近的格子优先 |
| | | if (cellComparison != 0) { |
| | | return cellComparison; |
| | | } else { |
| | | return n2.getstorageCage().getTier().compareTo(n1.getstorageCage().getTier()); |
| | | return n2.getstorageCage().getTier().compareTo(n1.getstorageCage().getTier());//靠出片口近的格子外层优先 |
| | | } |
| | | } |
| | | } else { |
| | |
| | | north_glass_buffer1.setstorageCage(homeMapper.SelectStorageGlassById(north_glass_buffer1.getbarcode())); |
| | | north_glass_buffer1.setOut_slice(homeMapper.SelectQueueByglassid(north_glass_buffer1.getbarcode())); |
| | | } |
| | | // 对嵌套类的其中一列进行排序 |
| | | // 对嵌套类进行排序 |
| | | Collections.sort(listAluminumFrame, new north_glass_buffer1Comparator()); |
| | | return listAluminumFrame; |
| | | } |
| | |
| | | List<north_glass_buffer1> north_glass_buffer1s = SelectAluminumFrameInfoById(FrameBarcode); |
| | | String flip = jdbcConnections.SelectFlipByFrameBarcode(FrameBarcode); |
| | | String position = jdbcConnections.SelectPositionByFrameBarcode(FrameBarcode); |
| | | String framelength=jdbcConnections.SelectFrameLengthByFrameBarcode(FrameBarcode); |
| | | String frameheight=jdbcConnections.SelectFrameHeightByFrameBarcode(FrameBarcode); |
| | | int sequence = homeMapper.SelectMaxSquence(); |
| | | for (north_glass_buffer1 north_glass_buffer1 : north_glass_buffer1s) { |
| | | Short state = 0; |
| | |
| | | north_glass_buffer1.getglassheightmm().toString(), sequence, position, state, |
| | | north_glass_buffer1.getordernumber(), north_glass_buffer1.getlistnumber(), |
| | | north_glass_buffer1.getboxnumber(), north_glass_buffer1.getglasslength().toString(), |
| | | north_glass_buffer1.getglassheight().toString()); |
| | | north_glass_buffer1.getglassheight().toString(),framelength,frameheight); |
| | | sequence += 1; |
| | | } |
| | | } |