Maagalhaes
Maagalhaes
FFilament
Created by Maagalhaes on 12/7/2023 in #❓┊help
Parameters for index and create is it possible?
Hello! I have a question, I hope you can help me. I created a resource with edit, create and index pages. I would like to know if I can pass parameters to these pages. Example: I created an action on the table that calls a resource (index) and another case the resource (create) but I would like to pass parameters to index and create, is there any way? Thanks.
14 replies
FFilament
Created by Maagalhaes on 9/5/2023 in #❓┊help
Collapse a menu option
I need a way that the menu only opens a single option, if you have an option open and click on another, just the clicked one remains open. It is possible?
7 replies
FFilament
Created by Maagalhaes on 8/15/2023 in #❓┊help
TextInput does not add mask to field
Sorry for the bad english. I have problems when I add a TextInput with mask, because the mask is not added. When inspecting an element in firefox I see that two blur and two input events are loaded, one from the filament and the other from the livewire, when I cancel the propagation of the livewire by inspecting the mask it works normally, but I haven't found a way to do that in the code. I'm making use of the Resource, creating the TextInput.
public static function form(Form $form): Form
{
return $form
->schema([
Section::make('Dados Gerais')
->icon('heroicon-o-document-text')
->schema([
Select::make('user_id')
->label('Responsável')
->relationship('user', 'name')
->required(),
TextInput::make('nome')
->label('Nome Academia')
->required()
->maxLength(255),
TextInput::make('cnpj')
->label('CNPJ')
->mask('99.999.999/9999-99')
->placeholder('99.999.999/9999-99')
->required()
->maxLength(18)
]),
// other methods
]);
}
public static function form(Form $form): Form
{
return $form
->schema([
Section::make('Dados Gerais')
->icon('heroicon-o-document-text')
->schema([
Select::make('user_id')
->label('Responsável')
->relationship('user', 'name')
->required(),
TextInput::make('nome')
->label('Nome Academia')
->required()
->maxLength(255),
TextInput::make('cnpj')
->label('CNPJ')
->mask('99.999.999/9999-99')
->placeholder('99.999.999/9999-99')
->required()
->maxLength(18)
]),
// other methods
]);
}
22 replies