Leaderboard variables
Variable | Description |
---|---|
total | Total, if the leaderboard has a goal e.g. {{ leaderboard.total }} |
display_name | Name of leaderboard e.g. {{ leaderboard.display_name }} |
time_range_name | Time period of leaderboard e.g. {{ leaderboard.time_range_name }} |
goal_name | What's being calculated e.g. Amount of Political Capital, amount of numbers called in a phone bank, etc. |
goal_name_short | Abbreviated name of what's being calculatede.g. "pc," "calls made," etc. |
goal | Goal total set in page's settings e.g. {{ leaderboard.goal }} |
has_goal? | Checks if a goal has been set for the page e.g. {% if leaderboard.has_goal? %} -- see loop example in "total" variable above |
has_met_goal? | Checks if the goal has been met e.g. {% if leaderboard.has_met_goal? %} |
percent_of_goal | Percent of goal met e.g. {{ leaderboard.percent_of_goal }} |
display_number_results | Number of leaderboard rankings being displayed e.g. |
number_results | Total number of rankings e.g. {{ leaderboard.number_results }} |
entries | Array of leaderboard_entry e.g. |