-
-
Notifications
You must be signed in to change notification settings - Fork 950
feat(doctrine): doctrine filters like laravel eloquent filters #6775
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
feat(doctrine): doctrine filters like laravel eloquent filters #6775
Conversation
fd22d9c to
93b3226
Compare
93b3226 to
6cfee88
Compare
|
@soyuka As requested, the swagger UI doc looks like this for the |
77cb4c6 to
fc7f5f1
Compare
|
@soyuka As requested, the swagger UI doc looks like this for the |
src/Metadata/Tests/Resource/Factory/ParameterResourceMetadataCollectionFactoryTests.php
Outdated
Show resolved
Hide resolved
2f4ec07 to
8f0620e
Compare
68d2dfb to
3736645
Compare
3736645 to
74919ff
Compare
74919ff to
4456cb1
Compare
4456cb1 to
7513e53
Compare
7513e53 to
eb9277d
Compare
eb9277d to
db108d5
Compare
db108d5 to
d9bc540
Compare
7047de6 to
3dde14a
Compare
e8b6dd9 to
d1ffc14
Compare
…platform#6775) * feat(doctrine): doctrine filters like laravel eloquent filters * fix: allow multiple validation with :property placeholder * fix: correct escape filter condition * fix: remove duplicated block --------- Co-authored-by: soyuka <[email protected]>
|
@vinceAmstoutz @soyuka I think, |
Why we should do that? @1ed |
|
Because new symbols like |
interface ManagerRegistryAwareInterface implemeted by ApiPlatform\Doctrine\{Orm,Odm}\Filter\AbstractFilter
api-platform#6775
…latform#6775) * feat(doctrine): doctrine filters like laravel eloquent filters * fix: allow multiple validation with :property placeholder * fix: correct escape filter condition * fix: remove duplicated block --------- Co-authored-by: soyuka <[email protected]>


mainCompletes #6749.
Goal:
Using Dotrine filters as we use Laravel Eloquent filters. Example using a
BooleanFilterwith Symfony and Doctrine:#[ApiResource] #[GetCollection( parameters: [ 'active' => new QueryParameter( filter: new BooleanFilter(), ), // support also for filter aliasing 'enabled' => new QueryParameter( filter: new BooleanFilter(), property: 'active', ), ], )] #[ORM\Entity] class FilteredBooleanParameter { // ... }TODO:
Will be done in another PR: