Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents
minLevel1
maxLevel3

Introduction

Below is a list of methods grouped by the resource they interact with. These methods are available to the page under the fb_client object that is injected into the browser window. Unfortunately, we are unable to interact with these methods using native objects. So passing complex data is done by serializing objects into JSON strings, and vice-versa.

...

Code Block
var closing = fb_client.dialogClose();

void showStatusBar(boolean show)

Hides/Shows the status bar of the browser window, which includes a status label, and a small progress bar.

Examples

Show the status bar.

Code Block
fb_client.showStatusBar(true);

Image TBD

Hide the status bar.

Code Block
fb_client.showStatusBar(false);

Image TBD

void dialogStatus(String message)

Displays a short message in the status bar, approx. less than 100 characters.

Example

Code Block
fb_client.dialogStatus("Hello");

Image TBD

void pbUpdate(int value)

Controls the Progress Bar component in the status bar. Use whole integers for 0-100, and -1 for indeterminate progress.

Examples

Set progress bar to 100%

Code Block
fb_client.pbUpdate(100);

Image TBD

Set progress bar to 50%

Code Block
fb_client.pbUpdate(50);

Image TBD

Set progress bar to indeterminate.

Code Block
fb_client.pbUpdate(-1);

Image TBD

Client

String getCompanyName()

Returns the company name.

Example

Get the company name

Code Block
var company_name = fb_client.getCompanyName();
console.log(company_name);

int getUserId()

Returns an int of the current user id.

...

Code Block
var user_name = fb_client.getUsername();
console.log(user_name);
> "admin"

String getUserEmail()

Returns the current user’s email.

Example

Code Block
var user_email = fb_client.getUserEmail();
console.log(user_email);
> "admin@example.com"

boolean savePluginDataByGroup(String group_name, String data_dictionary)

...