Lesson 2 of 6
Processes, forms and approvals
10 min
Listen to this lesson
This lesson builds the people part of Fleet Customer Onboarding in the process builder: the inputs, a form for fleet sales, an approval for Maria's master data check, and an approval for Dan's credit decision. The decision itself comes in lesson 3, and the trigger from S/4HANA in lesson 4. For now the process starts with test inputs.
Process inputs and data types
A process has a process context: inputs set by the trigger, plus outputs of each step. Define a data type for anything structured. Contoso's data type FleetCustomer holds the business partner number, name, sales area 1710 / 10 / 00, expected annual volume in pieces, fleet size and the requested credit limit in USD. Steps map their inputs from the context with the binding dialogs; a misspelled or unmapped field is the most common silent defect in a process.
Step by step: building the process
- In SAP Build, create a project of type Business Process, then a process named
Fleet Customer Onboarding. - Add process inputs (for now) for the business partner number and name, so the process can be started with test data.
- Add an input form for fleet sales: fleet size, expected annual volume of CMC-ALT-100 and CMC-ALT-240, requested credit limit, and a comment. Mark required fields as required.
- Add an approval form for Maria: subject with the partner name, the captured data shown read-only, and Approve and Reject buttons. Set the recipient to a group rather than a person, so substitution and absence do not block the process.
- Add a condition after Maria's approval: Rejected goes to a notification step and ends; Approved continues.
- Add the credit decision (lesson 3) and a second approval form for Dan when the decision says a finance approval is needed.
- Add an action that writes the approved credit limit back to S/4HANA (lesson 4), then an end event.
- Set a due date on both approval tasks; Contoso uses three working days for the master data check.
Forms that testers can trust
| Form element | Contoso setting | Why it matters in testing |
|---|---|---|
| Required fields | Fleet size, annual volume, requested limit | A test without them must be blocked by the form |
| Field types | Numbers as numbers, not text | Decisions compare numbers; text "5,000" fails silently |
| Read-only display | Captured data shown to approvers, not editable | Approvers approve what sales entered, not a changed copy |
| Subject line | Includes partner name and number | Approvers find the task; testers find the instance |
| Buttons | Approve and Reject with a mandatory comment on reject | The reject path carries a reason for the audit trail |
Form settings Contoso standardizes, and why each matters for testing and audit.
Approvals and recipients
An approval step creates a task in the recipients' inbox. The task carries the form, the subject and the due date. Recipients can be users or groups, and can be mapped from the context, for example from a decision output that names the approver group. Contoso sends master data tasks to the group CMC_O2C_MASTERDATA (Maria and her backup) and credit tasks to CMC_FIN_CREDIT (Dan and a deputy). Groups come from the identity provider; testing with the right test users in each group is part of test preparation.
Conditions and notifications
Conditions branch on context values: the approval outcome, a decision output, or a form field. Keep them simple and name each branch after its business meaning ("Master data rejected", "Finance approval needed"), because the names appear in the process diagram that Maria and Dan review and in the instance log testers read. Notifications (mail steps) close each branch so that the person who started the work learns the result; a reject that ends silently leaves fleet sales asking for days. Contoso's rule is that every end event is preceded by a notification that says what happened and, for rejects, why.
What goes wrong in testing
- Recipient is one person. When Maria is on vacation, every onboarding stops. Use groups.
- Unmapped outputs. The approval's decision is not mapped into the condition; every instance takes the default branch.
- Text where numbers belong. A requested limit captured as text never matches "greater than 50,000".
- No reject path test. Teams test approve, approve, approve; the reject notification has a broken recipient.
- Due dates ignored. Nobody tests what happens when a task is overdue.
- StartTrigger the process with test business partner data
- Act as salesFill the input form as a fleet sales test user
- Act as MariaLog in as an O2C group test user, open the task, approve
- Act as DanLog in as a finance group test user, reject with a comment
- CheckInstance completed on the reject branch; notification sent; nothing written to S/4HANA
What would you do?
In the first test run, every onboarding instance goes straight to the write-back action, even when Maria rejects. What is the most likely cause?
- Define data types for structured context and map every step input and output explicitly.
- Send approval tasks to groups, not individuals, and set due dates.
- Every condition branch, including reject paths, is a test path.
- Form field types matter: numbers must be numbers for decisions to work.
Check your understanding · not graded
Lesson check
1. Why does Contoso send approval tasks to groups?
2. Every instance takes the same branch after an approval. What is the likely cause?
3. Why should the requested credit limit be a number field?
4. What does an approval step create?
5. Which path do teams most often forget to test?