mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-04 21:15:55 +01:00
Fixed issue where page view counts kept changing
... when they should only really be updated for the hourly pageviews graph.
This commit is contained in:
@@ -332,6 +332,13 @@ define('admin/general/dashboard', ['semver'], function(semver) {
|
||||
graphs.traffic.scale.xLabels = getDaysArray(until);
|
||||
} else {
|
||||
graphs.traffic.scale.xLabels = getHoursArray();
|
||||
|
||||
$('#pageViewsThisMonth').html(data.monthlyPageViews.thisMonth);
|
||||
$('#pageViewsLastMonth').html(data.monthlyPageViews.lastMonth);
|
||||
$('#pageViewsPastDay').html(data.pastDay);
|
||||
utils.addCommasToNumbers($('#pageViewsThisMonth'));
|
||||
utils.addCommasToNumbers($('#pageViewsLastMonth'));
|
||||
utils.addCommasToNumbers($('#pageViewsPastDay'));
|
||||
}
|
||||
|
||||
for (var i = 0, ii = data.pageviews.length; i < ii; i++) {
|
||||
@@ -349,13 +356,6 @@ define('admin/general/dashboard', ['semver'], function(semver) {
|
||||
graphs.traffic.update();
|
||||
currentGraph.units = units;
|
||||
currentGraph.until = until;
|
||||
|
||||
$('#pageViewsThisMonth').html(data.monthlyPageViews.thisMonth);
|
||||
$('#pageViewsLastMonth').html(data.monthlyPageViews.lastMonth);
|
||||
$('#pageViewsPastDay').html(data.pastDay);
|
||||
utils.addCommasToNumbers($('#pageViewsThisMonth'));
|
||||
utils.addCommasToNumbers($('#pageViewsLastMonth'));
|
||||
utils.addCommasToNumbers($('#pageViewsPastDay'));
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user