Hello, I'm not sure if this issue is duplicated (search on issues seems to work strange in drupal website now) I'd like to know how to add categorized points using Rules, it seems it's not possible to select the category. Any help? Thanks!
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | userpoints-378910-1826174.patch | 446 bytes | thijsvdanker |
Comments
Comment #1
daniorama commentedHello, I'm not sure if this issue is duplicated (search on issues seems to work strange in drupal website now) I'd like to know how to show categorized points on Views. I cannot find any option to select the category. Thanks!
Comment #2
jredding commentedits not currently possible to select the category for the points.
Comment #3
jredding commentedfor views or for rules.
Comment #4
daniorama commentedI'm trying both, that's why I have written two different issues. But I think Drupal made something strange with the issues and mix them (I wrote this while Drupal was changing to 6) This should be two.
Knowing that is not possible to select categories with Rules I just leave this issue with the Views question. Sorry for the mixing :( Maybe I should close this one and start a new because I cannot change the first post...
I tried to create both a page view and a block view but I couldn't find how to show just a category or show all of them. Thanks
Comment #5
asak commentedWhat i get in views after adding a "Userpoints: points" field is a row for every category of points for every user.
what i need is a column for every category, so that a user would have one row with multiple points columns.
Possible...?
Comment #6
qandeel commentedIts a simple thing ...
You can use hook_userpoints($op, $params){---}
OP = 'points before' and params = parameters passed by userpoint module now you can do some manipulation in your module by calling this hook...and assign cataegory ID which is a termID to $params['tid'] and then again call userpoints_userpointsapi($params) function to process updated $params variable and by doing this you can add your points to specific category...
regarding Views... i think its again a simple thing to do... only we need to add extra logic in userpoints module in hook_views_data() to apply termid in joins... i dont know how to do that.. and if somebody have some experinnce in playing with views can easily do that...
any thought from community is welcome, for implementation of category points let me know if some one need a code example
Qandeel
Comment #7
thijsvdanker commentedThis joins the userpoints table with the taxonomy table (term_data) so you can use all the available taxonomy information (field name etc.)
Comment #8
cerup commentedthijsvdanker Is this patch used for views? Can you give an example of how to use it? I applied the patch but I don't seem to see any type of relationship between terms and user points with this patch.
Comment #9
Bilmar commentedsubscribing
Comment #10
robby.smith commented+1 subscribing
Comment #11
YK85 commentedI tried #7 and patch applied but I don't see any text in Userpoints Category column.
I have 2 categories created and users have points from both and values in Points column is shown correctly.
Comment #12
Bilmar commentedsame - chatted with yaz085 and we don't know how to use this at the moment
Comment #13
berdirPatch for Views category is here #871126: Fix Bugs in Views Integration (only for D7, will be backported).