ariaieboy / filament-currency

Enhanced Currency Related stuff for Filament
MIT License
42 stars 8 forks source link

[Bug]: Not support null value in column with ->currency() #16

Closed DawidMazur closed 8 months ago

DawidMazur commented 8 months ago

What happened?

Tables\Columns\TextColumn::make('cost')
                    ->sortable()
                    ->placeholder(__('Brak'))
                    ->currency('PLN'),

currency macro not work with null value, I'm getting fatal error with null. I want to show placeholder if value is null.

How to reproduce the bug

Create TextColumn with null value and add ->currency()

Package Version

3.1

PHP Version

8.2

Laravel Version

10.34.2

Which operating systems does with happen with?

No response

Notes

No response

ariaieboy commented 8 months ago

@DawidMazur I've tested your example and it works fine for me. Please create a minimum repo that reproduces this issue so I can check it.