Guess not. Here is a hack I came up with that does the job.
Add this event script to create a context variable that will hold the name of
jsf target. You can put this in the same places you can put an Action Handler.
| <event type="node-leave">
| <script>
| <expression>
| executionContext.setVariable("taskjspface", "task1")
| </expression>
| </script>
| </event>
|
Then in the HomeBean, I changed the method "selectTaskInstance" to the below
code. This hack does require that you set the context variable then set it
back to null for every task you want to have a customized jsp for. Also don't
forget to update the faces-config.xml with your new navigation rule (target)
and add the jsp.
| public String selectTaskInstance() {
| // Get the task instance id from request parameter
| long taskInstanceId = JsfHelper.getId("taskInstanceId");
| TaskInstance taskInstance =
taskMgmtSession.loadTaskInstance(taskInstanceId);
| taskBean.initialize(taskInstance);
|
| Token currentToken = taskInstance.getToken();
|
| ProcessInstance processInstance = currentToken.getProcessInstance();
|
| ContextInstance contextInstance = processInstance.getContextInstance();
|
| String taskjspface1 =
(String)contextInstance.getVariable("taskjspface");
|
| if (taskjspface1 != null)
| return taskjspface1;
| else
| return "task";
| }
|
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3910103#3910103
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3910103
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user