SAP Knowledge Base Article - Public

2540872 - Archived - [Custom MDF] How to set the field values to Null by default in custom MDF portlets.

Symptom

  • For custom MDF portlets on Employee Profile, when user clicks on "Edit" or "Insert New Record", the fields are populated with the existing values.
  • Not able to set the default values to Null while entering the New record or Editing the existing record.

Environment

  • SuccessFactors Cloud HCM: MDF
  • SuccessFactors Cloud HCM: MDF UI Rules

Reproducing the Issue

  • Navigate to the custom MDF portlet on the Employee Profile or PP3 (People Profile)
  • Click on History->Insert new Record.
    1.png
  • Values in the fields appear from the already saved record.

2.PNG

Cause

This is by design in Employee Profile and PP3, however user can set the fields in the portlets to populate with null values rather than having existing values using a UI rule.

Resolution

To have desired behavior, user will have to make a UI rule in the respective UI screen and configure it as onInsertUI rule.

1. Go to Manage Configuration UI page and search for respective UI screen.

3.png

2. Click on Manage UI rules -> Add Rule.

3. Create a new rule with If condition Always set to True (So that rule does not wait for any condition to be met to start executing) and set the desired field values to Null like in below screenshot.

4.png

4. Click on Save and then Close.

6.png

5. Click on Edit Properties.

5.png

6. Add the rule on the onInsertUI section and click on OK.

oninsertUI.png

7. Click on the Save button on the top.

8. Navigate again to portlet on PP3 page and Click on History ->Insert new Record.

Now you will see that the values in the fields load up as Blank/Null on that portlet, as desired.

8.png

Please Note: 

  • Fields of type "Attachment" and "DateTime" cannot be set to null by default hence this rule does not work for these fields.

Keywords

  • MDF: Metadata Framework
  • Custom MDF portlets
  • UI rules
  • onInitUI rule
  • onInsertUI rule
  • Insert New Record
, KBA , LOD-SF-MDF-UI , UI Config, Rules, Custom MDF Portlets on V12 & PP3 , LOD-SF-MDF-RUL , Rule Issues in MDF Object , How To

Product

SAP SuccessFactors HCM Core 1708