Playframework 2.0 play20验证程序中的约束消息
我想有一个约束验证器不同的消息,但我徘徊如何做。。。。 范例 我想要点什么Playframework 2.0 play20验证程序中的约束消息,playframework-2.0,Playframework 2.0,我想有一个约束验证器不同的消息,但我徘徊如何做。。。。 范例 我想要点什么 @Constraints.Required @Constraints.Pattern(message="ThisismyspecificMessage",value=\\d{1,6}") public String thisIsAnInt; 用于在窗体中使用引导正确地显示它 有可能吗? 非常感谢正如您所写,您可以使用 @Constraints.Required(message = "This is fi
@Constraints.Required
@Constraints.Pattern(message="ThisismyspecificMessage",value=\\d{1,6}")
public String thisIsAnInt;
用于在窗体中使用引导正确地显示它
有可能吗?
非常感谢正如您所写,您可以使用
@Constraints.Required(message = "This is field required")
@Constraints.Pattern(value = "\\d{1,6}", message = "This field must contain from 1 to 6 digits")
public String thisIsAnInt;
@Constraints.Required(message = "This is field required")
@Constraints.Pattern(value = "\\d{1,6}", message = "This field must contain from 1 to 6 digits")
public String thisIsAnInt;