Skip to content

Commit

Permalink
Merge PR #4032 into 16.0
Browse files Browse the repository at this point in the history
Signed-off-by sergiocorato
  • Loading branch information
OCA-git-bot committed Oct 4, 2024
2 parents 1d50a33 + 6ab9778 commit f0e9c29
Show file tree
Hide file tree
Showing 15 changed files with 909 additions and 10 deletions.
4 changes: 4 additions & 0 deletions l10n_it_intrastat_statement/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,12 @@
"report/report_intrastat_mod1.xml",
"report/intrastat_mod1_bis.xml",
"report/intrastat_mod1_ter.xml",
"report/report_intrastat_mod1_quater.xml",
"report/report_intrastat_mod1_quinquies.xml",
"report/report_intrastat_mod2.xml",
"report/report_intrastat_mod2_bis.xml",
"report/report_intrastat_mod2_quater.xml",
"report/report_intrastat_mod2_quinquies.xml",
"report/reports.xml",
],
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ class IntrastatStatementPurchaseSection3(models.Model):
comodel_name="res.country", string="Payment Country"
)

def get_supply_method_key(self):
self.ensure_one()
return self.supply_method

def get_payment_method_key(self):
self.ensure_one()
return self.payment_method

@api.model
def get_section_number(self):
return 3
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,14 @@ class IntrastatStatementPurchaseSection4(models.Model):
comodel_name="res.country", string="Payment Country"
)

def get_supply_method_key(self):
self.ensure_one()
return self.supply_method

def get_payment_method_key(self):
self.ensure_one()
return self.payment_method

@api.model
def get_section_number(self):
return 4
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,14 @@ class IntrastatStatementSaleSection3(models.Model):
comodel_name="res.country", string="Payment Country"
)

def get_supply_method_key(self):
self.ensure_one()
return self.supply_method

def get_payment_method_key(self):
self.ensure_one()
return self.payment_method

@api.model
def get_section_number(self):
return 3
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,14 @@ class IntrastatStatementSaleSection4(models.Model):
help="The Adjustment is intended for cancellation",
)

def get_supply_method_key(self):
self.ensure_one()
return self.supply_method

def get_payment_method_key(self):
self.ensure_one()
return self.payment_method

@api.model
def get_section_number(self):
return 4
Expand Down
10 changes: 8 additions & 2 deletions l10n_it_intrastat_statement/report/intrastat_mod1_bis.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,13 @@
<t t-call="web.html_container">
<t t-translation="off">
<t t-foreach="docs" t-as="o">
<t t-call="web.internal_layout">
<t t-if="not o" t-set="o" t-value="doc" />
<div
class="article"
t-att-data-oe-model="o and o._name"
t-att-data-oe-id="o and o.id"
t-att-data-oe-lang="o and o.env.context.get('lang')"
>
<div class="page">
<div class="row">
<div class="col-3">
Expand Down Expand Up @@ -189,7 +195,7 @@
</div>
</div>
</div>
</t>
</div>
</t>
</t>
</t>
Expand Down
10 changes: 8 additions & 2 deletions l10n_it_intrastat_statement/report/intrastat_mod1_ter.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,13 @@
<t t-call="web.html_container">
<t t-translation="off">
<t t-foreach="docs" t-as="o">
<t t-call="web.internal_layout">
<t t-if="not o" t-set="o" t-value="doc" />
<div
class="article"
t-att-data-oe-model="o and o._name"
t-att-data-oe-id="o and o.id"
t-att-data-oe-lang="o and o.env.context.get('lang')"
>
<div class="page">
<div class="row">
<div class="col-3">
Expand Down Expand Up @@ -179,7 +185,7 @@
</div>
</div>
</div>
</t>
</div>
</t>
</t>
</t>
Expand Down
10 changes: 8 additions & 2 deletions l10n_it_intrastat_statement/report/report_intrastat_mod1.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,13 @@
<t t-call="web.html_container">
<t t-translation="off">
<t t-foreach="docs" t-as="o">
<t t-call="web.internal_layout">
<t t-if="not o" t-set="o" t-value="doc" />
<div
class="article"
t-att-data-oe-model="o and o._name"
t-att-data-oe-id="o and o.id"
t-att-data-oe-lang="o and o.env.context.get('lang')"
>
<div class="page" style="font-size: 10px">
<div class="row">
<div class="col-2">
Expand Down Expand Up @@ -248,7 +254,7 @@
</tr>
</table>
</div>
</t>
</div>
</t>
</t>
</t>
Expand Down
173 changes: 173 additions & 0 deletions l10n_it_intrastat_statement/report/report_intrastat_mod1_quater.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,173 @@
<?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-if="not o" t-set="o" t-value="doc" />
<div
class="article"
t-att-data-oe-model="o and o._name"
t-att-data-oe-id="o and o.id"
t-att-data-oe-lang="o and o.env.context.get('lang')"
>
<div class="page">
<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>
</div>
<div class="col-7 col-offset-3">
<table class="table text-center table-bordered">
<td>
<b>RIEPILOGO DELLE CESSIONI INTRACOMUNITARIE
<br />DI BENI E DEI SERVIZI RESI</b>
</td>
<td>Mod. INTRA-1 Quater</td>
</table>
</div>
</div>
<div class="row">
<span class="text-center col-7 col-offset-3">
<strong
>SEZIONE 3. SERVIZI RESI REGISTRATI NEL PERIODO</strong>
<p />
</span>
</div>
<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">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>
</div>
</div>
<div class="row">
<div class="col-12">
<p />
<table class="table table-bordered">
<thead class="fondo">
<tr>
<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.sequence" />
<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>
</div>
</t>
</t>
</t>
</template>
</odoo>
Loading

0 comments on commit f0e9c29

Please sign in to comment.