allow purchase = no, but can recharge

This commit is contained in:
iBNu Maksum 2024-03-01 16:10:01 +07:00 committed by GitHub
parent dc70a49f52
commit 012a1ecfab
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -99,8 +99,7 @@ if (isset($_GET['recharge']) && !empty($_GET['recharge'])) {
if(!$plan['enabled']){ if(!$plan['enabled']){
r2(U . "home", 'e', 'Plan is not exists'); r2(U . "home", 'e', 'Plan is not exists');
} }
if($plan['allow_purchase'] != 'yes'){
r2(U . "home", 'e', 'Cannot recharge this plan');
} }
if ($user['balance'] > $plan['price']) { if ($user['balance'] > $plan['price']) {
r2(U . "order/pay/$router[id]/$bill[plan_id]", 'e', 'Order Plan'); r2(U . "order/pay/$router[id]/$bill[plan_id]", 'e', 'Order Plan');