Fix broken toggling script

This commit is contained in:
Raphael Michel
2017-09-09 11:09:03 +02:00
parent b5bea6fe7a
commit 94a97fb0fd

View File

@@ -23,7 +23,7 @@ $(function () {
$(".js-hidden").hide();
$(".variations-collapsed").hide();
$("a[data-toggle=variations]").click(function (e) {
$(this).parent().parent().parent().find(".variations").slideToggle();
$(this).closest(".item-with-variations").find(".variations").slideToggle();
e.preventDefault();
});
$("div.collapsed").removeClass("collapsed").addClass("collapse");