PHP code example of rickdbcn / filament-email

1. Go to this page and download the library: Download rickdbcn/filament-email 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/ */

    

rickdbcn / filament-email example snippets


->plugin(\RickDBCN\FilamentEmail\FilamentEmail::make())

use RickDBCN\FilamentEmail\Models\Email;
use RickDBCN\FilamentEmail\Filament\Resources\EmailResource;

return [

    'resource' => [
        'class' => EmailResource::class,
        'model' => Email::class,
        'cluster' => null,
        'group' => null,
        'sort' => null,
        'icon' => null,
        'default_sort_column' => 'created_at',
        'default_sort_direction' => 'desc',
        'datetime_format' => 'Y-m-d H:i:s',
        'table_search_fields' => [
            'subject',
            'from',
            'to',
            'cc',
            'bcc',
        ],
    ],

    'keep_email_for_days' => 60,

    'label' => null,

    'prune_enabled' => true,

    'prune_crontab' => '0 0 * * *',

    'can_access' => [
        'role' => [],
    ],

    'pagination_page_options' => [
        10, 25, 50, 'all',
    ],

    'attachments_disk' => 'local',
    'store_attachments' => true,

    //Use this option for customize tenant model class
    //'tenant_model' => \App\Models\Team::class,

];
bash
> php artisan vendor:publish --tag="filament-email-migrations"
> php artisan migrate
> 
bash
php artisan vendor:publish --tag="filament-email-migrations"
php artisan migrate
bash
php artisan vendor:publish --tag="filament-email-config"