提交 b9bd0fec authored 作者: 艾庆国's avatar 艾庆国

Merge branch 'refs/heads/v26.2-jdk17springboot3-20240912' into test_jdk17

Former-commit-id: 0bf214ee
......@@ -8,8 +8,6 @@ import com.clx.performance.dao.settle.SettlementDriverDao;
import com.clx.performance.enums.loan.OwnerLoanRecordEnum;
import com.clx.performance.mapper.settle.SettlementDriverMapper;
import com.clx.performance.model.settle.SettlementDriver;
import com.clx.performance.model.settle.SettlementOrderChildRisk;
import com.clx.performance.model.settle.SettlementOwner;
import com.clx.performance.param.pc.driver.PageCarrierSettlementDriverParam;
import com.msl.common.base.Optional;
import com.msl.common.dao.impl.BaseDaoImpl;
......@@ -18,7 +16,6 @@ import org.springframework.stereotype.Repository;
import java.util.List;
import java.util.Objects;
import java.util.Set;
/**
* @Author: aiqinguo
......@@ -38,6 +35,16 @@ public class SettlementDriverDaoImpl extends BaseDaoImpl<SettlementDriverMapper,
);
}
@Override
public boolean updateInvoiceCompany(SettlementDriver item) {
return update(lUdWrapper()
.eq(SettlementDriver::getId, item.getId())
.set(SettlementDriver::getInvoicingCompanyId, item.getInvoicingCompanyId())
.set(SettlementDriver::getInvoicingCompanyShorterName, item.getInvoicingCompanyShorterName())
.set(SettlementDriver::getInvoicingCompanyGroupCode, item.getInvoicingCompanyGroupCode())
);
}
@Override
public Optional<SettlementDriver> findBySettlementNo(String settlementNo) {
return Optional.of(lQrWrapper()
......
......@@ -20,6 +20,8 @@ public interface SettlementDriverDao extends BaseDao<SettlementDriverMapper, Set
boolean updatePayStatus(SettlementDriver item);
boolean updateInvoiceCompany(SettlementDriver item);
Optional<SettlementDriver> findBySettlementNo(String settlementNo);
Optional<SettlementDriver> findByChildNo(String childNo);
......
......@@ -300,6 +300,9 @@ public class SettlementMqHandlerServiceImpl implements SettlementMqHandlerServic
settlementDriverDao.saveEntity(settlementDriver);
settlementDriverDetail.setSettlementNo(settlementDriver.getSettlementNo());
settlementDriverDetailDao.updateSettlementNo(settlementDriverDetail);
//车主结算单自动支付
log.info(" 运单号 {}, 是否是普通单 {} ",settlementDriverDetail.getChildNo(),settlementDriverDetail.getInvoiceType());
if (!settlementDriverDetail.getInvoiceType().equals(SettlementOwnerEnum.InvoiceType.ONLINE.getCode())) {
......@@ -1017,7 +1020,8 @@ public class SettlementMqHandlerServiceImpl implements SettlementMqHandlerServic
SettlementDriverDetail settlementDriverDetail = settlementDriverDetailDao
.getByChildNo(childNo).orElseThrow(PerformanceResultEnum.DATA_NOT_FIND);
SettlementDriver settlementDriver = settlementDriverDao
.getByChildNo(childNo).orNull();
OrderChild orderChild = orderChildDao
.getByChildNo(childNo).orElseThrow(PerformanceResultEnum.ORDER_CHILD_NO_FOUND);
......@@ -1058,6 +1062,13 @@ public class SettlementMqHandlerServiceImpl implements SettlementMqHandlerServic
settlementOwnerDetailDao.updateInvoiceType(settlementOwnerDetail);
settlementDriverDetailDao.updateInvoiceTypeAndPrepayFreightFlag(settlementDriverDetail);
if (settlementDriver != null) {
settlementDriver.setInvoicingCompanyId(settlementOwnerDetail.getInvoicingCompanyId());
settlementDriver.setInvoicingCompanyShorterName(settlementOwnerDetail.getInvoicingCompanyShorterName());
settlementDriver.setInvoicingCompanyGroupCode(settlementOwnerDetail.getInvoicingCompanyGroupCode());
settlementDriverDao.updateInvoiceCompany(settlementDriver);
}
if (Objects.equals(settlementOwnerDetail.getReportFlag(), com.clx.order.enums.OrderEnum.ReportFlag.NO.getCode())){
// 网运单转普通单
orderChildSyncTransportListener.extracted(orderChild, settlementOwnerDetail, settlementDriverDetail, settlementOwnerDetail.getInvoiceType(), null);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论