Sunday, December 16, 2012

Parent Action Activity in ADF Bounded Task Flow



Effective use of Parent Action Activity
Here in this post I am explaining the way of Using Parent Action Activity. Using Parent Action client taskflow can call the activity defined in parent task flow. 

This sample application is developed using Hr database, bounded taskflow, control-flow-case, Read only View Object.

Steps to create sample Application
  • Create a Generic Application provide application name as ParentAction. 
  • Create a Project with name ParentAction
  • Select ADF Faces, ADF page flow, Java, ADF Business component as Project Technology
  • Create Business Component from table 
  • Define connection to database using "Hr" schema
  • Create read-only view object for Employee and Department

Define bounded taskflow
Define bounded parent action taskflow
  • Create a taskflow with and ParentActionTasskFlowDefn.xml
  • Added ViewActivity like EmployeeView and DepartmentView 
  •  Define control flow for Employee and Department view
  •  add jsff pages for each ViewActivity.
Define Child taskflow
  • ·         Create a new taslfkow name department-task-flow-definition.xml
  • ·         Add view activity with name of department
  • ·         add parent action
  • ·         define control flow between view and parent action activity
  • ·         add page to view activity
  • ·         Drag drop department view from data control to screen and design page with navigation button
  • ·         Add new button to page, in action of button select the control flow name define in department -task-flow-definition.xml
  • ·         select the parent action update the parent action property to control flow name defined in parent taskflow i.e. ShowEmployee

(Repeat same steps for defining Employee child task flow)
Design the page used in view activity
Drag drop the corresponding taskflow to jsff page used as a view activity in ParentActiontaskFlowDefn.xml
Add lending page
Add the jspx page to application. drag drop ParentActiontaskFlowDefn as region to jspx. Run the application and test it 

Download sample application located at ParentAction.zip




26 comments:

  1. Nice man,It helped me a lot..Thanks a ton

    ReplyDelete
  2. Hi Amit sharma.It's very helped to me.. thanks a lot...

    ReplyDelete
  3. hi amit sharma.. I have a doubt on immediate attribute in adf. Please help me with this.

    advance in Thank you.

    ReplyDelete
    Replies
    1. Immediate property just skip all validation on ur current page and submit the request to server

      Delete
    2. Thank you for immediate response amit... but, I want some more information from this topic with explanation.

      thanks in advance.
      suresh

      Delete
  4. This comment has been removed by the author.

    ReplyDelete
  5. how to create custom component?

    ReplyDelete
  6. hi amit the application showing error for me how did you run the taskflow without using UBT's ?
    you just runned it using bounded taskflow as default activity ?

    ReplyDelete

Thanks for your valuable comment. You comment will go live soon.