Skip to main content
akasht489174
New Participant
Sep 6, 2021 11:04 AM UTC
Question

RE: Record link rule

Why we are using .@attributes.@anyAttribute._recordRef in the below rule and what is the need for using it in that rule.

cons!COM_ENV_TXT_SITE_URL & cons!CLM_TXT_RECORD_URL & a!recordLink(
recordType: cons!CLM_RECORD_REQUEST_DETAILS,
identifier: ri!requestId,
dashboard: ri!dashboard
).@attributes.@anyAttribute._recordRef & "/view/" & ri!urlStub

    2 replies

    danny.verb
    Employee
    Sep 7, 2021 1:23 PM UTC

    You are trying to access properties of the record link that are not supported which is dangerous for your app. I imagine you want to use a safeLink so instead you should use fn!urlForRecord()

    mikes0011
    Brainy
    Sep 7, 2021 1:50 PM UTC

    And also let's not forget that for the past few versions we can now (thank goodness) use a!recordLink() and instruct it to open in a new tab similar to the behavior of a!safeLink, except doing it this way also stays within the context of the user's current Site.

    The Expression Guru