This manual is deprecated. Please visit https://groupoffice.readthedocs.io for the latest documentation.

Difference between revisions of "Billing E-mail template variables"

From Group-Office Groupware and CRM Documentation
Jump to: navigation, search
(New page: <pre> %order_company_id% The company id %order_contact_id% The contact id %id% The database id of the order %order_id% The testual order ID %po_id% The purchase order ID %or...)
 
(Customer)
 
(16 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
==Order data==
 
<pre>
 
<pre>
%order_company_id% The company id
+
{company_id} The company id
%order_contact_id% The contact id
+
{contact_id} The contact id
%id% The database id of the order
+
{id} The database id of the order
%order_id% The testual order ID
+
{order_id} The textual order ID
%po_id% The purchase order ID
+
{po_id} The purchase order ID
%order_date% The date of the order
+
{btime} The date of the order
%reference% The order reference
+
{reference} The order reference
%order_total% The total amount of the order
+
{total} The gross amount of the order  
%order_subtotal%
+
{subtotal} The nett amount of the order
%order_vat%
+
{vat}
 +
{due_date}              The due date field value (Since 6.0.31)
 +
{due_days}              The due days field value (Since 6.0.31)
 +
</pre>
  
Address fields:
+
==Custom fields==
 +
Lookup the database name in the custom fields module and use {col_x}.
  
%customer_salutation%
+
==Customer==
%customer_name%
+
<pre>
%customer_address%
+
{customer_salutation}
%customer_address_no%
+
{customer_name}
%customer_zip%
+
{customer_address}
%customer_city%
+
{customer_address_no}
%customer_state%
+
{customer_zip}
%customer_vat_no%
+
{customer_city}
%customer_country%
+
{customer_state}
 +
{customer_vat_no}
 +
{customer_country}
 +
{customer_countryname} (since 4.1.30)
 +
</pre>
 +
 
 +
==Shipping==
 +
Combined address field tag:
 +
<pre>
 +
{formatted_shipping_address}
 +
</pre>
 +
 
 +
Separate attribute tags:
 +
<pre>
 +
{shipping_to}
 +
{shipping_salutation}
 +
{shipping_address}
 +
{shipping_address_no}
 +
{shipping_zip}
 +
{shipping_city}
 +
{shipping_state}
 +
{shipping_country}
 +
{shipping_extra}
 +
</pre>
 +
 
 +
==Logged in user==
 +
For the logged in user fields see this page: [[Addressbook#Document_templates]]
 +
 
 +
==Invoice items==
 +
You can generate a table of the invoice items like this:
 +
 
 +
<pre>
 +
{items_table_start}
 +
<table style="width: 100%;">
 +
<tbody>
 +
    <tr>
 +
        <td><strong>Description</strong></td>
 +
        <td style="text-align: center;"><strong>Amount</strong></td>
 +
        <td style="text-align: right;"><strong>Unit price</strong></td>
 +
        <td style="text-align: right;"><strong>Price</strong></td>
 +
    </tr>
 +
    <tr>
 +
        <td>{item_description}</td>
 +
        <td style="text-align: center;">{item_amount}</td>
 +
        <td style="text-align: right;">{item_unit_price}</td>
 +
        <td style="text-align: right;">{item_total}</td>
 +
    </tr>
 +
    <tr>
 +
        <td colspan="3" style="font-weight: bold;"><br />
 +
        Totaal (including VAT):</td>
 +
        <td style="border-top: 1px solid black; font-weight: bold; text-align: right;"><br />
 +
        &euro; {order_total}</td>
 +
    </tr>
 +
</tbody>
 +
</table>
 +
{items_table_end}
 +
</pre>
 +
 
 +
==Invoice item rows in ODF templates==
 +
 
 +
<pre>
 +
{amount_delivered}
 +
{markup}
 +
{cost_code}
 +
{discount}
 +
{vat} VAT Percentage. eg. 19 for 19%
 +
{amount}
 +
{unit_total} The unit price including VAT.
 +
{unit_list} The unit price from the catalog.
 +
{unit_price} The unit price without VAT
 +
{unit_cost} The unit cost price without VAT
 +
{description}
 +
{item_total} The localized item total (amount*unit_total) incl. VAT
 +
{item_subtotal} The localized item total (amount*unit_price) excl. VAT
 
</pre>
 
</pre>

Latest revision as of 09:37, 14 April 2015

Order data

{company_id}		 The company id
{contact_id}		 The contact id
{id}			 The database id of the order
{order_id}		 The textual order ID
{po_id}			 The purchase order ID
{btime}			 The date of the order
{reference}		 The order reference
{total}			 The gross amount of the order 
{subtotal}		 The nett amount of the order
{vat}
{due_date}               The due date field value (Since 6.0.31)
{due_days}               The due days field value (Since 6.0.31)

Custom fields

Lookup the database name in the custom fields module and use {col_x}.

Customer

{customer_salutation}
{customer_name}
{customer_address}
{customer_address_no}
{customer_zip}
{customer_city}
{customer_state}
{customer_vat_no}
{customer_country}
{customer_countryname} (since 4.1.30)

Shipping

Combined address field tag:

{formatted_shipping_address}

Separate attribute tags:

{shipping_to}
{shipping_salutation}
{shipping_address}
{shipping_address_no}
{shipping_zip}
{shipping_city}
{shipping_state}
{shipping_country}
{shipping_extra}

Logged in user

For the logged in user fields see this page: Addressbook#Document_templates

Invoice items

You can generate a table of the invoice items like this:

{items_table_start}
<table style="width: 100%;">
<tbody>
     <tr>
        <td><strong>Description</strong></td>
        <td style="text-align: center;"><strong>Amount</strong></td>
        <td style="text-align: right;"><strong>Unit price</strong></td>
        <td style="text-align: right;"><strong>Price</strong></td>
    </tr>
    <tr>
        <td>{item_description}</td>
        <td style="text-align: center;">{item_amount}</td>
        <td style="text-align: right;">{item_unit_price}</td>
        <td style="text-align: right;">{item_total}</td>
    </tr>
    <tr>
        <td colspan="3" style="font-weight: bold;"><br />
        Totaal (including VAT):</td>
        <td style="border-top: 1px solid black; font-weight: bold; text-align: right;"><br />
        € {order_total}</td>
    </tr>
</tbody>
</table>
{items_table_end}

Invoice item rows in ODF templates

{amount_delivered}
{markup}
{cost_code}
{discount}
{vat} VAT Percentage. eg. 19 for 19%
{amount}
{unit_total} The unit price including VAT.
{unit_list} The unit price from the catalog.
{unit_price} The unit price without VAT
{unit_cost} The unit cost price without VAT
{description}
{item_total} The localized item total (amount*unit_total) incl. VAT
{item_subtotal} The localized item total (amount*unit_price) excl. VAT