推广分佣功能开发

This commit is contained in:
Dev
2026-10-14 14:44:01 +08:00
parent da26eb5306
commit 1754df972d
34 changed files with 1414 additions and 16 deletions
@@ -7,6 +7,7 @@ use app\common\service\AccountService;
use app\common\service\EasyWeChatService;
use app\common\service\OrderService;
use app\common\service\OrderShipService;
use app\common\service\PromotionService;
use app\common\service\SubscribeMessageService;
use think\console\Command;
use think\console\Input;
@@ -27,6 +28,8 @@ class DemandDeal extends Command
$output->writeln("bidding:deal:");
$this->confirmReceiptTimeoutDeal($input, $output);
$this->demandProfitUnfreezeDeal($input, $output);
//兜底:结算交易完成但未结算的推广佣金(如后台直接改为已完成的订单)
PromotionService::settlePendingOrders();
}
/**
@@ -64,6 +67,8 @@ class DemandDeal extends Command
if (!$upRes) {
exception('更新订单状态失败');
}
//交易完成:结算推广佣金
PromotionService::settleOrders(['parent_order_no' => $item->parent_order_no]);
}
});
} catch (\Exception $e) {