- Issue created by @heavystonehead
- 🇫🇷France lazzyvn paris
You can read the documentation carefully it basically looks like this
http://yourDrupal.host/jsonapi/entity_type/bundle?filter[field_data][condition][path]=field_data.text&filter[field_data][condition][value]=testreplace with your field
- 🇩🇪Germany heavystonehead
Thanks for the answer, but the question was how I filter the term. when I filter by the pattern I need to know the taxonomy ID, but I want to enter the name, which leads to an error.
http://yourDrupal.host/jsonapi/entity_type/bundle?filter[field_n_od_work...field_n_od_work.work_taxonomy&filter[field_n_od_work][condition][value]=123
http://yourDrupal.host/jsonapi/entity_type/bundle?filter[field_n_od_work...field_n_od_work.work_taxonomy.name&filter[field_n_od_work][condition][value]=test not working
- 🇫🇷France lazzyvn paris
Hum I see what you mean have you read the description of the module?
Please note: all custom fields are not entity fields, so you cannot benefit from field widget, field renderer, or the entity formatter. It's just for the data.
you can make 2 queries. 1st query with taxonomy to get tid by name and 2nd query you can search with data field with tid
- 🇩🇪Germany heavystonehead
thanks for the reply. I was hoping there was something more elegant that I didn't see. I will then do it this way (have to do it this way) by first searching for the word in the taxonomies, having a list of the IDs returned to me in order to filter the content based on the IDs. It's my first attempt with json api, I hope the many mini queries don't matter. (JavaScript)
- 🇫🇷France lazzyvn paris
LOL sad but true. I hope someone can continue to develop Normalizer datafield. All the output data will pass the class's EntityNormalizer data so we can override method normalize, it have to lookup the settings fields converting the tid to entity data, so performance will be lower. There are many projects that do not need this function so it will take a lot of time to seek support from others. Best you can do it yourself and send me the patch
- Status changed to Fixed
11 months ago 11:25pm 2 February 2024 Automatically closed - issue fixed for 2 weeks with no activity.