D5300
D5300
FFilament
Created by D5300 on 4/8/2025 in #❓┊help
Field is hidden test - Pest
Hi guys, I have on my tenant create a form which I want to test. It has a depending field which I try to test if its visible or not. But using isVisible or isHidden, both return an error: Failed asserting that a field with the name [company_name] is hidden on the form named [form] on the [App\Filament\Pages\Tenancy\RegisterWebsite] component. Failed asserting that an array does not have the key 'company_name'. My test looks like the following:
it('hides the company name field when you want to create a new company', function () {
$user = newUser();
$this->actingAs($user);
$company = Company::factory(['owner_id' => $user])->create();
Website::factory(['company_id' => $company])->create();

$livewire = livewire(RegisterWebsite::class);

$livewire->fillForm([
'company_id' => Company::first()->id
]);

$livewire->assertFormFieldIsHidden('company_name');
});
it('hides the company name field when you want to create a new company', function () {
$user = newUser();
$this->actingAs($user);
$company = Company::factory(['owner_id' => $user])->create();
Website::factory(['company_id' => $company])->create();

$livewire = livewire(RegisterWebsite::class);

$livewire->fillForm([
'company_id' => Company::first()->id
]);

$livewire->assertFormFieldIsHidden('company_name');
});
The form will be in a seperate message as I dont have discord premium 😄
3 replies
FFilament
Created by D5300 on 4/2/2025 in #❓┊help
Guidance custom field
Hi, Im looking for someone that can guide me with creating a custom field in Laravel Filament. Will be by discord and I will pay for it (don't know if this is the right channel so if im wrong, correct me). Custom field is about using data from the active form in that component. Cheers!
5 replies
FFilament
Created by D5300 on 3/12/2025 in #❓┊help
Exporting by command line
Hi! Is it possible to make a export command with the Filament Excel exporter through the terminal? I can't really find anything about it.
3 replies
FFilament
Created by D5300 on 2/20/2024 in #❓┊help
Set description for CheckboxList dynamically
Hi, how can I access the collection which is loaded from the relations method? I dont see how I can access the relationship data
CheckboxList::make('menuSections')
->hiddenLabel()
->relationship('sections', 'title')
->descriptions(function ($collection) {
return $collection->pluck('description', 'id')->toArray();
})
->bulkToggleable()
CheckboxList::make('menuSections')
->hiddenLabel()
->relationship('sections', 'title')
->descriptions(function ($collection) {
return $collection->pluck('description', 'id')->toArray();
})
->bulkToggleable()
2 replies
FFilament
Created by D5300 on 1/13/2024 in #❓┊help
Vue 3 in custom page
For my application I need a custom page with a Vue app. Is it possible to to achieve something like this or am I bound to Livewire?
20 replies
FFilament
Created by D5300 on 1/12/2024 in #❓┊help
MorphTo morpheable resources
Hi, I got a morph relation which looks like: RentReservation House Apartment Car A RentReservation is always attached to a house, apartment or car. When I open the RentReservation resource, I see all the RentReservations. Is it possible to create a resource for each morph type? How about creating those relations? I can't find it in the docs
2 replies
FFilament
Created by D5300 on 1/4/2024 in #❓┊help
"use" table/infolist fields on edit page
No description
3 replies
FFilament
Created by D5300 on 1/3/2024 in #❓┊help
Looking for custom input field (paid)
Hi, Im looking for a package which has just a button. On click, fire the afterStateChanged function so I can manipulate another field. Contact me for more details
2 replies