Drupal Views displays the latest content by limiting taxonomy to one node

I want to create a view where all 5 of my taxonomic conditions will be displayed and then it displays the last published node, but it is limited to 1. For example:

Tax Term 1
Latest Node Published

Tax Term 2
Latest Node Published

etc.

I am currently grouping by taxonomic term to display all published nodes, sorted descending by publication date. I can't figure out how to restrict nodes to only display one item for a taxonomic term.

Any help would be greatly appreciated.

+2


a source to share


4 answers


This is possible with Views 3. I tested this on D7 but should work with D6 as well.



  • Add a new type of type - taxonomic terms
  • Add Relationship - Taxonomy term: Representative node
  • Other - Use Aggregation: Yes
  • Add Field - Content: Title. Change aggregation options for group results together
+7


a source


It's not great if you have many nodes, but I've done it in other cases using a filter for Promoted to First Page - then you just make sure you only advertise one node at a time.



+1


a source


I would suggest using a combination of ans views panels. First, create (or use the default) view for nodes that take a taxonomy term as an argument. Second, create a dashboard page containing five regions. Each region should be filled with a point of view (in fact, it will be the same view from the first step, but with different arguments). Inside the ui panels, you can limit the number of displayed posts of each type, set this value to one, so that only one article is displayed for each term.

Panels: http://drupal.org/project/panels

Views: http://drupal.org/project/views

0


a source


I would recommend checking out the Views Group By module.

http://drupal.org/node/389230

The tutorial above actually describes almost what you are trying to do.

0


a source







All Articles