yeg
2026-09-14 84913d997c70c2e3cc8406cf23eaba710cd5c9d6
talent-card-server/src/main/java/com/talentcard/server/business/order/OrderService.java
@@ -11,6 +11,7 @@
import com.talentcard.server.business.MoneyUtils;
import com.talentcard.server.business.merchant.MerchantPaymentReadinessService;
import com.talentcard.server.business.payment.HuifuRefundService;
import com.talentcard.server.business.payment.PaymentFundConfirmationService;
import com.talentcard.server.business.PageResult;
import com.talentcard.server.common.BusinessException;
import com.talentcard.server.common.ErrorCode;
@@ -28,12 +29,14 @@
   private final HuifuRefundService refundService;
   private final MerchantPaymentReadinessService merchantPaymentReadinessService;
   private final OrderFundBoundaryService orderFundBoundary;
   private final PaymentFundConfirmationService fundConfirmation;
   public OrderService(JdbcTemplate jdbcTemplate, HuifuRefundService refundService, MerchantPaymentReadinessService merchantPaymentReadinessService, OrderFundBoundaryService orderFundBoundary) {
   public OrderService(JdbcTemplate jdbcTemplate, HuifuRefundService refundService, MerchantPaymentReadinessService merchantPaymentReadinessService, OrderFundBoundaryService orderFundBoundary, PaymentFundConfirmationService fundConfirmation) {
      this.jdbcTemplate = jdbcTemplate;
      this.refundService = refundService;
      this.merchantPaymentReadinessService = merchantPaymentReadinessService;
      this.orderFundBoundary = orderFundBoundary;
      this.fundConfirmation = fundConfirmation;
   }
   @Transactional
@@ -118,6 +121,8 @@
      if (updated != 1) {
         throw new BusinessException(ErrorCode.CONFLICT, "订单已核销");
      }
      // 后台核销是第三条核销入口,同样要在核销后把延迟入账的钱确认给商户。
      fundConfirmation.confirmForOrder(orderId);
      return detail(orderNo);
   }