public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
ActionErrors errors = super.validate(mapping, request);
if(data.getDescription().getBytes().length>2000){
String description="摘要";
String maxString = "2000";
errors.add(ActionErrors.GLOBAL_MESSAGE,new ActionMessage("errors.maxlength",new Object[]{description,maxString}));
}
return errors;
}如果我要从资源文件里获取description,maxString请问该怎么写????求教!!!!
ActionErrors errors = super.validate(mapping, request);
if(data.getDescription().getBytes().length>2000){
String description="摘要";
String maxString = "2000";
errors.add(ActionErrors.GLOBAL_MESSAGE,new ActionMessage("errors.maxlength",new Object[]{description,maxString}));
}
return errors;
}如果我要从资源文件里获取description,maxString请问该怎么写????求教!!!!
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货