Closed glassfishrobot closed 11 years ago
Reported by mojavelinux
mojavelinux said: Change target milestone.
mojavelinux said: Andy Schwartz clarifies:
1. View actions would be processed during invoke application phase. PreRenderView events are delivered during the render response phase.
2. View actions would be integrated with the navigation system (allow navigation rules to be applied). PreRenderView events require programmatic interaction with the NavigationHandler.
3. View actions would be part of the view metadata (like view parameters) and
thus would be available before the full component tree has been created.
PreRenderView event listeners are registered (via
@edburns said: sheetalv
@edburns said: Lincoln also shared http://docs.jboss.org/seam/3/faces/reference/snapshot/en-US/html_single/#viewaction
jkva said:
rogerk said: triage
@edburns said: Bulk assign all of Sheetal's spec issues to me.
@edburns said: Move viewParameters automated test to jsf-test
@edburns said: In progress.
@edburns said: Brian, if you could please hack upon this and make it a simple sample of s:viewAction, I'd really appreciate it.
@edburns said: Brian, if you could please simply hack upon this and turn it into a simple example of s:viewAction, that would be great.
@edburns said: Sending jsf-api/build.xml Adding jsf-api/doc/expert-draft-bg.graffle Adding jsf-api/doc/expert-draft-bg.png Adding jsf-api/doc/jsdoc-template Adding jsf-api/doc/jsdoc-template/static Adding jsf-api/doc/jsdoc-template/static/default.css Sending jsf-api/doc/standard-html-renderkit-base.xml Sending jsf-api/doc/standard-html-renderkit.xml Adding jsf-api/doc/uiviewaction-props.xml Adding jsf-api/src/main/java/javax/faces/component/UIViewAction.java Sending jsf-api/src/main/java/javax/faces/context/ExternalContextWrapper.java Sending jsf-api/src/main/java/javax/faces/event/PhaseId.java Sending jsf-api/src/main/resources/jsf-api.css Sending jsf-demo/build.xml Sending jsf-ri/build.xml Sending jsf-ri/conf/share/facelets_jsf_core.taglib.xml Sending jsf-ri/conf/share/facelets_jsf_core.tld Sending jsf-ri/conf/share/tlddoc-resources/stylesheet.css Sending jsf-ri/src/main/java/com/sun/faces/facelets/tag/jsf/ComponentSupport.java Sending jsf-ri/src/main/java/com/sun/faces/facelets/tag/jsf/core/CoreLibrary.java Adding jsf-test/#758 Adding jsf-test/#758/build.xml Adding jsf-test/#758/i_spec_758_htmlunit Adding jsf-test/#758/i_spec_758_htmlunit/pom.xml Adding jsf-test/#758/i_spec_758_htmlunit/src Adding jsf-test/#758/i_spec_758_htmlunit/src/main Adding jsf-test/#758/i_spec_758_htmlunit/src/main/java Adding jsf-test/#758/i_spec_758_htmlunit/src/main/java/com Adding jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun Adding jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces Adding jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces/regression Adding jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces/regression/i_spec_758 Adding jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces/regression/i_spec_758/Issue758TestCase.java Adding jsf-test/#758/i_spec_758_war Adding jsf-test/#758/i_spec_758_war/pom.xml Adding jsf-test/#758/i_spec_758_war/src Adding jsf-test/#758/i_spec_758_war/src/main Adding jsf-test/#758/i_spec_758_war/src/main/java Adding jsf-test/#758/i_spec_758_war/src/main/java/com Adding jsf-test/#758/i_spec_758_war/src/main/java/com/sun Adding jsf-test/#758/i_spec_758_war/src/main/java/com/sun/faces Adding jsf-test/#758/i_spec_758_war/src/main/java/com/sun/faces/regression Adding jsf-test/#758/i_spec_758_war/src/main/java/com/sun/faces/regression/i_spec_758 Adding jsf-test/#758/i_spec_758_war/src/main/java/com/sun/faces/regression/i_spec_758/NewsIndex.java Adding jsf-test/#758/i_spec_758_war/src/main/java/com/sun/faces/regression/i_spec_758/NewsReader.java Adding jsf-test/#758/i_spec_758_war/src/main/java/com/sun/faces/regression/i_spec_758/NewsStory.java Adding jsf-test/#758/i_spec_758_war/src/main/webapp Adding jsf-test/#758/i_spec_758_war/src/main/webapp/WEB-INF Adding jsf-test/#758/i_spec_758_war/src/main/webapp/WEB-INF/faces-config.xml Adding jsf-test/#758/i_spec_758_war/src/main/webapp/WEB-INF/web.xml Adding jsf-test/#758/i_spec_758_war/src/main/webapp/events.xhtml Adding jsf-test/#758/i_spec_758_war/src/main/webapp/page01.xhtml Adding jsf-test/#758/i_spec_758_war/src/main/webapp/page02.xhtml Adding jsf-test/#758/i_spec_758_war/src/main/webapp/page03.xhtml Adding jsf-test/#758/i_spec_758_war/src/main/webapp/template.xhtml Sending jsf-test/build.xml Sending jsf-tools/src/main/resources/com/sun/faces/generate/facesdoc/stylesheet.css Transmitting file data ................................ Committed revision 9173.
Checkpoint. Specified but not implemented.
@edburns said: snapshot. Brian Leathem's simple testcase works.
@edburns said: Snapshot, sample app based on Dan Allen's original NewsReader testcase works.
@edburns said: Snapshot to run automated tests on ADC machine.
@edburns said: The i_spec_915 testcase caught a mod in this changebundle that introduced breakage. The jsf-ri-config.xml does not need to be modified and I'm not sure why it was. Victory for automated tests.
@edburns said: Resolution attempt one realized http://java.net/jira/browse/JAVASERVERFACES_SPEC_PUBLIC-758
M applicationIntegration.fm
If a matching
call getRedirectURL() on the ViewHandler, passing the current
FacesContext, the
Call responseComplete() on the FacesContext instance for the current
request. If the content of
M jsf-api/src/main/java/javax/faces/component/UIViewAction.java
complete spec for this feature
rename "if" attribute of f:viewAction to "rendered".
M jsf-ri/conf/share/facelets_jsf_core.tld
M jsf-ri/src/main/java/com/sun/faces/application/NavigationHandlerImpl.java
M jsf-test/#758/build.xml M jsf-test/#758/i_spec_758_war/src/main/java/com/sun/faces/regression/i_spec_758/NewsReader.java M jsf-test/#758/i_spec_758_war/src/main/webapp/page02.xhtml
A jsf-test/#758/i_spec_758_simple_war A jsf-test/#758/i_spec_758_simple_war/src A jsf-test/#758/i_spec_758_simple_war/src/main A jsf-test/#758/i_spec_758_simple_war/src/main/java A jsf-test/#758/i_spec_758_simple_war/src/main/java/com A jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun A jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces A jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces/regression A jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces/regression/i_spec_758_simple_war A jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces/regression/i_spec_758_simple_war/ViewActionTestBean.java A jsf-test/#758/i_spec_758_simple_war/src/main/webapp A jsf-test/#758/i_spec_758_simple_war/src/main/webapp/main.xhtml A jsf-test/#758/i_spec_758_simple_war/src/main/webapp/WEB-INF A jsf-test/#758/i_spec_758_simple_war/src/main/webapp/WEB-INF/web.xml A jsf-test/#758/i_spec_758_simple_war/src/main/webapp/result.xhtml A jsf-test/#758/i_spec_758_simple_war/pom.xml A + jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces/regression/i_spec_758/Issue758SimpleTestCase.java
@edburns said: Sending jsf-api/src/main/java/javax/faces/component/UIViewAction.java Sending jsf-ri/conf/share/facelets_jsf_core.tld Sending jsf-ri/src/main/java/com/sun/faces/application/NavigationHandlerImpl.java Sending jsf-test/#758/build.xml Adding jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces/regression/i_spec_758/Issue758SimpleTestCase.java Adding jsf-test/#758/i_spec_758_simple_war Adding jsf-test/#758/i_spec_758_simple_war/pom.xml Adding jsf-test/#758/i_spec_758_simple_war/src Adding jsf-test/#758/i_spec_758_simple_war/src/main Adding jsf-test/#758/i_spec_758_simple_war/src/main/java Adding jsf-test/#758/i_spec_758_simple_war/src/main/java/com Adding jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun Adding jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces Adding jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces/regression Adding jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces/regression/i_spec_758_simple_war Adding jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces/regression/i_spec_758_simple_war/ViewActionTestBean.java Adding jsf-test/#758/i_spec_758_simple_war/src/main/webapp Adding jsf-test/#758/i_spec_758_simple_war/src/main/webapp/WEB-INF Adding jsf-test/#758/i_spec_758_simple_war/src/main/webapp/WEB-INF/web.xml Adding jsf-test/#758/i_spec_758_simple_war/src/main/webapp/main.xhtml Adding jsf-test/#758/i_spec_758_simple_war/src/main/webapp/result.xhtml Sending jsf-test/#758/i_spec_758_war/src/main/java/com/sun/faces/regression/i_spec_758/NewsReader.java Sending jsf-test/#758/i_spec_758_war/src/main/webapp/page02.xhtml Transmitting file data ............ Committed revision 9254.
Sending applicationIntegration.fm Sending preface.fm Transmitting file data .. Committed revision 1027.
Committed to trunk.
@edburns said: snapshot
@edburns said: Corner cases on using viewAction to go back to the same page http://java.net/jira/browse/JAVASERVERFACES_SPEC_PUBLIC-758
M applicationIntegration.fm
If a matching
getFlash().setKeepMessages(true) on the current FacesContext. Compare
the viewId of the current viewRoot with the
matching
to effectively restart the JSF lifecycle on the
matching
parameters or navigation case parameters, clear the view map of the
UIViewRoot, and call setRenderAll(true) on the
PartialViewContext. Implementations may choose to meet this
requirement by treating this case as if a
on the matching
continue on to the next bullet point.
M jsf-api/src/main/java/javax/faces/component/UIViewAction.java
M jsf-ri/src/main/java/com/sun/faces/application/NavigationHandlerImpl.java
M jsf-test/build.xml
M jsf-test/#758/i_spec_758_simple_war/src/main/java/com/sun/faces/regression/i_spec_758_simple_war/ViewActionTestBean.java A + jsf-test/#758/i_spec_758_simple_war/src/main/webapp/pageAviewActionPageA.xhtml A + jsf-test/#758/i_spec_758_simple_war/src/main/webapp/pageAviewActionEmpty.xhtml A + jsf-test/#758/i_spec_758_simple_war/src/main/webapp/pageAviewActionPageAExplicitRedirect.xhtml A jsf-test/#758/i_spec_758_simple_war/src/main/webapp/WEB-INF/faces-config.xml A + jsf-test/#758/i_spec_758_simple_war/src/main/webapp/pageAviewActionNull.xhtml M jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces/regression/i_spec_758/Issue758SimpleTestCase.java D jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces/regression/i_spec_758/Issue758TestCase.java A + jsf-test/#758/i_spec_758_htmlunit/src/main/java/com/sun/faces/regression/i_spec_758/ViewParametersTestCase.java M jsf-test/#758/build.xml
@edburns said: Committed frame changes.
Sending applicationIntegration.fm Transmitting file data . Committed revision 1028. Rhombus:frame edburns$
lamine_ba said: Hi,
Regarding the instruction below
<f:view>
<f:metadata>
<f:viewParam name="id" value="#{blogController.id}"/>
<f:viewAction execute="#{blogController.loadEntry}" onPostback="false"/>
</f:metadata>
</f:view>
I'm wondering if we could have this short variation
<f:view>
<f:metadata>
<f:viewAction param-name="id" param-value="#{blogController.id}"
execute="#{blogController.loadEntry}" onPostback="false"/>
</f:metadata>
</f:view>
Thanks
@edburns said: Closed pending verification of implementation.
@edburns said: Leo found some additional work for this issue.
@arjantijms said: Now that the JSF 2.2 spec has been finalized, shouldn't this issue be closed as well?
File: 20110615_i_spec_758.patch Attached By: @edburns
File: 20110729-01-i_spec_758.patch Attached By: @edburns
File: 20110810-i_spec_758.patch Attached By: @edburns
File: 20110812-i_spec_758.patch Attached By: @edburns
File: 20110818-i_spec_758.patch Attached By: @edburns
File: changebundle.txt Attached By: @edburns
File: diffs.patch Attached By: @edburns
File: diffs.patch Attached By: @edburns
File: i_spec_758_war.zip Attached By: @edburns
File: newfiles.zip Attached By: @edburns
Issue-Links: depends on JAVASERVERFACES_SPEC_PUBLIC-762 JAVASERVERFACES-2165 JAVASERVERFACES-2269
This issue was imported from java.net JIRA JAVASERVERFACES_SPEC_PUBLIC-758
Marked as fixed on Friday, May 10th 2013, 2:46:29 pm
JSF should provide a view metadata component that defines a method expression to be invoked before the component tree is built (or restored), with support for navigating to an alternative view afterward using navigation rules. Navigation may be the result of a constraint violation, a security restriction, or because the request was for a pseudo-view.
As an example, the developer might use a view action to load a blog entry before the view is displayed. If the entry cannot be found, the user would be redirected to another page using a navigation rule.