Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
WCBasicAdminGuide.pdf
Скачиваний:
71
Добавлен:
23.03.2015
Размер:
3.31 Mб
Скачать

Note

Ad hoc activities and blocks are also composed of a group of activities. A block is a way of simplifying the graphical representation of the process, by combining a number of activities under one icon. An ad hoc activity is a group of activities defined at runtime.

Defining Connectors

The Workflow Template Editor supports the following connector types:

Connector

Description

Type

 

Start

The Start connector represents the starting point in a process.

 

Each process has only one Start connector, which cannot be

 

removed or duplicated.

And

An And connector does not fire until all predecessor links have

 

fired. It waits for all preceding activities to complete before

 

allowing the process to continue. For example, a Promote

 

activity can be connected to multiple review activities by an

Or

And connector.

An Or connector fires if any of its predecessor links fire. That

 

is, it allows the process to continue if any of the preceding

 

activities have completed. For example, a Revise activity can

 

be linked to multiple review activities by an Or connector.

354

PTC Windchill® Basic Administration Guide

Terminate Open Predecessor Activities When Fired window or the window.
Because the Or connector and the Threshold connector do not require all activities to be completed before allowing the process to continue, unnecessary activities can remain open. To terminate these activities, click
on the
Threshold Properties
Or Properties

Connector

Description

Type

 

Threshold

AThreshold connector fires if a user-defined number of

 

predecessor links fire. That is, it allows the process to continue

 

only when the user-defined number of preceding activities have

 

completed. To set the number of activities that must complete

 

before a Threshold connector fires, enter a number in the Firing

 

Threshold text box, on the Threshold Properties window.

 

To set a dynamic threshold, in which the firing threshold is set

 

to 0 at runtime and is reset to the number of started predecessor

 

activities, select Add one from the Action in Threshold list on

 

the preceding Link Properties window.

Conditional

A Conditional Router fires user-defined events based on an

Router

automatic event firing expression. Because you can define user

 

events and fire them with an expression for all connectors, the

 

Conditional Router is essentially an Or connector identified by

 

a special icon.

Note

Whenever possible, expressions should be inside a try catch block. Inside the catch block, take corrective action for the exception.

Specify custom routing events, which can be used to control process flow, on the Routing tab panel on the Connector Properties window. For more information, see the workflow help.

Note

Defining Links

Links define the flow of control among nodes within a process definition. They also determine which actions are performed in an activity when a predecessor activity broadcasts (or emits) events. For example, when a user completes a review task (indicating completion by clicking a button on that task page), you can specify that the completion event will cause a link to the next activity to fire.

Understanding Workflow

355

On the Link Properties window, you can map events to actions.

To map an event (in the left column), select a successor action from the dropdown list in the right column. You can specify more than one event to cause the same action to occur. To indicate that an event will be ignored, leave the field in the Action column blank. If an event is ignored, no action is performed when that event is emitted.

To reset all connectors in an events path when it is fired, select the Loop Link checkbox. Selecting the Loop Link checkbox ensures that connectors that are in the loop get reset prior to the workflow loop getting traversed again. The connectors that have already fired are reset, and they can be fired again. Loop links are designed to reset all connectors in the path of the workflow activity that is the target of the loop link. A connector is considered in the path of this activity if it is reached by going forward from the activity AND going backwards from the activity. Loop links appear in red.

You can define custom routing events for most activities and processes. When you do so, these events are also displayed in the Link Properties window, and you can map them to actions in a successor activity. For example, you could include in a process definition the following assigned activities:

Approve

Revise

Promote

The Approve activity defines two custom routing events, yes and no. This activity has two links: one link connects to the Revise activity and another connects to a Promote robot. The link to the Revise activity can be configured to perform the Start action in Revise when the no event is emitted from the Approve activity. The other link can be configured to perform the Start action in the Promote robot when the yes event is emitted from Approve. In this way, the flow of control to the Revise or Promote activity is controlled by the event emitted from the Approve activity.

356

PTC Windchill® Basic Administration Guide

The figures that follow show possible results:

or

Exporting and Importing Workflow

Templates Across Releases

Importing workflow templates across releases is denied by default due to the fact that it could cause data corruption.

Understanding Workflow

357

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]