HTML Content in Employee forms

JohnnySnow
Kilo Sage

Hi Team,

 

We have a record producer with lot of variables, so instead of adding new fields on the LCE table, we are capturing all the variable details(from the front end esc) that the user selected in a rich text description.

I’m using employee forms to populate this field (through field mapping). Since there are lot of fields I thought of representing it in a tabular format which I’m able to see properly in that Case form.

 

The issue happens when I try to view this value in the esc portal. The employee form which I created has a multi line string mapped to rich text description(which I'm populating as mentioned above).

These values in the esc portal is rendered as a string and all html tags are shown instead of html table which I had created for easier representation of data.

 

Is there a way to show the data in HTML format on the employee forms(surveys) in the esc portal or is there any other way of presenting the data.. like pdf?

 

 

Thanks
Johnny

Please mark this response as correct or helpful if it assisted you with your question.
1 ACCEPTED SOLUTION

Hi All,

 

I was able to solve this, might not be the right solution for all but in my case, the managers just wanted to see all the fields values that the end user had input and take the decision of approving/rejecting accordingly.

Solution:

The HTML content from the description was pushed to the HR tasks using activity field mapping of the first task as below.

JohnnySnow_0-1685624874883.png

So, now when the approver logs in, in the tasks he can see the richtext description by default.

 

I no longer need to add the fields in the table. 

Thanks
Johnny

Please mark this response as correct or helpful if it assisted you with your question.

View solution in original post

3 REPLIES 3

Sandeep Rajput
Tera Patron
Tera Patron

@JohnnySnow From the documentation, it looks like mapping is not supported for HTML field type.

 

Screenshot 2023-05-31 at 8.35.09 AM.png

Referencehttps://docs.servicenow.com/en-US/bundle/utah-employee-service-management/page/product/human-resourc...

Amit Gujarathi
Giga Sage
Giga Sage

HI @JohnnySnow ,
I trust you are doing great.

To address this issue, I recommend the following solution:

  1. Modify the field mapping in the record producer:

    • Instead of capturing all the variable details in a rich text description, create individual fields for each variable on the LCE table.
    • Map these individual fields to the respective variables on the employee forms.
  2. Update the employee forms:

    • Remove the rich text description field that is currently being used to capture the variable details.
    • Add the individual fields for each variable on the employee forms, using appropriate field types (text, dropdown, checkbox, etc.).
  3. Display data in the ESC portal:

    • After implementing the above changes, the data captured through employee forms will be stored in separate fields on the LCE table.
    • Update the ESC portal to display the data from these individual fields in the desired format. For example, you can create a UI page or UI macro to render the data as an HTML table.
    • Modify the appropriate portal page to incorporate this UI page or macro, so that the data is displayed as an HTML table in the ESC portal.

Was this answer helpful?


Please consider marking it correct or helpful.


Your feedback helps us improve!


Thank you!


Regards,


Amit Gujrathi



Hi All,

 

I was able to solve this, might not be the right solution for all but in my case, the managers just wanted to see all the fields values that the end user had input and take the decision of approving/rejecting accordingly.

Solution:

The HTML content from the description was pushed to the HR tasks using activity field mapping of the first task as below.

JohnnySnow_0-1685624874883.png

So, now when the approver logs in, in the tasks he can see the richtext description by default.

 

I no longer need to add the fields in the table. 

Thanks
Johnny

Please mark this response as correct or helpful if it assisted you with your question.