|
...
|
...
|
@@ -171,6 +171,7 @@ public class ShipmentsPlanDetailServiceImpl extends BaseMpServiceImpl<ShipmentsP |
|
171
|
171
|
throw new DefaultClientException("发货计划不存在!");
|
|
172
|
172
|
}
|
|
173
|
173
|
vo.setWorkshopId(plan.getWorkshopId());
|
|
|
174
|
+ List<String> existOrderSpecIds = new ArrayList<>();
|
|
174
|
175
|
// 获取已经存在的明细数据
|
|
175
|
176
|
LambdaQueryWrapper<ShipmentsPlanDetail> queryWrapper = Wrappers.lambdaQuery(ShipmentsPlanDetail.class);
|
|
176
|
177
|
queryWrapper.eq(ShipmentsPlanDetail::getPreShipments, Boolean.FALSE)
|
|
...
|
...
|
@@ -178,13 +179,14 @@ public class ShipmentsPlanDetailServiceImpl extends BaseMpServiceImpl<ShipmentsP |
|
178
|
179
|
List<ShipmentsPlanDetail> detailList = getBaseMapper().selectList(queryWrapper);
|
|
179
|
180
|
if (CollectionUtils.isNotEmpty(detailList)) {
|
|
180
|
181
|
List<String> orderSpecIds = detailList.stream().map(ShipmentsPlanDetail::getOrderSpecId).collect(Collectors.toList());
|
|
181
|
|
- vo.setOrderSpecIds(orderSpecIds);
|
|
|
182
|
+ existOrderSpecIds.addAll(orderSpecIds);
|
|
182
|
183
|
}
|
|
183
|
184
|
detailList = listByPlanId(plan.getId(), true);
|
|
184
|
185
|
if (CollectionUtils.isNotEmpty(detailList)) {
|
|
185
|
186
|
List<String> orderSpecIds = detailList.stream().map(ShipmentsPlanDetail::getOrderSpecId).collect(Collectors.toList());
|
|
186
|
|
- vo.setOrderSpecIds(orderSpecIds);
|
|
|
187
|
+ existOrderSpecIds.addAll(orderSpecIds);
|
|
187
|
188
|
}
|
|
|
189
|
+ vo.setOrderSpecIds(existOrderSpecIds);
|
|
188
|
190
|
// 开启分页
|
|
189
|
191
|
PageHelperUtil.startPage(pageIndex, pageSize);
|
|
190
|
192
|
List<ShipmentsPlanDetail> dataList = getBaseMapper().queryCanShipmentsData(vo);
|
...
|
...
|
|