yiisoft/yii2 — pull request #4955 by kartik-v (2014-09-08 12:23:08+00:00)
Title: Trigger `onValidationError` event on input & form

Trigger a new `onValidationError` event on both input & form, whenever a validation error is encountered. This can help one to code advanced stuff like:
```js
$form.on('onValidationError', function(event, messages) {
if (messages.length) {
// do something
}
});
```