1

How do I create a heartbeat activity that shows only user related activity? For example, user 1 is related to user 2 and 3 (user relation module). When user 1 is logged in, he should be able to see activity only from user 2 and 3 and not from other users; similarly, it should happen for user 2 and 3. I'm logging the activity using the heartbeat_api_log() function.

UPDATE

The orthodox method of achieving this is to use hook_heartbeat_related_uids().

It works fine, but in order to fine tune according to your own customizations you might want to use hook_heartbeat_load(), and remove unnecessary messages based on a condition you specify.

2
  • are you using 6 or 7?
    – uwe
    Oct 22, 2011 at 12:00
  • 7 - sorry I didn't mention
    – user2948
    Oct 22, 2011 at 12:06

0

Your Answer

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