Closed bobsingor closed 6 days ago
It think it doesn't work for you because you're using both decorators at the same time like this
@FilterField(() => String, { sqlExp: 't.title'})
@FilterField({exclude: true})
Can you show your DTO?
this PR fixes my issue https://github.com/Adrinalin4ik/Nestjs-Graphql-Tools/issues/48
It think it doesn't work for you because you're using both decorators at the same time like this
@FilterField(() => String, { sqlExp: 't.title'}) @FilterField({exclude: true})
Can you show your DTO?
No I am using only one decorator per field. Try using multiple fields with exclude property in your DTO. Only one will work.
Same problem for SortingField
Same problem for SortingField
I added that one also to the PR! @Adrinalin4ik Please take a look and verify this issue #48!
@bobsingor I think you can also update SortingField
accordingly
PR look good so far. I wanna test it tomorrow and if everything is fine, then merge it. Thanks for fixing it.
The exclude on field decorator is currently not working because it is not properly restored from metadata at initialization of GraphqlFilterTypeDecoratorMetadata.
This pull request fixes that issue