Browse Source

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

fix-sign
zhaoqiaobo 2 months ago
parent
commit
bc714081d0
  1. 55
      blade-service/logpm-report/src/main/java/com/logpm/report/mapper/ReportTimeMapper.xml
  2. 6
      blade-service/logpm-report/src/main/java/com/logpm/report/mapper/largeScreen/DeliveryDataMapper.xml
  3. 12
      blade-service/logpm-report/src/main/java/com/logpm/report/service/largeScreen/impl/CarsLoadDataServiceImpl.java
  4. 18
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java

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

@ -1391,6 +1391,18 @@
where ltad.waybill_id is not null
and ltad.create_time > '2024-10-22 00:00:00'
and lww.departure_warehouse_id != lww.destination_warehouse_id
<if test="param.startTime != null ">
and ltad.create_time &gt;= #{param.startTime}
</if>
<if test="param.endTime != null ">
and ltad.create_time &lt;= #{param.endTime}
</if>
<if test="param.openTimeStart != null ">
and lww.create_time &gt;= #{param.openTimeStart}
</if>
<if test="param.openTimeEnd != null ">
and lww.create_time &lt;= #{param.openTimeEnd}
</if>
<if test="param.brandList != null and param.brandList.size() > 0">
and lww.brand in
<foreach collection="param.brandList" item="item" open="(" separator="," close=")">
@ -1445,18 +1457,6 @@
<if test="param.loadCode != null and param.loadCode !='' ">
and GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) like concat('%',#{param.loadCode},'%')
</if>
<if test="param.startTime != null ">
and min(ltad.create_time) &gt;= #{param.startTime}
</if>
<if test="param.endTime != null ">
and min(ltad.create_time) &lt;= #{param.endTime}
</if>
<if test="param.openTimeStart != null ">
and min(lww.create_time) &gt;= #{param.openTimeStart}
</if>
<if test="param.openTimeEnd != null ">
and min(lww.create_time) &lt;= #{param.openTimeEnd}
</if>
</trim>
</select>
@ -1505,6 +1505,18 @@
where ltad.waybill_id is not null
and ltad.create_time > '2024-10-22 00:00:00'
and lww.departure_warehouse_id != lww.destination_warehouse_id
<if test="param.startTime != null ">
and ltad.create_time &gt;= #{param.startTime}
</if>
<if test="param.endTime != null ">
and ltad.create_time &lt;= #{param.endTime}
</if>
<if test="param.openTimeStart != null ">
and lww.create_time &gt;= #{param.openTimeStart}
</if>
<if test="param.openTimeEnd != null ">
and lww.create_time &lt;= #{param.openTimeEnd}
</if>
<if test="param.brandList != null and param.brandList.size() > 0">
and lww.brand in
<foreach collection="param.brandList" item="item" open="(" separator="," close=")">
@ -1544,12 +1556,6 @@
<if test="param.destinationWarehouseName != null and param.destinationWarehouseName !='' ">
and lww.destination_warehouse_name like concat('%',#{param.destinationWarehouseName},'%')
</if>
<if test="param.trainNumber != null and param.trainNumber !='' ">
and GROUP_CONCAT(DISTINCT ltad.train_number) like concat('%',#{param.trainNumber},'%')
</if>
<if test="param.loadCode != null and param.loadCode !='' ">
and GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) like concat('%',#{param.loadCode},'%')
</if>
group by ltad.order_code,
ltad.waybill_no,
ltad.brand,
@ -1561,23 +1567,10 @@
<trim prefix="HAVING" prefixOverrides="AND">
<if test="param.trainNumber != null and param.trainNumber !='' ">
and GROUP_CONCAT(DISTINCT ltad.train_number) like concat('%',#{param.trainNumber},'%')
GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) loadCode,
</if>
<if test="param.loadCode != null and param.loadCode !='' ">
and GROUP_CONCAT(DISTINCT IFNULL(ltcls.load_code,ltclsm.load_code)) like concat('%',#{param.loadCode},'%')
</if>
<if test="param.startTime != null ">
and min(ltad.create_time) &gt;= #{param.startTime}
</if>
<if test="param.endTime != null ">
and min(ltad.create_time) &lt;= #{param.endTime}
</if>
<if test="param.openTimeStart != null ">
and min(lww.create_time) &gt;= #{param.openTimeStart}
</if>
<if test="param.openTimeEnd != null ">
and min(lww.create_time) &lt;= #{param.openTimeEnd}
</if>
</trim>
</select>

6
blade-service/logpm-report/src/main/java/com/logpm/report/mapper/largeScreen/DeliveryDataMapper.xml

@ -4,7 +4,7 @@
<select id="getDeliveryAllData" resultType="com.logpm.report.vo.largeScreen.DeliveryDataVO">
select
count(*) as total,
sum(case when delivery_status = '3' then 0 else 1 end) as toBeSigned
count(case when delivery_status = '3' then null else 1 end) as toBeSigned
from logpm_platform.logpm_distribution_delivery_list
<if test="startTime != null">
where create_time between #{startTime} and #{endTime}
@ -13,7 +13,7 @@
<select id="getDelivery2BData" resultType="com.logpm.report.vo.largeScreen.DeliveryDataVO">
select
count(*) as total2B,
sum(case when delivery_status = '3' then 0 else 1 end) as toBeSigned2B
count(case when delivery_status = '3' then null else 1 end) as toBeSigned2B
from logpm_platform.logpm_distribution_delivery_list
where type = '1'
<if test="startTime != null">
@ -23,7 +23,7 @@
<select id="getDelivery2CData" resultType="com.logpm.report.vo.largeScreen.DeliveryDataVO">
select
count(*) as total2C,
sum(case when delivery_status = '3' then 0 else 1 end) as toBeSigned2C
count(case when delivery_status = '3' then null else 1 end) as toBeSigned2C
from logpm_platform.logpm_distribution_delivery_list
where type = '2'
<if test="startTime != null">

12
blade-service/logpm-report/src/main/java/com/logpm/report/service/largeScreen/impl/CarsLoadDataServiceImpl.java

@ -41,6 +41,18 @@ public class CarsLoadDataServiceImpl implements ICarsLoadDataService {
HashMap<Long, CareerLineDataVO> resultMap = new HashMap<>();
// 构建返回的事业线数据
for (DeptInfoVO deptInfoVO : careerLineMap.values()) {
if(deptInfoVO.getDeptName().contains("事业线") && !deptInfoVO.getDeptName().equals("事业线")){
resultMap.put(deptInfoVO.getId(), new CareerLineDataVO(deptInfoVO.getDeptName().replace("事业线", ""), monthDataInit()));
}
}
for (VehicleStowageDataVO vehicleStowageDataVO : vehicleStowageData) {
Long DeptId = warehouseDept.get(vehicleStowageDataVO.getWarehouseId());
if (!careerLineMap.containsKey(DeptId)) {

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

@ -1146,6 +1146,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
Long warehouseId = loadCarsDTO.getWarehouseId();
Integer unloadType = loadCarsDTO.getUnloadType();
Date date = new Date();
BasicdataWarehouseEntity warehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId);
if (Objects.isNull(warehouseEntity)) {
log.warn("#############unloadByLoadId: 仓库信息不存在 warehouseId={}", warehouseId);
@ -1319,6 +1321,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
newStockArticleEntity.setAllocation(null);
newStockArticleEntity.setTrays(null);
newStockArticleEntity.setCarsLoadNum(0);
newStockArticleEntity.setWarehouseEntryTime(date);
newStockArticleEntity.setWarehouseEntryTimeEnd(date);
Long orderId = distributionStockArticleClient.addData(newStockArticleEntity);
if (orderId != 0) {
@ -1340,6 +1344,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
newParcelListEntity.setWarehouse(warehouseEntity.getName());
newParcelListEntity.setStockArticleId(orderId);
newParcelListEntity.setQuantity(totalUnloadNum);
newParcelListEntity.setWarehouseEntryTimeEnd(date);
Long acceptWarehouseId = parcelListEntity.getAcceptWarehouseId();
if(warehouseId.equals(acceptWarehouseId)){
newParcelListEntity.setIsTransfer(0);
@ -1390,6 +1395,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
newStockArticleEntity.setHandQuantity(hQuantity);
newStockArticleEntity.setIncomingNum(incomingNum);
newStockArticleEntity.setWarehouseEntryTimeEnd(date);
List<DistributionParcelListEntity> listEntityList = distributionParcelListClient.findEntityListByOrderCode(orderCode, warehouseId);
//把listEntityList中所有元素的id放入一个集合
@ -1517,12 +1523,6 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
// 发送卸车作业事件
carsLoadAsyncService.sendStationArrivedEnter(carsLoadEntity,brands, AuthUtil.getUser(), warehouseEntity);
}
@ -5120,6 +5120,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
@Override
public R zeroUnloadEnter(List<Long> loadScanIds, Long warehouseId, String warehouseName) {
Date date = new Date();
List<TrunklineCarsLoadScanEntity> carsLoadScanEntityList = trunklineCarsLoadScanService.findListByIds(loadScanIds);
//排除carsLoadScanEntityList中unloadCheck为1的值
carsLoadScanEntityList = carsLoadScanEntityList.stream().filter(carsLoadScanEntity -> !carsLoadScanEntity.getUnloadCheck().equals(1)).collect(Collectors.toList());
@ -5181,6 +5183,8 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
newStockArticleEntity.setAllocation(null);
newStockArticleEntity.setTrays(null);
newStockArticleEntity.setCarsLoadNum(0);
newStockArticleEntity.setWarehouseEntryTime(date);
newStockArticleEntity.setWarehouseEntryTimeEnd(date);
Long orderId = distributionStockArticleClient.addData(newStockArticleEntity);
if (orderId != 0) {
@ -5202,6 +5206,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
newParcelListEntity.setWarehouse(warehouseName);
newParcelListEntity.setStockArticleId(orderId);
newParcelListEntity.setQuantity(totalUnloadNum);
newParcelListEntity.setWarehouseEntryTimeEnd(date);
Long acceptWarehouseId = parcelListEntity.getAcceptWarehouseId();
if(warehouseId.equals(acceptWarehouseId)){
newParcelListEntity.setIsTransfer(0);
@ -5248,6 +5253,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
newStockArticleEntity.setHandQuantity(hQuantity);
newStockArticleEntity.setIncomingNum(incomingNum);
newStockArticleEntity.setWarehouseEntryTimeEnd(date);
List<DistributionParcelListEntity> listEntityList = distributionParcelListClient.findEntityListByOrderCode(orderCode, warehouseId);
//把listEntityList中所有元素的id放入一个集合

Loading…
Cancel
Save