---
title: tm.document
slug: db/tmdocument
createdAt: 2023-12-14T14:12:45.882Z
---

Document templates that can be linked to orders or contacts, for example an invoice or an address slip.

## Fields

| FIELD        | TYPE                           | DESCRIPTION                                                                |
| ------------ | ------------------------------ | -------------------------------------------------------------------------- |
| id           | `int`                          | Unique ID                                                                  |
| typeid       | `int`                          | Type ID<br />**References:** [tm.systemtype](docId\:YVf7OQ_iruf6NpUOHG2XQ) |
| name         | `mlstring`                     | Name of the document                                                       |
| description  | `mlstring`                     | Description of the document                                                |
| htmltemplate | `string`                       | HTML content for the document template                                     |
| css          | `string`                       | Css content for the document template                                      |
| translations | `map[k:string t:map v:string]` | Translations for the document template                                     |
| options      | `DocumentOptions`              | Key-value array of options. Can contain: nbrperpage                        |
| createdts    | `timestamp`                    | Created timestamp                                                          |
| lastupdatets | `timestamp`                    | Last updated timestamp                                                     |

