Revise, retire or reopen a published template
Change a published document template without disturbing the version in use, publish the changes as a new version, go back to an earlier version, and take a template out of use or bring it back.
Revise, retire or reopen a published template
A published template keeps producing documents from its current version while you work on the next one: your edits wait in the draft until you publish them. Every published version is kept, so you can bring old wording back, and every generated document remembers the version it came from. When a template should no longer be used, retire it rather than delete it.
Before you start
- Permissions, in the role editor's words, on Document Templates: View to open the template, Edit to save the draft or restore a version, and publish to publish, retire or reopen. In the default roles the Administrator, the Sales Manager and Legal & Documentation hold all three.
- To preview, a real record of the template's type and the View permission on its module.
- Before retiring, check Rules for active workflow rules that generate or attach the template: they fail once it is retired.
Steps
- Open the account menu in the top bar, choose Settings, then Documents > Templates, and click the template's name. The designer shows the Published badge and the current version, for example "v2". See Document template.
- Make your changes: wording, merge fields, Letterhead, Document title or page settings. An amber Unsaved changes badge appears next to the name.
- Click Save draft. You see "Template saved." The badge now reads Draft differs from the published version, and the templates list shows Draft changes. Documents are still made from the published version.
- In the Preview panel pick a real record and click Preview (or Open PDF). The preview uses your draft; a change to Letterhead or Document title shows only after Save draft.
- Click Publish changes. The dialog "Publish a new version" reads "The draft is snapshotted as version <n>. Documents generated from now on use it; earlier documents keep the version they were made with." Add Notes (optional) saying what changed and click Publish. You see "Published as version <n>." The version badge moves up by one and the amber badge goes.
- To go back to earlier wording, click Versions (<n>). The dialog "Versions of <name>" lists each version, newest first, as "Version <n>" with its publish date and time, how many documents it produced and its notes; the one in use carries a green Current badge.
- Click Restore into draft beside the version you want. You see "Version <n> copied into the draft." and the dialog closes. Its body, header, footer, document title, page settings and letterhead are now the draft; nothing is published yet.
- Preview it, then click Publish changes and Publish. You see "Published as version <n>." The restored wording is in use as a new version number.
- To take the template out of use, click Retire. The confirmation "Retire this template?" reads "It disappears from the generate pickers and workflows that use it will fail. Existing documents are unaffected. You can reopen it later."
- Click Retire. You see "Template retired." The status becomes Retired; the fields are greyed out and only Reopen and Versions remain.
- To bring a retired template back, open it and click Reopen. You see "Template reopened." It is Published again (or Draft if it was never published), active, and offered in the pickers.
What happens next
- Documents generated after you publish use the new version; documents made earlier keep the wording they were made with. To give a buyer the new wording, generate the document again (see Generate a document from a record) and void the old one if it must not be used (see Email, void or delete a generated document).
- A retired template disappears from Generate document and from the offer's Letter choice. Workflow rules that generate it fail with "Template <CODE> is not published" until it is reopened or the rule is changed. Documents already made from it stay on their records.
- A template that has produced documents can't be deleted; retiring is how you stop using it.
If something goes wrong
- Publish changes is greyed out: there is nothing new to publish (no unsaved edits, and the saved draft matches the current version). No reason is shown on hover.
- "body_html: <problem> (line <n>)" when saving, or "Template could not be rendered: <error>" in the preview: a merge tag is broken. See Template will not save, publish or render (trouble.documents.template-syntax-error).
- A workflow run fails with "Template <CODE> is not published" after retiring: reopen the template or change the rule. See Nothing to generate (trouble.sales.no-published-template).
- Restore into draft isn't shown: the template is Retired (reopen it first) or you lack the Edit permission.
- "Documents were generated from this template; retire it instead" when deleting from the list: retire it as in steps 9 and 10. See Template, letterhead or document cannot be deleted (trouble.documents.template-cannot-be-deleted).
- No Save draft, Publish changes, Retire or Reopen button: your role lacks the permission listed above. See No access (trouble.admin.no-access).
Related
Related
- Document templateScreen
The template designer: write a template's wording with merge fields, set its letterhead, title and page layout, preview it against a real record, and publish, retire or restore its versions.
- Document templatesScreen
The list of your organization's document templates (demand letters, offer letters, termsheets, agreements, allotment letters, receipts, cost sheets), with filters and the actions to create, duplicate, open or delete one.
- Generated documentsScreen
The organization-wide log of every document generated from a template or uploaded against a record, where you preview, download, email, void or delete them.
- RulesScreen
Every automation rule in your organization, system and custom, with filters, the switch that turns each rule on or off, and shortcuts to edit, test, clone, see the run history of or delete a rule.
- Design a new document templateHow-to
Create a document template for a record type, write its wording with merge fields, repeat a table row for line items, show a block only when a condition holds, preview it against a real record and publish it so people can generate documents from it.
- Put a starter document template into useHow-to
Review one of the six starter templates that come as drafts, preview it against a real record, publish it, and switch on the system workflow rule that sends it automatically.
- Generate a document from a recordHow-to
From a booking, demand, opportunity, estimate or offer, pick a published template and a format, generate the numbered document, check it on screen and download it; every document is also listed in the organization-wide Generated documents log.
- Document templates, published versions and letterheadsConcept
A document template is an HTML letter with merge fields written for one record type; publishing it freezes a numbered version that generation uses while the draft stays editable, and a letterhead (the template's own, else the project's, else the organization's default) supplies the logo, header, footer and page layout around it.
- Template will not save, publish or render: a tag, expression or the HTML is wrongTroubleshooting
A document template, message template or rule action that carries a broken merge tag is refused when saved or published, names the field and the line; a template that parses but fails while filling in a record, or whose HTML the PDF or Word engine cannot lay out, fails at preview, generation or sending; the editor's own dialogs and fields have their own checks.
- Template, letterhead or generated document cannot be deleted: retire or void it insteadTroubleshooting
A document template that produced documents, that an email template attaches or that a workflow rule uses is kept for history and is retired rather than deleted; a letterhead is deleted only once no template uses it; a generated document that was sent is voided, never deleted.
- Generate document has nothing to offer: no published template for this record typeTroubleshooting
Documents are generated only from published document templates of the record's type; the starter templates (cost sheet, allotment letter, offer letter and others) ship as drafts, so until someone publishes one, Generate document has nothing to pick, offers issue without a letter and workflow rules that generate the template fail.
- "No access" or "You do not have permission": your role lacks a permissionTroubleshooting
Every screen, button and picker is gated by a permission on a module; your role decides which you hold, so a missing one shows as a No access card, a refused action, a greyed-out button with a hover reason, or a picker that explains which permission it needs.