Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I don't think it should show 'Order History' on the My Account page unless the user is allowed to create orders. This happened to effect me because I'm making a site in which one role can make purchases and another cannot.
Comment | File | Size | Author |
---|---|---|---|
#1 | orderaccess2.patch | 2.25 KB | Jody Lynn |
orderaccess.patch | 851 bytes | Jody Lynn | |
Comments
Comment #1
Jody LynnI also added the same logic to showing the 'Orders' tab.
Comment #2
Shawn Conn CreditAttribution: Shawn Conn commentedI think you misunderstand the permission for "create orders". The permission allows an account to use the store administration backend to manually create orders. The role is used for accounts that you want to be store administrators. The order history tab is used for customers or store administrators to review previously created orders by a customer account. If your patch is implemented, only store administrators would be able to review past orders, not the customers who made them. And if you gave customers the "create orders" permission, they would be able to review their order history but they would also be able to create orders for anyone, something you definitely don't want to do.
Comment #3
Jody LynnAh, thanks very much for the clarity and saving me from figuring that out down the road. So I guess that there actually is no permission for 'make purchases' the way I wanted to use it. I think I will have to add that permission for my uses- would you be interested in a patch for that?