Hi all, i'm new to the records. i'm wondering how to display a list

Hi all, i'm new to the records.
i'm wondering how to display a list instead of item detail in the summary dashboard.

for example, there two cdts : department and employee.
how to display all employees when clicking one department?

can someone give me the sample code of the summary dashboard?

thank you very much.

what's more, i noticed we use rf!name in summary dashboard to refer one item in record list. but i also see expression ri!id.

what is the difference between "rf!" and "ri!"?...

OriginalPostID-112180

OriginalPostID-112180

  Discussion posts and replies are publicly visible

  • 0
    Certified Lead Developer
    Hi,
    'rf' refers to the record field whereas 'ri' refers to rule input.
    Assuming the 'department' as the field in Department CDT, you can achieve your usecase by getting all the employees by 'rf!department' and save it in a local variable.
    Example:
    local!deptEmployees: queryRuleToGetEmployeesByDepartment(rf!department)
  • hi,
    thank you for explaining the "rf" and "ri".
    regarding the "department" and "employee",
    i have created a queryrule.but i don't know how to use it in the dashboard summary
    to display a list of employees.

    right now, my dashboard code is
    =a!dashboardLayout(
    firstColumnContents: {
    a!textField(
    label: "Department Name",
    readOnly: true,
    value: rf!name
    ),
    a!textField(
    label: "Manager Name",
    readOnly: true,
    value: rf!managerName
    )
    }
    )