angular-schema-form icon indicating copy to clipboard operation
angular-schema-form copied to clipboard

OnBlur validation

Open alexandroscgb opened this issue 7 years ago • 2 comments

Hi.

I was wondering if I could validate if the field is empty or not when it looses the focus, showing the validation message, in adition to the submit validation.

I have an onChange function that populate another field and I need to add onBlur validation, is it possible?

Thanks.

alexandroscgb avatar Jun 16 '17 19:06 alexandroscgb

Or I could use onChange property to see if the field is empty and if it is, trigger the same mecanism submit button triggers to show validation messages and css. How could I do something like this? I mean, what is the mecanism to show validation messages and styles?

alexandroscgb avatar Jun 16 '17 20:06 alexandroscgb

I found some similar way, and that is to $scope.$broadcast(fieldId) the field I need to validate, but again, I can't link it to the onBlur event.

alexandroscgb avatar Jun 16 '17 21:06 alexandroscgb