|
@@ -749,7 +749,7 @@ class StoreOrderRepository extends BaseRepository
|
|
|
|
|
|
public function grant_integral(StoreOrder $order, User $user)
|
|
|
{
|
|
|
- if($order->residue_percentage <= 0){
|
|
|
+ if($order->residue_percentage >= 0){
|
|
|
return true;
|
|
|
}
|
|
|
$residue_percentage = abs($order->residue_percentage);
|
|
@@ -758,7 +758,6 @@ class StoreOrderRepository extends BaseRepository
|
|
|
$residue_percentage = $max_discount;
|
|
|
}
|
|
|
$integral = $residue_percentage * $order->total_price / 100;
|
|
|
- var_dump($integral);exit();
|
|
|
if($integral){
|
|
|
app()->make(UserBillRepository::class)->incBill($user->uid, 'integral', 'rebate', [
|
|
|
'link_id' => $order->order_id,
|