Skip to content

Commit ef7d65a

Browse files
Migration to 11.0
1 parent e393edf commit ef7d65a

14 files changed

Lines changed: 13 additions & 146 deletions

File tree

l10n_it_withholding_tax/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2015 Alessandro Camilli (<http://www.openforce.it>)
32
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
43

l10n_it_withholding_tax/__manifest__.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2015 Alessandro Camilli (<http://www.openforce.it>)
32
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
43

54
{
65
'name': 'Italian Withholding Tax',
7-
'version': '10.0.1.2.2',
6+
'version': '11.0.1.0.0',
87
'category': 'Account',
98
'author': 'Openforce, Odoo Italia Network, '
109
'Odoo Community Association (OCA)',
@@ -15,7 +14,6 @@
1514
'views/account.xml',
1615
'views/withholding_tax.xml',
1716
'security/ir.model.access.csv',
18-
'workflow.xml',
1917
'security/security.xml',
2018
],
2119
"installable": True

l10n_it_withholding_tax/models/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2015 Alessandro Camilli (<http://www.openforce.it>)
32
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
43

l10n_it_withholding_tax/models/account.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2015 Alessandro Camilli (<http://www.openforce.it>)
32
# Copyright 2018 Lorenzo Battistini - Agile Business Group
43
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
@@ -96,20 +95,20 @@ def generate_wt_moves(self):
9695
p_date_maturity = False
9796
payment_lines = wt_st.withholding_tax_id.payment_term.compute(
9897
amount_wt,
99-
rec_line_statement.date or False)
98+
rec_line_payment.date or False)
10099
if payment_lines and payment_lines[0]:
101100
p_date_maturity = payment_lines[0][0][0]
102101
wt_move_vals = {
103102
'statement_id': wt_st.id,
104-
'date': rec_line_statement.date,
103+
'date': rec_line_payment.date,
105104
'partner_id': rec_line_statement.partner_id.id,
106105
'reconcile_partial_id': self.id,
107106
'payment_line_id': rec_line_payment.id,
108107
'credit_debit_line_id': rec_line_statement.id,
109108
'withholding_tax_id': wt_st.withholding_tax_id.id,
110109
'account_move_id': rec_line_payment.move_id.id or False,
111110
'date_maturity':
112-
p_date_maturity or rec_line_statement.date_maturity,
111+
p_date_maturity or rec_line_payment.date_maturity,
113112
'amount': amount_wt
114113
}
115114
wt_move_vals = self._prepare_wt_move(wt_move_vals)

l10n_it_withholding_tax/models/withholding_tax.py

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2015 Alessandro Camilli (<http://www.openforce.it>)
32
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
43

@@ -345,26 +344,12 @@ def _compute_display_name(self):
345344

346345
@api.multi
347346
def action_paid(self):
348-
for pt in self:
349-
wf_service = netsvc.LocalService("workflow")
350-
wf_service.trg_validate(self.env.uid, self._name, pt.id, 'paid',
351-
self.env.cr)
352-
353-
@api.multi
354-
def action_set_to_draft(self):
355-
for pt in self:
356-
wf_service = netsvc.LocalService("workflow")
357-
wf_service.trg_validate(self.env.uid, self._name, pt.id, 'cancel',
358-
self.env.cr)
359-
360-
@api.multi
361-
def move_paid(self):
362347
for move in self:
363348
if move.state in ['due']:
364349
move.write({'state': 'paid'})
365350

366351
@api.multi
367-
def move_set_due(self):
352+
def action_set_to_draft(self):
368353
for move in self:
369354
if move.state in ['paid']:
370355
move.write({'state': 'due'})

l10n_it_withholding_tax/views/account.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@
100100
</field>
101101
</xpath>
102102

103-
<xpath expr="//field[@name='amount_total']" position="after">
103+
<xpath expr="//group[@class='oe_subtotal_footer oe_right']/field[@name='amount_total']" position="after">
104104
<field name="withholding_tax_amount" widget="monetary" options="{'currency_field': 'currency_id'}"
105105
attrs="{'invisible': [('withholding_tax', '=', False)]}"/>
106106
<field name="amount_net_pay" widget="monetary" options="{'currency_field': 'currency_id'}" class="oe_subtotal_footer_separator"

l10n_it_withholding_tax/workflow.xml

Lines changed: 0 additions & 48 deletions
This file was deleted.

l10n_it_withholding_tax_payment/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2015 Alessandro Camilli (<http://www.openforce.it>)
32
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
43

l10n_it_withholding_tax_payment/__manifest__.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2015 Alessandro Camilli (<http://www.openforce.it>)
32
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
43

54
{
65
'name': 'Italian Withholding Tax Payment',
7-
'version': '10.0.1.1.0',
6+
'version': '11.0.1.0.0',
87
'category': 'Account',
98
'author': 'Openforce, Odoo Italia Network, '
109
'Odoo Community Association (OCA)',
@@ -14,7 +13,6 @@
1413
'l10n_it_withholding_tax'],
1514
"data": [
1615
'views/withholding_tax.xml',
17-
'workflow.xml',
1816
'security/ir.model.access.csv',
1917
'data/sequence.xml',
2018
'wizard/create_move_payment_view.xml',

l10n_it_withholding_tax_payment/models/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# -*- coding: utf-8 -*-
21
# Copyright 2015 Alessandro Camilli (<http://www.openforce.it>)
32
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
43

0 commit comments

Comments
 (0)