Understanding Templates
Templates consist of:- Template Name - Identifier for the template
- Sections - Logical groups of content (header, body, footer, etc.)
- Elements - Individual print items within each section (text, barcode, image, etc.)
Opening the Template Editor
Select a Template
Click on an existing template to edit it.The editor will load with all sections and elements visible.
Working with Sections
Sections organize your template into logical blocks like headers, item lists, and footers.Adding a Section
Configure Section Properties
Name - Section identifier (e.g., “Encabezado”, “Items”, “Pie de Página”)Type (Type) - Section behavior:
Select which data collection to iterate over (e.g.,
Static- Prints once with fixed contentRepeating- Repeats for each item in a data source
LeftCenterRight
Select which data collection to iterate over (e.g.,
Items, Payments)Format - Text formatting:- Size dropdown:
Small,Medium,Large, etc. - N checkbox: Bold text
Section Controls
| Button | Action |
|---|---|
| ▼/▶ | Expand/collapse section |
| ↑ | Move section up |
| ↓ | Move section down |
| + | Add element to section |
| ✕ | Delete section |
Working with Elements
Elements are the individual print items within a section.Adding an Element
Element Types
- Text
- Barcode
- QR Code
- Image
- Table
Display static text or dynamic data fields.Static/Dynamic Toggle
Examples:
- Static - Fixed text entered manually
- Dynamic - Data from a source field
Examples:
DocumentNumber, CustomerName, TotalAlignment - Left, Center, RightSize - Font sizeBold - Make text boldElement Controls
| Button | Action |
|---|---|
| ↑ | Move element up |
| ↓ | Move element down |
| ✕ | Delete element |
Data Sources and Field Suggestions
The editor provides field suggestions based on your document type. Common fields include:DocumentNumber- Invoice/receipt numberDocumentDate- Transaction dateCustomerName- Customer nameTotal- Total amountItems- Line items collectionQuantity- Item quantityDescription- Item descriptionPrice- Item price
Available fields vary depending on the document type (Invoice, Receipt, Kitchen Ticket, etc.)
Saving Your Template
Review Your Design
Scroll through all sections to verify your layout.Ensure all data sources are correctly mapped.
Save Template
Click Guardar Plantilla at the bottom of the editor.A success message confirms the template was saved.
Template Design Tips
Use Sections Wisely
Separate header, repeating items, and footer into distinct sections for clarity.
Alignment Matters
Center titles and totals, left-align item descriptions, right-align prices.
Test with Real Data
Always test templates with actual transaction data before production use.
Keep It Simple
Thermal printers have limited width - avoid overcrowding elements.
Common Template Patterns
Invoice Header
Repeating Line Items
Footer with QR
Troubleshooting
Template not saving
Template not saving
- Ensure template name is not empty
- Check that all required data sources are selected
- Verify you have write permissions to the templates directory
Data not appearing in print
Data not appearing in print
- Confirm the data source field name matches exactly (case-sensitive)
- Ensure the data is present in the print job payload
- Check that dynamic elements have “Source” configured, not “Value”
Layout looks wrong when printed
Layout looks wrong when printed
- Verify paper width matches printer configuration (58mm vs 80mm)
- Avoid using table widths that exceed 100% total
- Test alignment with different paper sizes
Editor is slow or unresponsive
Editor is slow or unresponsive
- Close and reopen the editor
- Reduce the number of elements in large repeating sections
- Clear browser cache if using web interface
Related Documentation
Printer Configuration
Configure printers for your templates
API Reference
Template API endpoints