This commit is contained in:
jhd
2026-05-30 10:47:52 +08:00
48 changed files with 2758 additions and 354 deletions

View File

@@ -338,6 +338,33 @@ public class WmsDeliveryWaybillDetailServiceImpl implements IWmsDeliveryWaybillD
return list.stream().map(WmsDeliveryWaybillDetail::getCoilId).distinct().collect(Collectors.toList());
}
@Override
public List<Long> getBoundCoilIdsByPlanId(Long planId, Date startTime, Date endTime) {
LambdaQueryWrapper<WmsDeliveryWaybill> waybillWrapper = Wrappers.lambdaQuery();
waybillWrapper.eq(WmsDeliveryWaybill::getPlanId, planId);
waybillWrapper.eq(WmsDeliveryWaybill::getDelFlag, 0);
if (startTime != null) {
waybillWrapper.ge(WmsDeliveryWaybill::getDeliveryTime, startTime);
}
if (endTime != null) {
waybillWrapper.le(WmsDeliveryWaybill::getDeliveryTime, endTime);
}
List<WmsDeliveryWaybill> waybills = wmsDeliveryWaybillMapper.selectList(waybillWrapper);
if (waybills == null || waybills.isEmpty()) {
return Collections.emptyList();
}
List<Long> waybillIds = waybills.stream().map(WmsDeliveryWaybill::getWaybillId).collect(Collectors.toList());
LambdaQueryWrapper<WmsDeliveryWaybillDetail> detailWrapper = Wrappers.lambdaQuery();
detailWrapper.in(WmsDeliveryWaybillDetail::getWaybillId, waybillIds);
detailWrapper.isNotNull(WmsDeliveryWaybillDetail::getCoilId);
detailWrapper.eq(WmsDeliveryWaybillDetail::getDelFlag, 0);
detailWrapper.select(WmsDeliveryWaybillDetail::getCoilId);
List<WmsDeliveryWaybillDetail> list = baseMapper.selectList(detailWrapper);
return list.stream().map(WmsDeliveryWaybillDetail::getCoilId).distinct().collect(Collectors.toList());
}
@Override
public List<Long> getBoundCoilIdsByPrincipal(String principal) {
if (principal == null || principal.trim().isEmpty()) {

View File

@@ -630,6 +630,8 @@ public class WmsMaterialCoilServiceImpl implements IWmsMaterialCoilService {
qw.eq(StringUtils.isNotBlank(bo.getBusinessPurpose()), "mc.business_purpose", bo.getBusinessPurpose());
// 是否与订单相关0=否1=是)
qw.eq(bo.getIsRelatedToOrder() != null, "mc.is_related_to_order", bo.getIsRelatedToOrder());
// 加上remark的模糊匹配
qw.like(StringUtils.isNotBlank(bo.getRemark()), "mc.remark", bo.getRemark());
//逻辑删除
qw.eq("mc.del_flag", 0);
// 统一处理 warehouseId 与 warehouseIds