Skip to content

Commit 5b09cba

Browse files
Pooja.ManralPooja.Manral
authored andcommitted
AC-10826::Storefront Bundle Checkbox Validation Error message count more than 1
1 parent 27b55ac commit 5b09cba

File tree

3 files changed

+7
-66
lines changed

3 files changed

+7
-66
lines changed

app/code/Magento/Bundle/view/frontend/requirejs-config.js

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,5 @@ var config = {
1111
slide: 'Magento_Bundle/js/slide',
1212
productSummary: 'Magento_Bundle/js/product-summary'
1313
}
14-
},
15-
config: {
16-
mixins: {
17-
'mage/validation': {
18-
'Magento_Bundle/js/validation': true
19-
}
20-
}
2114
}
2215
};

app/code/Magento/Bundle/view/frontend/web/js/validation.js

Lines changed: 0 additions & 58 deletions
This file was deleted.

lib/web/mage/validation.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1875,7 +1875,7 @@ define([
18751875
*/
18761876
errorPlacement: function (error, element) {
18771877
var errorPlacement = element,
1878-
fieldWrapper;
1878+
fieldWrapper,messageBox;
18791879

18801880
// logic for date-picker error placement
18811881
if (element.hasClass('_has-datepicker')) {
@@ -1904,6 +1904,12 @@ define([
19041904
if (element.next().find('.tooltip').length) {
19051905
errorPlacement = element.next();
19061906
}
1907+
1908+
if (element.attr('data-errors-msg-box')) {
1909+
messageBox = $(element.attr('data-errors-msg-box'));
1910+
messageBox.html(error);
1911+
return;
1912+
}
19071913
errorPlacement.after(error);
19081914
}
19091915
},

0 commit comments

Comments
 (0)