Some might be quite taken back by me saying that Taxonomy is not a desirable option for classifying content. How can I make such a negative comment about something so tightly engrained in Drupal for so many years? How can I dare say that Taxonomy, even though still in Drupal 8 core is a bad idea? The answer is simple...I cannot commit to a classification solution that allows for unlimited data entry errors, creates very heavy weight Views queries and promotes unnecessary layers of data maintenance steps and navigation. While I'm sure there are many that would willingly debate what I have said, I find it a better use of time to illustrate the basis of my comment, in real-world terms and how my comment directly relates to the Relativity Data Model.
Sometimes, when learning a new way of doing thigs, it helps to visualize and bring into perspective the "real world" scenario. So here's one to ponder... Assume you go to a bookstore and are looking to find a book on building model airplanes. You browse, but need help finding the target book or books because book storage areas are not clearly and intuitively marked. The store owner happily points you to a specific area in the store, pointing out the specific shelf, area of the shelf and perhaps general position of the book. It might even be something like row 2, shelf 3, position 5. But ask yourself a simple question... when trying to find this book, should I go directly to the coordinates given, or, maybe, I can find this same book in multiple places in the store. My point is, to classify this book, the best course of action is to identify it's "target" audience. In this case, that would be hobbyists. So, to classify this book, really only warrants a single term, "hobbies". There isn't much of a point in having the same book in multiple places being classified with several unrelated terms. Taxonomy, in my eyes, lends itself to automatically lead you down the path of over-classifying.
Remember, our job as site builders is to bring users the content they desire in the smallest path possible. The magic also is to bring the user back to where they began just as quickly and intuitively. So with that said, does over classifying help us in that concept? Not at all. If anything, it over complicates the "go to" and "come back" simplicity.
Let's go back to our Event content type and use that for a mental visual. To classify, or, describe a piece of content, we really only need a single value. With this said, try to clear your mind of the concept of taxonomy and instead, use this thought process... A node is described, or classified by a type controller. Whoa... what's a controller? Quite simply, a controller, is just another node. But the magic of this "other" node is that it relies on only one field, Drupal's core Title field.
So, from scratch, with a clear mind, try this:
- Create a content type called Event with a machine name of even
- Create a content type called Event Type with a machine name of eventy (note the "ty" is your visual identifier that it is a controller)
- Enter some content for the Event Type node using "descriptive terms" such as Picnic, Lecture, Concert etc
- Come back to your Event content type and add a new field called Event Type as an entity reference field with a machine name of even_eventy_ref using the select list widget
- Enter an Event node and you'll now have a drop down field where you can in a very elegant way, describe the Event you are currently creating.
Pretty cool, but, there's even more cool stuff we can do with minimal effort.
- Edit your Event Type content type and add a new field named Event Type Icon as an image field using the machine name eventy_icon_img
- Edit your Event Type nodes and add an icon image to each one
- Come back and edit your Event content type, then edit the Event Type entity reference field. Scroll down to the bottom and check the box for Render Views Filter as select list
The previous three bulet points may seem unclear, but rest assured, you'll see the explicit value very very soon.
One last exercise:
- Come back to your Event content type, edit the Event Type entity reference field and ensure that you have Entity Connect enabled for both Add and Edit.