F
Filament2mo ago
fagner

Error on upload multiple files on livewire page component inside infolist.

Error on upload multiple files on livewire page component inside infolist.
9 Replies
toeknee
toeknee2mo ago
Ok
fagner
fagnerOP2mo ago
i try upload multiple files but show me errors on console livewire and hide modal.
public function form(Form $form): Form
{
return $form
->schema([
TextInput::make('situacao')
->autocomplete(false)
->required(),
Textarea::make('observacao'),
FileUpload::make('anexos.path')
->label('Anexos')
->multiple()
->panelLayout('compact')
->disk('do')
->storeFileNamesIn('anexos.nome')
->directory('demandas')
->visibility('public'),
]);
}
public function form(Form $form): Form
{
return $form
->schema([
TextInput::make('situacao')
->autocomplete(false)
->required(),
Textarea::make('observacao'),
FileUpload::make('anexos.path')
->label('Anexos')
->multiple()
->panelLayout('compact')
->disk('do')
->storeFileNamesIn('anexos.nome')
->directory('demandas')
->visibility('public'),
]);
}
livewire show console error: Uncaught TypeError: Cannot read properties of undefined (reading 'after')
fagner
fagnerOP2mo ago
hey man, I messed up when creating the post on discord, sorry
toeknee
toeknee2mo ago
Looks like it's related to your custom import that's failing somewhere in your app.js
fagner
fagnerOP2mo ago
my app.js have no imports
No description
fagner
fagnerOP2mo ago
When I upload only one file, it works, but when I add two or more files at once, the modal closes unexpectedly.
toeknee
toeknee2mo ago
Look at the start of your video the import error in app.js
fagner
fagnerOP2mo ago
ok thanks, i look but error is other. when i try upload file.
No description
toeknee
toeknee2mo ago
You are uploading in a n action, try adding: ->fillForm([]) to the action to be safe
Want results from more Discord servers?
Add your server