Beboost

Form & Infolist

Filament form fields and infolist entries for Status Management

Form Components

Status Select

A select field that lists available statuses for the current model. Options the user cannot transition to are automatically disabled based on transition rules.

Implementation

use Beboost\StatusManagement\Filament\Forms\Components\StatusSelect;

StatusSelect::make()

Modifiers

// Hide statuses the user cannot transition to (instead of showing them disabled)
StatusSelect::make()->hideDisabledOptions()

// Control the icon shown inside each option
StatusSelect::make()->optionIcon()         // enable (uses status icon)
StatusSelect::make()->optionIcon(false)    // disable

// Control the icon color inside each option
StatusSelect::make()->optionIconColor()        // enable (uses status color)
StatusSelect::make()->optionIconColor(false)   // disable

Infolist Components

Use these entries to display status information on Filament View pages (infolists).

Displays the record's current status in an infolist. Extends Filament's TextEntry, so all standard entry methods work. The status name is rendered, and color, icon and icon color are taken from the status automatically.

Implementation

use Beboost\StatusManagement\Filament\Infolists\StatusEntry;

public static function infolist(Infolist $infolist): Infolist
{
    return $infolist->schema([
        StatusEntry::make(),
    ]);
}

StatusEntry::make() defaults to the status attribute. By default it derives:

  • the label from the status name,
  • the color and icon color from the status color,
  • the icon from the status icon.

Override any of them by passing your own value, e.g. StatusEntry::make()->icon(false) or StatusEntry::make()->color('gray').

Next Steps

How is this guide?

On this page