Phone API Reference -Extended - app.showErrors

Phone API Reference -Extended - app.showErrors

app.showErrors

Description

Clears the screen and shows an error popup on the entire screen. Takes an array of error messages so you can show multiple messages at one time.

Basic Example: 

 

app.showErrors(parameters);

 

The errors array should contain at least one object that requires the key 'message.' In addition, 'code' can be used to supply an error code in parens at the end of the message.

Parameters

 

Name

Required

Type

Default

Description

errors (app.showErrors)

Yes

array

 

An array of messages for display. Each item in the array should be an object that requires the key 'message' and can optionally take the key 'code.'

[{ 'message' : 'Bad Number', 'code' : '123313' }, { 'message' : 'Too short' }];



An example Error Screen
This error screen is a result of the app.checkRequired function. If you manually form your on errors array, it will look the same. 

Return to Documentation Home I Return to Sangoma Support