diff --git a/addons/sale_layout/report/order.rml b/addons/sale_layout/report/order.rml deleted file mode 100755 index cde59d18e02..00000000000 --- a/addons/sale_layout/report/order.rml +++ /dev/null @@ -1,378 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [[ repeatIn(objects,'o') ]] - [[ setLang(o.partner_id.lang) ]] - - - - Shipping address : - [[ o.partner_id.title or '' ]][[ o.partner_id.name ]] - [[ o.partner_shipping_id.title or '' ]][[ o.partner_shipping_id.name ]] - [[ o.partner_shipping_id.street ]] - [[ o.partner_shipping_id.street2 or '' ]] - [[ o.partner_shipping_id.city or '' ]] [[ o.partner_shipping_id.zip or '' ]] - [[ o.partner_shipping_id.state_id and o.partner_shipping_id.state_id.name or '' ]][[ o.partner_shipping_id.country_id and o.partner_shipping_id.country_id.name or '' ]] - - - - Invoice address : - [[ o.partner_invoice_id.street ]][[ o.partner_invoice_id.street2 and (', %s' % o.partner_invoice_id.street2 or '') ]] - [[ o.partner_invoice_id.city or '' ]] [[ o.partner_invoice_id.zip or '' ]] - [[ o.partner_invoice_id.country_id and ('%s' % (o.partner_invoice_id.country_id and o.partner_invoice_id.country_id.name or '')) ]] - - - - - - - - [[ o.partner_id.title or '' ]][[ o.partner_id.name ]] - [[ o.partner_order_id.title or '' ]][[ o.partner_order_id.name ]] - [[ o.partner_order_id.street ]] - [[ o.partner_order_id.street2 or '' ]] - [[ o.partner_order_id.city or '' ]] [[ o.partner_order_id.zip or '' ]] - [[ o.partner_order_id.state_id and o.partner_order_id.state_id.name or '' ]][[ o.partner_order_id.country_id and o.partner_order_id.country_id.name or '' ]] - - - - Tel. : [[ o.partner_order_id.phone or removeParentNode('para') ]] - Fax : [[ o.partner_order_id.fax or removeParentNode('para') ]] - TVA : [[ o.partner_id.vat or removeParentNode('para') ]] - - - - - - - - - - [[ o.state<>'draft' and removeParentNode('para') ]] Quotation N° [[ o.name ]] - [[ o.state=='draft' and removeParentNode('para') ]] Order N° [[ o.name ]] - - - - - - - Your Reference - - - Date Ordered - - - Our Salesman - - - Payment Terms - - - - - - - [[ o.name ]] - - - [[ o.date_order ]] - - - [[ o.user_id.name ]] - - - [[ o.payment_term.name ]] - - - - - - - - - - Description - - - VAT - - - Quantity - - - Unit Price - - - Disc.(%) - - - Price - - - -
- [[ repeatIn(o.order_line,'line') ]] - - - - [[ line.name ]] - - - [[ ', '.join(map(lambda x: x.name, line.tax_id)) or '0.00' ]] - - - [[ line.product_uos and line.product_uos_qty or line.product_uom_qty or '0.00']] - - - [[ line.product_uos and line.product_uos.name or line.product_uom.name ]] - - - [[ line.price_unit or '0.00' ]] - - - [[ line.discount and str(line.discount) or '0.00' ]] - - - [[ line.price_subtotal or '0.00' ]] - - - - - [[ format(line.notes or removeParentNode('tr')) ]] - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - Net Total : - - - [[ o.amount_untaxed or '0.00' ]] - - - [[ o.pricelist_id.currency_id.name ]] - - - - - - - - - - Taxes : - - - [[ o.amount_tax or '0.00' ]] - - - [[ o.pricelist_id.currency_id.name ]] - - - - - - - - - - Total : - - - [[ o.amount_total or '0.00' ]] - - - [[ o.pricelist_id.currency_id.name ]] - - - - - - - - - - [[ format(o.note or '') ]] - - - - - [[ format((o.partner_id.property_payment_term and o.partner_id.property_payment_term.note) or '') ]] - - - - - - -
-
diff --git a/addons/sale_layout/report/report_sale_layout.rml b/addons/sale_layout/report/report_sale_layout.rml index 9413ca09901..990c4c5c7b1 100755 --- a/addons/sale_layout/report/report_sale_layout.rml +++ b/addons/sale_layout/report/report_sale_layout.rml @@ -190,23 +190,23 @@ - Shipping address : - [[ o.partner_id.title.name or '' ]] [[ o.partner_id.name ]] - [[ o.partner_shipping_id.street ]] - [[ o.partner_shipping_id.street2 or removeParentNode('para') ]] - [[ o.partner_shipping_id.city or '' ]] [[ o.partner_shipping_id.zip or '' ]] - [[ (o.partner_shipping_id.state_id and o.partner_shipping_id.state_id.name) or removeParentNode('para') ]] - [[ o.partner_shipping_id.country_id and o.partner_shipping_id.country_id.name or '' ]] + Shipping address : + [[ (o.partner_id and o.partner_id.title and o.partner_id.title.name) or '' ]] [[ (o.partner_id and o.partner_id.name) or '' ]] + [[ (o.partner_shipping_id and o.partner_shipping_id.street) or '' ]] + [[ (o.partner_shipping_id and o.partner_shipping_id.street2) or removeParentNode('para') ]] + [[ (o.partner_shipping_id and o.partner_shipping_id.zip) or '' ]] [[ (o.partner_shipping_id and o.partner_shipping_id.city) or '' ]] + [[ (o.partner_shipping_id and o.partner_shipping_id.state_id and o.partner_shipping_id.state_id.name) or removeParentNode('para') ]] + [[ (o.partner_shipping_id and o.partner_shipping_id.country_id and o.partner_shipping_id.country_id.name) or '' ]] Invoice address : - [[ o.partner_invoice_id.partner_id.name or '' ]] - [[ o.partner_invoice_id.street ]] - [[ o.partner_invoice_id.street2 or removeParentNode('para') ]] - [[ o.partner_invoice_id.zip or '' ]] [[ o.partner_invoice_id.city or '' ]] - [[ (o.partner_invoice_id.state_id and o.partner_invoice_id.state_id.name) or removeParentNode('para') ]] - [[ o.partner_invoice_id.country_id and o.partner_invoice_id.country_id.name or '']] + [[ (o.partner_invoice_id and o.partner_invoice_id.title and o.partner_invoice_id.title.name) or '' ]] [[ (o.partner_invoice_id and o.partner_invoice_id.name) or '' ]] + [[ (o.partner_invoice_id and o.partner_invoice_id.street) or '' ]] + [[ (o.partner_invoice_id and o.partner_invoice_id.street2) or removeParentNode('para') ]] + [[ (o.partner_invoice_id and o.partner_invoice_id.zip) or '' ]] [[ (o.partner_invoice_id and o.partner_invoice_id.city) or '' ]] + [[ (o.partner_invoice_id and o.partner_invoice_id.state_id and o.partner_invoice_id.state_id.name) or removeParentNode('para') ]] + [[ (o.partner_invoice_id and o.partner_invoice_id.country_id and o.partner_invoice_id.country_id.name) or '' ]] @@ -214,19 +214,18 @@ - [[ o.partner_id.title.name or '' ]] [[ o.partner_id.name ]] - [[ o.partner_order_id.street ]] - [[ o.partner_order_id.street2 or removeParentNode('para') ]] - [[ o.partner_order_id.zip or '' ]] [[ o.partner_order_id.city or '' ]] - [[ (o.partner_order_id.state_id and o.partner_order_id.state_id.name) or removeParentNode('para') ]] - [[ o.partner_order_id.country_id and o.partner_order_id.country_id.name or '' ]] + [[ (o.partner_id and o.partner_id.title and o.partner_id.title.name) or '' ]] [[ (o.partner_id and o.partner_id.name) or '' ]] + [[ (o.partner_order_id and o.partner_order_id.street) or '' ]] + [[ (o.partner_order_id and o.partner_order_id.street2) or removeParentNode('para') ]] + [[ (o.partner_order_id and o.partner_order_id.zip) or '' ]] [[ (o.partner_order_id and o.partner_order_id.city) or '' ]] + [[ (o.partner_order_id and o.partner_order_id.state_id and o.partner_order_id.state_id.name) or removeParentNode('para')]] [[ (o.partner_order_id and o.partner_order_id.country_id and o.partner_order_id.country_id.name) or '' ]] - Tel. : [[ o.partner_order_id.phone or removeParentNode('para') ]] - Fax : [[ o.partner_order_id.fax or removeParentNode('para') ]] - TVA : [[ o.partner_id.vat or removeParentNode('para') ]] - + Tel. : [[ (o.partner_order_id and o.partner_order_id.phone) or removeParentNode('para') ]] + Fax : [[ (o.partner_order_id and o.partner_order_id.fax) or removeParentNode('para') ]] + TVA : [[ (o.partner_id and o.partner_id.vat) or removeParentNode('para') ]] + @@ -265,7 +264,7 @@ [[ formatLang(o.date_order,date=True) ]] - [[ o.user_id.name ]] + [[ (o.user_id and o.user_id.name) or '' ]] [[ o.payment_term.name ]] @@ -425,7 +424,7 @@ - [[ format((o.partner_id.property_payment_term and o.partner_id.property_payment_term.note) or '') ]] + [[ format((o.partner_id and o.partner_id.property_payment_term and o.partner_id.property_payment_term.note) or '') ]]