Browse Source

1.bug修复

dev
zhenghaoyu 4 days ago
parent
commit
f3f946f204
  1. 3
      blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/ExportWarehouseWaybillVO.java
  2. 1
      blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/service/impl/AftersalesAbnormalRecordServiceImpl.java
  3. 16
      blade-service/logpm-report/src/main/java/com/logpm/report/mapper/ReportTimeMapper.xml
  4. 8
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/CarsLoadController.java
  5. 1
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineCarsLoadService.java
  6. 5
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/CarsLoadAsyncServiceImpl.java
  7. 5
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java
  8. 25
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceServiceImpl.java
  9. 16
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadLinePhotoEntityServiceImpl.java
  10. 19
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java
  11. 6
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseWaybillMapper.xml

3
blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/ExportWarehouseWaybillVO.java

@ -125,6 +125,9 @@ public class ExportWarehouseWaybillVO implements Serializable {
@ExcelProperty(value = "仓储操作费")
private BigDecimal handlingFee;
@ExcelProperty(value = "安装费")
private BigDecimal installFee;
@ExcelProperty(value = "申明价值")
private BigDecimal claimingValue;

1
blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/service/impl/AftersalesAbnormalRecordServiceImpl.java

@ -503,6 +503,7 @@ public class AftersalesAbnormalRecordServiceImpl extends BaseServiceImpl<Aftersa
carsLoadScanEntity.setUnloadNodeName(warehouseEntity.getName());
carsLoadScanEntity.setUnloadUserName(AuthUtil.getNickName());
carsLoadScanEntity.setUnloadTime(new Date());
carsLoadScanEntity.setUnloadCheck(1);
trunklineCarsLoadScanClient.updateEntity(carsLoadScanEntity);
String waybillNo = carsLoadScanEntity.getWaybillNo();

16
blade-service/logpm-report/src/main/java/com/logpm/report/mapper/ReportTimeMapper.xml

@ -686,11 +686,11 @@
lww.destination_warehouse_name destinationWarehouseName,
ldsa.warehouse warehouseName,
ldsa.brand brand,
sum(ldsa.total_number) incomingNum,
sum(ldsa.incoming_num) incomingNum,
IFNULL(sum(ltcls.num),0) outNum,
sum(if(ltcll.start_date &lt;= DATE_ADD( ldsa.create_time, INTERVAL #{param.hoursTime} HOUR ),1,0)) outOnTimeNum,
IFNULL(round(sum(if(ltcll.start_date &lt;= DATE_ADD( ldsa.create_time, INTERVAL #{param.hoursTime} HOUR ),1,0))/sum(ltcls.num)*100,2),'0.00') outOnTimeRate,
round(sum(TIMESTAMPDIFF(SECOND, ldsa.create_time, ltcll.start_date))/sum(ltcls.num)/3600,1) avgTime
sum(if(ltcll.start_date &lt;= DATE_ADD( ldsa.create_time, INTERVAL #{param.hoursTime} HOUR ),ltcls.num,0)) outOnTimeNum,
IFNULL(round(sum(if(ltcll.start_date &lt;= DATE_ADD( ldsa.create_time, INTERVAL #{param.hoursTime} HOUR ),ltcls.num,0))/sum(ldsa.incoming_num)*100,2),'0.00') outOnTimeRate,
round(sum(TIMESTAMPDIFF(SECOND, ldsa.create_time, ltcll.start_date)*ltcls.num)/sum(ltcls.num)/3600,1) avgTime
from logpm_distribution_stock_article ldsa
left join logpm_warehouse_warehouse waw on waw.id = ldsa.warehouse_id
left join logpm_warehouse_waybill lww on lww.waybill_no = ldsa.order_code
@ -750,11 +750,11 @@
lww.destination_warehouse_name destinationWarehouseName,
ldsa.warehouse warehouseName,
ldsa.brand brand,
sum(ldsa.total_number) incomingNum,
sum(ldsa.incoming_num) incomingNum,
IFNULL(sum(ltcls.num),0) outNum,
sum(if(ltcll.start_date &lt;= DATE_ADD( ldsa.create_time, INTERVAL #{param.hoursTime} HOUR ),1,0)) outOnTimeNum,
IFNULL(concat(round(sum(if(ltcll.start_date &lt;= DATE_ADD( ldsa.create_time, INTERVAL #{param.hoursTime} HOUR ),1,0))/sum(ltcls.num)*100,2),'%'),'0.00%') outOnTimeRate,
round(sum(TIMESTAMPDIFF(SECOND, ldsa.create_time, ltcll.start_date))/sum(ltcls.num)/3600,1) avgTime
sum(if(ltcll.start_date &lt;= DATE_ADD( ldsa.create_time, INTERVAL #{param.hoursTime} HOUR ),ltcls.num,0)) outOnTimeNum,
IFNULL(concat(round(sum(if(ltcll.start_date &lt;= DATE_ADD( ldsa.create_time, INTERVAL #{param.hoursTime} HOUR ),ltcls.num,0))/sum(ldsa.incoming_num)*100,2),'%'),'0.00%') outOnTimeRate,
round(sum(TIMESTAMPDIFF(SECOND, ldsa.create_time, ltcll.start_date)*ltcls.num)/sum(ltcls.num)/3600,1) avgTime
from logpm_distribution_stock_article ldsa
left join logpm_warehouse_warehouse waw on waw.id = ldsa.warehouse_id
left join logpm_warehouse_waybill lww on lww.waybill_no = ldsa.order_code

8
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/CarsLoadController.java

@ -1094,6 +1094,14 @@ public class CarsLoadController {
// }
carsLoadService.unloadByLoadId(loadCarsDTO);
try{
carsLoadService.sendStationArrivedEnter(loadCarsDTO);
}catch (Exception e){
log.error("############sendOrders: 发送卸车数据异常",e);
}
return R.success("操作成功");
} catch (CustomerException e) {
log.error(e.message, e);

1
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/ITrunklineCarsLoadService.java

@ -285,4 +285,5 @@ public interface ITrunklineCarsLoadService extends BaseService<TrunklineCarsLoad
void saveCostShareRecord(Long loadId);
void sendStationArrivedEnter(LoadCarsDTO loadCarsDTO);
}

5
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/CarsLoadAsyncServiceImpl.java

@ -19,9 +19,7 @@ import com.logpm.basic.feign.IBasicCarModelClient;
import com.logpm.basicdata.entity.BasicdataWarehouseEntity;
import com.logpm.basicdata.feign.IBasicdataWarehouseClient;
import com.logpm.distribution.entity.DistributionParcelListEntity;
import com.logpm.distribution.entity.DistributionReservationEntity;
import com.logpm.distribution.entity.DistributionStockArticleEntity;
import com.logpm.distribution.entity.DistrilbutionBillLadingEntity;
import com.logpm.distribution.feign.IDistributionParcelListClient;
import com.logpm.distribution.feign.IDistributionStockArticleClient;
import com.logpm.factorydata.enums.BrandEnums;
@ -50,7 +48,6 @@ import org.springblade.common.exception.CustomerException;
import org.springblade.common.model.FanoutMsg;
import org.springblade.common.model.NodeFanoutMsg;
import org.springblade.common.model.PackageData;
import org.springblade.common.model.StockUpVO;
import org.springblade.common.model.workNode.StationArrivedByLineStationVO;
import org.springblade.common.model.workNode.StationArrivedEnterVO;
import org.springblade.common.utils.CommonUtil;
@ -477,7 +474,7 @@ public class CarsLoadAsyncServiceImpl implements ICarsLoadAsyncService {
abnormalRecordEntity.setOrderPackageCode(scanCode);
abnormalRecordEntity.setUpUserId(userId);
abnormalRecordEntity.setUpUserName(nickName);
abnormalRecordEntity.setAbnormalStatus(0);
abnormalRecordEntity.setAbnormalStatus(1);
abnormalRecordEntity.setUpTime(new Date());
abnormalRecordEntity.setAssociationId(scanId);
abnormalRecordEntity.setAssociationType(1);

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

@ -2909,6 +2909,9 @@ public class OpenOrderServiceImpl implements IOpenOrderService {
String warehouseName = openOrderDTO.getWarehouseName();
String editReson = openOrderDTO.getEditReson();
String refer = openOrderDTO.getRefer();
if(StringUtil.isBlank(refer)){
refer = " ";
}
List<TrunklineAdvanceDetailEntity> updateAdvanceDetailList = openOrderDTO.getUpdateAdvanceDetailList();
WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillId(waybillId);
@ -2986,6 +2989,8 @@ public class OpenOrderServiceImpl implements IOpenOrderService {
String updateMsg = verifyUpdateData(openOrderDTO, waybillEntity);
waybillEntity.setUpdateStatus(1);
warehouseWaybillClient.updateEntity(waybillEntity);
if (CollUtil.isNotEmpty(updateAdvanceDetailList)) {

25
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineAdvanceServiceImpl.java

@ -13,11 +13,7 @@ import com.logpm.basicdata.entity.BasicdataBrandEntity;
import com.logpm.basicdata.entity.BasicdataClientEntity;
import com.logpm.basicdata.entity.BasicdataStoreBusinessEntity;
import com.logpm.basicdata.entity.BasicdataWarehouseEntity;
import com.logpm.basicdata.feign.IBasicdataBrandClient;
import com.logpm.basicdata.feign.IBasicdataClientClient;
import com.logpm.basicdata.feign.IBasicdataStoreBusinessClient;
import com.logpm.basicdata.feign.IBasicdataTripartiteMallClient;
import com.logpm.basicdata.feign.IBasicdataWarehouseClient;
import com.logpm.basicdata.feign.*;
import com.logpm.distribution.dto.FindParamterDTO;
import com.logpm.distribution.entity.DistributionParcelListEntity;
import com.logpm.distribution.entity.DistributionStockArticleEntity;
@ -31,8 +27,6 @@ import com.logpm.trunkline.entity.TrunklineAdvanceEntity;
import com.logpm.trunkline.mapper.TrunklineAdvanceMapper;
import com.logpm.trunkline.service.ITrunklineAdvanceDetailService;
import com.logpm.trunkline.service.ITrunklineAdvanceService;
import com.logpm.trunkline.service.ITrunklineCarsLoadService;
import com.logpm.trunkline.service.ITrunklineDetailProductService;
import com.logpm.trunkline.vo.CustomerInfoVO;
import com.logpm.trunkline.vo.OpenOrderVO;
import com.logpm.trunkline.vo.TrunklineAdvanceVO;
@ -51,14 +45,7 @@ import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Set;
import java.util.*;
import java.util.function.Function;
import java.util.stream.Collectors;
@ -635,7 +622,13 @@ public class TrunklineAdvanceServiceImpl extends BaseServiceImpl<TrunklineAdvanc
}
Integer stockCount = waybillEntity.getStockCount();
waybillEntity.setStockCount(stockCount + 1);
Integer totalCount = waybillEntity.getTotalCount();
if(stockCount >= totalCount){
waybillEntity.setStockCount(totalCount);
}else{
waybillEntity.setStockCount(stockCount + 1);
}
}
parcelList.setConditions(1);

16
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadLinePhotoEntityServiceImpl.java

@ -1,5 +1,6 @@
package com.logpm.trunkline.service.impl;
import cn.hutool.core.collection.CollUtil;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.logpm.trunkline.entity.TrunklineCarsLoadLinePhotoEntity;
import com.logpm.trunkline.mapper.TrunklineCarsLoadLinePhotoMapper;
@ -9,6 +10,7 @@ import lombok.extern.slf4j.Slf4j;
import org.springblade.core.mp.base.BaseServiceImpl;
import org.springframework.stereotype.Service;
import java.util.ArrayList;
import java.util.List;
@Service
@ -29,10 +31,14 @@ public class TrunklineCarsLoadLinePhotoEntityServiceImpl extends BaseServiceImpl
@Override
public List<TrunklineCarsLoadLinePhotoEntity> findListByLoadIdListAndWarehouseId(List<Long> idList, Long warehouseId) {
QueryWrapper<TrunklineCarsLoadLinePhotoEntity> queryWrapper = new QueryWrapper<>();
queryWrapper.in("load_id",idList)
.eq("warehouse_id",warehouseId);
List<TrunklineCarsLoadLinePhotoEntity> trunklineCarsLoadLinePhotoEntities = baseMapper.selectList(queryWrapper);
return trunklineCarsLoadLinePhotoEntities;
List<TrunklineCarsLoadLinePhotoEntity> ls = new ArrayList<>();
if(CollUtil.isNotEmpty(idList)){
QueryWrapper<TrunklineCarsLoadLinePhotoEntity> queryWrapper = new QueryWrapper<>();
queryWrapper.in("load_id",idList)
.eq("warehouse_id",warehouseId);
ls = baseMapper.selectList(queryWrapper);
}
return ls;
}
}

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

@ -1527,9 +1527,9 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
}
trunklineCarsLoadLineService.updateById(updateUnloadStatus);
String brands = trunklineCarsLoadScanService.findBrandNameByCarLoadCode(carsLoadEntity.getCarsNo());
// 发送卸车作业事件
carsLoadAsyncService.sendStationArrivedEnter(carsLoadEntity,brands, AuthUtil.getUser(), warehouseEntity);
// String brands = trunklineCarsLoadScanService.findBrandNameByCarLoadCode(carsLoadEntity.getCarsNo());
// // 发送卸车作业事件
// carsLoadAsyncService.sendStationArrivedEnter(carsLoadEntity,brands, AuthUtil.getUser(), warehouseEntity);
}
@ -5590,6 +5590,19 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
}
@Override
public void sendStationArrivedEnter(LoadCarsDTO loadCarsDTO) {
Long warehouseId = loadCarsDTO.getWarehouseId();
Long loadId = loadCarsDTO.getLoadId();
TrunklineCarsLoadEntity carsLoadEntity = baseMapper.selectById(loadId);
BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId);
String brands = trunklineCarsLoadScanService.findBrandNameByCarLoadCode(carsLoadEntity.getCarsNo());
// 发送卸车作业事件
carsLoadAsyncService.sendStationArrivedEnter(carsLoadEntity,brands, AuthUtil.getUser(), warehouseEntity);
}
private void updateParcelListToWarehouse(TrunklineAdvanceDetailEntity advanceDetailEntity, Long warehouseId, String status) {
String orderPackageCode = advanceDetailEntity.getOrderPackageCode();
String orderCode = advanceDetailEntity.getOrderCode();

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

@ -195,6 +195,7 @@
lww.warehouse_management_fee warehouseManagementFee,
lww.sorting_fee sortingFee,
lww.handling_fee handlingFee,
lww.install_fee installFee,
lww.claiming_value claimingValue,
lww.rebate rebate,
lww.urgency urgency,
@ -216,6 +217,7 @@
lww.sign_check_user_name signCheckUserName,
lww.sign_check_time signCheckTime,
IFNULL(lww.check_status,0) checkStatus,
IFNULL(lww.update_status,0) updateStatus,
lww.check_reson checkReson,
lww.check_remark checkRemark,
lww.check_user_name checkUserName,
@ -1016,6 +1018,7 @@
lww.warehouse_management_fee warehouseManagementFee,
lww.sorting_fee sortingFee,
lww.handling_fee handlingFee,
lww.install_fee installFee,
lww.claiming_value claimingValue,
lww.rebate rebate,
lww.pay_type payType,
@ -1034,7 +1037,8 @@
lww.freeze_status freezeStatus,
lww.freeze_user_name freezeUserName,
lww.freeze_time freezeTime,
lww.check_status checkStatus,
IFNULL(lww.check_status,0) checkStatus,
IFNULL(lww.update_status,0) updateStatus,
lww.check_reson checkReson,
lww.check_remark checkRemark,
lww.check_user_name checkUserName,

Loading…
Cancel
Save