yagrasdemonde
yagrasdemonde
FFilament
Created by @nasilemak on 11/11/2024 in #❓┊help
Adding a list of placeholder variables to the RichEditor component
3 replies
FFilament
Created by yagrasdemonde on 10/10/2024 in #❓┊help
Issue with livewire component (a table) in Infolist
Up ! Did someone take a look at my reproduction repository? Thanks
3 replies
FFilament
Created by Jon Mason on 3/16/2024 in #❓┊help
Uncaught (in promise) Component not found
I had a similar issue too….
5 replies
FFilament
Created by Jon Mason on 3/16/2024 in #❓┊help
Uncaught (in promise) Component not found
Did you resolve this issue ?
5 replies
FFilament
Created by yagrasdemonde on 9/30/2024 in #❓┊help
Group Options in record Select in Relation Manager
No description
6 replies
FFilament
Created by yagrasdemonde on 9/30/2024 in #❓┊help
Group Options in record Select in Relation Manager
return this
6 replies
FFilament
Created by yagrasdemonde on 9/30/2024 in #❓┊help
Group Options in record Select in Relation Manager
dd($query->get()->groupBy('season')->map(function ($item) {
return $item->keyBy('id')->map(fn ($item) => $item->title);
}));
dd($query->get()->groupBy('season')->map(function ($item) {
return $item->keyBy('id')->map(fn ($item) => $item->title);
}));
6 replies
FFilament
Created by yagrasdemonde on 9/30/2024 in #❓┊help
Group Options in record Select in Relation Manager
Anyone ? 🫢
6 replies
FFilament
Created by itsmejyv on 9/19/2024 in #❓┊help
How to change summary text color?
Set extra classes and use them in css
3 replies
FFilament
Created by Hik on 8/16/2024 in #❓┊help
Form Wizard multiple models
Use relationship
7 replies
FFilament
Created by ericmp on 3/21/2024 in #❓┊help
How to hide action modal footer actions?
->modalSubmitAction(false)
->modalCancelAction(false)
->modalSubmitAction(false)
->modalCancelAction(false)
5 replies
FFilament
Created by yagrasdemonde on 3/10/2024 in #❓┊help
Render Hook in middleware problem
Idea?
4 replies
FFilament
Created by yagrasdemonde on 2/29/2024 in #❓┊help
Problem refreshing component
but no success
10 replies
FFilament
Created by yagrasdemonde on 2/29/2024 in #❓┊help
Problem refreshing component
I also tried with
php protected $listeners = [
'myevent' => '$refresh',
];
php protected $listeners = [
'myevent' => '$refresh',
];
10 replies
FFilament
Created by yagrasdemonde on 2/29/2024 in #❓┊help
Problem refreshing component
What did I miss ?
10 replies
FFilament
Created by yagrasdemonde on 2/29/2024 in #❓┊help
Problem refreshing component
I show this component with this, inside my
```php
FilamentView::registerRenderHook(
PanelsRenderHook::GLOBAL_SEARCH_BEFORE,
fn (): View => view('filament.views.general.complete-profil-btn'),
);
```php
FilamentView::registerRenderHook(
PanelsRenderHook::GLOBAL_SEARCH_BEFORE,
fn (): View => view('filament.views.general.complete-profil-btn'),
);
and the view is
<div class="relative flex">
<livewire:complete-profil/>
</div>
<div class="relative flex">
<livewire:complete-profil/>
</div>
Livewire complete-profil view
Livewire complete-profil view
<div>
<x-filament::button
x-data="{{ json_encode(['visible' => $visible]) }}"
x-show="visible"
outlined
color="danger"
icon="phosphor-identification-badge"
labeled-from="sm"
href="{{ $url }}"
tag="a"
>
{{ __('app.widgets.complete_profil_setup.button_label') }}
</x-filament::button>
</div>
<div>
<x-filament::button
x-data="{{ json_encode(['visible' => $visible]) }}"
x-show="visible"
outlined
color="danger"
icon="phosphor-identification-badge"
labeled-from="sm"
href="{{ $url }}"
tag="a"
>
{{ __('app.widgets.complete_profil_setup.button_label') }}
</x-filament::button>
</div>
10 replies
FFilament
Created by yagrasdemonde on 2/29/2024 in #❓┊help
Problem refreshing component
CompleteProfil.php
CompleteProfil.php
class CompleteProfil extends Component
{
public bool $visible;

public string $url;

protected $listeners = [
'myevent' => 'render',
];

public function mount(): void
{
$this->url = EditProfile::getUrl();
$this->visible = $this->getVisibility();
}

public function getVisibility(): bool
{
if (auth()->user()->extra) {

if (! auth()->user()->extra->firstname) {
return true;
}

return false;
}

return true;
}

public function render(): View
{
return view('livewire.complete-profil');
}
}
class CompleteProfil extends Component
{
public bool $visible;

public string $url;

protected $listeners = [
'myevent' => 'render',
];

public function mount(): void
{
$this->url = EditProfile::getUrl();
$this->visible = $this->getVisibility();
}

public function getVisibility(): bool
{
if (auth()->user()->extra) {

if (! auth()->user()->extra->firstname) {
return true;
}

return false;
}

return true;
}

public function render(): View
{
return view('livewire.complete-profil');
}
}
10 replies
FFilament
Created by yagrasdemonde on 2/29/2024 in #❓┊help
Problem refreshing component
EditProfile.php
EditProfile.php
class EditProfile extends Page implements HasForms
{
use Concerns\InteractsWithFormActions;
use InteractsWithForms;

protected static string $view = 'filament.pages.auth.edit-profile';

protected static ?string $slug = 'profil';

protected static bool $shouldRegisterNavigation = false;

public ?array $profileData = [];

public function mount(): void
{
$this->fillForms();
}

protected function getForms(): array
{
return [
'editProfileForm'
];
}

public function editProfileForm(Form $form): Form
{
return $form
->schema([
//Fields here
])
->model($this->getUser())
->statePath('profileData');
}

public function updateProfile(): void
{
try {
$data = $this->editProfileForm->getState();

$this->handleRecordUpdate($this->getUser(), $data);
} catch (Halt $exception) {
return;
}
$title = __('app.pages.auth.edit_profile.notifications.section_information');

$this->dispatch('myevent'); //<- My event
$this->sendSuccessNotification($title);
}

protected function getUpdateProfileFormActions(): array
{
return [
Action::make('updateProfileAction')
->label(__('filament-panels::pages/auth/edit-profile.form.actions.save.label'))
->submit('editProfileForm'),
];
}

protected function fillForms(): void
{
$data = $this->getUser()->attributesToArray();

$this->editProfileForm->fill($data);
}
}
class EditProfile extends Page implements HasForms
{
use Concerns\InteractsWithFormActions;
use InteractsWithForms;

protected static string $view = 'filament.pages.auth.edit-profile';

protected static ?string $slug = 'profil';

protected static bool $shouldRegisterNavigation = false;

public ?array $profileData = [];

public function mount(): void
{
$this->fillForms();
}

protected function getForms(): array
{
return [
'editProfileForm'
];
}

public function editProfileForm(Form $form): Form
{
return $form
->schema([
//Fields here
])
->model($this->getUser())
->statePath('profileData');
}

public function updateProfile(): void
{
try {
$data = $this->editProfileForm->getState();

$this->handleRecordUpdate($this->getUser(), $data);
} catch (Halt $exception) {
return;
}
$title = __('app.pages.auth.edit_profile.notifications.section_information');

$this->dispatch('myevent'); //<- My event
$this->sendSuccessNotification($title);
}

protected function getUpdateProfileFormActions(): array
{
return [
Action::make('updateProfileAction')
->label(__('filament-panels::pages/auth/edit-profile.form.actions.save.label'))
->submit('editProfileForm'),
];
}

protected function fillForms(): void
{
$data = $this->getUser()->attributesToArray();

$this->editProfileForm->fill($data);
}
}
10 replies
FFilament
Created by neerajk on 2/20/2024 in #❓┊help
Repeater: How can I conditionally show/hide Delete button in Repeater?
You should check (array $arguments, Repeater $component) inject in action button
8 replies
FFilament
Created by yagrasdemonde on 2/12/2024 in #❓┊help
Possible to use configureUsing for Filament\Tables\Actions\ActionGroup ?
Great !! Thank you very much
4 replies