Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is a drupal View useful for this use case

I have a list of nodes that I want to present to the user. The user then picks 3 and I need to remember that decision so I can present them in a smaller list later (your choices list).

To present the full list of nodes, I will just use views to get all published nodes.

The question is how do I store those 3 choices so I can pull them in the "your choices list"? What structure should I use to save them? create a content type called list or use views. Not sure, or there's something more logical for this use case?

like image 234
zaplin Avatar asked Jul 29 '10 19:07

zaplin


1 Answers

You most definitely want to take a closer look at the Flag module. It provides a flexible system for 'flagging' (or marking) nodes, users and comments, along with good views integration.

Using this, you could create a flag 'favorite', set it as 'per user' and your users can use this to mark nodes. With the views integration, you can create custom views filtering on those flags in many ways, thus you can easily create pages and blocks that display those favorites.

I'm not sure if it supports a limitation to e.g. three flags per user out of the box, but it also comes with an API so you should be able to influence things like that (no guarantee, though ;)

You might also want to check the following, but I have no experience using them, so no idea if they are good and/or fit your bill:

  • Favorite Nodes module
  • Favorites module
like image 182
Henrik Opel Avatar answered Oct 21 '22 12:10

Henrik Opel