- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-12-2016 12:56 AM
Hi There,
When an incident (Report something broken) is submitted on the ESS_Portal, the user's call back number is not populated. This is populated if the Incident is put in the back end "Service Desk" side. We need it to be consistent.We do not have a phone variable in "Report something broken" form but it should populate in the incident form after submit. Call back number field should pull value from phone field in the sys_user table. How can i do this?
Solved! Go to Solution.
- Labels:
-
Service Mapping
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-12-2016 11:51 AM
I would probably do this a little differently....
as I see it ... unless you manually enter an incident the call back number isn't populating... this means it won't work from the catalog or any other incident creation process.. yes you can do this with a catalog script on the item.. but that won't help if you come up with a different method of creating incidents... <inbound email, create incident ui actions from another record etc..>
what is really needed is that if a record is inserted into the table and the call back number is blank it should be populated from the user table... <i was going to ask why not just remove the call back number and add the users phone number from the table to the incident form.. but i suspect you want them able to specify a call back number OTHER than the default>
if what you are trying to acomplish is to ensure that all entries have a call back number i would use a before br on the incident table..
before insert <not update>
conditions call back number is empty
actions call back number to user.phone_number <use the correct field here>
if that isn't available in actions and it may not be depending on the types of fields involved... advanced checked with the following script
current.u_call_back_number_field_name = current.caller_id.phone_number //again use the right field name.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-12-2016 01:04 AM
use default field as : javascript:gs.getUser().getMobileNumber();
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-12-2016 01:14 AM
Hi Akhil,
I've added this and it is not showing the phone number.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-12-2016 01:22 AM
Hi Sarasaamani,
Can you try this?
- javascript:
- var gr = new GlideRecord('sys_user');
- gr.addQuery('sys_id',gs.getUserID());
- gr.query();
- if(gr.next()){
- gr.mobile_phone;
- }
Let me know if it works.
Regards,
Shamma
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-12-2016 01:22 AM