Browse Source

Merge remote-tracking branch 'origin/dev' into dev

master
zhaoqiaobo 9 months ago
parent
commit
ce73e0de57
  1. 2
      blade-biz-common/src/main/java/org/springblade/common/constant/loading/LoadScanSigningTypeStatusConstant.java
  2. 2
      blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/vo/BasicdataDriverArteryVO.java
  3. 4
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListVO.java
  4. 14
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataDriverArteryClient.java
  5. 2
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/mapper/BasicdataDriverArteryMapper.java
  6. 16
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/mapper/BasicdataDriverArteryMapper.xml
  7. 2
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataDriverArteryService.java
  8. 2
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataDriverArteryServiceImpl.java
  9. 2
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml
  10. 19
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryInfoServiceImpl.java
  11. 27
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java
  12. 4
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionReservationServiceImpl.java
  13. 2
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/InComingServiceImpl.java
  14. 4
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java
  15. 7
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionRecordServiceImpl.java

2
blade-biz-common/src/main/java/org/springblade/common/constant/loading/LoadScanSigningTypeStatusConstant.java

@ -7,7 +7,7 @@ package org.springblade.common.constant.loading;
*/
public enum LoadScanSigningTypeStatusConstant {
sijiqianshou("司机签收",1),
sijiqianshou("司机扫描签收",1),
sijipiliangqianshou("司机批量签收",2),
wenyuanpiliangqianshou("文员批量签收",3);

2
blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/vo/BasicdataDriverArteryVO.java

@ -42,6 +42,8 @@ public class BasicdataDriverArteryVO extends BasicdataDriverArteryEntity {
@ApiModelProperty(value = "车辆信息")
private String bindVehicles;
private String carNumbers;
/**
* 司机关联车辆列表
*/

4
blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/vo/DistributionParcelListVO.java

@ -146,6 +146,10 @@ public class DistributionParcelListVO extends DistributionParcelListEntity {
@TableField(exist = false)
private String signingUser;
@ApiModelProperty(value = "签收人")
@TableField(exist = false)
private String signingType;
/**
* 预约号
*/

14
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataDriverArteryClient.java

@ -22,15 +22,18 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.logpm.basicdata.entity.BasicdataDriverArteryEntity;
import com.logpm.basicdata.mapper.BasicdataDriverArteryMapper;
import com.logpm.basicdata.service.IBasicdataDriverArteryService;
import com.logpm.basicdata.vo.BasicdataDriverArteryVO;
import lombok.AllArgsConstructor;
import org.springblade.core.mp.support.BladePage;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.tool.utils.StringUtil;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import springfox.documentation.annotations.ApiIgnore;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
/**
@ -69,14 +72,21 @@ public class BasicdataDriverArteryClient implements IBasicdataDriverArteryClient
@Override
public List<JSONObject> findDriverListByName(String driverName) {
List<BasicdataDriverArteryEntity> ls = basicdataDriverArteryService.findDriverListByName(driverName);
List<BasicdataDriverArteryVO> ls = basicdataDriverArteryService.findDriverListByName(driverName);
List<JSONObject> list = new ArrayList<>();
for (BasicdataDriverArteryEntity driverArteryEntity:ls){
for (BasicdataDriverArteryVO driverArteryEntity:ls){
JSONObject jsonObject = new JSONObject();
jsonObject.put("driverId",driverArteryEntity.getId());
jsonObject.put("driverName",driverArteryEntity.getName());
jsonObject.put("driverPhone",driverArteryEntity.getPhone());
jsonObject.put("driverType",driverArteryEntity.getType());
String carNumbers = driverArteryEntity.getCarNumbers();
List<String> carNumberList = new ArrayList<>();
if(StringUtil.isNotBlank(carNumbers)){
String[] split = carNumbers.split(",");
carNumberList.addAll(Arrays.asList(split));
}
jsonObject.put("carNumberList",carNumberList);
list.add(jsonObject);
}
return list;

2
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/mapper/BasicdataDriverArteryMapper.java

@ -57,7 +57,7 @@ public interface BasicdataDriverArteryMapper extends BaseMapper<BasicdataDriverA
*/
List<BasicdataDriverArteryVO> selectBasicdataDictionary();
List<BasicdataDriverArteryEntity> findDriverListByName(@Param("driverName") String driverName);
List<BasicdataDriverArteryVO> findDriverListByName(@Param("driverName") String driverName);
void updateIsdeletedByPhone(@Param("phone") String phone);

16
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/mapper/BasicdataDriverArteryMapper.xml

@ -157,10 +157,20 @@
SELECT id,name,bind_vehicle FROM logpm_basicdata_driver_artery
</select>
<select id="findDriverListByName" resultType="com.logpm.basicdata.entity.BasicdataDriverArteryEntity">
select *
from logpm_basicdata_driver_artery
<select id="findDriverListByName" resultType="com.logpm.basicdata.vo.BasicdataDriverArteryVO">
select lbda.id id,
lbda.name name,
lbda.phone phone,
lbda.type type,
group_concat(lbv.vehicle_nub) carNumbers
from logpm_basicdata_driver_artery lbda
left join logpm_basicdata_drivermiddle lbdm on lbdm.driver_id = lbda.id
left join logpm_basicdata_vehicle lbv on lbv.id = lbdm.brand_id
where `name` like concat('%',#{driverName},'%')
group by lbda.id,
lbda.name,
lbda.phone,
lbda.type
limit 10
</select>
<select id="findDriverListByPhone" resultType="com.logpm.basicdata.entity.BasicdataDriverArteryEntity">

2
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/IBasicdataDriverArteryService.java

@ -70,5 +70,5 @@ public interface IBasicdataDriverArteryService extends BaseService<BasicdataDriv
void importDriverArtery(List<BasicdataDriverArteryImproterExcel> data);
List<BasicdataDriverArteryEntity> findDriverListByName(String driverName);
List<BasicdataDriverArteryVO> findDriverListByName(String driverName);
}

2
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataDriverArteryServiceImpl.java

@ -327,7 +327,7 @@ public class BasicdataDriverArteryServiceImpl extends BaseServiceImpl<BasicdataD
@Override
public List<BasicdataDriverArteryEntity> findDriverListByName(String driverName) {
public List<BasicdataDriverArteryVO> findDriverListByName(String driverName) {
return baseMapper.findDriverListByName(driverName);
}
}

2
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml

@ -131,7 +131,7 @@
<select id="selectDistributionDeliverywrapInfoPage"
resultType="com.logpm.distribution.entity.DistributionParcelListEntity">
SELECT
ldpl.*
DISTINCT ldpl.*
FROM
logpm_distribution_reservation_package ldrp
join logpm_distribution_parcel_list ldpl on ldrp.parce_list_id = ldpl.id

19
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryInfoServiceImpl.java

@ -37,6 +37,7 @@ import com.logpm.distribution.wrapper.DistributionParcelListWrapper;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springblade.common.constant.common.IsOrNoConstant;
import org.springblade.common.constant.loading.LoadScanSigningTypeStatusConstant;
import org.springblade.common.constant.loading.LoadingStatusConstant;
import org.springblade.common.constant.order.OrderStatusConstant;
import org.springblade.common.constant.orderpackage.OrderPackageLoadingStatusConstant;
@ -195,7 +196,7 @@ public class DistributionDeliveryInfoServiceImpl extends BaseServiceImpl<Distrib
log.info("loadscanEntity.getScanStatus() does not meet matching conditions: {}", loadscanEntity.getScanStatus());
break;
}
if (Func.isEmpty(loadscanEntity.getIsSignfor())){
if (Func.isEmpty(loadscanEntity.getIsSignfor())) {
switch (loadscanEntity.getScanStatus()) {
case "1":
parcel.setScanStatus(LoadingStatusConstant.quxiao.getName());
@ -224,6 +225,22 @@ public class DistributionDeliveryInfoServiceImpl extends BaseServiceImpl<Distrib
if (Func.isNotEmpty(loadscanEntity.getSigningUser())) {
parcel.setSigningUser(loadscanEntity.getSigningUser());
}
if (Func.isNotEmpty(loadscanEntity.getSignforType())) {
switch (loadscanEntity.getSignforType()) {
case 1:
parcel.setSigningType(LoadScanSigningTypeStatusConstant.sijiqianshou.getName());
break;
case 2:
parcel.setSigningType(LoadScanSigningTypeStatusConstant.sijipiliangqianshou.getName());
break;
case 3:
parcel.setSigningType(LoadScanSigningTypeStatusConstant.wenyuanpiliangqianshou.getName());
break;
default:
log.info("loadscanEntity.getSignforType() does not meet matching conditions: {}", loadscanEntity.getSignforType());
break;
}
}
}

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

@ -3576,6 +3576,10 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
break;
}
List<DistributionDeliverySelfDTO> allocationInfo = deliveryListDTO.getAllocationInfo();
if (Strings.isBlank(deliveryListDTO.getMasterDriverName())){
//无主司机信息 进行主司机默认赋予
deliveryListDTO.setMasterDriverName(allocationInfo.get(0).getDriverName());
}
if (Func.isEmpty(allocationInfo)) {
//这里就表示是三方配送
DistributionDeliveryTripartiteDTO tripartite = deliveryListDTO.getTripartite();
@ -3593,7 +3597,7 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
} else {
StringBuilder driverNames = new StringBuilder();
StringBuilder vehicleNubs = new StringBuilder();
if (Func.isEmpty(deliveryListDTO.getMasterDriverName()) || Func.isEmpty(deliveryListDTO.getMasterVehicleNub())) {
if (Func.isEmpty( deliveryListDTO.getMasterDriverName()) || Func.isEmpty(deliveryListDTO.getMasterVehicleNub())) {
//检测无主司机 进行随机赋予主司机
deliveryListDTO.setMasterDriverName(allocationInfo.get(0).getDriverName());
deliveryListDTO.setMasterVehicleNub(allocationInfo.get(0).getVehicleNub());
@ -3604,7 +3608,6 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
if (a.getDriverName().equals(deliveryListDTO.getMasterDriverName()) && a.getVehicleNub().equals(deliveryListDTO.getMasterVehicleNub())) {
deliverySelfEntity.setIsMaster(ServiceConstant.IS_MASTER_YES);
driverNames.append(deliverySelfEntity.getDriverName()).append("(主),");
} else {
driverNames.append(deliverySelfEntity.getDriverName()).append(",");
}
@ -4204,6 +4207,25 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
distributionParcelListVO.setScanStatus(LoadingStatusConstant.buluzhuangche.getName());
break;
}
distributionParcelListVO.setLoadingNub(loadscanEntity.getLoadedNub());
}
if (Func.isNotEmpty(loadscanEntity.getSignforType())) {
switch (loadscanEntity.getSignforType()) {
case 1:
distributionParcelListVO.setSigningType(LoadScanSigningTypeStatusConstant.sijiqianshou.getName());
break;
case 2:
distributionParcelListVO.setSigningType(LoadScanSigningTypeStatusConstant.sijipiliangqianshou.getName());
break;
case 3:
distributionParcelListVO.setSigningType(LoadScanSigningTypeStatusConstant.wenyuanpiliangqianshou.getName());
break;
default:
log.info("loadscanEntity.getSignforType() does not meet matching conditions: {}", loadscanEntity.getSignforType());
break;
}
distributionParcelListVO.setLoadingNub(loadscanEntity.getLoadedNub());
}
}
@ -6237,7 +6259,6 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
//进行了一条包件任务的取消,此时就应该对预约、配送任务进行数量的维护
distributionAsyncService.checkRetentionReservationAndDeliveryInfo(reservationId, deliveryId);
return true;
} else {
//包件未预约 处于异常驳回状态
//查询异常信息,对异常信息进行清理

4
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionReservationServiceImpl.java

@ -2381,6 +2381,10 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
} else {
//自主配送
List<DistributionDeliverySelfDTO> allocationInfo = allocationDTO.getAllocationInfo();
if (Strings.isBlank(allocationDTO.getMasterDriverName())){
//无主司机信息 进行主司机默认赋予
allocationDTO.setMasterDriverName(allocationInfo.get(0).getDriverName());
}
allocationInfo.forEach(a -> {
DistributionDeliverySelfEntity distributionDeliverySelfEntity = Func.copy(a, DistributionDeliverySelfEntity.class);
//设置车辆编号

2
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/InComingServiceImpl.java

@ -441,7 +441,7 @@ public class InComingServiceImpl implements IInComingService {
String dealerName = advanceEntity.getDealerName();
String dealerCode = advanceEntity.getDealerCode();
String brand = advanceEntity.getBrand();
if(Objects.isNull(waybillId)){
if(!Objects.isNull(waybillId)){
WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillId(waybillId);
if(!Objects.isNull(waybillEntity)){
String destinationWarehouseName = waybillEntity.getDestinationWarehouseName();

4
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java

@ -4719,7 +4719,9 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
//重新计算签收单的数量
updateSignOrderNumBySignOrderId(signOrderId);
return Resp.scanSuccess("签收成功",enterNum+"件");
// return Resp.scanSuccess("签收成功",enterNum+"件");
return R.success("签收成功");
}
@Override

7
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseRetentionRecordServiceImpl.java

@ -252,7 +252,7 @@ public class WarehouseRetentionRecordServiceImpl extends BaseServiceImpl<Warehou
.eq(WarehouseRetentionScanEntity::getDeliveryId, warehouseRetentionScanDTOS.getDeliveryId())
);
AtomicBoolean saveFlah = new AtomicBoolean(false);
if (Func.isNotEmpty(retentionScanEntityList)) {
if (Func.isNotEmpty(warehouseRetentionScanDTOList)) {
BladeUser user = AuthUtil.getUser();
Map<Long, WarehouseRetentionScanEntity> retentionPackageMap = retentionScanEntityList.stream().collect(Collectors.toMap(WarehouseRetentionScanEntity::getOrderPackageId, Function.identity(), (k1, k2) -> k2));
warehouseRetentionScanDTOList.forEach(rs -> {
@ -291,15 +291,14 @@ public class WarehouseRetentionRecordServiceImpl extends BaseServiceImpl<Warehou
break;
default:
log.error(">>>>> rs.getConditions()={}", rs.getConditions());
}
}
});
}
//统计该滞留任务的包件数量
int retentionTotal = warehouseRetentionScanService.list(Wrappers.<WarehouseRetentionScanEntity>query().lambda()
.eq(WarehouseRetentionScanEntity::getDeliveryId, warehouseRetentionScanDTOS.getDeliveryId())
.eq(WarehouseRetentionScanEntity::getRefId, warehouseRetentionScanDTOS.getId())).stream().mapToInt(WarehouseRetentionScanEntity::getRetentionQuantity).sum();
.eq(WarehouseRetentionScanEntity::getDeliveryId, warehouseRetentionScanDTOS.getDeliveryId())).stream().mapToInt(WarehouseRetentionScanEntity::getRetentionQuantity)
.sum();
if (saveFlah.get()) {
return Resp.scanSuccess("操作成功", "共计滞留" + retentionTotal + "件");
} else {

Loading…
Cancel
Save