Open the Delivery Note PDF from a client invoice
Allow an authorised customer contact to open the linked PDF from the CRM client invoice page.
Exact navigationClient Portal → Invoices → Open invoice → View DN PDF
What this guide covers
Allow an authorised customer contact to open the linked PDF from the CRM client invoice page. This guide follows the supplied Delivery Note module’s live hooks, controller actions, model rules, views and stored side effects.
Exact step-by-step process
- Sign in to the client portal and open the invoice, or use the exact invoice hash route authorised by the CRM.
- Select View DN PDF when the module button appears.
- Allow the PDF to open in a new tab.
- Verify the delivery-note reference and source invoice.
- Close the document when finished.
Fields, choices and supported possibilities
- Invoice ID
- Exact non-empty invoice hash when supplied
- Logged-in client ID comparison
- Existing non-void delivery note
Code-backed validations and workflow rules
- The customer hook adds the button only when it can resolve an authorised invoice and active note.
- The public invoice-PDF controller validates the exact invoice hash.
- Successful access logs `pdf_viewed_from_invoice`.
- The admin PDF URL is not used for client access.
Expected result and verification
- An authorised customer can retrieve the invoice-linked delivery-note PDF without admin access.
Checks, security and troubleshooting
- Do not share a different customer’s invoice hash or PDF link.
Stay within the supported flowDo not force database values, expose secure tokens, bypass permission checks, replace a stored signature or invent a status or interface that the supplied code does not implement.
