1. Documentation
  2. Frontend Reports
  3. [gamipress_frontend_reports_points_chart]

[gamipress_frontend_reports_points_chart]

Render a chart with user points balances of a specific points type.

Attributes:

  • type – The points type.
  • amount – The amount type(s) to use as chart values. Accepts: earned, deducted, expended
  • current_user – Show points balances of the current logged in user. Accepts: yes or no Default: yes
  • user_id – Show points balances of a specific user.
  • style – Style to render the chart. Accepts: inline, line, bar, horizontal-bar, radar, doughnut, pie, polar Default: inline
  • legend – Show chart legend. Accepts: yes or no Default: no
  • background – Single or comma-separated list of colors to use as chart statistics background color. Accepts colors in format hex, rgb and rgba. Default: rgba(54,162,235,0.5),rgba(255,99,132,0.5),rgba(75,192,192,0.5),rgba(255,205,86,0.5),rgba(201,203,207,0.5)
  • border – Single or comma-separated list of colors to use as chart statistics border color. Accepts colors in format hex, rgb and rgba. Default: #36a2eb,#ff6384,#4bc0c0,#ffcd56,#c9cbcf
  • grid – The grid lines color. Accepts colors in format hex, rgb and rgba. Default: rgba(0,0,0,0.1)
  • max_ticks – Set the maximum number of ticks. Leave blank to auto-calculate them.

Example:
[gamipress_frontend_reports_points_chart type="credits" amount="earned,deducted" current_user="yes" style="line" legend="yes" background="rgba(54,162,235,0.5),rgba(255,99,132,0.5),rgba(75,192,192,0.5),rgba(255,205,86,0.5),rgba(201,203,207,0.5)" border="#36a2eb,#ff6384,#4bc0c0,#ffcd56,#c9cbcf" grid="rgba(0,0,0,0.1)"]

How can we help?