Documentation

Documents & templates

Branded PDF headers/footers, email templates, variables and languages.

Templates

Settings → Template holds the branding used by every generated document: header and footer HTML, primary and secondary colours, logo and attached files (fonts, images). Quote and invoice PDFs are composed from section blocks (header, parties, lines, details, totals, terms, footer) wrapped in this branding.

  • Name identifies the template in code. The default print header is Print Billing Header; add more to offer a choice when printing.
  • Colour 1 / 2 drive the accent colours of the document.
  • Body is HTML and accepts variables (company, date, document number, current URL…). Click View variables in the editor for the full list.
  • Files: upload images or fonts and insert them at the cursor with the upload icon.

Languages

Documents are rendered in the client’s language (lang on the contact): EN or FR wording for labels, dates and number formats. Product descriptions, inclusions, exclusions, terms and notes are stored per language where it matters.

Email templates

CRM Settings → Email templates define reusable subject and body templates, active or not, per language, with the same variables plus recipient fields. They are used when sending quotes and invoices, by invoice reminders, and from a contact’s Emails tab.

Preview and regenerate

Use Preview on a quote or invoice to see the HTML rendering without producing a file; Regenerate PDF rebuilds the file after you change the template. Claude can do both through gc_pdf_preview and gc_regenerate_pdf.

Custom layouts

If a client contract dictates a specific layout, implement a renderer class (see App\Domains\Quote\QuoteDocumentBlock in the source) and reference it from the with_pdf parameter of the table in schema/*.hjson. Generated code stays untouched.