34ml / filament-price-converter-field
A price converter field for filament admin panel
v1.2.1
2024-01-23 09:55 UTC
Requires
- php: ^8.1
- filament/filament: ^2.0 | ^3.0
- spatie/laravel-package-tools: ^1.14.0
Requires (Dev)
- laravel/pint: ^1.0
- nunomaduro/collision: ^7.9
- orchestra/testbench: ^8.0
- pestphp/pest: ^2.0
- pestphp/pest-plugin-arch: ^2.0
- pestphp/pest-plugin-laravel: ^2.0
README
Installation
You can install the package via composer:
composer require 34ml/filament-price-coverter-field
This is the content of the published config file where you can set the default currency
return [ 'currency' => 'EUR', ];
Usage
Add the field in your resource, view, create or edit pages inside the form function
use _34ML\FilamentPriceConverterField\FilamentPriceConverterField; FilamentPriceConverterField::make('price')->required(),
Also if you want to use it inside a table for the list page
use _34ML\FilamentPriceConverterField\FilamentPriceConverterColumn; FilamentPriceConverterColumn::make('price')->label('Sale Price'),
Credits
License
The MIT License (MIT). Please see License File for more information.