IPopFlowGenericRequest

This object must be passed as the request object for pop operation to open any page.

Functions

setFlow

This function is used to set flow of application. .

The following example shows the syntax:
setFlow(flow: string): void;

The following table shows the parameter:

Parameters

Parameter Name Required? Description
flow No Flow URL of the page.

setPage

Function set to set the page of the application.

The following example shows the syntax:
setPage(page: string): void;

The following table shows the parameter:

Parameters

Parameter Name Required? Description
page No The name of the page.
The following code snippet shows an example in Typescript:
const frameworkProvider: IUiEventsFrameworkProvider = await CX_SVC_UI_EVENTS_FRAMEWORK.uiEventsFramework.initialize('MyFirstExtensionID''v1'); 
      const globalContext: IGlobalContext = await  frameworkProvider.getGlobalContext(); 
      const requestObject: IPopFlowGenericRequest = frameworkProvider.requestHelper.createPublishRequest('PopOperation') as IPopFlowGenericRequest;
      requestObject.setFlow('service/ec/container/sr');
      requestObject.setPage('view-article');
      requestObject.setInputParameters({answerId: "10006003"});
      const response: IPopFlowResponse = await globalContext.publish(requestObject) as IPopFlowResponse;

The following code snippet shows an example in JavaScript

const frameworkProvider = await CX_SVC_UI_EVENTS_FRAMEWORK.uiEventsFramework.initialize('MyFirstExtensionID''v1'); 
      const globalContext = await  frameworkProvider.getGlobalContext(); 
      const requestObject = frameworkProvider.requestHelper.createPublishRequest('PopOperation');
      requestObject.setFlow('service/ec/container/sr');
      requestObject.setPage('view-article');
      requestObject.setInputParameters({answerId: "10006003"});
      const response = await globalContext.publish(requestObject);