myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Agam Dass (JIRA)" <...@myfaces.apache.org>
Subject [jira] Created: (TRINIDAD-1407) DateTimeConverter doesn't convert correctly as per the expectedDataType
Date Fri, 20 Feb 2009 09:37:01 GMT
DateTimeConverter doesn't convert correctly as per the expectedDataType
-----------------------------------------------------------------------

                 Key: TRINIDAD-1407
                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1407
             Project: MyFaces Trinidad
          Issue Type: Bug
            Reporter: Agam Dass
            Priority: Blocker


In the org.apache.myfaces.trinidadinternal.convert.DateTimeConverter#getAsObject() retrieves
the date by parsing the String and then it calls  DateTimeConverter.__typeConvert() to convert
this type to the expected type. But in the method __typeConvert() it gets the expectedType
by calling the type instead of getting the expectedType(). 
So it should be changed to expression.getExpectedType() instead of expression.getType()

Class : org.apache.myfaces.trinidadinternal.convert.DateTimeConverter
Method : 
   static Object __typeConvert(FacesContext context, Converter converter, UIComponent component,

                                                      String strValue, Object value) 
Line # 123
Remove :     Class<?> expectedType = expression.getType(context.getELContext());
Add         :     Class<?> expectedType = expression.getExpectedType(); 
===========================================================================
This need to be fixed in Trinidad 1.2.10.1 and then forward-port to Trinidad 1.2.11.1. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message