Browse Source

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

dist.1.3.0
chenlong 8 months ago
parent
commit
35ea1790ef
  1. 1
      blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/dto/LoadCarsDTO.java
  2. 32
      blade-service/logpm-aftersales/src/main/java/com/logpm/aftersales/service/impl/AftersalesAbnormalRecordServiceImpl.java
  3. 1
      blade-service/logpm-basic/src/main/java/com/logpm/basic/BasicApplication.java
  4. 1
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/BasicDataApplication.java
  5. 4
      blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataPriceServiceImpl.java
  6. 1
      blade-service/logpm-business/src/main/java/com/logpm/business/BusinessApplication.java
  7. 1
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/DistributionApplication.java
  8. 10
      blade-service/logpm-report/src/main/java/com/logpm/report/util/QueryUtil.java
  9. 1
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingWaybillMapper.xml
  10. 4
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineCarsLoadMapper.xml
  11. 2
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineCarsLoadScanMapper.xml
  12. 21
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java
  13. 2
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineBillladingServiceImpl.java
  14. 16
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java
  15. 38
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineWaybillPackageServiceImpl.java
  16. 1
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/WarehouseApplication.java
  17. 2
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/QuestDetailServiceImpl.java

1
blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/dto/LoadCarsDTO.java

@ -63,6 +63,7 @@ public class LoadCarsDTO implements Serializable {
private List<ProductInfoDTO> productInfoList = new ArrayList<>();
private String goodsName;
private String orderCode;
private String trayCode;

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

@ -13,8 +13,12 @@ import com.logpm.distribution.entity.DistributionParcelListEntity;
import com.logpm.distribution.entity.DistributionStockArticleEntity;
import com.logpm.distribution.feign.IDistributionParcelListClient;
import com.logpm.distribution.feign.IDistributionStockArticleClient;
import com.logpm.trunkline.dto.AddWaybillTrackDTO;
import com.logpm.trunkline.entity.TrunklineCarsLoadScanEntity;
import com.logpm.trunkline.feign.ITrunklineCarsLoadScanClient;
import com.logpm.trunkline.feign.ITrunklineWaybillTrackClient;
import com.logpm.warehouse.entity.WarehouseWaybillEntity;
import com.logpm.warehouse.feign.IWarehouseWaybillClient;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springblade.common.utils.CommonUtil;
@ -43,6 +47,10 @@ public class AftersalesAbnormalRecordServiceImpl extends BaseServiceImpl<Aftersa
private final IDistributionParcelListClient parcelListClient;
private final IWarehouseWaybillClient warehouseWaybillClient;
private final ITrunklineWaybillTrackClient trunklineWaybillTrackClient;
@Override
public R findPageList(AbnormalRecordDTO abnormalRecordDTO) {
IPage<Object> page = new Page<>();
@ -268,7 +276,7 @@ public class AftersalesAbnormalRecordServiceImpl extends BaseServiceImpl<Aftersa
}
}else{
stockArticleClient.addHandQuantity(currentStockArticleEntity.getId(),enterNum);
stockArticleClient.addHandQuantityAndIncomingNum(currentStockArticleEntity.getId(),enterNum);
}
abnormalRecordEntity.setRemark("差异"+enterNum+"件数入库本仓,原仓返回"+diff+"件");
@ -276,6 +284,28 @@ public class AftersalesAbnormalRecordServiceImpl extends BaseServiceImpl<Aftersa
carsLoadScanEntity.setScanStatus("2");
carsLoadScanEntity.setUnloadNum(carsLoadScanEntity.getUnloadNum()+enterNum);
trunklineCarsLoadScanClient.updateEntity(carsLoadScanEntity);
String waybillNo = carsLoadScanEntity.getWaybillNo();
WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillNo(waybillNo);
Long waybillId = null;
if(!Objects.isNull(waybillEntity)){
waybillId = waybillEntity.getId();
}
String warehouseName = warehouseEntity.getName();
String operationRemark = warehouseName+"干线异常列表卸车,总数/卸车数:"+num+"/"+enterNum+",卸车时间"+ CommonUtil.dateToStringGeneral(new Date());
AddWaybillTrackDTO addWaybillTrackDTO = new AddWaybillTrackDTO();
addWaybillTrackDTO.setTrackType("80");
addWaybillTrackDTO.setWaybillId(waybillId);
addWaybillTrackDTO.setWaybillNo(waybillNo);
addWaybillTrackDTO.setRefer("异常列表卸车");
addWaybillTrackDTO.setOperationRemark(operationRemark);
addWaybillTrackDTO.setUserId(AuthUtil.getUserId());
addWaybillTrackDTO.setWarehouseId(warehouseId);
addWaybillTrackDTO.setWarehouseName(warehouseName);
addWaybillTrackDTO.setNickName(AuthUtil.getNickName());
trunklineWaybillTrackClient.addWaybillLog(addWaybillTrackDTO);
}
}
}

1
blade-service/logpm-basic/src/main/java/com/logpm/basic/BasicApplication.java

@ -13,7 +13,6 @@ import org.springblade.core.transaction.annotation.SeataCloudApplication;
* @author lmy
*/
@BladeCloudApplication
@SeataCloudApplication
public class BasicApplication {
public static void main(String[] args) {

1
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/BasicDataApplication.java

@ -13,7 +13,6 @@ import org.springblade.core.transaction.annotation.SeataCloudApplication;
*/
@BladeCloudApplication
@SeataCloudApplication
public class BasicDataApplication {
public static void main(String[] args) {

4
blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/service/impl/BasicdataPriceServiceImpl.java

@ -3456,6 +3456,8 @@ public class BasicdataPriceServiceImpl extends BaseServiceImpl<BasicdataPriceMap
} catch (Exception e) {
rowMessage.append("生效时间格式错误,例:2020-01-01;");
}
} else {
rowMessage.append("生效时间不能为空");
}
if (StrUtil.isNotEmpty(priceExcel.getExpiryTime())) {
// 校验是否为日期格式
@ -3464,6 +3466,8 @@ public class BasicdataPriceServiceImpl extends BaseServiceImpl<BasicdataPriceMap
} catch (Exception e) {
rowMessage.append("到期时间格式错误,例:2020-01-01;");
}
} else {
rowMessage.append("到期时间不能为空");
}
if (!ObjectUtil.isAllEmpty(startTime, endTime)) {
// 校验时间大小关系

1
blade-service/logpm-business/src/main/java/com/logpm/business/BusinessApplication.java

@ -7,7 +7,6 @@ import org.springblade.core.launch.BladeApplication;
import org.springblade.core.transaction.annotation.SeataCloudApplication;
@BladeCloudApplication
@SeataCloudApplication
public class BusinessApplication {
public static void main(String[] args) {

1
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/DistributionApplication.java

@ -27,7 +27,6 @@ import org.springblade.core.transaction.annotation.SeataCloudApplication;
* @author Chill
*/
@BladeCloudApplication
@SeataCloudApplication
public class DistributionApplication {
public static void main(String[] args) {

10
blade-service/logpm-report/src/main/java/com/logpm/report/util/QueryUtil.java

@ -9,6 +9,7 @@ import com.logpm.report.constant.ReportConstants;
import org.springblade.core.mp.support.Condition;
import java.util.Date;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
@ -28,8 +29,13 @@ public class QueryUtil {
* @return
*/
public static QueryWrapper buildQueryWrapper(Object vo, Class classz) {
Map<String, Object> stringObjectMap = BeanUtil.beanToMap(vo);
return Condition.getQueryWrapper(stringObjectMap, classz);
Map<String, Object> stringObjectMap = BeanUtil.beanToMap(vo, new LinkedHashMap<>(), true, false);
Map<String, Object> result = new LinkedHashMap<>();
for (Map.Entry<String, Object> entry : stringObjectMap.entrySet()) {
String keyWithSuffix = entry.getKey() + "_equal";
result.put(keyWithSuffix, entry.getValue());
}
return Condition.getQueryWrapper(result, classz);
}
/**

1
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineBillladingWaybillMapper.xml

@ -58,7 +58,6 @@
left join logpm_warehouse_waybill lww on lww.waybill_no = ltbw.waybill_no
where ltbw.billlading_id = #{billladingId}
and ltbw.is_deleted = 0
and ltbw.real_num > 0
</select>
<update id="updateDataByBillladingWaybillId" >

4
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineCarsLoadMapper.xml

@ -281,8 +281,8 @@
<if test="param.destinationWarehouseName != null and param.destinationWarehouseName != ''">
and lww.destination_warehouse_name like concat('%',#{param.destinationWarehouseName},'%')
</if>
<if test="param.productName != null and param.productName != ''">
and lww.goods_name like concat('%',#{param.productName},'%')
<if test="param.goodsName != null and param.goodsName != ''">
and lww.goods_name like concat('%',#{param.goodsName},'%')
</if>
<if test="param.shipper != null and param.shipper != ''">
and lww.shipper like concat('%',#{param.shipper},'%')

2
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/mapper/TrunklineCarsLoadScanMapper.xml

@ -509,7 +509,7 @@
<select id="findUnloadLoadScanWaybillList" resultType="com.logpm.trunkline.vo.LoadScanWaybillVO">
select waybill_no waybillNo,
sum(num) num,
sum(IF(unload_node_id = null,0,unload_num)) unloadNum
IFNULL(sum(IF(unload_node_id = null,0,unload_num)),0) unloadNum
from logpm_trunkline_cars_load_scan
where load_id = #{loadId}
and final_node_id = #{nodeId}

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

@ -1823,15 +1823,18 @@ public class OpenOrderServiceImpl implements IOpenOrderService {
Map<String, ImportStandardOuPaiDTO> importStandardOuPaiDTOMap = importStandardOuPaiDTOS.stream().collect(Collectors.toMap(ImportStandardOuPaiDTO::getOrderPackageCode, Function.identity(), (a, b) -> a));
List<TrunklineAdvanceDetailEntity> hasAdvanceDetailList = advanceDetailService.findListByOrderPackageCodeList(hasOrderPackageCodeList);
hasAdvanceDetailList.forEach(advanceDetailEntity -> {
ImportStandardOuPaiDTO importStandardOuPaiDTO = importStandardOuPaiDTOMap.get(advanceDetailEntity.getOrderPackageCode());
TrunklineAdvanceDetailEntity updateMaterialEntity = new TrunklineAdvanceDetailEntity();
updateMaterialEntity.setId(advanceDetailEntity.getId());
updateMaterialEntity.setMaterialCode(importStandardOuPaiDTO.getMaterialCode());
updateMaterialEntity.setMaterialName(importStandardOuPaiDTO.getMaterialName());
updateMaterialEntity.setFirstPackName(importStandardOuPaiDTO.getFirstsName());
updateMaterialEntity.setSecondPackName(importStandardOuPaiDTO.getSencodsName());
updateMaterialEntity.setThirdPackName(importStandardOuPaiDTO.getThirdsName());
updateMaterialList.add(updateMaterialEntity);
Long waybillId = advanceDetailEntity.getWaybillId();
if(Objects.isNull(waybillId)){
ImportStandardOuPaiDTO importStandardOuPaiDTO = importStandardOuPaiDTOMap.get(advanceDetailEntity.getOrderPackageCode());
TrunklineAdvanceDetailEntity updateMaterialEntity = new TrunklineAdvanceDetailEntity();
updateMaterialEntity.setId(advanceDetailEntity.getId());
updateMaterialEntity.setMaterialCode(importStandardOuPaiDTO.getMaterialCode());
updateMaterialEntity.setMaterialName(importStandardOuPaiDTO.getMaterialName());
updateMaterialEntity.setFirstPackName(importStandardOuPaiDTO.getFirstsName());
updateMaterialEntity.setSecondPackName(importStandardOuPaiDTO.getSencodsName());
updateMaterialEntity.setThirdPackName(importStandardOuPaiDTO.getThirdsName());
updateMaterialList.add(updateMaterialEntity);
}
});
if(CollUtil.isNotEmpty(updateMaterialList)){

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

@ -286,7 +286,7 @@ public class TrunklineBillladingServiceImpl extends BaseServiceImpl<TrunklineBil
BeanUtil.copy(billladingWaybillVO,billladingWaybillEntity);
billladingWaybillEntity.setBillladingId(billladingId);
billladingWaybillEntity.setBilladingCode(billladingCode);
billladingWaybillEntity.setRealNum(0);
billladingWaybillEntity.setRealNum(planNum);
billladingWaybillEntity.setRealWeight(BigDecimal.ZERO);
billladingWaybillEntity.setRealVolume(BigDecimal.ZERO);
billladingWaybillEntity.setBillladingFee(BigDecimal.ZERO);

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

@ -1127,9 +1127,9 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
//卸车数大于实际装车数
throw new CustomerException(405,"零担订单"+orderCode+"卸车件数已大于实际装车件数,请去调整补录");
}else {
if(unloadNum < realNum){
distributionStockArticleClient.addHandQuantity(stockArticleEntity.getId(),realNum-unloadNum);
}
// if(unloadNum < realNum){
// distributionStockArticleClient.addHandQuantity(stockArticleEntity.getId(),realNum-unloadNum);
// }
DistributionStockArticleEntity newStockArticleEntity = distributionStockArticleClient.findStockArticleByOrderCodeAndWarehouseId(orderCode, warehouseId);
if (Objects.isNull(newStockArticleEntity)) {
@ -1814,7 +1814,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
String enterTimeStartStr = loadCarsDTO.getEnterTimeStartStr();
String enterTimeEndStr = loadCarsDTO.getEnterTimeEndStr();
loadCarsDTO.setEnterTimeStart(CommonUtil.getStartByDateStr(enterTimeStartStr));
loadCarsDTO.setEnterTimeEnd(CommonUtil.getStartByDateStr(enterTimeEndStr));
loadCarsDTO.setEnterTimeEnd(CommonUtil.getEndByDateStr(enterTimeEndStr));
IPage<CarsLoadAllOrderVO> pageList = baseMapper.findAllOrderList(page, loadCarsDTO);
return R.data(pageList);
@ -4554,7 +4554,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
// carsLoadAsyncService.dealwithAfterAbnormalPackage(e.getOrderPackageCode(), warehouseId, warehouseName, carsLoadEntity.getCarsNo(), userId, deptId, nickName);
});
String content = "包件在 " + warehouseName + "卸车卸车方式:" + IncomingTypeEnum.getValue(incomingType);
String content = "包件在 " + warehouseName + "卸车,车次号:"+carsNo+",卸车方式:" + IncomingTypeEnum.getValue(incomingType);
List<WarehousePackageTrackLogEntity> list = new ArrayList<>();
orderPackageCodes.forEach(orderPackageCode -> {
@ -5579,7 +5579,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
warehousePackageTrackLogEntity.setWarehouseId(warehouseId);
warehousePackageTrackLogEntity.setWarehouseName(warehouseName);
warehousePackageTrackLogEntity.setWorkNode(WorkNodeEnums.INITIAL_WAREHOUSE_LOADING.getCode());
String content = "包件在 " + warehouseName + "手动批量装车,配载计划目的仓 " + carsLoadScanEntity.getFinalNodeName() + ",数据来源仓库 " + warehouseName;
String content = "包件在 " + warehouseName + "手动批量装车,车次号:"+carsNo+",配载计划目的仓 " + carsLoadScanEntity.getFinalNodeName() + ",数据来源仓库 " + warehouseName;
warehousePackageTrackLogEntity.setContent(content);
warehousePackageTrackLogEntity.setOperator(nickName);
addPackageTrackLogList.add(warehousePackageTrackLogEntity);
@ -6478,7 +6478,9 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
String loadStatus = trunklineCarsLoadVO.getLoadStatus();
trunklineCarsLoadVO.setLoadStatus(DictBizCache.getValue(DictBizConstant.CARS_LOAD_STATUS, loadStatus));
trunklineCarsLoadVO.setStockCarsNum(realLoadingNumber - unloadNumber);
int i = realLoadingNumber - unloadNumber;
if(i < 0) i = 0;
trunklineCarsLoadVO.setStockCarsNum(i);
trunklineCarsLoadVO.setLoadScanOrderList(loadScanOrderList);
trunklineCarsLoadVO.setZeroList(zeroList);
trunklineCarsLoadVO.setExceptionList(exceptionList);

38
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineWaybillPackageServiceImpl.java

@ -203,29 +203,31 @@ public class TrunklineWaybillPackageServiceImpl extends BaseServiceImpl<Trunklin
packageStatus = 10;
}
if(!Objects.isNull(packageStatus)){
List<TrunklineWaybillPackageEntity> waybillPackageEntities = new ArrayList<>();
Set<Long> waybillIds = new HashSet<>();
QueryWrapper<TrunklineWaybillPackageEntity> queryWrapper = new QueryWrapper<>();
queryWrapper.in("order_package_code",orderPackageCodes)
.eq("is_deleted",0);
List<TrunklineWaybillPackageEntity> trunklineWaybillPackageEntities = baseMapper.selectList(queryWrapper);
if(!trunklineWaybillPackageEntities.isEmpty()){
for (TrunklineWaybillPackageEntity trunklineWaybillPackageEntity : trunklineWaybillPackageEntities) {
trunklineWaybillPackageEntity.setPackageStatus(packageStatus);
waybillIds.add(trunklineWaybillPackageEntity.getWaybillId());
}
if(CollUtil.isNotEmpty(orderPackageCodes)){
if(!Objects.isNull(packageStatus)){
List<TrunklineWaybillPackageEntity> waybillPackageEntities = new ArrayList<>();
Set<Long> waybillIds = new HashSet<>();
QueryWrapper<TrunklineWaybillPackageEntity> queryWrapper = new QueryWrapper<>();
queryWrapper.in("order_package_code",orderPackageCodes)
.eq("is_deleted",0);
List<TrunklineWaybillPackageEntity> trunklineWaybillPackageEntities = baseMapper.selectList(queryWrapper);
if(!trunklineWaybillPackageEntities.isEmpty()){
for (TrunklineWaybillPackageEntity trunklineWaybillPackageEntity : trunklineWaybillPackageEntities) {
trunklineWaybillPackageEntity.setPackageStatus(packageStatus);
waybillIds.add(trunklineWaybillPackageEntity.getWaybillId());
}
updateBatchById(trunklineWaybillPackageEntities);
updateBatchById(trunklineWaybillPackageEntities);
for (Long waybillId : waybillIds) {
WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillId(waybillId);
updateWaybillStatus(waybillEntity);
for (Long waybillId : waybillIds) {
WarehouseWaybillEntity waybillEntity = warehouseWaybillClient.findByWaybillId(waybillId);
updateWaybillStatus(waybillEntity);
}
}
}
}
packageTrackLogAsyncService.sendPackageWorkNodeFanout(orderPackageCodes,workNode,warehouseId, map);
packageTrackLogAsyncService.sendPackageWorkNodeFanout(orderPackageCodes,workNode,warehouseId, map);
}
}
}

1
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/WarehouseApplication.java

@ -27,7 +27,6 @@ import org.springblade.core.transaction.annotation.SeataCloudApplication;
* @author Chill
*/
@BladeCloudApplication
@SeataCloudApplication
public class WarehouseApplication {
public static void main(String[] args) {

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

@ -22,6 +22,7 @@ import com.logpm.warehouse.vo.QuestDetailVO;
import com.logpm.warehouse.excel.QuestDetailExcel;
import com.logpm.warehouse.mapper.QuestDetailMapper;
import com.logpm.warehouse.service.IQuestDetailService;
import org.springblade.system.cache.DictBizCache;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
@ -49,6 +50,7 @@ public class QuestDetailServiceImpl extends BaseServiceImpl<QuestDetailMapper, Q
//questDetailList.forEach(questDetail -> {
// questDetail.setTypeName(DictCache.getValue(DictEnum.YES_NO, QuestDetail.getType()));
//});
return questDetailList;
}

Loading…
Cancel
Save