|
|
|
@ -819,7 +819,6 @@ public class InterfaceServiceImpl implements InterfaceService {
|
|
|
|
|
LocalDateTime now = LocalDateTime.now();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<PrintLog> printLogList = new ArrayList<>();
|
|
|
|
|
//循环处理 物料批次
|
|
|
|
|
for (int i = 0; i < itemBatchDtoList.size(); i++) {
|
|
|
|
|
ItemBatchDto itemBatchDto = itemBatchDtoList.get(i);
|
|
|
|
@ -867,42 +866,40 @@ public class InterfaceServiceImpl implements InterfaceService {
|
|
|
|
|
itemBatch.setCreateUser(Constants.SITE_ADMIN);
|
|
|
|
|
itemBatch.setCreatedDateTime(now);
|
|
|
|
|
itemBatchService.save(itemBatch);
|
|
|
|
|
|
|
|
|
|
//打印模板参数
|
|
|
|
|
List<LabelPrintDto> labelPrintDtoList = new ArrayList<>();
|
|
|
|
|
LabelPrintDto labelPrintDto = new LabelPrintDto();
|
|
|
|
|
labelPrintDto.setSite(site);
|
|
|
|
|
labelPrintDto.setPrintTemplate(Constants.PRINT_TYPE_INV);
|
|
|
|
|
labelPrintDto.setItem(item);
|
|
|
|
|
labelPrintDto.setItemDescription(itemModel.getDescription());
|
|
|
|
|
labelPrintDto.setSupplier(supplier);
|
|
|
|
|
//labelPrintDto.setBatch(inventory);
|
|
|
|
|
labelPrintDto.setBatch(batch);
|
|
|
|
|
labelPrintDto.setLabel(inventory);
|
|
|
|
|
labelPrintDtoList.add(labelPrintDto);
|
|
|
|
|
|
|
|
|
|
//记录打印数据
|
|
|
|
|
PrintLog printLog = new PrintLog();
|
|
|
|
|
printLog.setHandle(UUID.randomUUID().toString());
|
|
|
|
|
printLog.setSite(site);
|
|
|
|
|
printLog.setCategory(Constants.PRINT_TYPE_INV);
|
|
|
|
|
printLog.setPrintName("");
|
|
|
|
|
printLog.setPrintTemplate(Constants.PRINT_TYPE_INV);
|
|
|
|
|
printLog.setPrintParam(JSON.toJSONString(labelPrintDtoList));
|
|
|
|
|
printLog.setInventory(inventory);
|
|
|
|
|
printLog.setItemBo(itemModel.getHandle());
|
|
|
|
|
printLog.setIsPrint("false");
|
|
|
|
|
printLog.setPrintNum(0);
|
|
|
|
|
printLog.setCreateUser("SITE_ADMIN");
|
|
|
|
|
printLog.setCreatedDateTime(LocalDateTime.now());
|
|
|
|
|
printLogService.save(printLog);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//打印模板参数
|
|
|
|
|
List<LabelPrintDto> labelPrintDtoList = new ArrayList<>();
|
|
|
|
|
LabelPrintDto labelPrintDto = new LabelPrintDto();
|
|
|
|
|
labelPrintDto.setSite(site);
|
|
|
|
|
labelPrintDto.setPrintTemplate(Constants.PRINT_TYPE_INV);
|
|
|
|
|
labelPrintDto.setItem(item);
|
|
|
|
|
labelPrintDto.setItemDescription(itemModel.getDescription());
|
|
|
|
|
labelPrintDto.setSupplier(supplier);
|
|
|
|
|
//labelPrintDto.setBatch(inventory);
|
|
|
|
|
labelPrintDto.setBatch(batch);
|
|
|
|
|
labelPrintDto.setLabel(inventory);
|
|
|
|
|
labelPrintDtoList.add(labelPrintDto);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//记录打印数据
|
|
|
|
|
PrintLog printLog = new PrintLog();
|
|
|
|
|
printLog.setHandle(UUID.randomUUID().toString());
|
|
|
|
|
printLog.setSite(site);
|
|
|
|
|
printLog.setCategory(Constants.PRINT_TYPE_INV);
|
|
|
|
|
printLog.setPrintName("");
|
|
|
|
|
printLog.setPrintTemplate(Constants.PRINT_TYPE_INV);
|
|
|
|
|
printLog.setPrintParam(JSON.toJSONString(labelPrintDtoList));
|
|
|
|
|
printLog.setInventory(inventory);
|
|
|
|
|
printLog.setItemBo(itemModel.getHandle());
|
|
|
|
|
printLog.setIsPrint("false");
|
|
|
|
|
printLog.setPrintNum(0);
|
|
|
|
|
printLog.setCreateUser("SITE_ADMIN");
|
|
|
|
|
printLog.setCreatedDateTime(LocalDateTime.now());
|
|
|
|
|
printLogList.add(printLog);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (printLogList != null && printLogList.size() > 0) {
|
|
|
|
|
printLogService.saveBatch(printLogList);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|