Working with Fluid Page and Component PeopleCode

This topic discusses PeopleCode constructs and usage specific to working with fluid pages and fluid components.

The PeopleCode page Activate events for fluid pages execute in the following:

  1. Header page (PT_HEADERPAGE is the PeopleTools-delivered fluid header page).

  2. Side pages (Side 1 page and Side 2 page).

  3. Footer page.

  4. Main page (Standard Page page type).

Note: The Activate event is not supported for subpages, fluid or classic.

This table lists the PeopleCode built-in functions provided for use with fluid applications at the component or page level.

Function

Description

AddJavaScript

Add JavaScript to the document or page.

AddMetaTag

Add a meta tag to the document or page.

AddOnLoadScript

Add the script to execute in the onload event of the document.

AddStyleSheet

Add a free form style sheet to the HTML document for the page or component.

CreateSearchRowset

Create the rowset based of the search record and key list values.

DoModalComponentPopup

Display a secondary fluid component in a modal, secondary window with a child relationship to the parent window.

See Transfer and Modal Functions for a complete list of functions available for implementing transfers and creating modal windows.

DoModalPopup

Display a secondary fluid page in a modal, secondary window with a child relationship to the parent window.

See Transfer and Modal Functions for a complete list of functions available for implementing transfers and creating modal windows.

ExecuteSearchSavePC

Execute the SearchSave PeopleCode on the search page.

GetAddSearchRecName

Return the add search/prompt record name.

GetComponentTitle

Return the name of the component (from the component definition).

GetPagePrefix

Return the prefix for the page based on the page type as set on the Use tab.

GetPageTitle

Return the title of the page.

GetPageType

Return the page type—for example, header, footer, prompt, and so on.

GetPanelControlStyle

Return the styles set by the system that control the state of the left and right panels.

GetSearchRecName

Return the search/prompt record name.

GroupletRequestSource

Return an Integer value indicating the source page (location) for the grouplet.

IsAddEnabled

Return a boolean value indicating whether Add mode has been enabled on the component's Use tab.

IsAddMode

Return a boolean value indicating whether the component build process is in add mode.

IsAGComponent

Return a boolean value indicating whether the component type is set to Activity Guide on the Fluid tab.

IsAGRequest

Return a boolean value indicating whether the request was initiated by an activity guide wrapper.

IsBackEnabled

Return a boolean value indicating whether back navigation is enabled on the component.

IsFluidMode

Return a boolean value indicating whether Fluid Mode is enabled on the component.

IsFluidSearchStart

Return a boolean value indicating whether the Fluid Search is started on the component.

IsGroupletRequest

Return a boolean value indicating whether the request was initiated by a tile (also referred to as a grouplet).

IsHomeEnabled

Return a boolean value indicating whether the Home button is enabled on the component.

IsIScriptAuthorized

Return a boolean value indicating whether the current user is allowed to access the specified iScript.

IsLogoutEnabled

Return a boolean value indicating whether Logout is enabled on the component.

IsMDComponent

Return a boolean value indicating whether the component type is set to Master/Detail on the Fluid tab.

IsMDGuided

Return a boolean value indicating whether the master/detail or activity guide wrapper is in guided mode (that is, Previous and Next are displayed in the fluid banner).

IsMDListPopup

Return a boolean value whether the master/detail or activity guide wrapper is in non-optimized mode (that is, navigation to pages is presented in a drop-down list in the fluid banner, not in the left panel).

IsMDNonOptimized

This function is equivalent to the IsMDListPopup function.

IsMDRequest

Return a boolean value indicating whether the request was initiated by a component from within the master/detail wrapper.

IsMDSearchEnabled

Return a boolean value indicating whether the search type is set to Master/Detail for the current component.

IsModeless

Return a boolean value indicating whether the target content for the tile is currently being displayed in a modal window—that is, the Display In setting for the tile is set to Modal.

IsNavBarEnabled

Return a boolean value indicating whether the NavBar is enabled on the component.

IsNextInListEnabled

Return a boolean value indicating whether NextInList is enabled on the component.

IsNotificationEnabled

Return a boolean value indicating whether the Notifications button is enabled on the fluid component. This corresponds to the Notifications toolbar option on the component’s Fluid tab.

IsPinEnabled

Return a boolean value indicating whether the Add To functions are enabled on the component.

IsPrevInListEnabled

Return a boolean value indicating whether PreviousInList is enabled on the component.

IsSaveEnabled

Return a boolean value indicating whether Save is enabled on the component.

IsSearchEnabled

Important! In PeopleTools 8.55 or later, use either the IsMDSearchEnabled function or the IsStandardSearchEnabled function instead to determine which type of search is enabled.

Return a boolean value indicating whether search is enabled on the component.

IsSingleComponentAG

Return a boolean value indicating whether this is a single component activity guide.

IsSingleUnitOfWork

Return a boolean value indicating whether this is a single unit of work activity guide.

IsSmallFFOptimized

Return a boolean value indicating whether the Display on Small Form Factor Homepage option has been selected on the Fluid tab of the component properties.

IsStandardSearchEnabled

Return a boolean value indicating whether the search type is set to Standard for the current component.

SetAddMode

Set the AddMode attribute in the panel processor.

SetMDGuided

Set whether the master/detail or activity guide wrapper is in guided mode (that is, Previous and Next buttons are displayed in the fluid banner).

SetMDListPopup

Set whether the master/detail or activity guide wrapper is in non-optimized mode (that is, navigation to pages is presented in a drop-down list in the fluid banner, not in the left panel).

SetPanelControlStyle

Specify a String value that updates the system with styles that control the state of the left and right panels.

SetThemeId

Set the theme ID for the page so that proper theme style sheets get loaded.

SetTransferAttributes

Set certain fluid-related properties prior to executing a transfer to a different page or component.

The fluid page utilities classes of the PT_PAGE_UTILS application package provide tools to manage certain aspects of your fluid applications:

  • PT_PAGE_UTILS:Banner —

    Use the PT_PAGE_UTILS:Banner class to control items in the fluid banner including the title as well as visibility of some of the items that appear in the Actions menu.

    Many methods of this class are ignored and have no effect if the component is rendered in a context that does not allow access to the fluid banner and Actions menu such as in an activity guide, in a master/detail component, or in a modal window.

  • PT_PAGE_UTILS:PanelController —

    Use the PT_PAGE_UTILS:PanelController class to inquire on and update the modes and visibility of the Side Page 1 (left panel) and Side Page 2 (right panel). Because this class spawns Panel objects for each side panel, you do not need to instantiate Panel objects directly.

    The system determines the initial characteristics of each panel based on the configuration of the component, activity guide instance, or master/detail instance. The system also maintains the panels’ runtime characteristics. The panel state is not maintained within the PanelController object (or any Panel objects it spawns). Therefore, you must ensure that any changes are updated back to the server to effect an actual change either by directly invoking the UpdatePanel method or indirectly by invoking the Initialize method with auto-update set to true.

  • PT_PAGE_UTILS:Utils —

    The PT_PAGE_UTILS:Utils class provides general utility methods for working with viewport settings, displaying confirmation messages in the banner, and working with toggle buttons.

    Important! To be rendered correctly across all device types, each fluid application should set the viewport. The SetDefaultViewport method is the recommended way to do this.

This section lists other methods and properties of the Field class used in fluid development.

See AddFFClass.

See AriaAttributes.

See AriaWrapperAttributes.

See FreeFormStyleName.

See GetBaseName.

See HtmlAttributes.

See HtmlInputType.

See IsHyperlink.

See JavaScriptEvents.

See PlaceholderText.

See ReplaceFFClass.

See SetImageUrl.

This section lists other properties of the Grid class used in fluid development.

See Layout.

See FreeFormStyleName.

See Selector.

Additional meta-HTML you can use with fluid development include these constructs.

See %ExplainMessage.

See %FORMFACTOREXTRALARGE.

See %FORMFACTORLARGE.

See %FORMFACTORMEDIUM.

See %FORMFACTORSMALL.

See %BB.

See %BP.

See %BV.