PHP code example of crumbls / subscriptions-filament

1. Go to this page and download the library: Download crumbls/subscriptions-filament library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

crumbls / subscriptions-filament example snippets


use Crumbls\SubscriptionsFilament\SubscriptionsPlugin;

public function panel(Panel $panel): Panel
{
    return $panel
        ->plugins([
            SubscriptionsPlugin::make(),
        ]);
}

use Crumbls\SubscriptionsFilament\RelationManagers\PlanSubscriptionsRelationManager;

class TenantResource extends Resource
{
    public static function getRelations(): array
    {
        return [
            PlanSubscriptionsRelationManager::class,
        ];
    }
}

use Crumbls\SubscriptionsFilament\Resources\PlanResource\PlanResource;

class CustomPlanResource extends PlanResource
{
    // Add custom columns, filters, actions, etc.
}
bash
> php artisan filament:cache-components
>