0

there is a problem in my eshop (build with latest D7 and commerce 1.14) in checkout page where the "Shopping cart contents" section is empty for anonymous users.

I checked the permission "View any type of products" for anonymous users but didn't fix the problem

Any ideas?

Thanks

1

This is almost always due to some sort of relationship in the View's configuration linking from the cart order's line items to some other entity the user doesn't have direct access to view. Rather than try to find the right permissions, the easiest thing to do assuming you have other filters (or contextual filters) on the View to ensure the customer doesn't see other data is to disable SQL rewriting under the advanced settings for the View.

On a hunch, though, you should also make sure anonymous users have access to view their own orders. We have special code in the cart module to ensure access control works in that situation, and it could be the entire order is inaccessible and not just some related entity.

  • Thanks for your reply. I already tried these permissions and disabled SQL rewriting but there is something strange happening. The "Shopping cart contents" section is empty for me (as anonymous) but other anonymous users can sometimes see it. This is really strange! I send to a few friends for testing and they send me screenshots with the section filled as it should be. – isin May 28 '18 at 11:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.