Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
1805903
Create listOfRecordsBasedOnLocation.js
prashantmrshine Oct 21, 2024
8f01db3
Create Readme.md
prashantmrshine Oct 21, 2024
ef798d0
Update listOfRecordsBasedOnLocation.js
prashantmrshine Oct 21, 2024
efbd174
Update Readme.md
prashantmrshine Oct 21, 2024
233adce
Update Readme.md
prashantmrshine Oct 21, 2024
38a2db3
Update listOfRecordsBasedOnLocation.js
prashantmrshine Oct 21, 2024
13ce7e8
Merge branch 'ServiceNowDevProgram:main' into main
prashantmrshine Oct 24, 2025
fcf36f6
Create Telephone Icon Display in Short Description
prashantmrshine Oct 24, 2025
3752547
Delete Server-Side Components/Business Rules/Telephone Icon Display i…
prashantmrshine Oct 24, 2025
1e8a8bb
Create Create Telephone Icon Display in Short Description
prashantmrshine Oct 24, 2025
586e1a0
Delete Server-Side Components/Business Rules/Create Telephone Icon Di…
prashantmrshine Oct 24, 2025
c9624b4
code.js
prashantmrshine Oct 24, 2025
ff59df6
Rename code.js to code_snippet.js
prashantmrshine Oct 24, 2025
5301c73
README.md
prashantmrshine Oct 24, 2025
b8d0fe6
Update code_snippet.js
prashantmrshine Oct 24, 2025
59a14c1
Add files via upload
prashantmrshine Oct 24, 2025
3b20af1
Rename Screenshot 2025-10-24 182535.png to Screenshot
prashantmrshine Oct 24, 2025
511c286
Rename Screenshot to Screenshot.png
prashantmrshine Oct 24, 2025
8a4896d
Rename code_snippet.js to code_snippet.js
prashantmrshine Oct 24, 2025
35fa8bb
Delete Server-Side Components/Business Rules/Create Telephone Icon Di…
prashantmrshine Oct 24, 2025
3106399
README.md
prashantmrshine Oct 24, 2025
9647fb9
README.md
prashantmrshine Oct 24, 2025
fae985c
Add files via upload
prashantmrshine Oct 24, 2025
24dd245
Rename Screenshot 2025-10-24 182535.png to Screenshot.png
prashantmrshine Oct 24, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Get the list of records based on the User's Location while getting the list of records
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
// Business Rule to display the list of records based on the user's location

When to Run - Before Query
Table - Any table in which you want to perform this script
Scripts -
(function executeRule(current, previous /*null when async*/ ) {

// Add your code here
var current_user = gs.getUserID();

var usr = new GlideRecord('sys_user'); // Query User Table
usr.addQuery('sys_id', current_user);
usr.query();
if (usr.next()) {
if (usr.location != '') {
current.addQuery('location=' + usr.location); // Querying the user's location with current record location
}
}
})(current, previous);
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
This script basically updates the Description in Incident table which includes some text but added telephone icon using the script, so that it looks fascinating.
This includes screenshot as well where it shows telephone icon concatenated with specific meaningful string.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
// Update description with telephone icon with specific meaningful description concatenated
(function executeRule(current, previous /*null when async*/) {

try {
//code to execute goes here
var myTelephone = "\u260E"; // Create the telephone icon
if (current.description == "") {
current.setValue('description', "You really should " + myTelephone + " home more often."); // Update the description in concatenation with telephone icon script
}
} catch (err) {
//code to handle error goes here
gs.error("A runtime error has occurred: " + err);
}

})(current, previous);
Loading