Link an event to another page

  • Release version: Yokohama
  • Updated January 30, 2025
  • 6 minutes to read
  • Add a link to the destination event handler within UI Builder so that an event action can open another page. You can also configure the event handler to follow the App Route to the desired page.

    About this task

    To configure an event action to open another page, you must know what page you want to open, what the required and optional parameters are for that page, and what payload values to set on the event handler to pass the required parameters to the destination page.

    Tip:
    You may be able to find examples of both the components that you want to link from and the destination pages that you want to link to in the Base Agent Workspace Experience. This Next Experience is provided in the base system. If you create a page from a page template, you should only copy the contents of the template. Do not reference it. For more information about the difference between copying and referencing a page template, see Create a page from a template.

    Procedure

    1. Open your experience in UI Builder.
    2. Optional: If the destination page doesn't exist in your experience, create one.
      For information about creating pages, see Create a page in UI Builder. Make sure that you set the required and optional parameters for the page so that you can use it as a destination. If a particular component in the page is a destination, you must include that component. You also must configure the properties on the component to consume the page parameters with @context.props.<parameter-name> values.

      You might consider creating the page from a page template. The Base Agent Workspace Experience has several page templates that are already configured to be destinations for other components. If you create a destination page from a template, the components are already configured with the correct properties. Any necessary state parameters or client scripts are also copied over. You have to add the page parameters. You can copy these parameters from the UX App Routes related list on the Agent app config [sys_ux_app_config] record of the experience that contains the page templates.

      To make sure that the pages that you are creating work reliably as destinations in your experience, your experience must have the same app shell UI as the experience with the page templates.

    3. Switch to the page that you want to link to the destination page.
    4. Navigate to the relevant component and select it.
    5. Select the Events tab.
    6. Select + Add event mapping.
    7. Select the event you want to use.
    8. Select + Add event handler.
      Arrow pointing to the + add event handler option.
    9. In the Inherited event handlers section, select Link to destination.
      Arrow pointing to the link to destination inherited event handler.
    10. Click Select destination.
      Arrow pointing to the select destination button.
    11. Expand Pages and select the page in the experience that you want to link to.
      Fields appear for each of the parameters on the destination page that the route leads to. Required parameters are marked with an asterisk (*).
    12. Complete each required parameter field and the applicable parameter fields with an appropriate @payload.* value.
      If the developers of your component included default payload values in your event, you can select one through autocompletion. As shown in the following example, the payload value may not match the parameter name.

      Using autocomplete to select the @payload.indicator_sysId property for the uuid parameter field.

      Note:
      You have the option to link to an External URL instead of specifying an App route.

      If no default values are provided, or you can't determine which values are correct for some fields, refer to the configuration and API documentation for the component in the . If you still can't find the necessary @payload.* values, contact Customer Service and Support.

      Tip:
      If you create your linking component by creating a page from a Base Agent Workspace page template, the component contains Link to destination Relay event handlers. These event handlers do not work. However, they contain the applicable @payload.* values for the parameters.