- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-02-2019 07:31 AM
Hello All,
I am trying to set background color as orange for caller_id field on incident table as below using the field style for VIP caller, but it is not showing on the form view. However, in list view it does show the orange color. Please refer below screenshot and attachments.
Can anyone help why is it not showing on form view?
Thanks in advance.
Prajakta
Solved! Go to Solution.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-02-2019 08:21 AM
Hi,
We do not use Styles for the form view background color.
You will need to modify the OOB client script named "Highlight VIP Caller" and apply your CSS in it.
Add the following script
callerLabel.setStyle({backgroundImage: "url(images/icons/vip.gif)", backgroundRepeat: "no-repeat", backgroundPosition: bgPosition, paddingLeft: '30px' });
callerField.setStyle({color: "red"});
callerField.setStyle({backgroundColor: "orange"});
Here is the URL: https://instance_name.service-now.com/nav_to.do?uri=sys_script_client.do?sys_id=8f0b3ee00a0a0b5700e75f4aaabe4953
Replace instance_name with yours.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-26-2020 02:37 AM
Thank you paul, It worked.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-02-2019 08:45 AM
Are you checking this as an Admin, or are you checking as an ITIL user?
I've found that if I view while myself (admin) the fields are not colored; but if I impersonate an ITIL account, the field has the correct background color.