diff --git a/addons/website/tools.py b/addons/website/tools.py
index 48ee9aec53f..2abe896afff 100644
--- a/addons/website/tools.py
+++ b/addons/website/tools.py
@@ -4,7 +4,7 @@
import re
-def get_video_embed_url(video_url):
+def get_video_embed_code(video_url):
''' Computes the valid iframe from given URL that can be embedded
(or False in case of invalid URL).
'''
@@ -48,4 +48,4 @@ def get_video_embed_url(video_url):
else:
# We directly use the provided URL as it is
embedUrl = video_url
- return '' % (embedUrl)
+ return '' % embedUrl
diff --git a/addons/website_sale/models/product.py b/addons/website_sale/models/product.py
index e4d37a6ec76..b91657f746e 100644
--- a/addons/website_sale/models/product.py
+++ b/addons/website_sale/models/product.py
@@ -214,7 +214,7 @@ class ProductTemplate(models.Model):
help="The product will be available in each mentioned e-commerce category. Go to"
"Shop > Customize and enable 'E-commerce categories' to view all e-commerce categories.")
- product_template_image_ids = fields.One2many('product.image', 'product_tmpl_id', string="Extra Product Images", copy=True)
+ product_template_image_ids = fields.One2many('product.image', 'product_tmpl_id', string="Extra Product Media", copy=True)
@api.multi
def _has_no_variant_attributes(self):
diff --git a/addons/website_sale/models/product_image.py b/addons/website_sale/models/product_image.py
index f4f80209764..e991343b55d 100644
--- a/addons/website_sale/models/product_image.py
+++ b/addons/website_sale/models/product_image.py
@@ -4,7 +4,7 @@
from odoo import api, fields, models, _
from odoo.exceptions import ValidationError
-from odoo.addons.website.tools import get_video_embed_url
+from odoo.addons.website.tools import get_video_embed_code
class ProductImage(models.Model):
@@ -27,7 +27,7 @@ class ProductImage(models.Model):
@api.depends('video_url')
def _compute_embed_code(self):
for image in self:
- image.embed_code = get_video_embed_url(image.video_url)
+ image.embed_code = get_video_embed_code(image.video_url)
@api.constrains('video_url')
def _check_valid_video_url(self):
diff --git a/addons/website_sale/views/product_views.xml b/addons/website_sale/views/product_views.xml
index 0c2d9e9a995..4cac8d39f18 100644
--- a/addons/website_sale/views/product_views.xml
+++ b/addons/website_sale/views/product_views.xml
@@ -102,8 +102,8 @@
-
-
+
+
@@ -116,8 +116,8 @@
-
-
+
+
@@ -209,7 +209,7 @@
-
+