The daily average and projected totals are calculated using the numeric month, rather than day of month. New code would look like:

function uc_reports_sales_summary() {
  $order_statuses = uc_reports_order_statuses();

  $date_day_of_month = date('j');
  $date_month = date('n');
  $month_start = mktime(0, 0, 0, $date_month, 1);
  $month_end = mktime(0, 0, 0, $date_month + 1, 1) - 1;
  $today_start = mktime(0, 0, 0);
  $today_end = mktime(23, 59, 59);

Comments

longwave’s picture

Status: Active » Fixed

Committed, thanks for the report.

liliplanet’s picture

Thank you age3141592, works perfectly!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.