Hi everybody,

 

I'm having a tc:selectOnceChoce-component that contains a list of years as 
string. I'd like to set a select year in the bean as a Date-Object by using a 
converter. The converter runs without an error but the Tobago-Framework throws 
a ValidationException. 

In the log I find this message: 2007-11-16 15:10:17 ERROR - 
org.apache.myfaces.tobago.context.ResourceManagerImpl:292 - Path not found, and 
no fallback. Using empty string.

 

I tried to fix the problem with my own Validator, but I still get the same 
Problem. When I use a string instead of a date in the bean it works. But I 
don't want a String since this will cause problems somewhere else. 

What can I do? Who can help me?

 

Partial source code:

 

...

<tc:selectOneChoice value="#{controller.currentMedia.yearOfPubl}" id="year"

              disabled="#{not controller.editor}" >

            <f:converter converterId="books.YearListConverter" />

            <f:selectItems value="#{controller.yearList}" />

</tc:selectOneChoice>

 

 

This is the bean with the date:

...

@Entity

public class Book extends Hardware {

            private static final long serialVersionUID = -1766787777560262298L;

 

            private URL url;

            private Date yaerOfPubl;

 

            /** Creates a new instance of Book */

            public Book() {

                        super();

            }

 

            public URL getUrl() {

                        return url;

            }

 

            public void setUrl(URL url) {

                        this.url = url;

            }

 

            @Temporal(value = TemporalType.DATE)

            public Date getYearOfPubl() {

                        return yaerOfPubl;

            }

 

            public void setYearOfPubl(Date yearOfPubl) {

                        this.yaerOfPubl = yearOfPubl;

            }

}

...

 

 

Regards,

Mario



 

Reply via email to