Commit d4e3b709d05838a0f284224c0428be0d800535a4
Merge remote-tracking branch 'origin/develop' into develop
Showing
4 changed files
with
22 additions
and
14 deletions
src/main/java/com/huaheng/pc/monitor/job/task/RyTask.java
... | ... | @@ -330,35 +330,33 @@ public class RyTask extends BaseController { |
330 | 330 | .eq(ShipmentHeader::getShipmentType, "SCLLD") |
331 | 331 | .lt(ShipmentHeader::getMesErrorCount, 3) |
332 | 332 | .ne(ShipmentHeader::getMesSuccessStatus, 1) |
333 | - .gt(ShipmentHeader::getLastStatus, 500) | |
334 | - .gt(ShipmentHeader::getFirstStatus, 500)); | |
333 | + .gt(ShipmentHeader::getLastStatus, 499) | |
334 | + .gt(ShipmentHeader::getFirstStatus, 499)); | |
335 | 335 | |
336 | 336 | for (ShipmentHeader shipmentHeader:shipmentHeaderList){ |
337 | 337 | //出库详情 |
338 | - List<ShipmentContainerDetail> shipmentDetailList = shipmentContainerDetailService.list(new LambdaQueryWrapper<ShipmentContainerDetail>() | |
339 | - .eq(ShipmentContainerDetail::getShipmentId, shipmentHeader.getId())); | |
338 | + List<ShipmentContainerDetail> shipmentContainerDetailList = shipmentContainerDetailService.list(new LambdaQueryWrapper<ShipmentContainerDetail>() | |
339 | + .eq(ShipmentContainerDetail::getShipmentId, shipmentHeader.getId()) | |
340 | + .gt(ShipmentContainerDetail::getMaterialGrossWeight,0)); | |
340 | 341 | |
341 | - orderData.setBatterynumber(new BigDecimal(shipmentDetailList.size()));//电池包只会出一个 | |
342 | + orderData.setBatterynumber(new BigDecimal(shipmentContainerDetailList.size()));//电池包只会出一个 | |
342 | 343 | header.setMethod("ServicesCUS.Module_CUS.CUS_AcceptWMSBatterybarcode"); |
343 | 344 | header.setAccount("DS");header.setPassword("DS");header.setVersion("");header.setModules(new String[]{}); |
344 | 345 | header.setMac("");header.setLang("zh_CN");header.setIs_debug(true);header.setPlatform("web");header.setSession(""); |
345 | 346 | |
346 | 347 | List<Barcodedata> barcodedataList = new ArrayList<>(); |
347 | - for (int i = 0; i < shipmentDetailList.size(); i++) { | |
348 | - ShipmentContainerDetail shipmentContainerDetail=shipmentDetailList.get(i); | |
348 | + for (int i = 0; i < shipmentContainerDetailList.size(); i++) { | |
349 | + ShipmentContainerDetail shipmentContainerDetail=shipmentContainerDetailList.get(i); | |
350 | + | |
349 | 351 | ShipmentDetail shipmentDetail=shipmentDetailService.getById(shipmentContainerDetail.getShipmentDetailId()); |
350 | 352 | if (StringUtils.isEmpty(shipmentDetail.getOrderNo())) { |
351 | 353 | throw new ServiceException("订单号为空"); |
352 | 354 | } |
353 | 355 | orderData.setOrderNo(shipmentDetail.getOrderNo()); |
354 | 356 | Barcodedata barcodedata = new Barcodedata(); |
355 | - barcodedata.setWeight(shipmentDetailList.get(i).getMaterialNetWeight()); | |
356 | - if (StringUtils.isEmpty(shipmentDetailList.get(i).getBatteryPackTwoCode())) { | |
357 | - throw new ServiceException("电池编码为空"); | |
358 | - } | |
359 | - barcodedata.setBatterybarcode(shipmentDetailList.get(i).getBatteryPackTwoCode()); | |
360 | - barcodedata.setElectricquantity(shipmentDetailList.get(i).getElectricQuantity()); | |
361 | - barcodedata.setMaterialBatch(shipmentDetail.getMaterialBatch()); | |
357 | + barcodedata.setBatterybarcode(shipmentContainerDetail.getBatteryPackTwoCode()); | |
358 | + barcodedata.setElectricquantity(shipmentContainerDetail.getElectricQuantity()); | |
359 | + barcodedata.setMaterialBatch(shipmentContainerDetail.getMaterialBatch()); | |
362 | 360 | barcodedataList.add(barcodedata); |
363 | 361 | orderData.setBarcodedata(barcodedataList); |
364 | 362 | } |
... | ... |
src/main/java/com/huaheng/pc/shipment/shipmentContainerDetail/domain/ShipmentContainerDetail.java
... | ... | @@ -406,6 +406,14 @@ public class ShipmentContainerDetail implements Serializable { |
406 | 406 | @ApiModelProperty(value="电池包二维码") |
407 | 407 | private String batteryPackTwoCode; |
408 | 408 | |
409 | + /** | |
410 | + * 原料批次 | |
411 | + * @return | |
412 | + */ | |
413 | + @TableField(value = "materialBatch") | |
414 | + @ApiModelProperty(value="原料批次") | |
415 | + private String materialBatch; | |
416 | + | |
409 | 417 | |
410 | 418 | private static final long serialVersionUID = 1L; |
411 | 419 | } |
... | ... |
src/main/java/com/huaheng/pc/shipment/shipmentContainerHeader/service/ShipmentContainerHeaderServiceImpl.java
... | ... | @@ -415,6 +415,7 @@ public class ShipmentContainerHeaderServiceImpl extends ServiceImpl<ShipmentCont |
415 | 415 | shipmentContainerDetaill.setMaterialTareWeight(inventoryDetail.getMaterialTareWeight()); |
416 | 416 | shipmentContainerDetaill.setMaterialNetWeight(inventoryDetail.getMaterialNetWeight()); |
417 | 417 | shipmentContainerDetaill.setMaterialGrossWeight(inventoryDetail.getMaterialGrossWeight()); |
418 | + shipmentContainerDetaill.setMaterialBatch(inventoryDetail.getMaterialBatch()); | |
418 | 419 | shipmentContainerDetaill.setElectricQuantity(inventoryDetail.getElectricQuantity()); |
419 | 420 | shipmentContainerDetaill.setBatteryPackTwoCode(inventoryDetail.getBatteryPackTwoCode()); |
420 | 421 | shipmentContainerDetaill.setQty(qty); |
... | ... |
src/main/java/com/huaheng/pc/task/taskHeader/service/ShipmentTaskService.java
... | ... | @@ -411,6 +411,7 @@ public class ShipmentTaskService { |
411 | 411 | if (StringUtils.isNotNull(shipmentDetail)) { |
412 | 412 | if (shipmentDetail.getShipQty().compareTo(shipmentDetail.getRequestQty()) == 0) { |
413 | 413 | shipmentDetail.setBatteryPackTwoCode(taskDetail.getBatteryPackTwoCode()); |
414 | + shipmentDetail.setElectricQuantity(taskDetail.getElectricQuantity()); | |
414 | 415 | shipmentDetail.setMaterialBatch(taskDetail.getMaterialBatch()); |
415 | 416 | shipmentDetail.setStatus(QuantityConstant.SHIPMENT_HEADER_COMPLETED); |
416 | 417 | shipmentDetailService.updateById(shipmentDetail); |
... | ... |