I am wondering if somebody has wrote something to integrate the Privatemsg module and Activity module. Any help would be great.

#2 privatemsg_activity.zip1.65 KBneurovation.kiwi
Members fund testing for the Drupal project. Drupal Association Learn more


Lasac’s picture


neurovation.kiwi’s picture

Status: Active » Needs review
1.65 KB

hi folks

i just implemented it. please give your 2 cents!


Berdir’s picture

Status: Needs review » Needs work

Interesting, just a few first thoughts...

- The .info file seems to be missing...

- The module seems to integrate with token.module and trigger.module too. Is that necessary for activity or why are you doing that? Note that we are working on token integration for Drupal 7 here: #511796: Support tokens in private messages. Maybe that should be splitted up into several modules (so that you could use token integration without activity.module). Actually, token integration could live directly in privatemsg.module IMHO as these are only hook_implementations.

- Please always use two spaces instead of tabs. It is currently a mix and that totally messes up the display when viewing it with an editor that makes tabs 4 spaces wide.

- I have never used activity before but a few things seem overly complex. For example, you're defining a new hook and call that inside hook_privatemsg_message_sent(). Why don't you do that trigger stuff directly in that hook?

- I don't understand what the grants hooks are for but the query that loads the mid's of a user could return a rather big result set...

- Not yet necessary, but if you can upload the module as a patch (Creating patches with new files is tricky but possible with tools like cvsdo. See http//drupal.org/patch/create), I can give you a more details review.

neurovation.kiwi’s picture

ad info - file:
since this is no finished module yet - i didn't give one.

ad tabs:
big oopsi on my side. corrected it

ad patch:
not yet tested enough to really give a useable version - i will post a patch in a few weeks.

ad other stuff:
well - that's how activity works :(

ad token:
i'm fine when it would be integrated.


sirkitree’s picture

Was this for Activity 2.x?

ptmkenny’s picture

Version: » 6.x-2.x-dev
Category: support » feature
oadaeh’s picture

Issue summary: View changes
Status: Needs work » Closed (won't fix)

This issue is being closed because it is against a branch for a version of Drupal that is no longer supported.
If you feel that this issue is still valid, feel free to re-open and update it (and any possible patch) to work with the 7.x-1.x branch (bug fixes only) or the 7.x-2.x branch.
Thank you.