Skip to content

Commit

Permalink
[FIX] website_sale: fix open_website_url for product
Browse files Browse the repository at this point in the history
open_website_url was targeting product_template website_url instead of
product_product.

Related to odoo#33175

closes odoo#34383

Signed-off-by: Quentin Smetz (qsm) <[email protected]>
  • Loading branch information
fja-odoo authored and qsm-odoo committed Jun 28, 2019
1 parent 2337d41 commit e102ca8
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions addons/website_sale/models/product.py
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,13 @@ def website_publish_button(self):
res['url'] = self.website_url
return res

@api.multi
def open_website_url(self):
self.ensure_one()
res = self.product_tmpl_id.open_website_url()
res['url'] = self.website_url
return res

@api.multi
def _get_images(self):
"""Return a list of records implementing `image.mixin` to
Expand Down

0 comments on commit e102ca8

Please sign in to comment.