> ## Documentation Index
> Fetch the complete documentation index at: https://docs.unleash-commerce.eu/llms.txt
> Use this file to discover all available pages before exploring further.

# Resources

> Build custom Filament resources for the admin panel

## Overview

Filament Resources are the primary way to manage your data in the admin panel. They provide out-of-the-box functionality for listing, creating, editing, and deleting records.

## Creating a Resource

Resources are located in `src/Filament/Resources`. Use the Filament command to scaffold:

```bash theme={null}
php artisan make:filament-resource Product
```

This creates a resource class with list, form, and detail page configurations.

## Resource Contract

Always define a contract for each Filament Resource in `Esign\UnleashCommerce\Admin\Contracts\Filament\Resources`:

```php theme={null}
interface ProductResourceContract
{
    // Define your contract methods
}
```

## Registering Resources

Register replacements via the `FilamentResourceManifest` to allow swapping implementations.

## Tables

Configure your resource table with columns, filters, and actions:

```php theme={null}
public static function table(Table $table): Table
{
    return $table
        ->columns([
            Tables\Columns\TextColumn::make('name'),
        ])
        ->actions([
            Tables\Actions\EditAction::make(),
        ]);
}
```

## Forms

Define your form schema for creation and editing:

```php theme={null}
public static function form(Form $form): Form
{
    return $form
        ->schema([
            Forms\Components\TextInput::make('name')
                ->required(),
        ]);
}
```

## Documentation

For detailed information about Filament Resources, see the [Filament documentation](https://filamentphp.com/docs/5.x/resources/overview).
