Symptom
- The attachment was able to be used in a rule during a termination from 1705. This rule is not longer working. The rule is not recognizing when an attachment has been added.
- The attachment field is set required in manage business configuration/XML for employment information portlet.
There is no 'mandatory sign' and you can still save data without populating the field.
Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental.
Environment
SAP SuccessFactors Employee Central
Reproducing the Issue
The Attachment field is set as Required in Manage Business Configuration.
Although the asterisk sign is showing beside the field in the UI, you can still save data without populating the field.
No warning / validation error message appears
Cause
Configuration issue: The attachment is not correctly configured.
Attachment field will not have a value until at the end of save action, so if we try to check its value in onSave rule, it will not work.
Please try the below steps to meet the requirement here.
- Configure a rule with "Job information model" as base object.
- In the rule, check the value for event reason field and based on its value, set required property for attachment field to Yes or No.
- Add it as an onChange rule for event reason field in jobInfo element.
After this, on termination screen, once you select a value for "event reason" field, based on its value,
required property for attachment field will be set, and it will throw the validation accordingly.
Please follow an example Configuration below in the Resolution section
Resolution
The scenario detailed in here is to require attachment on termination event.
- Create the Event Reason field in BCUI.
- Create a rule based on your requirement
- Associate the rule to the Event Reason
- You can also add this directly to SDM and this is how it would look like in XML
- In this scenario, the rule for attachment is set to trigger on event Reason = Termination.
- Notice here that Employment Attachment is not mandatory
- Notice how Employment Attachment is now mandatory once the termination event is selected
- if you attempt to submit without attachment you get an error message
If you still have an issue after this please don't hesitate to contact our Support Team (LOD-SF-EC)
Keywords
Attachment, Mandatory field, rule, required , KBA , LOD-SF-EC-JOB , Job Information , How To