Order Export CSV Template
This template is rendered to create a CSV spreadsheet for one or more orders when you invoke the "Export" bulk action from the orders page here on the website.
If your office has an ERP or accounting system which is able to import CSV files, this can be a great and simple way of reducing the amount of data-entry work they have to do.
This template is rendered once for each order that is to be exported, and the output of all the separate renderings is joined together before the spreadsheet is downloaded to your browser. If you want to include a header row in the spreadsheet, it is important to check the
includeHeader parameter in your template to make sure you only render it once, at the top.
order (reference to SalesOrder)
A reference to the sales order that you're trying to render.
lines (collection of SalesOrderLine)
The set of line items that should be included in this export. Right now, the "Export" bulk action does not support exporting just the manufacturer-specific portions of an order, however, we will probably add support for this at some point in the future. You should use
lines instead of
order.lines to future-proof your template for when this support is added.
Flag indicating whether or not the template should render the header row. This will be true for the first order in the set to be exported and false for the rest.