-
Notifications
You must be signed in to change notification settings - Fork 211
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
'firstName' filter is not supported in OroCRM Rest JSON API #306
Comments
What version of oro platform do you use? |
@anyt 2.6.1 |
@anyt I've tested it in a fresh application of OroCRM, without any custom bundle. |
@anyt This error also appears in Oro demo (https://demo.orocrm.com/desktop/api/doc/rest_json_api). Try to use the 'firstName' filter to see the error. |
There is documentation in first tab of every methods, and there is no firstName filter described. But it's strange that this filter was not enabled by default I don't see any configuration responsible for that, let me check. |
@anyt Notify us if you have any news about this, or some workaround until the final solution. |
Hello @pedrofurtado, |
@vsoroka Could you give me an example code of |
File should be created at |
It's described at the beginning of documentation that @vsoroka mentioned before |
Yes, you should run the command. Forth paragraph form the above doc:
|
@anyt Thank you! I will try to package this issue into a new bundle. I will feedback you later about this. Thanks again! |
@anyt @vsoroka I created a micro bundle (https://github.com/pedrofurtado/orocrm-firstname-api-bundle) that has this funcionality out of box. |
Look like a good example of simple api customization. I guess the issue can be closed. |
@anyt Thanks for feedback! The issue can be closed. |
@pedrofurtado can you share publicly your micro-bundle ? It would be useful to us :) Thanks in advance ! |
@sadortun I uploaded the bundle to github: https://github.com/pedrofurtado/orocrm-firstname-api-bundle It is also available for download in Composer 👍 |
When I tested the Oro API in
/api/doc/rest_json_api#get--api-contacts
I've tried two filters. The first worked well, that is the field 'lastName' (See the image below):But when I change the filter to be 'firstName' (that Oro has a default field from installation), the endpoint not works, giving me an unexpected error (See the image below):
How do I, through the Oro REST API, select all contacts filtering by 'firstName'? Is this a bug?
Thanks!
The text was updated successfully, but these errors were encountered: