Win a copy of The Way of the Web Tester: A Beginner's Guide to Automating Tests this week in the Testing forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Capturing initial view instance in restore view phase

Joshua Antony
Ranch Hand
Posts: 254
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

Below is the scenario:

Initially,if I click on a command link that displays a pop up(using java script in the onclick event) below are the phases that get executed.

I can understand this, because this is the first time the page is accessed and hence no other phases will be executed.

Now I close the popup and again click the link, popup appears again and below is the log from PhaseListener


Now, from the phase listener I want to distinguish between these 2 by finding out if the request for page is already the one that
the user accessed before.
For sure, there will be some JSF object where this information is stored, but I am not able to find it.

I had a look at FacesContext, ApplicationImpl, ViewRoot but could not get the place where the PREVIOUS view id is stored.

  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic