Raziul Islam
Adding demo mode in filament application
Demo mode means the create/update/delete actions won't be applicable.
I used to do this via middleware in Laravel but wanted to do similar thing but can't figure it out.
Is there any easy way to add demo mode in a filament panel?
12 replies
Custom MoneyInput form field
I am using 'akaunting/laravel-money' package and custom cast that helps to store the value in cents in database and return money object while reading. ( A common approach for money)
The only issue was with filament TextInput which doesn't understands the object so I had to make a custom field.
This is the code:
and in the form:
Now it is working but I wanted to know if there is scope for improvement.
3 replies