• Resolved ripperman

    (@ripperman)


    Hi,

    Just wondering about the reports feature. It’s saying the site has only 4 sales but there’s been over 200 in the last week?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Support con

    (@conschneider)

    Engineer

    Hi there,

    The reports get generated every time you visit the report page in the admin. It should really pick up on your orders ;).

    Anything unusual setup in regards to order status on your WooCommerce site? For example are you using another order status besides “completed”?

    Kind regards,

    Thread Starter ripperman

    (@ripperman)

    Hi,

    Nope. It’s not. Only reporting a few sales.

    We added an auto-complete on orders plugin and
    we also had to add a “shipped” status to the site alright?
    Would either or both of these cause the issue?

    If so is there any work around?

    Thanks,

    Plugin Support Fernando a11n

    (@fhaps)

    Automattic Happiness Engineer

    @ripperman Is the custom “shipped” status the one that most orders sit on after their processing is complete?

    By default, only orders marked Processing, On Hold and Completed are counted as sales. This means that any orders that you have with any other status (included your custom Shipped one) won’t be counted towards the reported sales.

    Custom code would be needed to modify that behavior and make it recognize your custom status.

    Thread Starter ripperman

    (@ripperman)

    At this stage I would say yes.
    Order is placed > status changed automatically and immediately to “Completed” > office staff manually change status from “Completed” to “Shipped” within an hour or two tops.

    Ah I see. Thank you.
    Would something like this work? We’re reluctant to add anything further at this stage unless we’re sure it will work?

    add_filter( ‘woocommerce_reports_order_statuses’, ‘include_custom_order_status_to_reports’, 20, 1 );
    function include_custom_order_status_to_reports( $statuses ){
    // Adding the custom order status to the 3 default woocommerce order statuses
    return array( ‘processing’, ‘shipped’, ‘completed’, ‘on-hold’ );
    }

    Plugin Support Fernando a11n

    (@fhaps)

    Automattic Happiness Engineer

    Would something like this work? We’re reluctant to add anything further at this stage unless we’re sure it will work?

    I can’t comment on whether that particular piece of code would work or not. The easiest way for you to confirm this directly is to test it yourself.

    I understand you are reluctant to implement this on the site – and rightly so. We recommend that changes like these are never made on a live site without testing first, so I’d suggest you create a staging site where you can test the code first.

    You can use a plugin like WP Staging to create a copy of your website where you can test this code.

    Thread Starter ripperman

    (@ripperman)

    Hi,

    Thank you for your reply. The problem was in the way we implemented the new “shipped” status into the system. We added code to do this but woocommerce reports was’t picking this up. Instead we tested a plugin that added a new woocommerce status.
    So, the combination of a custom status plugin and an autocomplete plugin works and the reports are generating properly as a result.

    Thank you for the replies and help.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Reports not working?’ is closed to new replies.