pCon.basket - Plugin Development
    Preparing search index...

    Interface Integration

    PluginComponent created when the ActivityPlugin is loaded and createComponent is called. Defines the lifecycle and main menu actions for an activity.

    interface Integration {
        doneButtonOptions?: ButtonOptions;
        isActive?: boolean;
        showDoneButton: boolean;
        showUser: boolean;
        user: User | null;
        userRestrictions: ReadonlySet<UserRestriction> | null;
        dispose(): Promise<void>;
        getMainMenuActions(): readonly MenuAction[] | null;
        prepareActivityStop?(
            pCancelable: boolean,
            pReason?: "Logout",
        ): Promise<boolean>;
        setActive?(pActive: boolean): Promise<void>;
    }

    Hierarchy (View Summary)

    Index
    doneButtonOptions?: ButtonOptions

    Additional options for the done button.

    isActive?: boolean

    Optional activity state of this component. Initial component state should be inactive (false or undefined).

    showDoneButton: boolean

    If true the application will show a Done button which can be used from the user to finish the integration .

    showUser: boolean

    If true and user is defined the application will show the user information.

    user: User | null

    Current active user.

    userRestrictions: ReadonlySet<UserRestriction> | null

    Returns a set of restrictions for the current user. If null the default restrictions of the application will be used.

    • Called if this instance is no longer in use. Should be used to clean-up resources.

      Returns Promise<void>

    • Can be implemented to make preparations before the activity gets stopped and disposed. If pCancelable is true and the promise resolves with false, the activity stop will be canceled. Otherwise true should be returned.

      Parameters

      • pCancelable: boolean
      • OptionalpReason: "Logout"

      Returns Promise<boolean>

    • Optional activity state handling for this component. E.g. can be used to disable/enable event handling. Will be set from the component host to activate or deactivate the component. Initial component state should be inactive (false or undefined).

      Parameters

      • pActive: boolean

      Returns Promise<void>