| @@ -2,9 +2,11 @@ | ||
| 2 | 2 | |
| 3 | 3 | namespace FluentCart\App\Modules\Subscriptions; |
| 4 | 4 | |
| 5 | 5 | use FluentCart\App\App; |
| 6 | +use FluentCart\App\Models\Subscription; | |
| 6 | 7 | use FluentCart\App\Modules\Subscriptions\Services\Filter\SubscriptionFilter; |
| 8 | +use FluentCart\Framework\Support\Arr; | |
| 7 | 9 | |
| 8 | 10 | class SubscriptionModule |
| 9 | 11 | { |
| 10 | 12 | public static function register() |
| @@ -20,12 +22,16 @@ | ||
| 20 | 22 | }); |
| 21 | 23 | |
| 22 | 24 | (new \FluentCart\App\Modules\Subscriptions\Http\Handlers\AdminMenuHandler())->register(); |
| 23 | 25 | |
| 26 | + // Checkout gateway capability gate — new subscription carts, renewals, and reactivations. | |
| 27 | + (new \FluentCart\App\Modules\Subscriptions\Services\SubscriptionGatewayGate())->register(); | |
| 28 | + | |
| 29 | + // Auto-charge engine for system (token-charged) subscription renewal invoices. | |
| 30 | + (new \FluentCart\App\Modules\Subscriptions\Services\SystemChargeService())->register(); | |
| 31 | + | |
| 24 | 32 | add_filter('fluent_cart/admin_filter_options', function ($filterOptions, $args) { |
| 25 | 33 | $filterOptions['subscription_filter_options'] = SubscriptionFilter::getTableFilterOptions(); |
| 26 | 34 | return $filterOptions; |
| 27 | - }, 10, 2); | |
| 28 | - | |
| 35 | + }, 10, 2); | |
| 29 | 36 | } |
| 30 | - | |
| 31 | 37 | } |