Legacy platform

Utils for customizing Sterling Store Engagement

You can use the ias.utils along with other platform utils to customize Sterling Store Engagement screens.

Add and view the customized screen in the application

You can add and view a customized screen in the application either in an editor, wizard, pop-up window, and so on. Usually, utilities that are used to add and view the customized screens are ControllerUtils, BaseUtils, and WizardUtils. For example, to open screens in an editor use the methods that are provided in ControllerUtils. To open wizards in an editor, use WizardUtils, and to open a screen in pop-up window, use BaseUtils. The most commonly used methods are openScreenInEditor, openWizardInEditor, continueOpeningInEditor, and UIUtils.openSimplePopup. For more information about using other methods, see the JavaScript documentation.

Consider ias.utils.openWizardInEditor. The openWizardInEditor opens wizard in new editor. This method reads the EditorMap.json file to determine the editor to be use in the web and mobile environments.

By default, the EditorMap.json file is present in the <INSTALL_DIR>/repository/eardata/wsc/war/wsc/common/ directory. In run time, copy the EditorMap.json file to the extn/wsc/webpages/wsc/common/ directory. Build the WAR or EAR and deploy it to verify the changes. A code snippet from the EditorMap.json file is as follows:
Entities: {
		"wsc.components.shipment.container.pack.ContainerPackWizard": {
		    "WebEditorId":"wsc.desktop.editors.ShipmentEditor",
			"MobileEditorId": "wsc.mobile.editors.MobileEditor",
			"MobileTitle":"Title_ContainerPack",
			"RemoveFromMobileStack":true
			
		},
Here,
  • WebEditorId: Defines the editor to be used in the web environment.
  • MobileEditorId: Defines the editor to be used in the mobile environment.
  • MobileTitle: Defines the title to be displayed on the mobile screen. This attribute is applicable only to mobile environment. If this is not defined,
  • RemoveFromMobileStack: Determines whether the current wizard should be reopened when the user tries to navigate back. Consider the backroom pick flow. Once backroom pick is complete, the Shipment Summary screen is displayed. However, on clicking the back button, the backroom pick flow should not be relaunched as the process is complete. So if RemoveFromMobileStack is true, it indicates that backroom pick wizard will not be relaunched.
Similarly, you can add entries for custom entities.