- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-28-2018 01:29 AM
Hello everyone,
the constellation I am trying to make working is the following:
- I have a UI Action in the backend UI say to report time worked on INC
- in the GlideModal of the UI Action I open the SP page in the iFrame
- I need to close the GlideModal automatically after time is submitted in the Angular page in the iFrame
What I tried is to write in the session data when the Time is submitted from the SP Widget and then periodically query that from GlideModal. Another idea would be to query periodically the dedicated Time Reported table when GlifdeModal is open and close the GlideModal when new record is created.
Writing to session has not worked due to absence of syncronisation, which means if I write smth to the session on the server side, on the client side page should be reloaded to get new session attributes.
Second option with querying the table would probably work but I find it not pretty and didnt try it yet.
Any help on that issue would be greatly appreciated.
Yevgeniy
Solved! Go to Solution.
- Labels:
-
Service Portal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-04-2018 06:12 AM
Hi Yevgeniy,
I have done something similar for a custom app which basically allows the user to select multiple records from a custom list and reassign them to whatever user they chose in the GlideModal pop-up. The GlideModal window is basically a very small form with two radio buttons and a reference field to the User table. I then created two buttons at which appear at the bottom of the GlideModal pop-up which call client-side functions that either do a server.update() to reassign these record to the individual selected and close the GlideModal or simply Cancel the action which just closes the GlideModal with no action taken and puts the original widget back in focus.
If you have the GlideModal popping up as you've stated you can basically add however many buttons to the bottom of it. I used a the OOTB Panel class to keep the styling of the buttons and such in sync.
Body HTML Template
<div class="panel-footer text-right">
<button class="btn btn-primary" ng-click="c.raUpdateMass()">${Reassign}</button>
<button class="btn btn-danger" ng-click="c.closeModalMass()">${Cancel}</button>
</div>
This client-side function gets called either after the server-side update has completed and records are reassigned or the Cancel button is pressed.
c.closeModal = function() {
c.modalInstance.close();
spUtil.update($scope);
};
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-04-2018 06:12 AM
Hi Yevgeniy,
I have done something similar for a custom app which basically allows the user to select multiple records from a custom list and reassign them to whatever user they chose in the GlideModal pop-up. The GlideModal window is basically a very small form with two radio buttons and a reference field to the User table. I then created two buttons at which appear at the bottom of the GlideModal pop-up which call client-side functions that either do a server.update() to reassign these record to the individual selected and close the GlideModal or simply Cancel the action which just closes the GlideModal with no action taken and puts the original widget back in focus.
If you have the GlideModal popping up as you've stated you can basically add however many buttons to the bottom of it. I used a the OOTB Panel class to keep the styling of the buttons and such in sync.
Body HTML Template
<div class="panel-footer text-right">
<button class="btn btn-primary" ng-click="c.raUpdateMass()">${Reassign}</button>
<button class="btn btn-danger" ng-click="c.closeModalMass()">${Cancel}</button>
</div>
This client-side function gets called either after the server-side update has completed and records are reassigned or the Cancel button is pressed.
c.closeModal = function() {
c.modalInstance.close();
spUtil.update($scope);
};
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-04-2018 06:18 AM
I realized I should have mentioned first that using iFrames within the Service Portal is really not recommended. If you need help creating a true GlideModal pop-up/window or possibly a more in depth demonstration of the one I used as an example, please feel free to reach out to me directly anytime.