lcoq / ember-validations

Ember-Validations - An Ember.js library for handling object validations
MIT License
122 stars 25 forks source link

I can not customize my validation error messages #32

Closed zhangyuhui closed 11 years ago

zhangyuhui commented 11 years ago

How can I define my own error messages?

lcoq commented 11 years ago

It depends on which kind of error message you wants to customize.

If you want to change all the error messages for blank errors, you can do:

Ember.ValidationError.addMessage('blank', "my custom error message");

If you want to define a custom error message for a specific property, there is sadly no way to do that yet.

I close this issue as this is a duplicate of #13 .