简体   繁体   中英

Node “interest” notification in drupal

My question is quite simple (i think) but cannot find the right module for that.

I'm working on a small classified website in which i have a bunch of nodes. I display them using views.

I'd like for any (authenticated with role) user of the website to be able to click on a kind of button like "I'm interested" which will trigger an event doing various actions like 'changing one cck field' on that content-type and also send an e-mail to the author of the classified.

Pretty straight forward but no clue on where to start, which module should i use ?

For this, you can use the Flag Module and Rules Module

In your view, you can create a relationship to flags to allow the use of other 'fields'.

Using Rules, create a new rule that is triggered when a node is flagged (or unflagged). Rules allows you to do both: changing a CCK field and sending out emails when an event occurs.

Walk-through:

  1. Install and enable the Flag Module and Rules Module
  2. Create a new flag at "admin/build/flags"
  3. Edit/Create you classified view, add a relationship to Flags: Node Flag and choose > the name of the flag you just created.
  4. Under "fields" add Flags: Flag link and configure as you like
  5. Add a new rule at "admin/rules/trigger/add" for the event A node has been flagged,
    under "FLAG NAME"
    A node has been flagged,
    under "FLAG NAME"
  6. Add action to perform of Populate a field under the heading CCK
  7. Add action to perform of Send a mail to a user under the heading System and configure your desired settings.

Then when a user clicks the "interested" flag a field will be populated and email sent.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM