Hi,

an exception is being thrown  when trying to calculate history of indicators 

org.springframework.beans.TypeMismatchException

Failed to convert value of type [java.lang.String] to required type 
[java.util.Date]; nested exception is java.lang.IllegalArgumentException: 
Cannot convert value of type [java.lang.String] to required type 
[java.util.Date]: no matching editors or conversion strategy found
 
Looking through IndicatorHistoryController, I don't see where we register a 
CustomDateEditor to handle the "startDate" and "endDate" properties from the 
"Query" class.

Can we change initBinder and include a custom date editor for these 
properties?...add something like

SimpleDateFormat dateFormat = Context.getDateFormat();
dateFormat.setLenient(false);
binder.registerCustomEditor(Date.class, new CustomDateEditor(dateFormat,true, 
10)); 
-Bailly

_________________________________________

To unsubscribe from OpenMRS Developers' mailing list, send an e-mail to 
[email protected] with "SIGNOFF openmrs-devel-l" in the  body (not 
the subject) of your e-mail.

[mailto:[email protected]?body=SIGNOFF%20openmrs-devel-l]

Reply via email to