- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-08-2020 10:07 AM
Hi there
I want to add company specific icons into the glyph list in ServiceNow. How can I do this please?
Solved! Go to Solution.
- Labels:
-
Service Portal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2020 12:49 AM
Step1: You have to upload the image to image to the table "db_image"
Step2: Clone the widget Icon Link
Step3: Use the below Html code and Server Side code
HTML:
<div>
<!--// Top Icon -->
<a ng-if="::(options.link_template == 'Glyph Icon' || !options.link_template)" ng-href="{{::data.href}}" class="glyph_icon {{::options.class_name}}" target="{{::data.target}}">
<div class="m-b fa fa-{{::options.glyph}} fa-4x {{::options.class_name}} text-{{::options.color}}" align="center" style="margin-right: auto; margin-left: auto; display: block;"></div>
<h4 style="text-align: center;">{{::options.title}}</h4>
<span class="text-muted">{{::options.short_description}}</span>
<p> </p>
</a>
<!--// Image Icon -->
<a ng-if="::(options.link_template == 'Image Icon')" ng-href="{{::data.href}}" class="image_icon {{::options.class_name}} text-{{::options.color}}" target="{{::data.target}}">
<div><img src="{{data.image}}" alt="" align="center" style="margin-right: auto; margin-left: auto; display: block;"/>
<h4 style="text-align: center;">{{::options.title}}</h4>
<span class="text-muted">{{::options.short_description}}</span></div>
<p> </p>
</a>
Server Script:
(function(){
var gr = $sp.getInstanceRecord();
data.href = $sp.getMenuHREF(gr);
data.target = options.target || "";
var img = new GlideRecord('db_image');
img.addQuery('sys_id', options.image);
img.query()
if (img.next()){
data.image = img.getValue('name')
}
})();
Please mark as Correct Answer/Helpful, if applicable.
Thanks!
Kashyap
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-17-2020 06:58 AM
I did it on ur portal.. please check it
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-17-2020 07:01 AM
Oh ok. So we cannot get as a glyph ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-30-2021 01:22 AM
I followed all of this.
How to you select your custom Glyph over here?
After doing
Step1: You have to upload the image to image to the table "db_image"
Step2: Clone the widget Icon Link
Step3: Use the below Html code and Server Side code
P.S: I have added an PNG image in my Glyph
Thanks & Regards