Prosp30
Prosp30
FFilament
Created by Prosp30 on 4/1/2024 in #❓┊help
Modal footer actions alignment
No description
9 replies
FFilament
Created by Prosp30 on 3/19/2024 in #❓┊help
Download PDF using Spatie Laravel-PDF on table action
I am trying to download a PDF generated from a blade view. I tried DOMPDF and it works fine, but I would like to use Spatie's PDF which has better funcionality. I added the PDF to the table action, but the button just spins and nothing gets returned. Is there a way to convert the PDF to a stream to make it downloadable or? Action::make('download') ->action(function (Invoice $record) { return pdf()->view('pdf.invoice', ['invoice' => $record]) ->format('a4') ->name('your-invoice.pdf') ->download(); }) ->iconButton('heroicon-o-document-arrow-down') ->icon('heroicon-o-document-arrow-down') ->label('Preuzmi PDF'),
23 replies
FFilament
Created by Prosp30 on 2/23/2024 in #❓┊help
Placeholder overflow
No description
4 replies
FFilament
Created by Prosp30 on 2/23/2024 in #❓┊help
Money formatting a live field
No description
5 replies
FFilament
Created by Prosp30 on 2/18/2024 in #❓┊help
Custom text format
Hi there, I am wondering, how could I achieve the following with Filament? Let's say I have a text that is made of: User ID / Resource ID / Counter Ie: 500 / 1234 / 1 And the order of the fields can be customizable, ie it can be for some Resource ID / Counter / User ID Is there a way to preformat text with Filament by using the fields and a pattern or I shouldn't look into Filament for this part?
4 replies
FFilament
Created by Prosp30 on 2/10/2024 in #❓┊help
Update pivot table when editing record
Hi there, I am trying to update a pivot table record while editing the main record. I have the following table team_user user_id team_id operator_id (just a string value I wish to update) On both user and team I have belongsToMany (M:M relationship). This is how I fetch the operator_id in the table, using the team_user pivot table TextColumn::make('operator_id')->label('Oznaka operatera')->sortable()->searchable() ->state(function (User $record): string { return $record->getUserInTeam()->first()->pivot->operator_id; }), How can I acomplish the same so when the record is created, operator_id is filled from the form and when the record is being edited, operator ID gets displayed and can be edited?
3 replies
FFilament
Created by Prosp30 on 2/10/2024 in #❓┊help
RelationManager form actions
No description
3 replies
FFilament
Created by Prosp30 on 2/3/2024 in #❓┊help
RichText image upload on private disk
Hi there, I am trying to find a way on how to display images in the RichText editor that are private (ie. only viewable by the user that created the note). Using the public disk works, but as soon as I use private disk it fails to fetch the image (404). Section::make()->columns(1) ->schema([ RichEditor::make('notes')->label('Bilješke') ->fileAttachmentsDisk('private') ->fileAttachmentsDirectory('form-attachments') ->fileAttachmentsVisibility('private') ])]); filesystems.php 'private' => [ 'driver' => 'local', 'root' => storage_path('app/private'), 'url' => env('APP_URL').'/private', 'visibility' => 'private', ],
12 replies
FFilament
Created by Prosp30 on 1/28/2024 in #❓┊help
Reset password email locale
Hello, I am using non-english locale for my app. Everything is translated okay pretty much, except for the reset password notification and emails. Where should I look to overwrite these values, both in the notification and in the email itself? I tried setting up my custom email message and I can change the greetings, salute, line and action, but there's no way to change the footer where it says to copy and paste the link into the browser. Ie: We have emailed your password reset link.
6 replies
FFilament
Created by Prosp30 on 1/4/2024 in #❓┊help
When navigating fast on the navbar, sometimes JS breaks
The error Too many calls to Location or History APIs within a short timeframe. It causes the page not to load. Is there a workaround for this?
6 replies
FFilament
Created by Prosp30 on 1/2/2024 in #❓┊help
Changing default Save button and Create Another labels?
Hello there. I started learning Filament and I am building a small demo app to get a hang of it. I am loving it so far, had a few issues but managed to solve it. Only issue that I'm facing right now is how to change default action button labels, on the CreateRecord resource. I haven't found it in the docs (or I searched the wrong terms). Also, should I open an issue, because Croatian language translation is a bit off (not really in the spirit of the language). Actions are labeled: 1) Save - Napravi (literal translation would be Do it which sounds off) - more correct one would be Spremi 2) Save & Another - Napravi i napravi novi (sound off like in first point) - correct one would be Spremi i novi Thanks and apologies if it's a newbie question 🙂
6 replies