This object is used to work with user profiles on portals. As a separate app, a profile can store additional information about an external user. You can also use this app to organize complex interactions and processes on the portal.

Type parameters

Hierarchy

  • ApplicationUserProfile

Methods

block

  • Lock an external user’s profile.

    const profile = Context.data.external_user1;
    if (profile) {  
       await Global.ns._system_catalogs.app._user_profiles.block(profile); 
    }  
    

    If you pass an item of another app to the item parameter, an error will be returned.

    Parameters

    Returns Promise<void>

getByUser

  • Get an external user’s profile using the associated account.

    const user = Context.data.__createdBy;
    if (user) { 
        const portal_profile = await Global.ns._system_catalogs.app._user_profiles. getByUser(user); 
    } 
    

    Parameters

    Returns Promise<ApplicationItemRef<T, P> | undefined>

    A profile of an external user or undefined if no profile is linked to the account.

getUser

  • Get an external user’s account using the profile associated with it.

    const profile = Context.data.external_user1;
    if (profile) {  
       await Global.ns._system_catalogs.app._user_profiles.block(profile); 
    }  
    

    If you pass an item of another app to the item parameter, an error will be returned.

    Parameters

    Returns Promise<UserItem | undefined>

unblock

  • Unlock an external user’s profile.

    const profile = Context.data.external_user1;
    if (profile) {  
       await Global.ns._system_catalogs.app._user_profiles.block(profile); 
    }  
    

    If you pass an item of another app to the item parameter, an error will be returned.

    Parameters

    Returns Promise<void>