Skip to content
Docs Make a print template for invoices and slips

Make a print template for invoices and slips

Add a print template to a table and write its page in HTML, with the item’s fields between double braces: an invoice, a packing slip or a price list.

Add a print template

A print template (a document template) is the page that Base Captain prints from one item, or from a view's items: you write it in HTML, with the item's fields between double braces. The base's builders add print templates to a table.

  1. Click Builder in the rail, then the list it prints from, here Orders, then Print templates: the page lists the table's print templates, each with its name and its id. Click New print template.
  2. Give it a Name, such as Packing slip: an item's page then shows a button Print Packing slip, or lists it under one Print button when the table has three print templates or more.
  3. The Id follows from the name, packing-slip: lowercase letters, digits and dashes, 3 to 40 of them. Change it now if you like: a print template keeps its id.
  4. Under Prints, leave One item, or pick The items of one of the table's views to print them instead (Print a view: a price list or a statement of account).
  5. To print the items that point at the printed one, such as an order's payments or a project's change orders, click Add list under Lists. Pick The items of a table with a reference to this one and the reference they point by, under Linked by, give the list a Key, such as payments, and, if you like, keep only some of them under Only the … where and sort them. Click Add list: the list is a row under Lists, with its filters in words, to edit or remove. A print template holds up to 10 lists; a view's has none.
  6. Under Roles, select the roles that get the print, such as your staff roles for a checklist that your customers do not need. Select no role and every role that can see the item gets it.
  7. Write the Template: the page in HTML, with places for the item's values in double braces (Write a print template: fields in double braces).
  8. Click Save print template. The print template is created at once, with no box. It is in the list, and on the page of every order, as a button.

Preview a print template on an item

A print template's page shows a preview once the template is created: pick an item under Preview on and the item shows as it prints for that item, with a Print button; a view's print template shows the view's page. The preview reloads after each save. A template that cannot be printed for that item shows "This page could not be printed." in the preview instead.

Change or delete a print template

To change a print template, open it from Print templates, change its name, its roles or its template and click Save print template. A mistake in the template is refused with what is wrong, under the box, and nothing is saved.

To delete a print template, click Delete, then Delete print template in the box that asks: the print template is deleted, and its button leaves the items' pages.

Each change to a print template is a new version of your base, which you can go back from (Ask the assistant and review its changes).

Ask the assistant for a print template

The assistant makes a print template from your own words, on any page: "Add a printable packing slip to orders: the order number, the customer's name and shipping address, and each line's product and quantity, without prices." It answers with a card, such as "Add a packing slip print template to Orders", which says what it adds. Click Apply, or Cancel to leave the base as it is.

The request in the assistant, then its card Add a packing slip print template to Orders, a cosmetic change that adds the print template Packing slip to Orders, with Cancel and Apply. The request in the assistant, then its card Add a packing slip print template to Orders, a cosmetic change that adds the print template Packing slip to Orders, with Cancel and Apply.

Ask again to change one: "Put our bank details under the invoice's total", or "List the order's payments under the total." Your company's details come from the base's settings, so you fill them in once.

Offer a print only for some items

Only the assistant sets the condition that offers a print of an item only for some items: "Offer the receipt only for attended visits." The print template's page then says "Offered only when a rule the assistant wrote holds for the item." under Roles. To remove the condition, ask the assistant again. A print template of a view has no condition. What a condition does on an item's page is in Print an item or save it as a PDF.

Print templates: limits and details

Print templates keep these rules:

  • The page around a print template gives the title and a plain print style; add your own with a <style> block.
  • Scripts, and pictures or fonts from other websites, are left out of a print template.
Loading