Asset Stock Management

Filament 4/5
Also available in Filament 3 version

Shows how to create a simple stock management application with item export/import and transaction logging for stock changes.

P38nUYdSkxw8Hjv7kiPw9vPF8ODNkw-metaU2NyZWVuc2hvdCAyMDIzLTEwLTE3IGF0IDA3LjIyLjU4LnBuZw==-

Get the Source Code:

Only This Example

$9

One-time payment

Full source code for Asset Stock Management
Downloadable ZIP file with the source code
Lifetime access to this example
GitHub Sign in with GitHub to buy

Sign in first, then complete your $9 checkout.

Best value — all 169 examples

FilamentExamples Membership

$99 /year
or
$199 lifetime
Access to code of all 169 examples
Future new examples and updates included
FilaCheck Pro package licence included
MCP server included
View membership plans

30-day money-back guarantee

How it works

We have a simple resource to manage categories where the create and edit form opens in a modal. For category, we only have one field, name. Here is the code for CategoryResource:

class CategoryResource extends Resource
{
protected static ?string $model = Category::class;
 
protected static string | \BackedEnum | null $navigationIcon = Heroicon::OutlinedRectangleStack;
 
public static function form(Schema $schema): Schema
{
return CategoryForm::configure($schema);
}
 
public static function table(Table $table): Table
{
return CategoriesTable::configure($table);
}
 
public static function getPages(): array
{
return [
'index' => ManageCategories::route('/'),
];
}
}

Transactions resource manages transactions for an item. We can only create a new transaction.

The form of transaction is reused in the relation manager for ItemResource. We don't need a select input in the relation manager, so the hiddenOn() method is used where the Relation Manager class is passed as a parameter.

The amount text input has a column span of full only in the Relation Manager. Here is the code for the form in the TransactionResource:

The FULL tutorial is available after the purchase: in the Readme file of the official repository you would get invited to.