• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

JSF, rich:pickList and custom converter - Solving "Validation Error: Value is not valid" message

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am creating a JSF 2.0 project, and I am facing a problem when using the rich:pickList (richfaces 4) component with a custom converter.

I can populate the picklist left column rightly. But, when I move some item from left list to the right (by clicking in the pickList "add" button) and I try to submit the form that contains the pickList, I receive the following error message:

"mainForm:picklist: Validation Error: Value is not valid"

I have already overridden the methods equals and hashCode in my model class (Pessoas.java), but the problem remains.

Any idea about how to solve this problem?

Thank you!

cadastroEvento.xhtml



CadastroEventoBean.java


Pessoa.java (model - created automatically by hibernate)


EventSelectedApresentadorEventoConverter.java (custom converter)
 
Daniel Cugler
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Problem solved. My mistake. The method "PessoaLogic.getByID" was returning a list of objects and not just a single one. So, the method "getAsObject" in the converter was not working properly. Now, everything is working like a charm.
reply
    Bookmark Topic Watch Topic
  • New Topic