feat: 收益全额直入商城余额、存量结转与奖项名称全局规范化对齐
这个提交包含在:
@@ -5,18 +5,18 @@ namespace addons\shopro\service\partner;
|
||||
use app\admin\model\shopro\commission\Agent as AgentModel;
|
||||
|
||||
/**
|
||||
* 推荐开拓奖:398/400/600 循环,计到推荐人,自购不发
|
||||
* 推荐提成:398/400/600 循环,计到推荐人,自购不发
|
||||
*/
|
||||
class Push3Reward
|
||||
{
|
||||
public function run($order, $buyerId, $parent, ActiveService $active, $rules = null)
|
||||
{
|
||||
if (!$parent) {
|
||||
PartnerRewardService::writeSkip($order, $buyerId, 0, 'push3', 'taster', 'no_parent', '暂无推荐人,不计提推荐开拓奖');
|
||||
PartnerRewardService::writeSkip($order, $buyerId, 0, 'push3', 'taster', 'no_parent', '暂无推荐人,不计提推荐提成');
|
||||
return;
|
||||
}
|
||||
if (intval($parent['user_id']) === intval($buyerId)) {
|
||||
PartnerRewardService::writeSkip($order, $buyerId, $parent['user_id'], 'push3', 'taster', 'self_buy', '本人下单不计提推荐开拓奖');
|
||||
PartnerRewardService::writeSkip($order, $buyerId, $parent['user_id'], 'push3', 'taster', 'self_buy', '本人下单不计提推荐提成');
|
||||
return;
|
||||
}
|
||||
if (intval($parent['level']) < 1) {
|
||||
@@ -42,7 +42,7 @@ class Push3Reward
|
||||
$amount = $amounts[($seq - 1) % 3];
|
||||
|
||||
PartnerRewardService::account($order, $buyerId, $agent->user_id, 'push3', 'taster', $amount, $amount, [
|
||||
'formula' => "推荐开拓第{$seq}单,循环第" . ((($seq - 1) % 3) + 1) . "档 +{$amount}",
|
||||
'formula' => "推荐提成第{$seq}单,循环第" . ((($seq - 1) % 3) + 1) . "档 +{$amount}",
|
||||
'seq' => $seq,
|
||||
]);
|
||||
}
|
||||
|
||||
在新工单中引用
屏蔽一个用户