• Hi.

    The link in the order notice emails to customers and our office admins who are not logged in is no longer working to view the order in a browser. It used to work. Now it brings up a blank white page and says: You need to be logged into your account to access the Invoice. Please login first.

    What happened? It used to work fine. What do I need to change to make this work? We do not want/need our customers or our office admins to be logged in.

    Please advise!

Viewing 9 replies - 1 through 9 (of 9 total)
  • Also experiencing the same behavior. Print order is no longer working from customer dashboard or emails.

    Plugin Author priyankajagtap

    (@priyankajagtap)

    Hi @nettlequeen and @timbre-design,

    I want to clarify that the behavior you’re experiencing is not an issue with our plugin. It was implemented to enhance security for our users. Previously, the print link in the order emails could be accessed by anyone, which posed a security risk as sensitive information could potentially be exposed.

    To address this, we have implemented a requirement for users to log in before accessing the print link. This change ensures that only authorized users can view and print their receipts, thereby protecting their information.

    Could you please share what specific behavior you expected when accessing the email’s print link? Your feedback will help us understand your needs better, and we can explore possible alternatives or solutions that align with your expectations while maintaining the necessary security measures.

    Hi there, thanks for the response. I understand the security reason for needing to be logged in (though perhaps it would be nice to provide a settings switch to allow guests to use the print function as it was before). Alas, what I’ve experienced now is an issue. Print order (on all: thank you page, email & dashboard) is only working for Sales Managers and Admin. It is not working for logged in customers, nor my custom agents role. Despite being logged in still displays a message “You need to be logged into your account to access the Invoice. Please login first.” (even if they are logged in). I had to role back to version 5.2 to get it working again.

    Plugin Author priyankajagtap

    (@priyankajagtap)

    Hi @timbre-design,

    Thank you for your reply.

    Our developer has added a filter in our plugin and created the custom code to achieve your mentioned requirements.

    The change related to the filter code is added in the “class-wcdn-print.php” file of our plugin which can be downloaded from the below link:
    https://www.dropbox.com/scl/fi/a1ktvvu7fxgkwec2pjumf/class-wcdn-print.php?rlkey=ji0pbzp6rx0724hty7cz5trzk&st=z061dx51&dl=0

    Kindly download this file and you need to replace the existing file with the provided one on the
    below-mentioned path:
    Path- wp-content\plugins\woocommerce-delivery-notes\includes\

    Once you have replaced this file on your site, please add the custom code provided below to the “functions.php” file of your currently active theme.

    add_filter( 'allow_user_email_order_access', 'allow_non_logged_in_user_order_access' );

    /**
    * Filter to allow non-logged-in users to access orders.
    *
    * @return bool Modified access permission.
    */
    function allow_non_logged_in_user_order_access() {
    return true; // Allow non-logged-in users to access everything.
    }

    Once you have added this custom code to your site, please check and let me know if the print link in the email is accessible to non-logged-in users. If the issue you mentioned above persists on your site even after adding this custom code, please email us at ‘support at tychesoftwares dot com’ so we can investigate the issue in detail and better assist you.

    Hi, thank you for responding. However that code snippet does not help the error that I am getting.

    Print order is only working for Sales Managers and Admin. It is not working for logged in customers, nor my custom agents role. It still displays a message “You need to be logged into your account to access the Invoice. Please login first.” even if they are logged in. There is a bug in your code.

    Plugin Author priyankajagtap

    (@priyankajagtap)

    Hi @timbre-design,

    It is sad to know that the provided code snipped didn’t work for you.

    Could you please let us know if the user role for those logged-in customers is “Customer” or something else? Also, please let us know which plugin you are using for creating the custom agent roles. So I will check this once on our end and will let you know if I can replicate this issue or not. So we can check how we can move ahead with this issue.

    Hi,

    Correct, the default WooCommerce “customer” role (to note: all customers on the site do have multiple roles, but that shouldn’t be an issue since roles are arrays), as well as an agent role (that does not have the customer role). They are all custom roles I created particularly for the site.

    I do not need not logged in users to print orders.

    Thanks!

    Timbre Design

    (@timbre-design)

    Please respond, thank you!

    Plugin Author priyankajagtap

    (@priyankajagtap)

    Hi @timbre-design,

    Sorry for the delay in response to this.

    Could you please drop us an email at ‘support at tychesoftwares dot com’ regarding this? So we can discuss this in detail there and assist you in a better way.

Viewing 9 replies - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.