Navigation Menu

Skip to content

How to use Users Search Dialog

o5faruk edited this page May 2, 2021 · 6 revisions

⚠️⚠️⚠️

This sdk documentation is deprecated and will not be updated. Check out our new docs at https://sdk.buildfire.com/docs/users-search-dialog/

⚠️⚠️⚠️

Description

Users search dialog accessible via the plugin SDK from the control side of the plugin which allows plugin developers to show user search dialog through the control side to allow the app owner to select users and then do some operation on these users.

buildfire.auth.showUsersSearchDialog({},(error, users)=>{ });

This builtin dialog helps you, to show a dialog in order to be used to select users.

You can use this in the Control Side only.

arguments

  • options : object * This property will give the plugin developers the functionality for allowing changing users' search dialog options (to be extended later).

  • callback(errors, result): function will be invoked after the control panel user selects the users.

    • result: object
      • users (Array of objects)

          [
              {
                "firstName": "Bob",
                "lastName": "Steve",
                "displayName": "Bob Steve",
                "username": "example@buildfire.com",
                "isActive": true,
                "userProfile": {
                },
                "imageUrl": "imageUrl"
              },
              {
                "firstName": "Sara",
                "lastName": "Conor",
                "displayName": "Sarah Conor",
                "username": "example1@buildfire.com",
                "isActive": true,
                "userProfile": {        
                },
                "imageUrl": "imageUrl"
              }
            ]
        
      • userIds (Array of string)

            [
                "5dc0832959fda11018ffb5e8",
                "5dc0836c59fda11018ffb5ea"
            ]
        

Example:

var callback=function(error, result){
//Check for errors, the result will have users and userIds
};

buildfire.auth.showUsersSearchDialog({},callback);

Clone this wiki locally