burconsult
Forum Replies Created
Viewing 1 replies (of 1 total)
-
Forum: Plugins
In reply to: [Download Monitor] Reports not workingSmall errors in the wp-content/plugins/download-monitor/assets/js/reports/reports.min.js file which is a minified version of reports.js Lines 535 to 550 are like this in the original file:
// Get all dates from the startDate to the endDate let dayDownloads = dlmReportsInstance.getDates(new Date(startDate), new Date(endDate)), doubleDays, doubleMonthDownloads, weeksDownloads, weekDownloads; // Let's initiate our dlmDownloads with something switch (dlmReportsInstance.chartType) { case 'months': // Get double selected months doubleMonthDownloads = dlmReportsInstance.getDoubleMonths(dayDownloads); dlmDownloads = doubleMonthDownloads; break; case 'month': // Get selected months let monthDownloads = dlmReportsInstance.getMonths(dayDownloads); dlmDownloads = monthDownloads; break;Fixed it by making these changes:
// Get all dates from the startDate to the endDate let dayDownloads = dlmReportsInstance.getDates(new Date(startDate), new Date(endDate)), doubleDays, doubleMonthDownloads, monthDownloads, weeksDownloads, weekDownloads; // Let's initiate our dlmDownloads with something switch (dlmReportsInstance.chartType) { case 'months': // Get double selected months doubleMonthDownloads = dlmReportsInstance.getDoubleMonths(dayDownloads); dlmDownloads = doubleMonthDownloads; break; case 'month': // Get selected months monthDownloads = dlmReportsInstance.getMonths(dayDownloads); dlmDownloads = monthDownloads; break;
Viewing 1 replies (of 1 total)