summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Trigaux <mat@odoo.com>2018-08-13 16:48:13 +0200
committerMartin Trigaux <mat@odoo.com>2018-08-13 16:50:11 +0200
commit0d30db55de07b2c83bd06cf0dfe74c35c4328c11 (patch)
tree09988bc0e3405b9206b06286611907375bad5030
parent13f55a5a8944ac5d8d7f44ac45ce6fac9801692b (diff)
Revert "[IMP] sale,account: display tax amount when rounding method is perline"
This reverts commit f6216a99df42beefe70f75414eaa6c9eadb92430. What we wanted two years ago is no longer a true today. Only fools and dead men don't change their minds. Task id: 31052
-rw-r--r--addons/account/views/report_invoice.xml14
-rw-r--r--addons/report_intrastat/report/report_intrastat_invoice_template.xml15
-rw-r--r--addons/sale/report/sale_report_templates.xml8
3 files changed, 1 insertions, 36 deletions
diff --git a/addons/account/views/report_invoice.xml b/addons/account/views/report_invoice.xml
index f220b6d9059..5acb2ffcb9f 100644
--- a/addons/account/views/report_invoice.xml
+++ b/addons/account/views/report_invoice.xml
@@ -52,11 +52,6 @@
<!-- Is there a discount on at least one line? -->
<t t-set="display_discount" t-value="any([l.discount for l in o.invoice_line_ids])"/>
- <!-- show only in sale invoice -->
- <t t-set="type_is_out" t-value="o.type == 'out_invoice'"/>
- <!-- if Rounding Method is computed per line -->
- <t t-set="display_taxamount"
- t-value="o.company_id.tax_calculation_rounding_method == 'round_per_line'"/>
<table class="table table-condensed" name="invoice_line_table">
<thead>
@@ -67,7 +62,6 @@
<th class="text-right">Unit Price</th>
<th t-if="display_discount" class="text-right">Disc.(%)</th>
<th class="text-right">Taxes</th>
- <th t-if="display_taxamount and type_is_out" class="text-right">Tax Amount</th>
<th class="text-right">Amount</th>
</tr>
</thead>
@@ -88,13 +82,6 @@
<td class="text-right">
<span t-esc="', '.join(map(lambda x: (x.description or x.name), l.invoice_line_tax_ids))"/>
</td>
- <td t-if="display_taxamount and type_is_out" class="text-right">
- <t t-set="taxes"
- t-value="l.invoice_line_tax_ids.compute_all(l.price_unit, l.currency_id, l.quantity)"/>
- <t t-set="tax_amount"
- t-value="taxes and (taxes['total_included'] - taxes['base']) or 0.0"/>
- <span t-esc="tax_amount" t-options='{"widget": "monetary", "display_currency": o.currency_id}'/>
- </td>
<td class="text-right" id="subtotal">
<span t-field="l.price_subtotal"
t-options='{"widget": "monetary", "display_currency": o.currency_id}'/>
@@ -106,7 +93,6 @@
<td></td>
<td></td>
<td t-if="display_discount"></td>
- <td t-if="display_taxamount and type_is_out"></td>
<td></td>
<td></td>
</tr>
diff --git a/addons/report_intrastat/report/report_intrastat_invoice_template.xml b/addons/report_intrastat/report/report_intrastat_invoice_template.xml
index 2c9752ae483..47edc821e69 100644
--- a/addons/report_intrastat/report/report_intrastat_invoice_template.xml
+++ b/addons/report_intrastat/report/report_intrastat_invoice_template.xml
@@ -39,18 +39,12 @@
<!-- Is there a discount on at least one line? -->
<t t-set="display_discount" t-value="any([l.discount for l in o.invoice_line_ids])"/>
- <!-- show only in sale invoice -->
- <t t-set="type_is_out" t-value="o.type == 'out_invoice'"/>
- <!-- if Rounding Method is computed per line -->
- <t t-set="display_taxamount"
- t-value="o.company_id.tax_calculation_rounding_method == 'round_per_line'"/>
<table class="table table-condensed">
<thead>
<tr>
<th>Description</th>
<th class="text-right">Taxes</th>
- <th t-if="display_taxamount and type_is_out" class="text-right">Tax Amount</th>
<th class="text-right">Intrastat</th>
<th class="text-right">Weight</th>
<th class="text-right">Quantity</th>
@@ -64,13 +58,6 @@
<tr t-foreach="o.invoice_line_ids" t-as="l">
<td><span t-field="l.name"/></td>
<td class="text-right"><span t-esc="', '.join(map(lambda x: x.name, l.invoice_line_tax_ids))"/></td>
- <td t-if="display_taxamount and type_is_out" class="text-right">
- <t t-set="taxes"
- t-value="l.invoice_line_tax_ids.compute_all(l.price_unit, l.currency_id, l.quantity)"/>
- <t t-set="tax_amount"
- t-value="taxes and (taxes['total_included'] - taxes['base']) or 0.0"/>
- <span t-esc="tax_amount" t-options='{"widget": "monetary", "display_currency": o.currency_id}'/>
- </td>
<td class="text-right"><span t-esc="l.product_id.intrastat_id.name"/></td>
<td class="text-right"><span t-esc="l.product_id.weight"/></td>
<td class="text-right"><span t-field="l.quantity"/></td>
@@ -99,7 +86,7 @@
</td>
</tr>
<tr>
- <td>Taxes Amount</td>
+ <td>Taxes</td>
<td class="text-right">
<span t-field="o.amount_tax" t-options='{"widget": "monetary", "display_currency": o.currency_id}'/>
</td>
diff --git a/addons/sale/report/sale_report_templates.xml b/addons/sale/report/sale_report_templates.xml
index 3b948aef951..1911a45c3d5 100644
--- a/addons/sale/report/sale_report_templates.xml
+++ b/addons/sale/report/sale_report_templates.xml
@@ -68,9 +68,6 @@
<!-- Is there a discount on at least one line? -->
<t t-set="display_discount" t-value="any([l.discount for l in doc.order_line])"/>
- <!-- if Rounding Method is computed per line -->
- <t t-set="display_taxamount"
- t-value="doc.company_id.tax_calculation_rounding_method == 'round_per_line'"/>
<t t-foreach="doc.order_lines_layouted()" t-as="page">
<table class="table table-condensed">
@@ -81,7 +78,6 @@
<th class="text-right">Unit Price</th>
<th t-if="display_discount" class="text-right" groups="sale.group_discount_per_so_line">Disc.(%)</th>
<th class="text-right">Taxes</th>
- <th t-if="display_taxamount" class="text-right">Tax Amount</th>
<th class="text-right" groups="sale.group_show_price_subtotal">Amount</th>
<th class="text-right price_tax_included" groups="sale.group_show_price_total">Total Price</th>
</tr>
@@ -114,10 +110,6 @@
<td class="text-right">
<span t-esc="', '.join(map(lambda x: (x.description or x.name), l.tax_id))"/>
</td>
- <td t-if="display_taxamount" class="text-right">
- <span t-field="l.price_tax"
- t-options='{"widget": "monetary", "display_currency": doc.pricelist_id.currency_id}'/>
- </td>
<td class="text-right" groups="sale.group_show_price_subtotal">
<span t-field="l.price_subtotal"
t-options='{"widget": "monetary", "display_currency": doc.pricelist_id.currency_id}'/>