service portal widget to update a record
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-29-2017 08:04 AM
Hi Community,
I have a requirement to add a widget to the service portal to allow a user to escalate an incident. This is my fist time working with widgets so I have difficulty passing values between the html template and the server script
if it is not already escalated
- They will select a escalate reason from an sn-record-picker
- Enter their comment in a multiline textarea
- Submit their comments which will update the incident record
if it is escalated
- hide the widget
3 issues i have
- I'm unable to get the html template to get the value of the u_escalated filed (true/false). it always sees a 'false' value (log shows [object Object])
- I'm unable to get the the value of the sn-record-picker, (log shows 'undefined' value')
- My recording is not updating (not getting to gr.update)
Here is screen caps of my code
This is the log
Thanks Ray
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-26-2018 06:51 AM
Hi vikram_7
Is it just the escalate comments that are not updating the incident or are any of the fields updating?
Can you verify the the field names in the incident match the glide record?
Have you a field in the incident called u_escalate_comments?
gr.setValue('u_escalate_reason', input.reason);
gr.setValue('u_escalate_comments', input.comments);
gr.setValue('u_escalated', true);
gr.setValue('u_escalated_by', gs.getUserID());
gr.setValue('comments', 'incident escalated');
Regards
Ray
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-26-2018 04:17 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-09-2018 01:19 AM
Can anybody help with this?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-15-2020 01:10 AM
Hi ,
Can you share the template code?
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-17-2022 11:05 AM