- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-04-2017 07:32 AM
Hi guys,
I was wondering if I could open a modal popup with some data in it after a record producer is submitted in Service Portal. I have this record producer that requires displaying some information to the users upon submitting a form and wonder if someone could shed some light on how to achieve this please?
Many thanks,
JD
Solved! Go to Solution.
- Labels:
-
Service Portal Development

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-04-2017 11:19 AM
here is an example onload client script I wrote that should work for either SP or OOB views. you can render direct content in the glidemodal like this code below. If you would rather use a ui page that is fine for the GM, but for the spModal, you would need to create a new SP widget to display it. this should give you the concept though. spModal is only available on Portal, so that is why we handle both cases in one script. Make sure you select UI Type = All in your client script.
function onLoad() {
//Type appropriate comment here, and begin script below
if (typeof spModal != 'undefined') {
spModal.open({
message: 'This is a test SP modal',
title: 'Test SP Modal'
});
} else {
var gm = new GlideModal();
gm.setTitle('Test GM');
gm.renderWithContent('This is a test GlideModal');
}
}
This technically should work the same in a catalog onSubmit client script, but I still feel there will be an issue with redirects in the OOB view, though it actually may work fine in the SP because it is a single page app so doesn't do a true redirect after submission.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-04-2017 08:37 AM
I thought so, thats why i joined you in the question, i was trying to do something similar myself with little or no success. But when i saw you interested in the answer by Karthik i realized that i might have misunderstood you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-04-2017 08:45 AM
ah okay. so you haven't had much joy with the modal implementation then?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-04-2017 08:48 AM
Previously i have worked on angular implementation in cms, but no luck yet on this
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-04-2017 08:33 AM
Hi Karthik,
I included the script in a catalog client script and when I submit the form it creates this error 'ReferenceError: GlideDialogWindow is not defined'. Have I included the script in the right place, i.e. catalog client script or is there anything else I'm missing here?
Many thanks.
JD
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-04-2017 08:38 AM
Hi John ,
Do you mind posting your code?