2
可能重复:在
@Entity
-class
What are the i18n message ids for field infos and errors?玩! 2.0覆盖 “无效值” 消息
使用注解像@Required
,消息属性可以容易地设置。但是,如何设置/覆盖在Double类型的成员在表单中填充字符串时显示的“无效值”消息?
form.errors()
-map包含关键字段名称和值“error.invalid”的错误,但是我找不到在消息文件中用于覆盖默认消息的正确密钥。
我可以用Play来确认! 2.0,标签必须在message.xy(message.en或message.de等)文件中被覆盖。在默认消息文件中放置'error.invalid =我的无效值'不起作用。 – Joram