String String type receiving SpringMVC
entity bean is Date
Join bind
@InitBinder public void initBinder(WebDataBinder binder) { SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd"); // SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS Z"); dateFormat.setLenient(false); binder.registerCustomEditor (a Date. class , new new the CustomDateEditor (the dateFormat, to true )); // to true: enable input nulls, false: can not be null }
And the individual strings are receiving entity class bean onset