Solved on the forum

How do you open a patient’s related medications from a button in Adalo?

Pass a related parent record into one reusable detail screen, using a one-item list when an intermediate record cannot supply that parent directly.

Docs checkedBeginnerReviewed Sep 6, 2026
THE SHORT ANSWER 🎯

Pass the related parent record into the destination screen and filter its child list by that Current Parent. If an intermediate screen only has a child or join record, add a one-item list of parent records filtered to the related parent, then place the link inside that list so it can pass the correct record.

Let relationships carry identity through the flow. Pass the parent record directly whenever it is available. If an intermediate screen exposes only a related child or join record, filter a parent list to the related parent, keep that list to one result, and place the destination link inside the row so the required Current Parent reaches the reusable detail screen.

Completeness85%
Index decisionIndex now
Evidence basisReviewed against current Adalo relationship, link, and filtering documentation, with accepted forum evidence for direct and one-item-list navigation
WHAT YOU’LL HAVE 🎯

The intended outcome

A user can move from a parent list or an intermediate related record into one reusable parent detail screen, then see only that parent's child records.

BEFORE YOU START 🧰

Requirements

  • Caregivers, Patients, and Medications collections
  • A Patient-to-Medication relationship
  • A Patient detail screen that has Current Patient available
BUILD IT 🛠️

Step by step

  1. 01

    Model the relationships

    Relate each Medication to one Patient, and relate Caregivers to the Patients they may access. Do not add duplicate text fields to imitate foreign keys.

  2. 02

    Open the current patient

    From the caregiver’s patient list, link the selected list item to the Patient detail screen so Current Patient becomes available.

  3. 03

    Pass patient context from the button

    Add a button on the Patient detail screen and link it to the medications screen while passing Current Patient.

  4. 04

    Filter the medication list

    Set the medications list to Medications and filter where Medication > Patient equals Current Patient.

  5. 05

    Open medication details

    Link each medication list item to its detail screen while passing Current Medication.

  6. 06

    Add a one-item parent list when context is missing

    When an intermediate screen has Current Application but not Current Activity, add a list of Activities filtered so Activity ID equals Current Application > Activity > ID. Put the link button inside that list so the clicked row passes Current Activity to the existing Activity detail screen.

WHY IT WORKS 🧠

The underlying logic

Adalo screen context carries the selected record between screens, while relationships express which medications belong to that patient.

Manual foreign-key text fields duplicate relationship state and make filters harder to maintain.

A component can pass the Current record supplied by its list row, so a list filtered to one related parent can restore missing parent context without creating a second detail screen.

COLLECTIONS AND RELATIONSHIPS 🗃️

Data model

CollectionImportant propertiesRelationships
PatientsPatient detailsMany Medications; connected to permitted Caregivers
MedicationsMedication detailsBelongs to one Patient
CaregiversUser profile fieldsRelated to permitted Patients
EVIDENCE CONTEXT 🔎

What still needs checking?

  • This is a forum-native answer with no original Adalocado video. It is automatically organized from the accepted reply and remains open to correction reports.
IF IT DOESN’T WORK 🧯

Common failure modes

Current Patient is unavailable

Check that the previous list item or button links to the screen with the selected Patient record rather than navigating without data.

Every medication appears

Add the Patient relationship filter to the medications list and compare it to Current Patient, not Logged-in User.

The link menu offers only the intermediate record

Create a one-item list of the required parent collection, filter it to the intermediate record's related parent ID, and place the destination link inside that list.

BEFORE YOU MOVE ON ✅

Testing checklist

0 of 9 checked on this device

BOUNDARIES 🚧

Current limitations

  • Current Adalo documentation corroborates record relationships, link actions, and list filtering, but the source thread does not provide a complete current-builder reproduction of this patient workflow.
  • Authorization must still restrict which patients a caregiver can access; a list filter alone is not a security boundary.
  • The one-item-list fallback is necessary only when the required parent is missing from Available Screen Data. Prefer a direct link when the parent record is already available.
BUILDER REPORTS 🗣️

What the Adalo community is reporting

These are concise editorial summaries of public forum posts—not endorsements or independently reproduced results.

Accessing a simple list from a button

The solved thread confirms a working sequence from caregiver patients to patient details, patient medications, and medication details using Adalo record context.

Boundary: The accepted post reports the result but does not document every current editor control or authorization rule.

Kami (question) and Kami (accepted answer) · February 2026

Link action doesn't send data from a database with a relationship

The accepted answer explains how a one-item Activities list filtered through Current Application restores Current Activity and lets the existing Activity detail screen receive the correct record.

Boundary: The thread demonstrates the pattern with Activities and Applications, so collection names and relationship paths must be adapted to the app's data model.

Giosky and Victor · May 2025
VERSION NOTES 📝

Sources and status

This page was last reviewed on Sep 6, 2026. Its current status is Documented from current sources.

Verification owner: Adalocado daily AI publisher. Next review: Dec 6, 2026.

VERSION HISTORY 🕰️

Changelog

  1. Automatically posted from a solved Adalo forum topic; corrections are monitored on the live site.

SPOT SOMETHING FUNNY? 🕵️

Report this answer.

Automated Answers still pass evidence and publication checks, but they can be wrong, outdated, unclear, or missing an important boundary. Send the exact correction and the editor will check the live page.

Report a problem
MONTHLY APP MANAGEMENT · BY REHOST

Rehost becomes the monthly team behind your app. Fixes, releases, integrations, and ongoing changes have an owner.

See monthly management
FixesHandled
ReleasesHandled
Next changesHandled
YOUR PROBLEM IS DIFFERENT? 🤔

Bring us the messy version.

Describe what you expected, what happened instead, and what you already tried.

Ask Adalocado 💬