mirror of
https://github.com/v2board/v2board.git
synced 2024-11-10 17:49:11 +08:00
update downgrade
This commit is contained in:
parent
9925ab6b47
commit
f3ac8a37be
@ -143,7 +143,7 @@ class OrderController extends Controller
|
|||||||
$order->type = 3;
|
$order->type = 3;
|
||||||
$order->surplus_amount = $this->getSurplusValue($user);
|
$order->surplus_amount = $this->getSurplusValue($user);
|
||||||
if ($order->surplus_amount >= $order->total_amount) {
|
if ($order->surplus_amount >= $order->total_amount) {
|
||||||
if (!(int)config('v2oard.plan_downgrade_enable', 1)) abort(500, '目前不允许降级订阅,请联系管理员');
|
if (!(int)config('v2board.plan_downgrade_enable', 1)) abort(500, '目前不允许降级订阅,请联系管理员');
|
||||||
$order->refund_amount = $order->surplus_amount - $order->total_amount;
|
$order->refund_amount = $order->surplus_amount - $order->total_amount;
|
||||||
$order->total_amount = 0;
|
$order->total_amount = 0;
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user