[Tiki-devel] Get user`s rating on tracker field?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Tiki-devel] Get user`s rating on tracker field?

Fernando Vergos Torres
Hello Tiki experts,

I need something, but I`m not sure if it needs to be developed, or there is a way I can do right away,

I have a tracker where each user can vote on some items. Then, I have a CustomFilter plugin to dispay those items, but I wanted to filter the items that didn`t have a vote by the user yet. Or also sort depending on the user`s vote.

Found only those on documentation, but none allows me to filter/sort by the own user`s vote/rating:
  • tracker_field_PERMNAME/ID contains the average
  • tracker_field_PERMNAME/ID_sum contains the vote totals
  • tracker_field_PERMNAME/ID_count contains the number of votes

Anyone ever needed this?

Thanks

Fernando

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
TikiWiki-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [Tiki-devel] Get user`s rating on tracker field?

Jonny Bradley-4
Hi Fernando

Found this empty draft reply on this, didn't mean to ignore you, but it's not trivial i think. The problem is that we can't index things for every single user (can we?) so you would need to get this from the field directly (i.e. the database).

Maybe using trackerrender can get you the info and then some preg_match trickery in a smart template might be able to dig the data out of the rendered output?

jb




> On 26 Mar 2017, at 23:53, Fernando Vergos Torres <[hidden email]> wrote:
>
> Hello Tiki experts,
>
> I need something, but I`m not sure if it needs to be developed, or there is a way I can do right away,
>
> I have a tracker where each user can vote on some items. Then, I have a CustomFilter plugin to dispay those items, but I wanted to filter the items that didn`t have a vote by the user yet. Or also sort depending on the user`s vote.
>
> Found only those on documentation, but none allows me to filter/sort by the own user`s vote/rating:
> • tracker_field_PERMNAME/ID contains the average
> • tracker_field_PERMNAME/ID_sum contains the vote totals
> • tracker_field_PERMNAME/ID_count contains the number of votes
>
> Anyone ever needed this?
>
> Thanks
>
> Fernando
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________
> TikiWiki-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
TikiWiki-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-devel
Loading...