|
|
|
@ -103,7 +103,7 @@ class CommissionScoreLog |
|
|
|
|
return true; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
//1.非用户角色下单立即反积分 并且给公司账户返积分 |
|
|
|
|
//1.非用户角色下单立即反积分 |
|
|
|
|
if ($initLevel > self::LEVEL_1 && $currentCommissionLevel == 1) { |
|
|
|
|
$amount = bcsub($order['goods_price'], $current_level_price, 2); |
|
|
|
|
//算积分 |
|
|
|
@ -144,8 +144,9 @@ class CommissionScoreLog |
|
|
|
|
//4.向上反佣金 |
|
|
|
|
if ($parentLevel > $currentLevel) { |
|
|
|
|
$amount = bcsub($current_level_price, $parent_level_price, 2); |
|
|
|
|
//如果当前当前用户等级是会员 按原价算 |
|
|
|
|
if($currentLevel == self::LEVEL_2) { |
|
|
|
|
//如果当前当前用户等级是上级是会员 按原价算 |
|
|
|
|
// if($currentLevel == self::LEVEL_2) { |
|
|
|
|
if($initLevel == self::LEVEL_1 && $sonLevel == self::LEVEL_2) { |
|
|
|
|
$amount = bcsub($order['goods_price'], $parent_level_price, 2); |
|
|
|
|
} |
|
|
|
|
\think\Log::info('上级商品价格'.$parent_level_price); |
|
|
|
|