Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
It's always seemed a bit odd to me that points are awarded even when nodes/comments go into moderation.
I understand there's a points moderation system, but would it not be a simple matter to add the publication condition to the awarding of points?
Comments
Comment #1
Dialer3 CreditAttribution: Dialer3 commentedThis is really needed bugfix! It will really increase the degree of automation of ppl's work and save lots of time. I was shocked not finding this fix here and now going to write it by myself.
Comment #2
Dialer3 CreditAttribution: Dialer3 commentedWell, the hack issued simple:
Edit userpoints_nc.module
function userpoints_nodeapi
after
add
put closing braket } below after
after
add
after
add
put closing braket } below before
Enjoy.
Comment #3
esllou CreditAttribution: esllou commenteddialer, thanks for this. Could you post a patch that the module maintainer might consider for inclusion?
thanks again...this module has been screaming out for this from day one.
Comment #4
fourmi4x CreditAttribution: fourmi4x commentedI agree it would be awesome to have this directly in the module as an option. And many thanks for the solution !
Comment #5
FireBoss CreditAttribution: FireBoss commentedI accomplished this for my site today by changing a function within userpoints_nc module.
See the post I made for the code:
http://drupal.org/node/416358
My code covers quite a bit more areas than the code mentioned above - insert, delete, update code has all been coded to work properly to award and delete points upon changes to the publication status. I wasn't able to find a good solution for my site so I made one for myself and decided to post it here for others.
The only problem I could see with adding this code to the module code is that it eliminates the possibility for someone to have the points awarded as normal, although I'm sure this change could be done with ease by the maintainer of the module.
Comment #6
biolizard89 CreditAttribution: biolizard89 commentedWill the fixes posted in this issue also work for comments, or just nodes? I would like unpublished comments to not generate userpoints; I can't tell whether the fixes posted here will accomplish this.
Thanks.