Skip to content
Permalink
Browse files

[FIX] website_sale: use sudo to check pricelist code to avoid field g…

…roups check
  • Loading branch information...
tomeyro committed Mar 26, 2019
1 parent 7e9a13a commit bd0a23d33a25396b965fd62a4610f87d544be959
Showing with 1 addition and 1 deletion.
  1. +1 −1 addons/website_sale/models/product.py
@@ -79,7 +79,7 @@ def _is_available_on_website(self, website_id):
Change in this method should be reflected in `_get_website_pricelists_domain`.
"""
self.ensure_one()
return self.website_id.id == website_id or (not self.website_id and (self.selectable or self.code))
return self.website_id.id == website_id or (not self.website_id and (self.selectable or self.sudo().code))

def _get_website_pricelists_domain(self, website_id):
''' Check above `_is_available_on_website` for explanation.

0 comments on commit bd0a23d

Please sign in to comment.
You can’t perform that action at this time.