Ga naar hoofdinhoud

CnEmailLinkDialog

The "Link an existing email" picker on its own: the user picks a Mail message and it is linked to the record (POST /objects/{register}/{schema}/{id}/emails), as the email tab's "Link existing email" does. A message that is already linked counts as linked. After a link the dialog announces cn:timeline:changed for the record and closes; a failed link shows an error toast and stays open.

Register it as a modal in the app's registry and open it from a card header action:

{ "label": "Link email", "variant": "tonal", "action": { "type": "open-modal", "target": "EmailLinkDialog", "props": { "register": "pipelinq", "schema": "client", "objectId": "@objectId" } } }

Props​

PropTypeDefaultDescription
registerString(required)Register slug of the record.
schemaString(required)Schema slug of the record.
objectIdString(required)Id of the record.
apiBaseString'/apps/openregister/api'Base URL of the OpenRegister API.

Events​

EventPayloadDescription
closenoneThe picker closed, or the message is linked.