Exclude a user from the leader board in a CSM Community

codycotulla
Tera Guru

We want to exclude certain users from the leader board in our CSM Community. 

For example, we have an employee with a lot of points and we don't want that employee to appear on the leaderboard.

Screenshot 2024-08-12 at 10.41.06 AM.png

What is a method that I can use to exclude the employee from appearing on the leaderboard in the community?

Appreciate any help. Let me know you need additional information.

 

Thanks!

1 ACCEPTED SOLUTION

Slava Savitsky
Giga Sage

One way to do it is to change the code of the script includes that fetch data for the leaderboard, which I don't recommend because sooner or later it will get you into trouble. It is going to cause significant maintenance overhead and is likely to break after an upgrade.

 

A less intrusive approach would be to use a before-query business rule. The leaderboard pulls data from [sn_gamification_point_aggregate] table. A before-query business rule could seemly filter out some of the records based on referenced Live Profile. Ideally, you should not hardcode the users you want to filter out directly in the business rule code. Instead, consider either filtering on their attributes (Company, Department or similar) or adding them to a Group and filtering by group membership.

 

View solution in original post

1 REPLY 1

Slava Savitsky
Giga Sage

One way to do it is to change the code of the script includes that fetch data for the leaderboard, which I don't recommend because sooner or later it will get you into trouble. It is going to cause significant maintenance overhead and is likely to break after an upgrade.

 

A less intrusive approach would be to use a before-query business rule. The leaderboard pulls data from [sn_gamification_point_aggregate] table. A before-query business rule could seemly filter out some of the records based on referenced Live Profile. Ideally, you should not hardcode the users you want to filter out directly in the business rule code. Instead, consider either filtering on their attributes (Company, Department or similar) or adding them to a Group and filtering by group membership.