Popup Acknowledgment

Overview

The Popup Acknowledgment component is used to customize the Acknowledgment that pops up after the completion of an action during the user journey. The Popup Acknowledgment component can be customized to be used in multiple places. It is used to show warnings, status after a user signs out of the application, status of removing a biller from the biller list, etc.

The Popup Acknowledgment component contains a Popup screen with a message, an image showing the status, and one or two action buttons as per the requirement.

The action to select on the button may or may not be provided as per the requirement. For one sample, a popup acknowledgment can have two buttons to action (Yes/No). For a second sample, the popup acknowledgment may have one button to action (Done). For a third sample, the popup acknowledgment may not have any button to action, but the user will have to select outside the popup to close the acknowledgment.

NOTE: The Popup Acknowledgment component is used inside the Mobile Banking application.

Popup Acknowledgment Contracts

The Popup Acknowledgment component contains the following contracts for customizing the widgets and UI of the Acknowledgment Popup.

Service Parameters

The Service Parameters contract of the Popup Acknowledgment component provides services helps to set the service details to get the response data. The response data retrieved from the service is mapped to the widgets using the Data Mapping property and then displayed on the screen.

The Popup Acknowledgment component currently uses data only from the context variable.

Here is a sample of the JSON object provided in the Service Parameter of the Popup Acknowledgment component.

{}

Data Mapping

The Data Mapping property of the Popup Acknowledgment component maps the widget IDs with the data to be displayed. The data is retrieved from the Context variable. The Data Mapping property of Popup Acknowledgment component supports the following Tokens.

  • ${CNTX.lblTitle}: To map the value from the context variable.
  • ${i18n{i18n.common.signIn}}: To map the i18n text.

Here is a sample of the JSON object provided in the Data Mapping of the Popup Acknowledgment component.

{
	"fields": {
		"ackimg": "${CNTX.ack}",
		"closeimg": "${CNTX.close}",
		"lblTitle": "${i18n{i18n.common.successSignOutMsg}}",
		"lblDescription1": "${i18n{i18n.common.confirmationMsg}}",
		"lblDescription2": "",
		"btnPrimary": "${i18n{i18n.common.signIn}}",
		"btnSecondary": ""
	},
	"segments": {
		"segErrorDetails": {
			"segmentMasterData": "${CNTX.errorDetails}",
			"segmentUI": {
				"lblGenericMsgInfo": "${segmentMasterData.message}"
			},
			"maxErrorMsgLength": "3"
		}
	}
}
  

The Data Mapping contract is assigned a JSON object with the following key-value pairs.

Key Description
fields

JSON object that maps the widgets to the text or image displayed on the pop-up. This parameter contains the following key-value pairs.

  • ackimg: Sets the image showing the status of the action.
  • closeimg: Sets the image to be clicked to close the pop-up.
  • lblTitle: Sets the text of the header of the pop-up.
  • lblDescription1, lblDescription2: Sets the text to be displayed providing the details of the action.
  • btnPrimary, btnSecondary: Sets text to be displayed on the action buttons.

To hide any widget, provide an empty value to the widget mapping.

segments

This section maps the data with the widgets in a key value format. This parameter accepts a JSON object with the following key value pairs.

  • segErrorDetails: This parameter is mainly used when the action fails. This parameter accepts a JSON object with the following keys.
    • segmentMasterData: Maps the parent key of the error details in an Array format.
    • segmentUI: Maps the widget ID with the corresponding error details.
    • maxErrorMsgLength: Sets the length of the error messages displayed in the UI.

Data Formatting

The Data Formatting property is used to provide a custom format for a specific requirement. The Popup Acknowledgment component does not contain any customization.

{}

Conditional Mapping Key

The Conditional Mapping Key is used to define mapping based on a criteria.

For example, if a label defined in the UI must display different data according to the type of account, a developer must set the Conditional Mapping Key property to the following value. The Popup Acknowledgment component does not contain any value for this key.

{}

Conditional Mapping

The Conditional Mapping property key is used to map a widget with a data from Collection Object or service response as per the Conditional Mapping key. The Popup Acknowledgment component does not contain any customization for this key.

{}

Dynamic Skin

The Dynamic Skin contract of the Popup Acknowledgment component is used to override any existing skins used inside the component.

The Dynamic Skin contract assigned a JSON object with the following key-value pairs.

Key Description
fields

Maps widget IDs with the corresponding Component level widget skins.

Here is the format for mapping the widget with the corresponding skins.

{
 <widgetID1>  : <skinName1>,
 <widgetID2>  : <skinName2>
}

Here is a sample of the JSON object provided in the Dynamic Skin contract of the Popup Acknowledgment component.

{
  "fields" : {
    "lblTitle": "lblGrey500FS40Emp",
    "lblDescription1": "lblGrey400FS20",
    "lblDescription2": "lblGrey400FS20",
    "btnPrimary": "btnPrimary",
    "btnSecondary": "btnSecondary"
  }
}

onError event

The OnError event is invoked when an error occurs during the user journey. When the onError event is invoked, an error object is passed to the parent widget. This object contains the information about the error as well as where it had occurred.

Parameter Value
Input parameter JSON object

Object Description

The JSON object contains the following keys:

  • level: This key contains the String value regarding the place in which the error occurs. It can be from the component View controller or from the component Business controller.
  • method: This key contains the method to be executed when an error occurs.
  • error: This key contains the actual error message and the stack.

Sample Input

var errordata = {
	"level": "ComponentViewController",
	"method": "render",
	"error": err
};
this.onError(errordata);

handCallToAction Event

This event is used to pass the Button (CTA) ID and component context information to the parent widget.

Parameter Value
Input parameter

The following parameters are passed as a JSON object.

  • btnID: Current Button (CTA) Identifier
Programmatic Name handleCallToAction

Sample Code

this.handCallToAction(btnID);

Return Type

None

handleTitleBar Event

The handleTitleBar event is used to update the native title bar attributes based on popup visibility. This event is applicable only for iOS platform.

Parameter Value
Input parameter

NA

Programmatic Name handleTitleBar

Sample Code

this.handleTitleBar();

Return Type

None

setContext Method

This method is invoked inside the parent component or form controller. Using this method, you can pass the context object containing the information required for the component.

Parameter Value

Syntax

this.view.componentID.setContext(contextData);

Input parameter JSON object containing the context variable. For more information on the context object, click here.

Sample Input

this.view.popupAck.setContext(contextData);

Return Type

None

Context Object

The context object is a JSON object that is used to pass the data required for the component. The context variable helps the component get the data using the following parameters.

  • ack
  • close
  • title
  • description1
  • description2
  • primary
  • secondary
  • errorDetails

Here is a sample of the Context JSON Object used inside the component.

var data = {
	"ack": "acksuccess.png",
	"close": "",
	"title": "You have successfully signed out.",
	"description1": "Thank you for using Infinity Digital Banking",
	"description2": "",
	"primary": "",
	"secondary": "",
	"errorDetails": []
};

 

 

Copyright © 2020- Temenos Headquarters SA

Published on :
Monday, May 2, 2022 5:08:57 PM IST

Feedback
x