mirror of
https://github.com/hotspotbilling/phpnuxbill.git
synced 2025-08-04 10:15:03 +02:00
Update dashboard.tpl
fixed inactive users in graph
This commit is contained in:
parent
6c2658bf03
commit
500f3de6a9
1 changed files with 3 additions and 1 deletions
|
@ -308,13 +308,15 @@
|
|||
var u_act = '{/literal}{$u_act}{literal}';
|
||||
var c_all = '{/literal}{$c_all}{literal}';
|
||||
var u_all = '{/literal}{$u_all}{literal}';
|
||||
//lets calculate the inactive users as reported
|
||||
var inactive = u_all - u_act;
|
||||
|
||||
// Create the chart data
|
||||
var data = {
|
||||
labels: ['Active Users', 'Inactive Users', 'Total Users'],
|
||||
datasets: [{
|
||||
label: 'User Recharges',
|
||||
data: [parseInt(u_act), parseInt(u_all), parseInt(c_all)],
|
||||
data: [parseInt(u_act), parseInt(inactive), parseInt(c_all)],
|
||||
backgroundColor: ['rgba(4, 191, 13)', 'rgba(191, 35, 4)', 'rgba(0, 0, 255, 0.5'],
|
||||
borderColor: ['rgba(0, 255, 0, 1)', 'rgba(255, 99, 132, 1)', 'rgba(0, 0, 255, 0.7'],
|
||||
borderWidth: 1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue