Bug 149753 - input tags value attribute invalid when EL value evaluates to an object
Summary: input tags value attribute invalid when EL value evaluates to an object
Status: VERIFIED DUPLICATE of bug 198730
Alias: None
Product: Java Server Faces
Classification: WebTools
Component: Core (show other bugs)
Version: 1.5   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 3.0   Edit
Assignee: Cameron Bateman CLA
QA Contact:
URL:
Whiteboard:
Keywords: bugday, helpwanted
Depends on:
Blocks:
 
Reported: 2006-07-05 17:46 EDT by Gerry Kessler CLA
Modified: 2008-05-02 13:40 EDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gerry Kessler CLA 2006-07-05 17:46:10 EDT
The value attribute is being incorrectly marked invalid with "EL expression does not evaluate to expected types for this attribute". 

<h:inputText value="#{bean.val}"/> when val is an object.   

<h:inputText value="#{bean.date}"/> is another example.
Comment 1 Gerry Kessler CLA 2006-07-05 18:02:10 EDT
I neglected to mention that a converter has been applied in the above cases that could convert to a String.

Example from Core JSF samples: converter2

   <h:inputText id="card" value="#{payment.card}">
       <f:converter converterId="com.corejsf.CreditCard"/>
   </h:inputText>

where, 
public class CreditCard {
   private String number;

   public CreditCard(String number) { this.number = number; }
   public String toString() { return number; }
}
Comment 2 Raghunathan Srinivasan CLA 2007-01-05 15:10:58 EST
Triaged for WTP 2.0
Comment 3 Martin Zwosta CLA 2007-02-12 14:10:53 EST
Encountered the same problem (with the standard date-converter).
My System: OS: Win XP prof., Apache 5.0.31, myfaces 1.09.
Comment 4 Cameron Bateman CLA 2007-05-23 19:59:32 EDT
Need to defer this one to 3.0 unless it is critical for anyone.  Requires the ability to analyze nested components.
Comment 5 Cameron Bateman CLA 2007-09-18 20:06:22 EDT
See https://bugs.eclipse.org/bugs/show_bug.cgi?id=202697 to track future improvements in this area.

*** This bug has been marked as a duplicate of bug 198730 ***
Comment 6 Gerry Kessler CLA 2008-05-02 13:40:03 EDT
verified as dupe