-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Class "string" does not exist #5479
Comments
Friendly ping @silasjoisten |
I am also running into this bug. I'm using a custom Geography doctrine type from the Doctrine PostGIS package. The crud controller search works until I add an entity attribute using one of the PostGIS doctrine types:
|
Lol, bug from November and still not fixed? |
@dehy @MirandaCalls @OskarStark I made MR with fix: #5568 |
Fixed in #5568. Thanks a lot for fixing it! |
Describe the bug
I'm searching in a CrudController and got
Class "string" does not exist
To Reproduce
DoctrineEnumBundle
(see below)Additional context
Why ? DoctrineEnumBundle defines classes that makes us able to use enum in entities in the form of string. So the doctrine type is a subclass of
DoctrineEnumBundle\...\AbstractEnumType
but the stored value is a string.The forms would display a
<select>
widget with those 2 options and I can easily render the human readable text with a simple twig filter. The effective property value stored by doctrine is one of theconst
values (strings).Potential solution
The problematic line (L149) with context
EasyAdminBundle/src/Orm/EntityRepository.php
Lines 136 to 152 in 76d8585
As I undertand, this lib search for the property Doctrine type, and if it doesn't find default one (string, boolean, array...), it thinks it should be a custom PHP Class and try to Reflect it. But in my case, it's a custom doctrine type with a php scalar type.
My workaround for my case
The text was updated successfully, but these errors were encountered: