mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-01 03:26:36 +08:00
Fixes #5049.
This commit is contained in:
@ -300,10 +300,7 @@
|
|||||||
delete messages[i];
|
delete messages[i];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (needAjaxValidation && (!data.submitting || $.isEmptyObject(messages))) {
|
if (needAjaxValidation) {
|
||||||
// Perform ajax validation when at least one input needs it.
|
|
||||||
// If the validation is triggered by form submission, ajax validation
|
|
||||||
// should be done only when all inputs pass client validation
|
|
||||||
var $button = data.submitObject,
|
var $button = data.submitObject,
|
||||||
extData = '&' + data.settings.ajaxParam + '=' + $form.prop('id');
|
extData = '&' + data.settings.ajaxParam + '=' + $form.prop('id');
|
||||||
if ($button && $button.length && $button.prop('name')) {
|
if ($button && $button.length && $button.prop('name')) {
|
||||||
|
|||||||
Reference in New Issue
Block a user