0

I am trying to create a taxonomy term reference field or the equivalent in a View that uses the uuid of a field in a custom table. This field can contain multiple uuids.

My first approach after having issues with the views_handler_field_taxonomy ( because the table does not contain the vid and tid fields ) was using joins and another table that contained all the necessary taxonomy fields. Although I got it to work the multiple joins caused the results to become pretty ugly ( lots of duplicates ). I may have to use this approach and clean up the results with custom code but I would definitely prefer not to.

So the question. Is there any straightforward way I'm missing to get my custom database field of comma separated uuids treated like a taxonomy term reference field by Views? I have tried a variety of different relationship handlers as well as field handlers in my hook_views_data but no luck. I have found very limited documentation and only the simplest tutorials for custom views field and relationship handlers. Any links to good ones and/or good sample code would be greatly appreciated.

I would also be completely fine with a way to treat a custom entity property as a taxonomy term reference field.

1 Answer 1

0

The easiest solution would be to use some sort of system to synchronize those terms from whatever data set you have to real taxonomy terms.

It would probably function similarly to Node Auto Term.

1
  • After looking at the nat code they are using a simple join which would have worked for me except for the fact that I need to allow multiple values. It's definitely the right idea of what I need, just missing a necessary component.
    – sareed
    Commented Apr 22, 2016 at 13:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.