Skip to content

Commit ed7beea

Browse files
authored
Merge pull request #635 from magento-south/BUGS-2.1
[South] Bugs 2.1: - MAGETWO-56998 [Backport] Simple child product without a special price still shown as "was (original price)" #4442 #5097 #6645 - for 2.1
2 parents 673217a + 0fdb025 commit ed7beea

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

app/code/Magento/Swatches/view/frontend/web/js/swatch-renderer.js

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,10 @@ define([
191191
mediaGalleryInitial: [{}],
192192

193193
//
194-
onlyMainImg: false
194+
onlyMainImg: false,
195+
196+
// sly-old-price block selector
197+
slyOldPriceSelector: '.sly-old-price'
195198
},
196199

197200
/**
@@ -688,6 +691,11 @@ define([
688691
}
689692
);
690693

694+
if (result.oldPrice.amount !== result.finalPrice.amount) {
695+
$(this.options.slyOldPriceSelector).show();
696+
} else {
697+
$(this.options.slyOldPriceSelector).hide();
698+
}
691699
},
692700

693701
/**

0 commit comments

Comments
 (0)