Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.encoreos.io/llms.txt

Use this file to discover all available pages before exploring further.

The Edit Approval Template page (/settings/templates/approvals/:id) is the editor for creating and modifying approval chain templates, defining ordered approval steps with configurable approver types, parallel modes, and timeout settings.

Overview

No permission gate is on this specific route, though the parent /settings/templates route requires pf.templates.view. The page uses react-hook-form with Zod validation (approvalChainSchema). The :id parameter drives edit vs. create mode: the useApprovalChainTemplate hook is called when editing, and useApprovalChainTemplateMutation handles save. The form collects name, description, category (policy, document, financial, hr, compliance, general), and a steps array. Each step has a step_order, name, approver_type (user, role, dynamic, field), approver_config, parallel_mode (any/all), timeout_hours, and reminder_hours. Steps are managed via ApprovalStepEditor. At least one step is required. A back button navigates to /settings/templates.

Who it’s for

No explicit permission gate on this route. Parent navigation requires pf.templates.view.

Before you start

  • Navigate from the Templates Settings page (/settings/templates).
  • Understand the approver types available: user (specific user), role (role-based), dynamic (manager or department head resolver), and field (dynamic field-based).

Steps

1

Open the approval template editor

Navigate to /settings/templates/approvals/new to create, or /settings/templates/approvals/:id to edit an existing template.
2

Set template name and description

Enter a name (required, max 200 characters) and optional description (max 1000 characters).
3

Choose a category

Select one of: policy, document, financial, hr, compliance, or general.
4

Add approval steps

Use ApprovalStepEditor to add ordered approval steps. For each step, set the name, approver type, approver config, parallel mode, timeout hours, and reminder hours.
5

Save the template

Click Save. Validation errors are shown inline. On success, the template is saved and the form resets or navigates back.

Key concepts

user requires a specific user_id. role requires a role string. dynamic uses a resolver enum (manager or department_head). field uses a field string to resolve the approver at runtime.
any means only one approver in the step needs to approve. all requires every approver to approve before the chain advances.
timeout_hours sets when the step escalates or fails if no approval is given. reminder_hours sets how many hours before the timeout to send a reminder notification.

Platform Foundation

Platform Foundation overview.

Governance & parity

Documentation coverage and governance.
This page documents shipped product behavior. It is not medical, legal, or billing advice. Verify against your organization’s policies and applicable regulations before using it for clinical, compliance, or billing decisions. Protected health information (PHI) shown in the product is governed by your tenant’s access controls and is never exposed in this documentation.
  • src/routes/platform.tsx
  • src/platform/templates/pages/ApprovalChainTemplateEditor.tsx
  • src/platform/templates/hooks/index.ts