Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

Sales Report 2

Recommended Posts

I installed the Sales Report 2 contribution and it works great. There will be a problem shortly since we are more than 8 months into 2005 and the Report last date is December 2005, can someone tell me how to update it and where to change the years. I would like to start at Jan 1 2005.



Link to comment
Share on other sites

Having had a quick look at it. It seems to take it's date from 'today', so when we reach 2006, then the last date available will change.


If the report allows you to select december of this year, it will still only display reports up to tomorrow's date.


This appears to be the code you're loking for:


sales_report2.php in admin\includes\classes


if ($endDate > mktime(0, 0, 0, date("m"), date("d") + 1, date("Y"))) {

// set endDate to tomorrow

$this->endDate = mktime(0, 0, 0, date("m"), date("d") + 1, date("Y"));

} else {

$this->endDate = $endDate;


if ($this->endDate < $this->startDate + 24 * 60 * 60) {

$this->endDate = $this->startDate + 24 * 60 * 60;



Hope that helps.

Link to comment
Share on other sites

  • 2 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...