Skip to content

Commit

Permalink
Porting quater and quinquies reports to v16
Browse files Browse the repository at this point in the history
  • Loading branch information
eLBati committed Jul 5, 2024
1 parent e19ddb3 commit 7bfa2ee
Show file tree
Hide file tree
Showing 10 changed files with 622 additions and 411 deletions.
24 changes: 2 additions & 22 deletions l10n_it_intrastat_statement/i18n/it.po
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * l10n_it_intrastat_statement
# * l10n_it_intrastat_statement
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 12.0+e\n"
"Project-Id-Version: Odoo Server 12.0+e-20191007\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-11-12 11:04+0000\n"
"PO-Revision-Date: 2023-10-13 10:39+0000\n"
Expand Down Expand Up @@ -416,16 +416,6 @@ msgstr "Modello INTRA-1 bis"
msgid "INTRA-1 Model"
msgstr "Modello INTRA-1"

#. module: l10n_it_intrastat_statement
#: model:ir.actions.report,name:l10n_it_intrastat_statement.print_intrastat_mod1_quater
msgid "INTRA-1 Quater Model"
msgstr "Modello INTRA-1 quater"

#. module: l10n_it_intrastat_statement
#: model:ir.actions.report,name:l10n_it_intrastat_statement.print_intrastat_mod1_quinquies
msgid "INTRA-1 Quinquies Model"
msgstr "Modello INTRA-1 quinquies"

#. module: l10n_it_intrastat_statement
#: model:ir.actions.report,name:l10n_it_intrastat_statement.print_intrastat_mod1_ter
msgid "INTRA-1 Ter Model"
Expand All @@ -441,16 +431,6 @@ msgstr "Modello INTRA-2 bis"
msgid "INTRA-2 Model"
msgstr "Modello INTRA-2"

#. module: l10n_it_intrastat_statement
#: model:ir.actions.report,name:l10n_it_intrastat_statement.print_intrastat_mod2_quater
msgid "INTRA-2 Quater Model"
msgstr "Modello INTRA-2 quater"

#. module: l10n_it_intrastat_statement
#: model:ir.actions.report,name:l10n_it_intrastat_statement.print_intrastat_mod2_quinquies
msgid "INTRA-2 Quinquies Model"
msgstr "Modello INTRA-2 quinquies"

#. module: l10n_it_intrastat_statement
#: model_terms:ir.ui.view,arch_db:l10n_it_intrastat_statement.account_intrastat_statement_form_view
msgid "INTRASTAT Statement"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,10 @@ class IntrastatStatementPurchaseSection3(models.Model):
comodel_name="res.country", string="Payment Country"
)

@api.multi
def get_supply_method_key(self):
self.ensure_one()
return self.supply_method

@api.multi
def get_payment_method_key(self):
self.ensure_one()
return self.payment_method
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,10 @@ class IntrastatStatementPurchaseSection4(models.Model):
comodel_name="res.country", string="Payment Country"
)

@api.multi
def get_supply_method_key(self):
self.ensure_one()
return self.supply_method

@api.multi
def get_payment_method_key(self):
self.ensure_one()
return self.payment_method
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,10 @@ class IntrastatStatementSaleSection3(models.Model):
comodel_name="res.country", string="Payment Country"
)

@api.multi
def get_supply_method_key(self):
self.ensure_one()
return self.supply_method

@api.multi
def get_payment_method_key(self):
self.ensure_one()
return self.payment_method
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,10 @@ class IntrastatStatementSaleSection4(models.Model):
help="The Adjustment is intended for cancellation",
)

@api.multi
def get_supply_method_key(self):
self.ensure_one()
return self.supply_method

@api.multi
def get_payment_method_key(self):
self.ensure_one()
return self.payment_method
Expand Down
221 changes: 134 additions & 87 deletions l10n_it_intrastat_statement/report/report_intrastat_mod1_quater.xml
Original file line number Diff line number Diff line change
@@ -1,115 +1,162 @@
<?xml version="1.0"?>
<?xml version="1.0" ?>
<odoo>
<template id="report_intrastat_mod1_quater">
<t t-call="web.html_container">
<t t-translation="off">
<t t-foreach="docs" t-as="o">
<t t-call="web.internal_layout">
<div class="page">
<div class="row col-12">

<div class="row">
<div class="col-3">
<p class="text-right"><img src="/l10n_it_intrastat_statement/static/img/agenzia_dogane.jpg" height="80px"/></p>
<p class="text-right"><img
src="/l10n_it_intrastat_statement/static/img/agenzia_dogane.jpg"
height="80px"
/></p>
</div>
<div class="col-7 col-offset-3">
<table class="table text-center table-bordered">
<td>
<b>RIEPILOGO DEGLI ACQUISTI INTRACOMUNITARI
<br/>DI BENI E DEI SERVIZI RICEVUTI</b>
<br />DI BENI E DEI SERVIZI RICEVUTI</b>
</td>
<td>Mod. INTRA-1 Quater</td>
</table>

</div>
</div>
</div>
<div class="row">
<span class="text-center col-7 col-offset-3">
<strong>SEZIONE 3. SERVIZI RESI REGISTRATI NEL PERIODO</strong>
<p/>
<strong
>SEZIONE 3. SERVIZI RESI REGISTRATI NEL PERIODO</strong>
<p />
</span>
</div>
<div class="row text-center col-12">
<span>PERIODO: </span>
<div class="row">
<div class="text-center col-12">
<span>PERIODO: </span>

<span class="col-offset-1">MESE: </span>
<strong>
<t t-if="o.period_type == 'M'">
<span t-esc="o.period_number"/>
</t>
</strong>
<span class="col-offset-1">MESE: </span>
<strong>
<t t-if="o.period_type == 'M'">
<span t-esc="o.period_number" />
</t>
</strong>

<span class="col-offset-1">TRIMESTRE: </span>
<strong>
<t t-if="o.period_type == 'T'">
<span t-esc="o.period_number"/>
</t>
</strong>
<span class="col-offset-1">ANNO: </span>
<strong><span t-esc="o.fiscalyear"/></strong>
<span class="col-offset-1">TRIMESTRE: </span>
<strong>
<t t-if="o.period_type == 'T'">
<span t-esc="o.period_number" />
</t>
</strong>
<span class="col-offset-1">ANNO: </span>
<strong><span t-esc="o.fiscalyear" /></strong>

<span class="col-offset-2">PARTITA IVA</span>
<strong><span t-esc="o.company_id.vat"/></strong>
<span class="col-offset-2">PARTITA IVA</span>
<strong><span t-esc="o.company_id.vat" /></strong>
</div>
</div>
<div class="row col-12">
<p/>
<table class="table table-bordered">
<thead class="fondo">
<tr>
<!-- <th></th> -->
<th colspan="2" class="text-center">ACQUIRENTE</th>
<th></th>
<th colspan="2" class="text-center">RIFERIMENTO FATTURA</th>
<th></th>
<th></th>
<th></th>
<th></th>
</tr>
<tr>
<!-- <th class="text-center">PROGR.</th> -->
<th class="text-center">STATO</th>
<th class="text-center">CODICE IVA</th>
<th class="text-center">AMMONTARE DELLE OPERAZIONI IN EURO</th>
<th class="text-center">NUMERO</th>
<th class="text-center">DATA</th>
<th class="text-center">CODICE SERVIZIO</th>
<th class="text-center">MODALITA’ DI EROGAZIONE</th>
<th class="text-center">MODALITA’ DI INCASSO</th>
<th class="text-center">PAESE DI PAGAMENTO</th>
</tr>
</thead>
<tbody>
<tr class="small text-center">
<td>1</td>
<td>2</td>
<td>3</td>
<td>4</td>
<td>5</td>
<td>6</td>
<td>7</td>
<td>8</td>
<td>9</td>
<!-- <td>10</td> -->
</tr>
<t t-set="total" t-value="0"/>
<tr t-foreach="o.sale_section3_ids" t-as="l">
<!-- <td t-esc="l.progressive"></td> -->
<td><span t-field="l.country_partner_id.code"/></td>
<td><span t-field="l.vat_code"/></td>
<td><span t-field="l.amount_euro"/></td>
<td><span t-field="l.invoice_number"/></td>
<td><span t-field="l.invoice_date"/></td>
<td><span t-field="l.intrastat_code_id"/></td>
<td><span t-esc="l.get_supply_method_key()"/></td>
<td><span t-esc="l.get_payment_method_key()"/></td>
<td><span t-field="l.country_payment_id.code"/></td>
<t t-set="total" t-value="total + l.amount_euro"/>
</tr>
<tr>
<td colspan="2" class="text-right">TOTALE</td>
<td><t t-esc="total"/></td>
</tr>
</tbody>
</table>
<div class="row">
<div class="col-12">
<p />
<table class="table table-bordered">
<thead class="fondo">
<tr>
<!-- <th></th> -->
<th
colspan="2"
class="text-center"
>ACQUIRENTE</th>
<th />
<th
colspan="2"
class="text-center"
>RIFERIMENTO FATTURA</th>
<th />
<th />
<th />
<th />
</tr>
<tr>
<!-- <th class="text-center">PROGR.</th> -->
<th class="text-center">STATO</th>
<th class="text-center">CODICE IVA</th>
<th
class="text-center"
>AMMONTARE DELLE OPERAZIONI IN EURO</th>
<th class="text-center">NUMERO</th>
<th class="text-center">DATA</th>
<th
class="text-center"
>CODICE SERVIZIO</th>
<th
class="text-center"
>MODALITA’ DI EROGAZIONE</th>
<th
class="text-center"
>MODALITA’ DI INCASSO</th>
<th
class="text-center"
>PAESE DI PAGAMENTO</th>
</tr>
</thead>
<tbody>
<tr class="small text-center">
<td>1</td>
<td>2</td>
<td>3</td>
<td>4</td>
<td>5</td>
<td>6</td>
<td>7</td>
<td>8</td>
<td>9</td>
<!-- <td>10</td> -->
</tr>
<t t-set="total" t-value="0" />
<tr
t-foreach="o.sale_section3_ids"
t-as="l"
>
<!-- <td t-esc="l.progressive"></td> -->
<td><span
t-field="l.country_partner_id.code"
/></td>
<td><span t-field="l.vat_code" /></td>
<td><span
t-field="l.amount_euro"
/></td>
<td><span
t-field="l.invoice_number"
/></td>
<td><span
t-field="l.invoice_date"
/></td>
<td><span
t-field="l.intrastat_code_id"
/></td>
<td><span
t-esc="l.get_supply_method_key()"
/></td>
<td><span
t-esc="l.get_payment_method_key()"
/></td>
<td><span
t-field="l.country_payment_id.code"
/></td>
<t
t-set="total"
t-value="total + l.amount_euro"
/>
</tr>
<tr>
<td
colspan="2"
class="text-right"
>TOTALE</td>
<td><t t-esc="total" /></td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</t>
Expand Down
Loading

0 comments on commit 7bfa2ee

Please sign in to comment.