You can use this standard task to create a workflow step to enable users to edit a form, for example, a workflow step to create or correct data. Executing a work item calls up a form application in which users can edit the form of a form scenario in the portal. You can also:
Provide functions such as
Save Draft
or
Withdraw Process
.
They are optional elements that you can have in the form application.
Specify where data is to be saved. You can decide whether the data is to be saved directly to the database of the backend system (to update infotypes, for example) as well as in the process object.
Standard task: 17900100
ID:
Edit
Name:
Edit Form
For the authorization object P_ASRCONT, the activity P (Process) is used for the authorization check.
For more information, see Authorization Concept of HCM Processes and Forms .
When a user accesses a work item that is executed with this task, a form application is called. It has the following three views:
Edit
In this view, the users can display, enter, and change data in the form.They can carry out the following actions, provided that you specify in this standard task that the relevant buttons are made available:
Save Draft
Back to Author
Withdraw Process
Send to Expert
Next
Depending on the settings, the agent will be able to see the
Review and Send
button or the
Next
button.By choosing either of these buttons, the user goes to the next view.The system first checks the data.Depending on your settings in the container elements SEND_VARIATION and SEND_EXPERT_IF_INCONSTENT, the user can, for example, complete the work item even if the data is incorrect or send the data to an expert for error handling.
Review and Send
In this view, the user can check the data entered and complete the editing of the form by choosing the
Send
button.The system sends the data entered asynchronously to the backend system. It sets the status of the work item to
Completed
and continues with the next step in the workflow.
Completed
The user receives a confirmation that the data has been sent successfully.The work item disappears from the user's
universal worklist
.
The following graphic illustrates these user interface elements:
In the container definition, you can define the following types of container elements:
Container elements that control which form scenario is used with which scenario step when the task is executed
Container elements that control which of the optional functions are made available when the task is executed
If you use this task, you must also do the following tasks in the relevant workflow step:
Data flow of task container
Rule for agent determination with respective data flow to rule container
Programming exitCL_HRASR00_POBJ_WF_EXIT
Data Flow: Import Elements
Form (FORM) – Mandatory
This element specifies which form scenario is used when the workflow step is executed. It consists of a structure with the following fields, which you have to define for use with this task:
Form Scenario (FORM_SCENARIO)
Enter the form scenario that is to be used within the workflow step.
FormScenario Version (FORM_SCENARIO_VERSION)
Enter the version of the form scenario that you want to use.
Do Not Save Directly (SUPPRESS_SAVE)
You can use this field to override the value of the SEND_VARIATION element. You can use this field to control subworkflows, for example.
Enter an
X
if you do
not want the data to be written to the infotypes in the database of the backend system. This setting is valid even if the value A (
Check and Save
) has been set in the SEND_VARIATION element.
Enter nothing if the data is to be saved according to the settings in the SEND_VARIATION element.
Data type (type name on the
Data Type
tab page in the
ABAP Dictionary Data Type
field
)
:
HRASR00_FORM_KEY_ELEMENT
Form Scenario View (FORM_SCENARIO_STAGE) – Mandatory
Enter the scenario step that is to be used for the workflow step. You must have already defined the step in the
Create Form Scenario
IMG activity (view cluster HRASR00FSCN).
When defining the data flow in the workflow container, you can use a value help (F4) for the FORM_SCENARIO_STAGE field. This allows you to access your Customizing entries. You can use the value help in the
Workflow
column and, in the subsequent dialog box, the value help for the field in the
Temporary Check Results of Table
column
.
If the column is not visible, you can use the
Enter Constant
function.
Data type (
Data Type
tab page,
ABAP Dictionary Reference
field):
Structure
HRASR00_PROCESS_MODELLING
and
Field
FORM_SCENARIO_STAGE
Send
Variant
(SEND_VARIATION) – Optional
You can use this element to specify how you want the system to proceed when executing the
Review and Send
or
Send
functions. The element specifies:
Whether the data is saved in the infotypes in the backend system
Whether the user processing the work item can complete the work item, even if error messages were issued in the backend system due to inconsistent data
When a user executes a work item, the system checks the data in the form against the business logic for the fields that you have linked to the form fields when configuring the form. These checks can cause error messages in various categories, such as insufficient authorization, collisions between data records, or incorrect or inconsistent data. For more information, see Error Handling .
The following values are possible:
BLANK = Do not save (do not tolerate errors)
This is the default parameter. The system checks the data against the business logic in the backend system, meaning it checks the data entered. The user must resolve the error before he or she can complete the work item. To do this, the user can request the help from an expert who then returns the work item to the user. When the user has completed the work item, the data is not written to the backend system's database.
B = Do not save (tolerate errors)
The data is checked in the backend system. If error messages occur due to inconsistent data, the system can tolerate these messages and dynmically provide the user with the
Next
function. When the user has completed the work item, the data is
not written to the backend system's database. The work item is sent to the next agent.
This setting is useful if an expert, such as an HR administrator, performs a workflow step following this step. The user can complete the work item even if the entered data is inconsistent.
Errors that did
not occur due to inconsistent data are
not tolerated in this procedure (for example, missing authorizations). When theses errors occur, the system dynamically shows the
Send to Expert
button in the form application and automatically controls the further processing through an expert.
Note the interaction of the SEND_VARIATION and SEND_EXPERT_IF_INCONSISTENT elements here.
A = Save (do not tolerate errors)
The data is checked against the business logic in the backend system and written to the infotypes in the backend system. Error messages are not tolerated; users have to have entered all data correctly before they can continue editing the form. The user can request an expert's help for this.
If a work item is completed with SEND_VARIATION = A, the system also saves any process steps that were entered in previous steps but not yet saved in the backend system. If this setting is made, you therefore have to ensure that the user in a particular step is also able to correct incorrect data entered by other users. The corresponding fields must therefore be visible and modifiable in the form.
Data type (
Data Type
tab page,
ABAP Dictionary Reference
field):
Structure
HRASR00_PROCESS_MODELLING
and
Field
SEND_VARIATION
Save Draft
button (SAVE_DRAFT_BUTTON_VISIBLE) – Optional
You use this element to specify whether a button is provided to the user to temporarily save the entries in the form. Once the user has temporarily saved the data and the step is not yet completed, the corresponding work item continues to be available to the user in the
universal worklist
for processing with all previously entered data.
X =
Save Draft
button is visible
The user can save the current processing status of the form using the
Save Draft
button.
BLANK = Not visible
The
Save Draft
button is not visible and is therefore not available to the user (default setting).
Data type (
Data Type
tab page,
ABAP Dictionary Reference
field):
Structure
HRASR00_PROCESS_MODELLING
and
Field
BUTTON_IS_ENABLED
Back to Author
button (BACK_BUTTON_VISIBLE) – Optional
You use this element to specify whether a button is provided to the user to return a form to the initiator of a process.
X =
Back to Author
button is visible
The user can return the form to the initiator by choosing the
Back to Author
button. In this case, the processing status (PROCSTATE, see below) receives the value BACK.
Note that you must take account of this behavior in subsequent modeling of the workflow.
BLANK = Not visible
The
Back to Author
button is not visible and is therefore not available to the user (default setting).
Data type (
Data Type
tab page,
ABAP Dictionary Reference
field):
Structure
HRASR00_PROCESS_MODELLING
and
Field
BUTTON_IS_ENABLED
Process Cancelation
button (WITHDRAW_PROCESS_BUTTON_VISIBLE) – Optional
You use this element to specify whether a user can withdraw a process. Withdrawing a process has the following effects:
The entire process is stopped.
All work items in the relevant workflow steps and workflow template that are not completed receive the status
Cancelled
.
The process object is assigned the status
Withdrawn
.
All open work items disappear from the universal worklists of all involved in the process.
The element can have the following properties:
BLANK = Not visible (button not visible)
The
Process Cancelation
button is not visible and is therefore not available to the user (default setting).
ALWAYS = Visible (button visible and active, even after saving to backend system)
The
Process Cancelation
button is always available. The user can cancel the entire process.
You can use this setting to cancel a process even if data has already been saved in the infotypes. Note that this can affect your dataset.
IF_NO_SAVE = Visible before save (button is visible and active until saving to the backend system)
The
Process Cancelation
button is only available to users while the recorded data has not yet been saved in the backend system.
Data type (
Data Type
tab page,
ABAP Dictionary Reference
field):
Structure
HRASR00_PROCESS_MODELLING
and
Field
WITHDRAW_BUTTON_VISIBLE
Expert
button (SEND_EXPERT_IF_INCONSISTENT) – Optional
Users who are not experts at entering personnel data can encounter insolvable problems if error messages occur due to inconsistent data. For this reason, you should allow the system to dynamically show the
Send to Expert
button in the form application when such errors occur and if no suitable agent can correct the errors in the workflow step that follows.
Note the description of the SEND_VARIATION element. For more information, see Error Handling .
X =
Send to Expert
button is visible
The
Send to Expert
button is dynamically displayed if error messages occur due to inconsistent data.
If you specify SEND_EXPERT_IF_INCONSISTENT = X together with SEND_VARIATION (Send Variant) = B, the behavior of SEND_EXPERT_IF_INCONSISTENT overrides that of SEND_VARIATION. This means that if the agent receives error messages due to inconsistent data, he or she cannot complete the work item. The agent must either correct the entered data or send the work item to an expert.
The interaction between SEND_EXPERT_IF_INCONSISTENT and SEND_VARIATION is only relevant for errors in the
Inconsistent Data
error category. The system always provides the
Send to Expert
pushbutton for errors of the following error categories, even if you have set SEND_EXPERT_IF_INCONSISTENT = BLANK:
Data Collision
No Authorization
Object Is Locked (for background steps only)
Incorrect Customizing
For this reason, a user who receives error messages due to inconsistent data can only complete the work item under the following conditions:
He or she corrects the data entered.
He or she forwards the work item to an expert.
BLANK = Not visible
The
Send to Expert
button is not visible and is therefore not available to the user (default setting).
Data type (
Data Type
tab page,
ABAP Dictionary Reference
field):
Structure
HRASR00_PROCESS_MODELLING
and
Field
BUTTON_IS_ENABLED
Container Definition: Export Elements
Processing Status (PROCSTATE) – Optional
You can use this element to specify that the processing status is to be transferred from the workflow step to the workflow container once the work item is completed (data flow: workflow <-
Edit Form
step).
If the processing status is known in the workflow container, you can process the other workflow steps in accordance with the processing status.
A workflow step for editing a form can be completed with the processing status PROCESSED or BACK.
If the work item is completed with the PROCESSED status, the next workflow step should be carried out by an HR administrator.
If the work item is completed with the BACK status, the next workflow step should be carried out by the person who initiated the process.
You model the following workflow steps depending on the processing status.
To transfer the processing status to the workflow container, you must have previously created a suitable container element in the workflow container:
For example, element = PROCSTATE
For example, name = processing status
Data type (
Data Type
tab page,
ABAP Dictionary Reference
field):
Structure
HRASR00_PROCESS_MODELLING
and
Field
PROCESSING_STATUS
The processing status can have the following values:
PROCESSED
The work item was processed successfully. The user has chosen the
Send
function in the view of the form application
Review and Send
.
BACK
The user has chosen the
Back to Author
function.
ERROR
An error occurred in executing the work item. This status is possible only if you entered
B
for the SEND_VARIATION element.
For withdrawn processes, you no longer have to react to a processing status in the workflow. There is therefore no processing status for
Withdrawn
.