summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--addons/website_sale_comparison/static/src/js/website_sale_comparison.js12
-rw-r--r--addons/website_sale_comparison/static/src/xml/comparison.xml2
2 files changed, 7 insertions, 7 deletions
diff --git a/addons/website_sale_comparison/static/src/js/website_sale_comparison.js b/addons/website_sale_comparison/static/src/js/website_sale_comparison.js
index a4d25cf2dcc..40d750da293 100644
--- a/addons/website_sale_comparison/static/src/js/website_sale_comparison.js
+++ b/addons/website_sale_comparison/static/src/js/website_sale_comparison.js
@@ -35,7 +35,7 @@ var ProductComparison = Widget.extend({
self._loadProducts(this.comparelist_product_ids).then(function () {
self._updateContent(self.comparelist_product_ids, true);
if (self.comparelist_product_ids.length) {
- $('.o_product_feature_panel').show();
+ $('.o_product_feature_panel').addClass('d-md-block');
self._updateComparelistView();
}
});
@@ -136,7 +136,7 @@ var ProductComparison = Widget.extend({
*/
_addNewProducts: function (product_id) {
var self = this;
- $('.o_product_feature_panel').show();
+ $('.o_product_feature_panel').addClass('d-md-block');
if (!_.contains(self.comparelist_product_ids, product_id)) {
self.comparelist_product_ids.push(product_id);
if (_.has(self.product_data, product_id)){
@@ -188,14 +188,14 @@ var ProductComparison = Widget.extend({
*/
_updateComparelistView: function () {
this.$('.o_product_circle').text(this.comparelist_product_ids.length);
- this.$('.o_comparelist_button').hide();
+ this.$('.o_comparelist_button').removeClass('d-md-block');
if (_.isEmpty(this.comparelist_product_ids)) {
- $('.o_product_feature_panel').hide();
+ $('.o_product_feature_panel').removeClass('d-md-block');
this._togglePanel();
} else {
- this.$('.o_comparelist_products').show();
+ this.$('.o_comparelist_products').addClass('d-md-block');
if (this.comparelist_product_ids.length >=2) {
- this.$('.o_comparelist_button').show();
+ this.$('.o_comparelist_button').addClass('d-md-block');
this.$('.o_comparelist_button a').attr('href', '/shop/compare/?products='+this.comparelist_product_ids.toString());
}
}
diff --git a/addons/website_sale_comparison/static/src/xml/comparison.xml b/addons/website_sale_comparison/static/src/xml/comparison.xml
index 98d3a2e55ce..f3eca962374 100644
--- a/addons/website_sale_comparison/static/src/xml/comparison.xml
+++ b/addons/website_sale_comparison/static/src/xml/comparison.xml
@@ -1,7 +1,7 @@
<templates id="compare_products" xml:space="preserve">
<t t-name="product_comparison_template">
- <div class="o_product_feature_panel d-none d-md-block css_editable_mode_hidden" style="display:none">
+ <div class="o_product_feature_panel d-none css_editable_mode_hidden">
<span class="o_product_panel" id="comparelist">
<span class="o_product_panel_header">
<span class="o_product_icon"><i class="fa fa-exchange" role="img" aria-label="Product" title="Product"></i></span>