Browse Source

1.增加判断

training
pref_mail@163.com 1 year ago
parent
commit
164ec8843e
  1. 2
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionDeliveryListController.java
  2. 7
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java

2
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/controller/DistributionDeliveryListController.java

@ -345,7 +345,7 @@ public class DistributionDeliveryListController extends BladeController {
@PostMapping("/printBatch") @PostMapping("/printBatch")
@ApiOperationSupport(order = 2) @ApiOperationSupport(order = 2)
@ApiOperation(value = "批量打印", notes = "ids") @ApiOperation(value = "批量打印")
public R<PrintPreviewVO> printBatch(@ApiParam(value = "主键集合", required = true) @RequestParam String ids ,@ApiParam(value = "打印类型", required = true) @RequestParam Integer type) { public R<PrintPreviewVO> printBatch(@ApiParam(value = "主键集合", required = true) @RequestParam String ids ,@ApiParam(value = "打印类型", required = true) @RequestParam Integer type) {
try { try {

7
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java

@ -3165,7 +3165,6 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
String html = TemplateUtil.getTemplateByUrl(template.getTemplateUrl()); String html = TemplateUtil.getTemplateByUrl(template.getTemplateUrl());
printPreviewVO.setTemplateHtml(html); printPreviewVO.setTemplateHtml(html);
printPreviewVO.setTemplateId(template.getId()); printPreviewVO.setTemplateId(template.getId());
String[] idArray = ids.split(","); String[] idArray = ids.split(",");
if (ObjectUtils.isNull(idArray)) { if (ObjectUtils.isNull(idArray)) {
throw new ServiceException("参数错误"); throw new ServiceException("参数错误");
@ -3201,6 +3200,11 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
List<DistributionReservationEntity> distributionReservationEntityList = distributionReservationMapper.findByDeliveryId(byId.getId()); List<DistributionReservationEntity> distributionReservationEntityList = distributionReservationMapper.findByDeliveryId(byId.getId());
if(distributionReservationEntityList.isEmpty()){
throw new ServiceException("为找到相关数据");
}
for (DistributionReservationEntity distributionReservationEntity : distributionReservationEntityList) { for (DistributionReservationEntity distributionReservationEntity : distributionReservationEntityList) {
map.put("配送单号", distributionReservationEntity.getReservationCode()); map.put("配送单号", distributionReservationEntity.getReservationCode());
@ -3286,6 +3290,7 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
temp.put("数量",distributionReservationStockarticleEntity.getReservationNum()); temp.put("数量",distributionReservationStockarticleEntity.getReservationNum());
temp.put("备货区",null); temp.put("备货区",null);
//todo 这里还没完成 //todo 这里还没完成
temp.put("货位",null);
result.add(temp); result.add(temp);

Loading…
Cancel
Save