Attribute class "App\Entity\Get" not found
XyloxExe opened this issue · 2 comments
XyloxExe commented
Hi
i want to use VichUploader on API Platform but I get a error
I use composer require vich/uploader-bundle
I add Vich\UploaderBundle\VichUploaderBundle::class => ['all' => true], in the bundle.php
And I create the file vich_uploader.yaml and add :
api/config/packages/vich_uploader.yaml
vich_uploader:
db_driver: orm
metadata:
type: attribute
mappings:
media_object:
uri_prefix: /media
upload_destination: '%kernel.project_dir%/public/media'
# Will rename uploaded files using a uniqueid as a prefix.
namer: Vich\UploaderBundle\Naming\OrignameNamer
I go on http://localhost:8000/api and I have a error Attribute class "App\Entity\Get" not found
garak commented
You should provide the relevant part of code
JulienRAVIA commented
100% sure it's not a bundle problem. You Just imported badly your API Platform Get class in your entity