Hemanath
Hemanath
FFilament
Created by Hemanath on 9/27/2024 in #❓┊help
pxlrbt-excel(I am using different roles based on need to export the column fromTable)
I am using the export feature in Filament v2 where I have specified 'fromTable'. However, I need to display the text column based on the user's role. It appears correctly, but it is not functioning as expected with that column. Are there any possibilities in Filament to make a column visible or to use any other condition? ExportAction::make() ->label(trans('app.students.header_action.export_excel')) ->exports([ ExcelExport::make('table') ->withFilename('Students') ->fromTable() ->withChunkSize(500000), ]),
TextColumn::make('business_name') ->visible(function () { $franchisee = Model::find(Session::get('current_franchisee')); $result = false; if (in_array($franchisee->type, [config('constants.franchisee_types.sm'), config('constants.franchisee_types.so'), config('constants.franchisee_types.sf')])) { $result = true; } return $result; })
4 replies
FFilament
Created by Hemanath on 8/28/2024 in #❓┊help
When Changing url should not work in filament any method
I am using multiple logins and provider ,using middleware , i called in my every pages and resources those middleware's what i need http://exam.test/student when changing student to admin after /its should not work any possibilities we are having filament ..can you give guide anyone solutions
4 replies
FFilament
Created by Hemanath on 7/19/2024 in #❓┊help
Created a Laravel component for a pdf action, inside a custom page i used this:
Action::make('certificate')->button()->label('Certificate PDF') ->action(function () { $pdfUrl = route('competition-certificate-print', [ 'franchisee' => $this->franchisee->id, 'competition' => $this->record->id, ]); $this->dispatchBrowserEvent('open-pdf-modal', ['url' => $pdfUrl, 'title' => 'Certificate PDF', 'fileName' => 'Competition']); }), for the custom page blade file i used this : <x-pdf-action /> it worked, now i want to use that inside a resource action, how can i achieve this in there.
1 replies
FFilament
Created by Hemanath on 7/15/2024 in #❓┊help
How can we select minutes in form for timepicker ?
TimePicker::make('appointment_at')
5 replies
FFilament
Created by Hemanath on 4/1/2024 in #❓┊help
Autocomplete not working in textinput
TextInput::make('name') when i am typing the name while that time in registration form showing before data what i filled any possibilities to remove in fms..or some other suggestion anyone
8 replies
FFilament
Created by Hemanath on 3/28/2024 in #❓┊help
Unable to resolve repeater text input problem
i am using repeater. When i define some base price inside text input its not taking after typed 500; its show only 5 automatically removing inside the textbox 00 values how to resolve any solution in filament or anyone advise me to resolve the issue...
6 replies
FFilament
Created by Hemanath on 3/20/2024 in #❓┊help
I am using navigation group and navigationitem but page was broken
No description
7 replies
FFilament
Created by Hemanath on 3/11/2024 in #❓┊help
'SelectColumn ' i am using in my project
SelectColumn::make('status') ->options([ 'draft' => 'Draft', 'reviewing' => 'Reviewing', 'published' => 'Published',     ]) This is my code i am saved inside the table field like status ,but i need to save one more place inside Json field so how to update the field using select column can anyone explain or how to achieve this?
3 replies
FFilament
Created by Hemanath on 1/20/2024 in #❓┊help
protected function getTableColumns(): array
Using loop in the getTableColumns and repeat the TextColumn according to the record from the getTableQuery...
5 replies
FFilament
Created by Hemanath on 1/6/2024 in #❓┊help
Panel Logout
I have two panels, If I sign out of an Admin panel, I need to go to another panel's login. Can we do that?
12 replies
FFilament
Created by Hemanath on 1/5/2024 in #❓┊help
Panel redirect
I have multiple panels in that one panel is new panel if login using this panel based on user role its need to redirect another panel How can i achieve this?
8 replies
FFilament
Created by Hemanath on 12/22/2023 in #❓┊help
pxlrbt/filament-excel ExportAction
protected function getTableHeaderActions(): array { return [ ExportAction::make() ->label('Export') ->exports([ ExcelExport::make() ->withFilename('Materials sales report') ->withColumns([ ])->fromTable(), ]), ]; } this is my code i need to give default(0) for withcolumns any possibilities to give ..? Please suggest me any other way.
1 replies
FFilament
Created by Hemanath on 12/15/2023 in #❓┊help
How to use $get and $set in custom page
'the get and set is working only on resource, for custom page it is not working'
5 replies
FFilament
Created by Hemanath on 11/23/2023 in #❓┊help
Filament Access
What I am trying to do: I want give filament access to the particular user role. What I did: I used public function canAccessFilament(): bool inside the user model. My issue/the error: Cannot redeclare App\Models\User::canAccessFilament() Code: public function canAccessFilament(): bool { return $this->role != 'member'; }
11 replies
FFilament
Created by Hemanath on 11/22/2023 in #❓┊help
How use ->action() and ->url
I trying use the form and send the form data through the ->url(), if i use ->url() without opening the form it is redirecting to the url. Action::make('Print Label') ->action(function ($record, array $data) { // }) ->url( fn (Despatch $record, array $data): string => route('web.despatchprintlable', ['record' => $record, 'space' => Arr::get($data, 'space_no')]), shouldOpenInNewTab: true ) ->icon('heroicon-s-download') ->visible(function ($record) { $transactions = Transaction::find($record->transaction_ids); $flag = false; foreach ($transactions as $k => $transaction) { if ($transaction->sub_master_id == config('constants.transaction_types.cm_request')) { $flag = true; break; } } return ($flag) ? true : false; }) ->form([ TextInput::make('space_no')->numeric()->minValue(0)->required(), ]) ->modalWidth('xl') ->modalbutton('Print Lable'), this is the code.
6 replies
FFilament
Created by Hemanath on 11/3/2023 in #❓┊help
eyebutton() required in textinput
TextInput::make('email_password')->label('Email Password') ->password() ->dehydrated(false)  ->minLength(8) how to get view using eyebutton inside the textinput.Any one guide me
4 replies
FFilament
Created by Hemanath on 10/11/2023 in #❓┊help
Public Variable
filament custom page a public variable $data i want hold data in it even we refresh the page. any solution
2 replies
FFilament
Created by Hemanath on 10/6/2023 in #❓┊help
Select::make using resources
No description
5 replies
FFilament
Created by Hemanath on 10/3/2023 in #❓┊help
Forms\Components\Repeater::make('addresses')->relationship('addresses')
i am using the relationship in the repeater , but i am not getting that repeater data inside the handleRecordCreation(array $data) $data variable. How to get that data without removing the ->relationship.
4 replies
FFilament
Created by Hemanath on 9/25/2023 in #❓┊help
I am saving data inside the array,i need to search in list table
TextColumn::make('details.class_name')->toggleable() ->searchable(), I am saving data inside the array,i need to search in list table. i could not achieve the data to search. Please guide me how to resolve.
1 replies