This chapter describes how to create, edit, use, and manage task flow assets.
This chapter includes the following topics:
Permissions
To perform the tasks in this chapter, you need one of the following portal-level permissions:
Assets: Create, Edit, and Delete Assets
or Create Assets
and Edit Assets
(standard permissions)
Task Flows: Create, Edit, and Delete Task Flows
or Create Task Flows
and Edit Task Flows
(advanced permissions).
For more information about portal-level permissions, see About Roles and Permissions for a Portal.
Task flows are containers in which you can add components such as data controls, portlets, content, and other task flows. Task flows provide the advantage of being reusable, so that the same task flow can be consumed on multiple portal pages. You can create your own custom task flow, and add components to the task flow.
For example, data retrieved from a web service by a data control can be rendered on a portal page in a custom task flow. You can select how to present the data, appropriate to the specific data control. For example, the data can be shown as a table, graph, form, button, or label. You can enable users to control the data displayed by a data control by including a parameter form along with the data presentation. You can also wire data control parameters to task flow parameters so that the data control retrieves data based on the values specified for the task flow parameters. Users can change the value of the task flow parameters in the page editor to request the corresponding data from the data control.
The basic steps to accomplish this are:
Create a data control (see Creating a Web Service Data Control).
Create a custom task flow (see Creating a Task Flow).
Add the custom task flow component to a page, then add the data control you want to render on the page (see Consuming a Data Control in a Task Flow and Controlling the Data Displayed in a Task Flow Using a Data Control).
WebCenter Portal provides many built-in task flows, available through the resource catalog in the page editor. You can also create custom task flows as portal assets, which you can add to your portal pages to provide presentations of the data retrieved by web service data controls (see Working with Web Service Data Controls), along with other components such as portlets, content, and other task flows.
To create a task flow:
You can now edit the new task flow using the page editor and populate it with different resources, including data controls, that are available from the resource catalog. For more information, see Editing a Task Flow and Consuming a Data Control in a Task Flow.
You can edit a task flow using the page editor and populate it with different resources, including data controls, that are available from the resource catalog.
When you first create a task flow, it contains only the content specified by the selected task flow style. To add more content to the task flow, you must edit the task flow's view fragment. You can add a variety of resources to the view fragment from the resource catalog, including data controls. You may also want to edit your task flow to create or modify task flow parameters.
The most common way to edit a task flow is to use the page editor. However, if you prefer, you can edit the source code of the task flow directly. For example, you may want to clean up the page fragment and its page definition when you delete a referenced component, such as a data control, or make adjustments to the task flow's code. For more information, see Editing the Source Code of an Asset.
To edit a task flow in the page editor:
When published, a data control is automatically available in the resource catalog and can therefore be added to task flows. You can consume a data control in a task flow and render it in different presentations, such as a table, graph, or form.
If the data control defines parameters, you can also include a parameter form in the task flow so that users can specify a values for a data control parameter and display data based on that value.
Note:
Adding the same data control more than once to the same task flow may produce unexpected results. If you wish to use the same data control multiple times on a page, then the recommended approach is to create separate task flows for each instance.
This section includes the following topics:
Data retrieved using a web service data control can be rendered in a task flow in different ways. While editing a task flow, when you click Add against a data control's objects in the resource catalog, the Add menu displays different drop handlers. The drop handlers enable you to add a data control's objects as UI elements such as tables, graphs, forms, buttons, or labels. Depending on the type of object and the flavors supported, you can add different UI elements.
Table—This option is displayed when you select a data control accessor that returns a collection of objects that can be displayed in the columns of a table. Select this option to display data in a tabular layout.
For more information, see Presenting Data as a Table.
Form—This option is displayed when you select a data control accessor that returns a collection of objects that can be displayed in a form. Select this option to display source data in a form.
For more information, see Presenting Data as a Form.
Graph—This option is displayed when you select a data control accessor that returns a collection of objects that can be displayed as a graph. This is useful for the purpose of analysis, when you want to generate a report. Select this option to display your data graphically, as a bar, pie, line, or an area chart.
For more information, see Presenting Data as a Graph.
Button or Link—The ADF Button, ADF Link, ADF Image Link, and ADF Toolbar Button options are displayed when you select a data control's methods or operations that perform an action. Select any of the button or link options while adding methods or operations such as Create
, Update
, Delete
, Commit
, Rollback
, Save
, or Close
. Different options are available for different data controls depending on the methods exposed by the data source.
Text or Label—The ADF Output Text, ADF Output Text w/ Label, ADF Output Formatted, ADF Output Formatted w/ Label, ADF Input Text, ADF Input Text w/Label, and ADF Label options are displayed when you select a data control's attributes or methods that return a single object. An attribute can be a scalar parameter of an accessor, a method return, or an object member of a complex parameter. Select a text or label option depending on whether you want to display the value to users or want users to specify a value.
When you add a data control inside a task flow, you can wire data control parameters to task flow parameters so that the data control retrieves data based on a parameter value that you specify. For more information, see Binding a Data Control Parameter to a Task Flow Parameter.
When you add a data control, its accessors, or its methods to a task flow, you can select different options for visualizing the data.
Depending on the object you select and the presentations it supports, different options are listed in the Add menu. For more information, see Supported Presentations.
To add a data control to a task flow:
The Table option is displayed only for data control accessors that return a collection of objects that can be displayed in the columns of a table.
When you add a data control to a task flow as a table, you have two options:
Read-only Table—Add the data control as a read-only table. The content in the table cannot be edited.
Table—Editable tables are not currently supported.
To present data as a table:
The Form option is displayed only for data control accessors that return a collection of objects that can be displayed as a form element.
When you add a data control to a task flow as a form, you have two options:
Read-only Form—Add the data control as a read-only form. The form displays data based on your specification, but the data cannot be edited.
Form—Currently editable forms are not supported.
To present data as a form:
The Graph option is displayed only for data control accessors that return a collection of objects that can be displayed as a graph. You can display data as a bar, pie, line, or an area chart.
To present data as a graph:
If you add a data control to a task flow, editing or deleting the data control at a later date may break the task flow. You can repair the task flow by removing references to the data control from the task flow's source files.
To repair a task flow with broken references to a data control:
Data control parameters are used to restrict the data retrieved by a data control based on the criteria you specify.
For more information, see Creating a Web Service Data Control.
If a data control provides parameters, there are several ways you can change the values of those parameters after you have added the data control to a task flow.
This section includes the following subsections:
If you want end users to be able to change the data displayed in the task flow, you can include the data control's parameters in a parameter form in the task flow. Users can enter values for the data control parameters in the parameter form and the data displayed in the task flow reflects the values specified.
To add a parameter form to a task flow used to present data on a portal page:
If you can edit the task flow where the data control is visualized, you can edit the data control's parameter values in the Component Properties dialog of the table, form, or graph to control the display of data.
To edit data control parameter values:
You can bind a data control parameter to a task flow parameter so that the data control retrieves data based on the value specified for the task flow parameter.
You can bind a data control parameter to a task flow parameter so that the data control retrieves data based on the value specified for the task flow parameter.
For example, if your task flow contains an employee information data control with a bind parameter to limit the data retrieved to a specified job role only, you can create a corresponding job
parameter on the task flow. Users who can edit the task flow can specify a job title for the task flow parameter so that the data control displays the employees with the specified job.
To bind a data control parameter to a task flow parameter:
The data control parameter now uses the value of the task flow parameter to drive the content of the table, form, or graph.
Note:
If you are using a web service data control for which you have not defined a parameter value, you must set an initial value for the task flow parameter. If not, the task flow displays an empty presentation (table, form, or graph). Therefore, in the Data dialog for a web service data control, you must pass an initial value for the task flow parameter as shown in the following example:
#{empty pageFlowScope.stock_Quote ? 'ORCL' : pageFlowScope.stock_Quote}
When published (marked as Available), task flows are automatically available in the resource catalog to be added to a page in the page editor.
For information about creating task flows that can be used on a page to present the data retrieved by data controls, see Creating a Task Flow.
To add a task flow to a portal page:
The Assets and Shared Assets pages provide options to manage task flows.
See Also:
Create—For more information, see Creating a Task Flow.
Delete—You can delete task flows when they are no longer required.
For more information, see Deleting an Asset.
Upload—You can upload an archive file that contains a task flow from another portal.
For more information, see Uploading an Asset.
You cannot use the Upload option to upload a task flow that has been exported from Oracle JDeveloper.
If the task flow that you are uploading consumes data controls, you must first upload those data controls. For more information, see Managing Web Service Data Controls.
Download—You can download a task flow into an archive file for uploading into another portal or for importing into JDeveloper.
Task flows created at runtime may contain components that are bound to data controls. When you download such a task flow, the referenced data controls are not downloaded. When you open the task flow in JDeveloper, you will not see a fully running task flow because the associated data controls are not available in JDeveloper. The task flow will work properly only when you upload it back into WebCenter Portal.
For more information, see Downloading an Asset.
Actions
Copy—You can create a copy of a task flow. The Copy feature enables you to replicate a local task flow in the runtime environment without having to actually export and upload the task flow.
Fore more information, see Copying an Asset.
Security Settings—You can control whether all users or only specific users or groups can access the task flow that you created.
For more information, see Setting Security for an Asset.
Show Properties—Each task flow has certain properties associated with it that control how it is displayed in a portal. These properties are summarized in the Show Properties dialog.
For more information, see Viewing Information About an Asset.
Edit Source—For more information, see Editing the Source Code of an Asset. When editing the source code of a task flow, consider the following:
Do not refer to a Java bean that is not available on the portal server.
Do not refer to functions in JavaScript files that are not available on the portal server.
Do not refer to other task flows that are not available on the portal server.
Do not add a data control that has been created in JDeveloper. The data control may not be available on the portal server, which will cause the rendition of the task flow to break.
Edit Properties—Each task flow has certain properties associated with it that control how it is displayed in the portal. You can edit these properties through the Edit Properties dialog.
For more information, see Setting Properties on an Asset.
Preview—You can preview how the task flow will appear when displayed on a page.
For more information, see Previewing an Asset.
Available—You can control whether or not a task flow is included in the resource catalog, and therefore whether or not it is available for use in a portal.
For more information, see Showing and Hiding Assets.
Tip:
In addition to showing or hiding a task flow in the resource catalog, you can also control whether a shared task flow is available to any, all, or selected portals in WebCenter Portal. For more information, see Setting Properties on an Asset.
Edit—For more information, see Editing a Task Flow.