- Customer posted the custom fields through API and it is not appeared in Panels.
- Applicable to All Data Centers.
- Please follow below steps in order to post custom fields successfully and to appear in panels:
1.First of all the custom elements need to be added to an XSLT file in Super Admin. This file defines the data elements of the PostNewhireRecord API.
To add the custom elements to the XSLT file we you have to download it, then update it with the elements, and import it back into Super Admin again. To download the XSLT file click on the Account name under ONBPREM Accounts >> Import/Export Settings >> HRXML.ImportNewHire then select Export file and click on Submit.
Open the XSLT file HRXML.ImportNewHire.XSLT in Notepad++ (or any other suitable XML editor). Add custom elements in the /hrxml/NewHire/UserArea/CustomField section using the below as an example :
<!-- preferred_name -->
<xsl:value-of select="normalize-space(/hrxml:NewHire/hrxml:UserArea/hrxml:CustomField/hrxml:preferred_name)" />
Once you have added all the custom elees click on Import File >> Choose File >> Submit.
Note: with each version that you import you will see the Modification history getting built up.You can revert to an earlier version of the XSLT by clicking on Restore for a given version.
Now that we have seen how custom fields are updated in the XSLT in Super Admin, we shall look at the changes required in the API payload.
2.Remove only this string “<xsl:text>CustomField.</xsl:text>” from xslt file in custom fields section and your file should be like below:
<!-- Custom fields -->
<!-- <xsl:text>CustomField.</xsl:text> -->
<xsl:value-of select="./@name" />
<xsl:value-of select="./@value" />
3. Custom Elements:
First of all the custom elements need to be added to the custom Panels of a custom Process. This is typically done by a Functional Consultant, who then provides the list of the custom fields to the Integration Consultant.
All the custom elements are represented by name and value pairs in the section <UserArea> as illustrated in the XML snippet below –
<!-- Custom Fields -->
<xpresshr:CustomField name="name" value=" Test"/>
<xpresshr:CustomField name="addrs1" value=" Test1"/>
<xpresshr:CustomField name="addrs2" value="Test2"/>
<xpresshr:CustomField name="mobile" value="123456789"/>
<xpresshr:CustomField name="country" value="US"/>
- custom field
- Posting custom fields