Browse Source

1.干线bug修复

pre-production
zhenghaoyu 1 month ago
parent
commit
78e480e9a8
  1. 3
      blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseWaybillClient.java
  2. 2
      blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/mapper/StatisticsOrderInfoMapper.xml
  3. 11
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/OpenOrderController.java
  4. 13
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java
  5. 7
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseWaybillClient.java
  6. 2
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseWaybillMapper.java
  7. 4
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseWaybillMapper.xml
  8. 2
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseWaybillService.java
  9. 5
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseWaybillServiceImpl.java

3
blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/feign/IWarehouseWaybillClient.java

@ -102,4 +102,7 @@ public interface IWarehouseWaybillClient {
@PostMapping(API_PREFIX + "/findWaybillVOByWaybillNoSet")
List<WarehouseWaybillVO> findWaybillVOByWaybillNoSet(@RequestBody Set<String> allWaybillNoSet);
@GetMapping(API_PREFIX+"/updateWaybillCondigneeId")
void updateWaybillCondigneeId(@RequestParam Long waybillId, @RequestParam Long newConsigneeId);
}

2
blade-service/logpm-statisticsdata/src/main/java/com/logpm/statistics/mapper/StatisticsOrderInfoMapper.xml

@ -105,7 +105,7 @@
and Locate(#{param.shipperMoblie},lww.shipper_mobile) > 0
</if>
<if test="param.consigneePerson != null and param.consigneePerson != '' ">
and Locate(#{param.consigneePerson},lww.consignee_person) > 0
and Locate(#{param.consigneePerson},lww.consignee_name) > 0
</if>
<if test="param.consigneeMobile != null and param.consigneeMobile != '' ">
and Locate(#{param.consigneeMobile},lww.consignee_mobile) > 0

11
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/OpenOrderController.java

@ -1401,12 +1401,13 @@ public class OpenOrderController {
//当前登录人选择的仓库
BasicdataWarehouseEntity myCurrentWarehouse = warehouseClient.getMyCurrentWarehouse();
if (Objects.isNull(myCurrentWarehouse)) {
log.warn(method + "仓库信息为空 myCurrentWarehouse={}", myCurrentWarehouse);
return R.fail(403, "多仓权限无法操作,请选择仓库");
if (!Objects.isNull(myCurrentWarehouse)) {
// log.warn(method + "仓库信息为空 myCurrentWarehouse={}", myCurrentWarehouse);
// return R.fail(403, "多仓权限无法操作,请选择仓库");
openOrderDTO.setWarehouseId(myCurrentWarehouse.getId());
openOrderDTO.setWarehouseName(myCurrentWarehouse.getName());
}
openOrderDTO.setWarehouseId(myCurrentWarehouse.getId());
openOrderDTO.setWarehouseName(myCurrentWarehouse.getName());
if (Objects.isNull(waybillId)) {
log.warn(method + "运单号id为空 waybillId={}", waybillId);

13
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java

@ -5457,9 +5457,16 @@ public class OpenOrderServiceImpl implements IOpenOrderService {
stringBuilder.append("收货单位:").append(consignee).append("-->").append(newConsignee).append(";");
waybillEntity.setConsignee(newConsignee);
waybillEntity.setConsigneeId(newConsigneeId);
BasicdataClientEntity basicdataClient = basicdataClientClient.findEntityById(newConsigneeId);
if(!Objects.isNull(basicdataClient)){
waybillEntity.setServiceType(basicdataClient.getTypeService());
if(Objects.isNull(newConsigneeId)){
waybillEntity.setServiceType(1);
warehouseWaybillClient.updateWaybillCondigneeId(waybillId,newConsigneeId);
}else{
BasicdataClientEntity basicdataClient = basicdataClientClient.findEntityById(newConsigneeId);
if(!Objects.isNull(basicdataClient)){
waybillEntity.setServiceType(basicdataClient.getTypeService());
}else{
waybillEntity.setServiceType(1);
}
}
}

7
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/feign/WarehouseWaybillClient.java

@ -10,13 +10,11 @@ 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.secure.utils.AuthUtil;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;
import springfox.documentation.annotations.ApiIgnore;
import java.util.Collections;
import java.util.List;
import java.util.Set;
@ -131,4 +129,9 @@ public class WarehouseWaybillClient implements IWarehouseWaybillClient {
public List<WarehouseWaybillVO> findWaybillVOByWaybillNoSet(Set<String> allWaybillNoSet) {
return warehouseWaybillService.findWaybillVOByWaybillNoSet(allWaybillNoSet);
}
@Override
public void updateWaybillCondigneeId(Long waybillId, Long newConsigneeId) {
warehouseWaybillService.updateWaybillCondigneeId(waybillId,newConsigneeId);
}
}

2
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseWaybillMapper.java

@ -79,4 +79,6 @@ public interface WarehouseWaybillMapper extends BaseMapper<WarehouseWaybillEntit
void deleteByWaybillIds(@Param("waybillIds") List<Long> waybillIds);
List<WarehouseWaybillVO> findWaybillVOByWaybillNoSet(@Param("waybillNos") Set<String> allWaybillNoSet);
void updateWaybillCondigneeId(@Param("waybillId") Long waybillId, @Param("newConsigneeId") Long newConsigneeId);
}

4
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseWaybillMapper.xml

@ -1276,4 +1276,8 @@
group by lww.id
</select>
<update id="updateWaybillCondigneeId">
update logpm_warehouse_waybill set consignee_id = #{newConsigneeId} where id = #{waybillId}
</update>
</mapper>

2
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/IWarehouseWaybillService.java

@ -91,4 +91,6 @@ public interface IWarehouseWaybillService extends BaseService<WarehouseWaybillEn
void deleteByWaybillIds(List<Long> waybillIds);
List<WarehouseWaybillVO> findWaybillVOByWaybillNoSet(Set<String> allWaybillNoSet);
void updateWaybillCondigneeId(Long waybillId, Long newConsigneeId);
}

5
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseWaybillServiceImpl.java

@ -1224,4 +1224,9 @@ public class WarehouseWaybillServiceImpl extends BaseServiceImpl<WarehouseWaybil
public List<WarehouseWaybillVO> findWaybillVOByWaybillNoSet(Set<String> allWaybillNoSet) {
return baseMapper.findWaybillVOByWaybillNoSet(allWaybillNoSet);
}
@Override
public void updateWaybillCondigneeId(Long waybillId, Long newConsigneeId) {
baseMapper.updateWaybillCondigneeId(waybillId,newConsigneeId);
}
}

Loading…
Cancel
Save