You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
52 lines
2.2 KiB
52 lines
2.2 KiB
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
Copyright 2019 Ecosoft Co., Ltd.
|
|
License LGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html).-->
|
|
<odoo>
|
|
|
|
<record id="sale_order_xlsx_template" model="xlsx.template">
|
|
<field name="res_model">sale.order</field>
|
|
<field name="fname">sale_order.xlsx</field>
|
|
<field name="name">Sale Order Template</field>
|
|
<field name="description">Sample Sales Order Tempalte for testing</field>
|
|
<field name="input_instruction">
|
|
{
|
|
'__EXPORT__': {
|
|
'sale_order': {
|
|
'_HEAD_': {
|
|
'B2': 'partner_id.display_name${value or ""}#{align=left;style=text}',
|
|
'B3': 'name${value or ""}#{align=left;style=text}',
|
|
},
|
|
'order_line': {
|
|
'A6': 'product_id.display_name${value or ""}#{style=text}',
|
|
'B6': 'name${value or ""}#{style=text}',
|
|
'C6': 'product_uom_qty${value or 0}#{style=number}',
|
|
'D6': 'product_uom.name${value or ""}#{style=text}',
|
|
'E6': 'price_unit${value or 0}#{style=number}',
|
|
'F6': 'tax_id${value and ",".join([x.display_name for x in value]) or ""}',
|
|
'G6': 'price_subtotal${value or 0}#{style=number}',
|
|
}
|
|
}
|
|
},
|
|
'__IMPORT__': {
|
|
'sale_order': {
|
|
'_NODEL_order_line': {
|
|
'A6': 'product_id',
|
|
'B6': 'name',
|
|
'C6': 'product_uom_qty',
|
|
'D6': 'product_uom',
|
|
'E6': 'price_unit',
|
|
'F6': 'tax_id',
|
|
}
|
|
}
|
|
},
|
|
# '__POST_IMPORT__': '${object.post_import_do_something()}',
|
|
}
|
|
</field>
|
|
</record>
|
|
|
|
<function model="xlsx.template" name="load_xlsx_template">
|
|
<value eval="[ref('sale_order_xlsx_template')]"/>
|
|
</function>
|
|
|
|
</odoo>
|