• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Junilu Lacar
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Ganesh Patekar

JSF 2.0 and AJAX Problem

 
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

facing a strange problem for some days when build up a very simple General-Detail-View. I reproduce the issue with a (even more simple) demo application.

[The Idea]
- select from a list box an item
- a detail view appears. which edit the underlaying data-object
- save the date

[The Problem]
- selecting an item from a listbox and show the detail-data with ajax-request work.
- the FIRST time after changing the item-list i edit a field from the detail-data and submit the form, the changes are not saved in the bean (and the action-method isn't invoked)
- the SECOND time (without changing the item, just edit the field again) works (model-update and action-method)
>> Problem doesn't occurs when i deactivate the ajax-change event on the listbox and make a full request

[The Code]
Simple Java Bean:


the handler



the page:


I am out of ideas, maybe someone else can test it and see my mistake .

Thanks a lot
Dom
 
Dominik Müller
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

i have no ideas, removed ajax functions from my application for resolving the problem, but that isn't a real good solution.

To test it, i uploaded a little war file, including the sources, i hope somebody can test it and maybe find the solution.

http://rapidshare.com/files/423794519/AjaxBug.war

Thanks a lot again.
Dom
 
Ranch Hand
Posts: 199
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just a guess, but maybe something to test.

You are updating a value in different form there. Is it possible to combine those two forms and send both requests (ajax and full) from the same form?
 
brevity is the soul of wit - shakepeare. Tiny ad:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!