Process Foundation
Process Foundation
Process Foundation
This chapter provides details about the Business Center Foundation part Process
Foundation.
The technical concept assumes that every task in the process will end with a result.
These possible results are defined by the content of single task modules. Linking one
task to another, depending on the result of the previous one, allows to create a
complete process flow.
How a single task of the process flow appears is determined by task types, for
example dialog or background task. You can further control the appearance by usual
concepts like requested start or end conditions and event handling capabilities.
Therefore, the Process Foundation allows an easy configuration of processes without
the need for complex development.
Per design, the Process Foundation does not contain any business data context or
business data processing logic. It expects that these are implemented by each
business scenario using suitable data models and processing modules, which are
executed during runtime. Therefore, the Process Foundation has to be considered as
a pure technical platform to simplify the use of SAP Business Workflow.
Important
The Process Foundation is reserved for internal use only. Any custom
configurations beside the activities described in this document are not
supported. With the standard delivery of the product, a pre-configured
Process Foundation profile PF_DEFAULT is delivered. It covers all processing
aspects required for any business scenario and must not be changed at any
time.
To add business scenario related content to the generic process patterns, the product
offers the following concepts. They all are mandatory steps that must be performed:
Important
As a prerequisite, the SAP Business Workflow engine must be configured to
run processes based on Process Foundation. Additionally, the following
tasks must be maintained as general tasks in the PFTC transaction:
Receiver /OTX/PF02_EVENT_RECEIVER
Function
Module
2. In the Basic Settings Overview screen, configure basic settings, using the
following parameters.
Default Language
Enter the default language.
The default language is used to read description texts in some customizing
views. This applies if no description texts are found in the current logon
language. Set the value to EN because this language is already included in
the standard delivery.
Default Profile
Enter the default profile.
The default profile entered here is used as a template when generating new
process foundation profiles. For more information, see “Process Foundation
profile” on page 106.
Note: The data model configuration is used by an internal data handling API.
It automatically reads and writes data to the defined process ledger tables. You
must not perform any database updates manually without using this API. In
general, all usable or extendable interfaces in the product already offer the
corresponding process ledger data. This includes header and item data for use
or to be changed. The interfaces also automatically take care about updates
without the need to use any methods of the data handling API at any point of
time.
2. In the Data Model Configuration Overview screen, define the data model
using the following parameters:
Data Model ID
Define the data model ID, a 10 character unique ID.
Description
Enter a meaningful description to outline for which purpose the data model
is used.
Author
Enter the user name of the creator of the data model or the responsible
person.
Lock Object
Enter the lock object which has been created for the process header ledger
table. If no lock object is provided, no data lock is performed.
Before you can define the levels, you must create the business scenario related data
tables. They must fulfill the following mandatory conditions:
• /OTX/PF02_S_PLH_DATA
• /OTX/PF04_S_BCF_DATA
Note: When creating work object types based on data tables, always make
sure to include the key fields PROJECT_ID, PLKEY and (in case of item tables)
ITEM_NR in the table field list of the corresponding dynamic data selection.
Also make sure to include the non-key field EXTINDEX. For more information,
see “Defining dynamic data selection” on page 170.
To define levels:
2. In the Levels Overview screen, define levels using the following parameters.
Note: Only the hierarchy levels 1 and 2 are supported by the product
standard. Higher hierarchy levels are generally possible using the
standard configuration. However, they are not provided anywhere in
the standard delivery.
Description
Enter a meaningful description for the data hierarchy level.
Table Name
Enter the name of the corresponding process ledger table to be used in the
hierarchy level.
1. In the Levels Overview screen (see “Defining levels” on page 99), mark an entry
and double-click Fields in the Dialog Structure.
2. In the Fields Overview screen, maintain the level key fields, using the following
parameters.
Field Name
Name of the key field of the process ledger table where data of the
corresponding hierarchy level is hold.
Key type
This parameter defines how the value of the key field is determined when
inserting new data entries. Select one of the possible values from the list:
Automatic indexing
The key field value is populated by sequential numbering using the
logic defined with the index parameter fields. This only makes sense for
numeric data types.
Timestamp
The key field value is determined by a timestamp. The field must be of
data type TIMESTAMP or TIMESTAMPL.
Object
Enter the name of the number range object used for the key field in case of
key type Create key by number range object.
Important
The number range interval must be configured in the SNUM
transaction for number range object /OTX/PF02L (not delivered in
BC set). Maintain the number range 01 with the range 1 to
999999999999.
This number range object is used within the DEFAULT Data Model
(also used within Solution Accelerators).
Fieldname to-year
Optional setting.
Enter the field name that contains the value of the to-year to be used in the
number range object in case of key type Create key by number range
object.
Index start
Enter the first index value used for the key field in case of key type
Automatic indexing.
Index interval
Enter the Interval used for new key index determination for the key field in
case of key type Automatic indexing.
If a data entry already exists and the value of the highest index does not
apply to the interval definition, the next generated value is the next free one
of the interval.
2. In the External Data Mapping Overview screen, define the external data
mapping using the following parameters:
Mapping ID
Unique technical ID which identifies the mapping scenario
Description
Enter a meaningful description for the mapping scenario.
Mapping Class
You can use this to implement custom logic in your own handler class for
the mapping. The handler class must implement the /OTX/
PF20_IF_FIELD_MAPPING interface. If no custom handler class is
configured, the standard handler class /OTX/PF02_CL_FIELD_MAPPING will
be called.
Default
Select this check box for one mapping ID. To process different mapping for
different incoming channels, the mapping ID is assigned to an incoming
channel. If no assignment to a channel can be found, the default mapping is
processed. The default mapping usually maps the external fields one-to-one
to the internal ledger table fields.
MAP_HEADER
This method maps external header fields (EXTINDEX = 1 in /OTX/
PF01_T_1EXT) to header table (Level = 1).
It is used for frame workflow processing in /OTX/PF02_CL_WORKFLOW ->
INIT_FRAMEWORKFLOW.
MAP_ITEMS
This method maps external item fields (EXTINDEX = 2 to 999 in /OTX/
PF01_T_1EXT) to item table (Level = 2).
It is used for frame workflow processing in /OTX/PF02_CL_WORKFLOW ->
INIT_FRAMEWORKFLOW.
PROCESS_MAPPING
This method is used for process mapping. It is called inside mapping class.
1. In the External Data Mapping Overview screen (see “Defining external data
mapping” on page 102), mark an entry and double-click Field Mapping in the
Dialog Structure.
2. In the Field Mapping Overview screen, maintain the field mapping, using the
following parameters.
Note: You must configure the external field name in the same way as
it is delivered (case-sensitive).
Field Name
Enter the name of the table field in the ledger target table in the
corresponding data hierarchy level.
Currency Field
Select this check box to indicate a currency field.
Field Mapping Type
Enter the field mapping type. The mapping is processed according to the
mapping type. The following values are possible:
External Field with Conversion (SAP / Custom)
The field is mapped according the assignment of external and internal
field name. It takes the necessary conversion of the SAP field into
account. If a field conversion exit is configured, this exit is processed. If
no exit is configured, the standard SAP conversion is processed which
is assigned to the SAP field.
External Field without Conversion
The field is mapped according the assignment of external and internal
field name. It does not take the necessary conversion of the SAP field
into account.
System variable
A system variable is assigned to the target field. The value is configured
in the Value field (see Value on page 105).
Ignore Character
Enter characters that are deleted in an extra step before mapping continues.
This is useful, for example, if there are apostrophes in a Reference Number.
The field can contain up to 6 characters.
Condense
Select this check box to condense the value.
Value
For field mapping type constant or system variable, assign the related
value.
Channel
Incoming channel in which the document has been processed. For more
information, see “Configuring channels” on page 50).
Mapping ID
Enter the unique technical ID which identifies the mapping scenario.
2. Select the profile that you want to transport. Click Table View > Transport from
the menu and include all corresponding configuration settings in a transport
request.
Note: You must always manually add profile entries in the tables /OTX/
PF02_T_TBWD and /OTX/PF02_T_TBWT to a transport from the SE16
transaction.
Profile ID
ID of the Process Foundation profile
Data Model ID
Enter the name of the business data model containing the process ledger
header and item tables. This stores the business data of the corresponding
business scenario.