Templates¶
Documents includes a template system that allows you to create reusable document templates with dynamic field mappings. Templates are particularly powerful when combined with spreadsheet quotation integration, enabling salespeople to generate sale orders directly from filled-in spreadsheet templates.
Understanding Templates¶
A template is a document with the is_template flag enabled. Templates differ from
regular documents in several ways:
Templates appear in the Templates menu section
Templates are organized by category (sales, project, HR, finance, marketing, legal, other)
Templates support field mappings – dynamic placeholders that are replaced with real data when a working copy is created
Templates generate working copies instead of being edited directly
Template Categories¶
Templates are organized into categories to help users find the right starting point:
Category |
Typical Templates |
|---|---|
Sales |
Quotation templates, proposals, price lists, order forms |
Project |
Project plans, status reports, timelines, meeting notes |
HR |
Employment contracts, onboarding checklists, policies, job descriptions |
Finance |
Invoice templates, budget worksheets, expense reports, financial statements |
Marketing |
Campaign briefs, content calendars, brand guidelines, press releases |
Legal |
Contract templates, NDA templates, compliance documents, terms of service |
Other |
General-purpose templates that do not fit other categories |
Creating a Template¶
From an existing document¶
Open an existing document that you want to use as a template
Enable the Is Template toggle or flag
Select the appropriate Template Category
Click Save
The document is now available in the Templates section and can be used to generate working copies.
From scratch¶
Navigate to the Templates section
Click New
Choose the document type (file or spreadsheet)
Create the template content
Set the Template Category
Click Save
Tip
For spreadsheet templates intended for quotation generation, design the layout with clear sections for header information (customer, date, reference) and line items (products, quantities, prices).
Working Copies¶
A working copy is an independent copy of a template that can be freely edited without affecting the original template. Working copies are the primary way templates are used in daily work.
Creating a working copy¶
Navigate to the Templates section
Find the desired template
Click Create Working Copy (or the equivalent action)
A new document is created as a copy of the template
If the template has field mappings and is linked to a CRM opportunity or sale order, the placeholders are automatically replaced with actual data
Edit the working copy as needed
The working copy retains a reference to its source template, making it easy to track which documents were generated from which templates.
Note
Changes to a working copy do not propagate back to the template. Similarly, changes to a template do not affect existing working copies.
Field Mapping¶
Field mappings define dynamic placeholders within templates that are automatically replaced with real data when a working copy is created.
How field mapping works¶
A template contains placeholder text (e.g.,
{{customer_name}})A field mapping record connects the placeholder to a source field in Progrid
When a working copy is created in the context of a specific record (e.g., a CRM lead), the system looks up the mapped field value
The placeholder in the working copy is replaced with the actual value
Setting up field mappings¶
Open the template document
Navigate to the field mapping configuration
Click Add a line to create a new mapping
Define the Placeholder text (e.g.,
customer_name)Select the Source Model (e.g., CRM Lead, Sale Order)
Select the Source Field (e.g., Partner Name, Expected Revenue)
Click Save
Common field mappings¶
Placeholder |
Source Field |
Description |
|---|---|---|
|
Partner / Name |
The customer or contact name |
|
Partner / Email |
The customer email address |
|
Partner / Phone |
The customer phone number |
|
Lead / Name |
The CRM opportunity name |
|
Lead / Expected Revenue |
The expected deal value |
|
Lead / Salesperson |
The assigned salesperson name |
|
Company / Name |
Your company name |
|
Current Date |
Today’s date in the configured format |
Quotation Integration¶
The most powerful template feature is the ability to generate Progrid sale orders from spreadsheet templates. This bridges the gap between flexible spreadsheet-based quoting and structured sale order management.
How quotation integration works¶
A spreadsheet template is created with a layout for quotation line items
Cell mappings define which cells contain product, quantity, and price data
Line ranges define which rows contain the individual line items
A salesperson creates a working copy, fills in the spreadsheet
An action extracts the data and creates a sale order with the corresponding lines
This workflow allows sales teams to use familiar spreadsheet layouts for complex quotes while still feeding data into the Progrid sales pipeline.
Setting up spreadsheet cell mappings¶
Cell mappings are configured through the sale.order.template.field.mapping model.
Each mapping connects a spreadsheet cell (or column) to a sale order line field.
Open the sale order template configuration
Navigate to the field mapping section
For each data element, define:
Field Name – The sale order line field (e.g., product, quantity, unit price)
Cell Reference – The spreadsheet column or cell that contains this data (e.g., column B for product name, column D for quantity)
Click Save
Typical cell mappings for a quotation template:
Sale Order Field |
Spreadsheet Column |
Description |
|---|---|---|
Product |
Column A or B |
Product name or reference |
Description |
Column C |
Line item description |
Quantity |
Column D |
Number of units |
Unit Price |
Column E |
Price per unit |
Discount |
Column F |
Discount percentage (if applicable) |
Defining line ranges¶
Line ranges are configured through the sale.order.template.line.range model. They
define which rows in the spreadsheet contain line item data.
Open the sale order template configuration
Navigate to the line range section
Define the start and end rows for each section containing line items
Multiple ranges can be defined if the spreadsheet has line items in different sections (e.g., products in rows 10-20 and services in rows 25-35)
Tip
Design your spreadsheet template with clear, contiguous sections for line items. Leave header rows above and summary rows below the line item ranges.
Example: Complete quotation workflow¶
This example walks through creating and using a quotation spreadsheet template:
1. Design the template spreadsheet:
Row 1: [Company Logo] Quotation
Row 2: Date: {{today_date}}
Row 3: Customer: {{customer_name}}
Row 4: Reference: {{opportunity_name}}
Row 5: (blank)
Row 6: Product Description Qty Unit Price Total
Row 7: [line item 1]
Row 8: [line item 2]
...
Row 20: [line item 14]
Row 21: (blank)
Row 22: Subtotal: =SUM(E7:E20)
Row 23: Tax: =E22*0.1
Row 24: Total: =E22+E23
2. Configure field mappings:
{{today_date}}maps to the current date{{customer_name}}maps to the partner name from the linked CRM lead{{opportunity_name}}maps to the lead name
3. Configure cell mappings:
Column A = Product
Column B = Description
Column C = Quantity
Column D = Unit Price
4. Configure line range:
Start row: 7
End row: 20
5. Usage:
Salesperson opens the template and creates a working copy linked to a CRM opportunity
Field mappings auto-fill customer name, date, and reference
Salesperson fills in line items in the spreadsheet
Salesperson clicks the action to generate a sale order
The system reads rows 7-20, extracts product/quantity/price data, and creates sale order lines
Sale Order Template Integration¶
Documents extends the standard Progrid sale order template (sale.order.template)
with spreadsheet support. A sale order template can reference a spreadsheet document as
its data source, enabling the quotation integration workflow described above.
The extended sale order model (sale.order) also supports creating orders from
spreadsheet templates, allowing the entire flow from spreadsheet to confirmed sale order
to happen within Progrid.
See also
Spreadsheets for spreadsheet editing features
Managing Documents for general document management
Sharing for sharing templates and working copies