Good morning, I have a filament form in a modal on a custom livewire page. I have a select field which is dependent on another select field. Nothing crazy, just use GET $get()... Atleast that's what I thought.
Because its appearing to not find those fields for some reason. But I have no Idea what's going wrong.
It is finding the "answer" field outside of the FieldSection, but all the fields within are simply nowhere to be seen.
Repeater::make($step . '.answers')
->reorderable(false)
->hiddenLabel()
->minItems(1)
->schema([
TextInput::make('answer')
->required(),
Fieldset::make('Filter (Not required)')
->columns(3)
->schema([
Select::make('attributes')
->searchable()
->columnSpan(1)
->native(false)
->options($productAttributes)
->live(),
Select::make('operator')
->columnSpan(1)
->native(false)
->options(FilterOperators::get()),
Select::make('attributeValues')
->searchable()
->columnSpan(1)
->native(false)
->multiple()
->options(function (Get $get) use ($productAttributes) {
$attribute = $get('attributes');
dd($get());
if (!$attribute) {
return ['' => 'no-attribute'];
}
$options = app(GetSiteProductAttributesValues::class)(
site: SiteTenant::current()
attribute: $attribute);
dd($get(), $options, $attribute, $productAttributes);
return $options;
}),
]),