Hi,
I am making use of the @Redirect tag as below:
@ApplicationException(rollback=true)
| @Redirect(viewId = "/secure/structure/management/adminHome.xhtml")
| public class NAPException extends Exception implements Serializable {
This works well. However, ideally I would like to configure the viewId at
runtime to direct to a specfic page (depending on what the user was doing and
where the exception got thrown).. eg.
@Name("napException")
| @ApplicationException(rollback=true)
| @Redirect(viewId = "#{napException.viewId}")
| public class NAPException extends Exception implements Serializable {
| @Out(required=false)
| private String viewId;
| public NAPException(String message) {
| super(message);
| }
|
| public NAPException(String viewId, String message) {
| super(message);
| this.viewId=viewId;
| }
|
| public String getViewId() {
| return viewId;
| }
|
|
| public void setViewId(String viewId) {
| this.viewId = viewId;
| }
| }
and invoked through:
throw new NAPException("/secure/structure/management/adminHome.xhtm",e);
Unfortunately the above does not work, Is there a way I can specify the target
viewId ?
Thanks
Louis
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977248#3977248
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977248
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user