@ -5966,6 +5966,44 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
return aftersalesAbnormalPackageVOS ;
}
/ * *
*
* 工单查询配送数据
* @param page
* @param distributionDeliveryInfoDTO
* @return
* /
@Override
public IPage < DistributionDeliveryWordVO > getShippingInformation ( IPage < Object > page , DistributionDeliveryListDTO distributionDeliveryInfoDTO ) {
IPage < DistributionDeliveryWordVO > iPage = baseMapper . getShippingInformation ( page , distributionDeliveryInfoDTO ) ;
if ( ! iPage . getRecords ( ) . isEmpty ( ) ) {
iPage . getRecords ( ) . forEach ( i - > {
if ( "1" . equals ( i . getKind ( ) ) ) {
//自主
//查询司机信息
List < DistributionDeliverySelfEntity > distributionDeliverySelfEntities = distributionDeliverySelfMapper . selectList ( Wrappers . < DistributionDeliverySelfEntity > query ( ) . lambda ( )
. eq ( DistributionDeliverySelfEntity : : getDeliveryId , i . getId ( ) )
) ;
if ( ! distributionDeliverySelfEntities . isEmpty ( ) ) {
String collect = distributionDeliverySelfEntities . stream ( ) . map ( DistributionDeliverySelfEntity : : getDriverName ) . collect ( Collectors . joining ( "," ) ) ;
i . setDriverName ( collect ) ;
}
} else {
//三方
List < DistributionDeliveryTripartiteEntity > list = distributionDeliveryTripartiteService . list ( Wrappers . < DistributionDeliveryTripartiteEntity > query ( ) . lambda ( )
. eq ( DistributionDeliveryTripartiteEntity : : getDeliveryId , i . getId ( ) )
) ;
if ( ! list . isEmpty ( ) ) {
String collect = list . stream ( ) . map ( DistributionDeliveryTripartiteEntity : : getDriverName ) . collect ( Collectors . joining ( "," ) ) ;
i . setDriverName ( collect ) ;
}
}
} ) ;
}
return iPage ;
}
public Map < String , String > getDriverCar ( String kind , Long deliveryListEntityId ) {
Map < String , String > map = new HashMap < > ( ) ;