Answer the question
In order to leave comments, you need to log in
When can a @ViewScoped bean update its instance?
There is a @ViewScoped bean that contains some data. I update this bean via setInterval which calls the bean's method via AJAX (h:commandScript). The fields are updated on click, but after the interval is completed, i.e. The next call to the bean method, in the getters, the instance is changed to the old one and the values set earlier are reset. Those. it turns out that the bean has two instances for the page. One before the interval, and the other after, which, subsequently, is reset to the previous one.
Any ideas why this might be happening?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question