← Knowledge library

Facility administration

Prepare, preview and save a Draft HTML report template

Create a static synthetic Account Report layout while keeping report type, data context, output format, preview and saved Draft status distinct.

Current source · Actual local synthetic UI operations on the pinned application source. Successful tag and template writes independently read through normal product APIs. No full role/facility or clinical reporting qualification. · 4 min read

Before you begin

1. Review the Draft layout identity and context

In Template Builder, enter the approved Template Name and lowercase Slug. Select Draft status and HTML default format. Review Report Type and Select Context separately; the example uses Account Report for both. The left Template HTML editor contains only a static synthetic heading and disclaimer, with no patient, account or invoice fields.

Prepare a Draft HTML template with explicit report type and data context. Actual MANSOQ local synthetic training. No real patient, workforce or financial records.1234
Prepare a Draft HTML template with explicit report type and data context · 2026-10-18Actual isolated synthetic application on audited source f6e9f05f. Only the depicted operation and context were observed; full role, facility and workflow qualification remains separate.
  1. Identity and slug: Use an approved name and unique lowercase slug.
  2. Draft and HTML: Status and default output format are separate choices.
  3. Data context: Account Report context determines the available fields; it is separate from Report Type.
  4. Save Template: Save the draft after reviewing its content; preview does not prove persistence.

2. Preview the actual output

Choose Preview Template and inspect the rendered heading and disclaimer. Clear Preview returns to the editor. The pictured output is a static training layout and contains no patient, account, invoice or financial data. Preview does not save the template.

Preview a static synthetic layout before saving the draft. Actual MANSOQ local synthetic training. No real patient, workforce or financial records.1234
Preview a static synthetic layout before saving the draft · 2026-10-18Actual isolated synthetic application on audited source f6e9f05f. Only the depicted operation and context were observed; full role, facility and workflow qualification remains separate.
  1. Rendered preview: Inspect the output rather than assuming HTML source will render as intended.
  2. Clear Preview: Clear Preview returns to the HTML editor.
  3. Save separately: Preview does not save the template; Save Template is a separate control.
  4. Draft status: The current template is still Draft.

3. Save and verify the Draft template

Select Save Template separately from preview. In the template catalogue, confirm the exact name, generated facility-qualified slug, Draft badge, HTML format and Account Report type. The independent normal template detail GET confirmed Draft, account_base context and the exact static HTML. Edit opens this saved template. It was not activated and no person/account report was generated.

Preview a static synthetic layout before saving the draft. Actual MANSOQ local synthetic training. No real patient, workforce or financial records.1234
Preview a static synthetic layout before saving the draft · 2026-10-18Actual isolated synthetic application on audited source f6e9f05f. Only the depicted operation and context were observed; full role, facility and workflow qualification remains separate.
  1. Rendered preview: Inspect the output rather than assuming HTML source will render as intended.
  2. Clear Preview: Clear Preview returns to the HTML editor.
  3. Save separately: Preview does not save the template; Save Template is a separate control.
  4. Draft status: The current template is still Draft.
Verify saved Draft template, format and facility-qualified slug. Actual MANSOQ local synthetic training. No real patient, workforce or financial records.1234
Verify saved Draft template, format and facility-qualified slug · 2026-10-18Actual isolated synthetic application on audited source f6e9f05f. Only the depicted operation and context were observed; full role, facility and workflow qualification remains separate.
  1. Saved template identity: Confirm the exact template name and generated full slug.
  2. Draft state: The template remains Draft; it was not activated.
  3. Format and type: HTML and Account Report are the saved choices.
  4. Edit saved template: Edit opens the existing full-slug template rather than a new copy.

Slug and field validation in the audited source

The schema accepts a lowercase letters/digits/hyphens slug of 5–25 characters. Its translated length message currently says max 36 while the schema max is 25, so follow the implemented constraint and actual validation response. Name, status, format, report type, context and non-empty HTML have separate fields. The pictured valid save does not exercise every invalid variant.

Preview, activation and report generation are separate

Preview submits the current HTML, context and output format. Saving persists the template. Actual report generation also requires an associating record, suitable permissions and an active template in the audited card control. This walkthrough keeps the template Draft and qualifies neither data-bound field insertion, PDF generation nor clinical/financial report correctness.

Troubleshooting

The preview differs from the intended layout

Return with Clear Preview, inspect the template HTML and selected context, then preview again before saving. Use synthetic fixtures to test placeholders before processing real records.

Source evidence

References are pinned to the private MANSOQ source repository. Repository access is required to open these links.