Page 75 of 86 FirstFirst ... 2565737475767785 ... LastLast
Results 741 to 750 of 859
  1. #741
    Join Date
    Apr 2008
    Location
    Qld, Australia
    Posts
    257
    Plugin Contributions
    6

    Default Re: Sales report 2.0 (V3.2.0 PHP7)

    Sales Report 2.0 (Version 3.2.0) PHP 7.x

    The following changes are required as a minimum. My line numbers are higher than for the original files due to inserted comments for all changes I make.

    file: YOUR_ADMIN\includes\classes\sales_report.php
    where: at the top of the file approx line 29
    Code:
    define('DATE_FORMAT', 'd/m/Y'); // this is used for date() // BMH addition PHP 7
    file: YOUR_ADMIN\includes\classes\sales_report.php
    where: at approx lines 266, 270 CHANGE
    Code:
    if (count($this->timeframe[$id]['orders']) == 0) {
            $this->timeframe[$id]['orders'] = false;
    TO
    Code:
     if (empty($this->timeframe[$id]['products'])) { 
            $this->timeframe[$id]['orders'] = false;
    file: YOUR_ADMIN\includes\classes\sales_report.php
    where: at approx line 411 CHANGE
    Code:
    if (!in_array($pID, $this->timeframe[$id]['total']['diff_products'])) {
           $this->timeframe[$id]['total']['diff_products'][] = $pID;
    }
    TO
    Code:
    if (!empty($this->timeframe[$id]['orders'][$oID]['diff_products']) ) {
    		if (!in_array($pID, $this->timeframe[$id]['orders'][$oID]['diff_products'])) {
                       $this->timeframe[$id]['orders'][$oID]['diff_products'][] = $pID;
    		}
    	}
    file: YOUR_ADMIN\includes\classes\sales_report.php
    where: at approx line 417 CHANGE
    Code:
    if (!in_array($pID, $this->timeframe[$id]['orders'][$oID]['diff_products'])) {
                    $this->timeframe[$id]['orders'][$oID]['diff_products'][] = $pID;
           }
    TO
    Code:
    if (!empty($this->timeframe[$id]['orders'][$oID]['diff_products']) ) {
        if (!in_array($pID, $this->timeframe[$id]['orders'][$oID]['diff_products'])) {
               $this->timeframe[$id]['orders'][$oID]['diff_products'][] = $pID;
        }
    }
    Perform these changes in a test environment making only one change at a time and review your log files after each test of the report. Add comments to your code.

  2. #742
    Join Date
    Oct 2005
    Posts
    287
    Plugin Contributions
    0

    Default Re: Sales report 2.0

    ------
    will try and get back.
    Thanks
    Last edited by harry2cool; 26 Jan 2019 at 08:41 PM. Reason: did not see earlier email, trying now

  3. #743
    Join Date
    Oct 2005
    Posts
    287
    Plugin Contributions
    0

    Default Re: Sales report 2.0

    Did the changes, however under date it still shows the same as below, however do not get any error in the logs:

    IST0JanE_Tue0st+05:300AM2019_TueAM2019

  4. #744
    Join Date
    Apr 2008
    Location
    Qld, Australia
    Posts
    257
    Plugin Contributions
    6

    Default Re: Sales report 2.0

    Sorry for the incorrect file reference.

    The date format
    Code:
    define('DATE_FORMAT', 'd/m/Y'); // this is used for date() // BMH addition PHP 7
    should be placed in YOUR_ADMIN\stats-sales_report.php at approx line 29.

  5. #745
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,495
    Plugin Contributions
    88

    Default Re: Sales report 2.0

    I've got a GitHub update staged that, I believe, addresses this issue: https://github.com/lat9/sales_report/issues/4

  6. #746
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,495
    Plugin Contributions
    88

    Default Re: Sales report 2.0

    Quote Originally Posted by lat9 View Post
    I've got a GitHub update staged that, I believe, addresses this issue: https://github.com/lat9/sales_report/issues/4
    I've just submitted v3.2.1 of Sales Report to the Zen Cart devs for review. Once accepted, it can be downloaded from this link: https://www.zen-cart.com/downloads.php?do=file&id=9

    This release contains the changes associated with the following GitHub issue:


    #4: zc156 inter-operation due to language-file load-order change.


    If you can't wait for the changes to be posted on the Zen Cart link, you can download the report's distribution zip-file from its GitHub repository: https://github.com/lat9/sales_report...ses/tag/v3.2.1

  7. #747
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,495
    Plugin Contributions
    88

    Default Re: Sales report 2.0

    v3.2.1 of Sales Report is now available for download (thanks, @swguy!).

  8. #748
    Join Date
    Dec 2006
    Location
    Hudson Valley, New York USA
    Posts
    93
    Plugin Contributions
    0

    Default Re: Sales report 2.0

    Any idea how to fix the SpiffyCal layout? I'm assuming this has to do with the new Bootstrap based Admin style or the updates to the calendar javascript in 1.5.6a, but when attempting to choose a custom date, the calendar goes off the left side of the screen and browser doesn't allow scrolling to the left.

    ZenCart 1.5.6a
    PHP 7.1

    Tested in Firefox 65, Chrome 72, MS Edge
    Attachment 18358

  9. #749
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,692
    Plugin Contributions
    9

    Default Re: Sales report 2.0

    Quote Originally Posted by gwynwyffar View Post
    Any idea how to fix the SpiffyCal layout? I'm assuming this has to do with the new Bootstrap based Admin style or the updates to the calendar javascript in 1.5.6a, but when attempting to choose a custom date, the calendar goes off the left side of the screen and browser doesn't allow scrolling to the left.

    ZenCart 1.5.6a
    PHP 7.1

    Tested in Firefox 65, Chrome 72, MS Edge
    Attachment 18358
    the problem is with the spiffyCal plugin that comes with the base ZC package. it is version 2.1 and dated 2001. i think this is a plugin that needs to be replaced by the ZC team.

    this spiffyCal is used in a number of places, so changes here can affect where it is used elsewhere. so use with caution.

    if you go here:

    YOUR_ADMIN/includes/javascript/spiffyCal/spiffyCal_v2_1.js

    lines 1026 and 1037; you will see:

    - 250

    change that to

    -10

    not sure how it will affect other dates in your admin.

    Code:
                    if (scIE) {
                        if (this.displayLeft) {
                            scX = getOffsetLeft(document.images[this.btnName]) - 10 + document.images[this.btnName].width;
                        } else {
                            scX = getOffsetLeft(document.images[this.btnName]);
                        }
                        if (this.displayTop) {
                            scY = getOffsetTop(document.images[this.btnName]) - 138;
                        } else {
                            scY = getOffsetTop(document.images[this.btnName]) + document.images[this.btnName].height + 2;
                        }
                    } else if (scNN) {
                        if (this.displayLeft) {
                            scX = document.images[this.btnName].x - 10 + document.images[this.btnName].width;
                        } else {
                            scX = document.images[this.btnName].x;
    author of square Webpay.
    mxWorks has premium plugins. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  10. #750
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,495
    Plugin Contributions
    88

    Default Re: Sales report 2.0

    Thanks, @carlwhat, for that investigation. I've noted the issue on Sales Report's GitHub repository (https://github.com/lat9/sales_report/issues/5).

    Please note that since it's a Zen Cart core-file involved, it's not likely that I'll be including that change with the plugin ... other than to document the anomaly and your fix.

 

 
Page 75 of 86 FirstFirst ... 2565737475767785 ... LastLast

Similar Threads

  1. v139b Sales Report
    By irishshopper in forum General Questions
    Replies: 1
    Last Post: 26 Jan 2014, 01:00 AM
  2. Sales Report
    By jgold723 in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 9 Nov 2011, 05:58 PM
  3. Sales report
    By tlahtine in forum All Other Contributions/Addons
    Replies: 2
    Last Post: 27 Dec 2010, 10:01 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR