The channel decides who reads, who answers, and where.
The patient can now write in the portal, and the message lands in the staff Inbox beside WhatsApp. One rule routes everything: WhatsApp, calls, email and SMS are the desk’s; the portal is the care team’s, from the first message. Nothing is decided by what a message says, by a stage or by a date. Curitt only; Carla Nogués is unchanged.
Prototype: admin-preview, Curitt tenant, Inbox → Presale | Patients; patient-preview as Sven de Wit. Brief: Amiro.Next/features/portal-messages-in-inbox/brief.md (COM-D-101 … 110).
Two tabs, one rule, nothing moves.
tabs in the Inbox: Presale holds everyone’s WhatsApp, calls, email and SMS; Patients holds everyone’s portal.
thing decides who may read a message: the channel it came on. Not the person, not the words, not a per-message grant.
conversations move between tabs. A person can be a row in both; those are two conversations with two owners, not one shown twice.
| Who | Sees | Answers |
|---|---|---|
| Front desk (Presale) | All WhatsApp, calls, email, SMS. The portal as envelopes: the lock, Message in the portal, sent, read; booking and payment notifications in full. | WhatsApp, email, SMS, a call. Never the portal. |
| Care team (doctors, owner, manager) | Both tabs: WhatsApp in full, and every portal thread in full. | The portal; WhatsApp too, if they want to. Whoever answers first clears the item. |
| Amiro | Both channels. | WhatsApp on its own, as today. On the portal it only drafts. |
Access follows the channel. So does the queue.
| Channel | Who may read | Whose queue |
|---|---|---|
| WhatsApp, calls, email, SMS | Everyone with the Inbox (Inbox · Presale). | Presale. A doctor may answer too; answering is not owning. |
| The portal | The care team (Inbox · Patients), from the first message. Presale sees envelopes: who, kind, sent, read; never the text. | The care team. A question for the desk written there becomes a task. |
| Automatic messages | Whoever may read the record: a visit → Calendar, a payment → Sales, a form, prescription or letter → Patient. | Nobody’s; they are events. Presale sees clinical ones as envelopes. |
The desk sees Sven’s WhatsApp in full and his portal as envelopes.
Sofie has no tabs. Her Inbox is the Presale list.
A role with Inbox · Patients set to No access does not see the switch. The Inbox is simply the Presale queue.
Thomas asks a medical question on WhatsApp. It is answered in the portal.
The rule needs no state on the person. Thomas has not been to a visit; his portal is the care team’s all the same, because it is the portal.
The care team reads the portal, and sees WhatsApp as context.
An automatic message opens what it is about, in the house widget.
| Step | Opens |
|---|---|
| Complete form | The EMR form page (PatientFormSubmissionSheet) with the real template, the Annual health review. |
| Confirm visit, View visit | The Calendar visit drawer, with its Payment and Activity sections. |
| Pay, View refund | The Sales panel of the sale. |
| Download prescription, Prescription cancelled | The record’s prescription row, with Reprint. |
| View documents (a letter) | The letter and its attachments. |
| Confirm visit (the patient’s side) | The visit page /v/:token, as the patient sees it. |
Two rows in Settings → Roles. Only one of them differs.
| Role | Inbox · Presale | Inbox · Patients |
|---|---|---|
| Owner, Manager | Act | Act |
| Provider | Act | Act |
| Front desk | Act | No access |
| Operator | Act | No access |
Three tasks for Artur, and the Brain catches up.
| Brain | Change |
|---|---|
| COM-R-030 | “A patient cannot write” withdrawn. |
| COM-R-016 | “A sent note is final” narrowed to the record’s documents; chat messages may be edited or deleted while unread. |
| CRM-D-094 | One list with the stage on the row holds for organizations without a Patients Inbox; with one, COM-D-103 applies. |
| CRM-DQ-032 | Who answers which stage: closed by COM-D-101 and 102. |