Skip to content

Commit cefb54b

Browse files
author
Alexander Makeev
committed
MAGETWO-51768: Checkout agreement is not a link on PayPal Order Review page
- fixed problem with validation error notification
1 parent 960cf08 commit cefb54b

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

app/code/Magento/Paypal/view/frontend/web/order-review.js

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,8 @@ define([
102102
this.element.find(this.options.updateOrderSelector).fadeTo(0, 0.5)
103103
.end().find(this.options.waitLoadingContainer).show()
104104
.end().submit();
105+
this._updateOrderSubmit(true);
105106
}
106-
this._updateOrderSubmit(true);
107107
},
108108

109109
/**
@@ -242,19 +242,16 @@ define([
242242
shippingMethod = $.trim($(this.options.shippingSelector).val());
243243
this._shippingTobilling();
244244

245-
var validateFormResult = this._validateForm();
246-
var isShippingUpdate = url == $(this.options.shippingSubmitFormSelector).prop('action') && shippingMethod;
247-
248-
if (url && resultId && (validateFormResult || isShippingUpdate)) {
249-
this._updateOrderSubmit(validateFormResult);
250-
this._toggleButton(this.options.updateOrderSelector, !validateFormResult);
245+
if (url && resultId && shippingMethod) {
246+
this._updateOrderSubmit(true);
247+
this._toggleButton(this.options.updateOrderSelector, true);
251248

252249
// form data and callBack updated based on the shippping Form element
253250
if (this.isShippingSubmitForm) {
254251
formData = $(this.options.shippingSubmitFormSelector).serialize() + "&isAjax=true";
255252
callBackResponseHandler = function (response) {
256253
$(resultId).html(response);
257-
this._updateOrderSubmit(!validateFormResult);
254+
this._updateOrderSubmit(false);
258255
this._ajaxComplete();
259256
};
260257
} else {

0 commit comments

Comments
 (0)