[FIX] website_sale: use variable partner_pl in method _get_pl_partner_order()

This commit is contained in:
Raphael Collet
2016-06-14 13:12:15 +02:00
committed by Christophe Matthieu
parent b3302398bc
commit 717692d76a
+1 -1
View File
@@ -170,7 +170,7 @@ class Website(models.Model):
pricelists |= all_pl.filtered(lambda pl: not show_visible or pl.selectable or pl.pricelist_id.id in (current_pl, order_pl)).mapped('pricelist_id')
partner = self.env.user.partner_id
if not pricelists or partner.property_product_pricelist.id != website_pl:
if not pricelists or (partner_pl or partner.property_product_pricelist.id) != website_pl:
pricelists |= partner.property_product_pricelist
return pricelists.sorted(lambda pl: pl.name)