π”…π”˜π”‡π”ž
π”…π”˜π”‡π”ž
FFilament
Created by π”…π”˜π”‡π”ž on 6/20/2024 in #β“β”Šhelp
Rich Editor + Spatie?
Is there any easy way to have uploaded files be processed through spatie? The docs on the rich editor don't mention it. On the github, I see it has a HasFileAttachments contract, but I'm not sure how to expand the RichEditor to support spatie. Any help or examples would be awesome!
1 replies
FFilament
Created by π”…π”˜π”‡π”ž on 6/12/2024 in #β“β”Šhelp
JSON keys get overriden if they are not used in a form.
I am trying to modify some keys in a json array for a Spatie Media item. The json array has values that are not exposed to the front end.
Textarea::make('custom_properties.caption')
->label('Caption')
->columnSpanFull(),

TextInput::make('custom_properties.alt_text')
->label('Alt text')
->columnSpanFull(),
Textarea::make('custom_properties.caption')
->label('Caption')
->columnSpanFull(),

TextInput::make('custom_properties.alt_text')
->label('Alt text')
->columnSpanFull(),
I have a custom_properties.width / custom_properties.height that is being set through a job, so these values don't make sense to be a part of the form builder. When I save my model, the entire json array is overriden instead of just the keys I am accessing. I would love to know if this is a bug or if I missing something to tell filament to only update those keys.
7 replies