ModalWindowContext

ModalWindowContext is a context in the UEF provider object used to perform actions in modal and dialog box.

You can get the ModalWindowContext by calling getModalWindowContext API provided in UEF provider object.

Syntax

Here's the syntax:
getModalWindowContext(): Promise<IModalWindowContext>;

Here's how you can access ModalWindowContext:

const uiEventsFrameworkInstance: IUiEventsFrameworkProvider = await CX_SVC_UI_EVENTS_FRAMEWORK.uiEventsFramework.initialize('appname', 'v1'); 
const modalWindowContext:IModalWindowContext = await uiEventsFrameworkInstance.getModalWindowContext();

Supported Operations

Supported Operations

Operation Name Description Example
OpenModal Used to open the model window. OpenModal operation
CloseModal Used to close the modal window. CloseModal operation
OpenPopup Used to open a dialog box. OpenPopup operation
ClosePopup Used to close a dialog box. ClosePopup operation

Supported Methods

Supported Methods

Method Name Description Example
publish Publishes an operation in record context. For instance, Open Modal, Close Modal, Open Popup, Close Popup Publish
getSupportedActions Returns actions supported by that record context as an array. Get supported actions
Note: All the modal window operations work with GlobalContext and TabContext.