mirror of
https://github.com/OCA/contract.git
synced 2025-02-13 17:57:24 +02:00
[MIG] contract_payment_mode: Migration to 11.0
This commit is contained in:
@@ -30,7 +30,7 @@ Usage
|
|||||||
|
|
||||||
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
|
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
|
||||||
:alt: Try me on Runbot
|
:alt: Try me on Runbot
|
||||||
:target: https://runbot.odoo-community.org/runbot/110/10.0
|
:target: https://runbot.odoo-community.org/runbot/110/11.0
|
||||||
|
|
||||||
Bug Tracker
|
Bug Tracker
|
||||||
===========
|
===========
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||||
|
|
||||||
from . import models
|
from . import models
|
||||||
|
|||||||
@@ -1,15 +1,14 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
# Copyright 2015 Domatix (<www.domatix.com>)
|
# Copyright 2015 Domatix (<www.domatix.com>)
|
||||||
# Copyright 2016 Antiun Ingenieria S.L. - Antonio Espinosa
|
# Copyright 2016 Antiun Ingenieria S.L. - Antonio Espinosa
|
||||||
# Copyright 2017 Tecnativa - Vicent Cubells
|
|
||||||
# Copyright 2017 Tecnativa - David Vidal
|
# Copyright 2017 Tecnativa - David Vidal
|
||||||
# Copyright 2017 Tecnativa - Carlos Dauden <carlos.dauden@tecnativa.com>
|
# Copyright 2017 Tecnativa - Carlos Dauden <carlos.dauden@tecnativa.com>
|
||||||
|
# Copyright 2017-2018 Tecnativa - Vicent Cubells <vicent.cubells@tecnativa.com>
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||||
|
|
||||||
{
|
{
|
||||||
'name': 'Contract Payment Mode',
|
'name': 'Contract Payment Mode',
|
||||||
'summary': 'Payment mode in contracts and their invoices',
|
'summary': 'Payment mode in contracts and their invoices',
|
||||||
'version': '10.0.1.0.1',
|
'version': '11.0.1.0.0',
|
||||||
'author': 'Domatix, '
|
'author': 'Domatix, '
|
||||||
'Tecnativa, '
|
'Tecnativa, '
|
||||||
'Odoo Community Association (OCA)',
|
'Odoo Community Association (OCA)',
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
# Copyright 2016 Antiun Ingenieria S.L. - Antonio Espinosa
|
# Copyright 2016 Antiun Ingenieria S.L. - Antonio Espinosa
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||||
|
|
||||||
|
|||||||
@@ -1,2 +1 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
from . import contract
|
from . import contract
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
from odoo import api, fields, models
|
from odoo import api, fields, models
|
||||||
|
|
||||||
|
|
||||||
@@ -13,7 +12,6 @@ class AccountAnalyticAccount(models.Model):
|
|||||||
|
|
||||||
@api.onchange('partner_id')
|
@api.onchange('partner_id')
|
||||||
def on_change_partner_id(self):
|
def on_change_partner_id(self):
|
||||||
if self.partner_id.customer_payment_mode_id:
|
|
||||||
self.payment_mode_id = self.partner_id.customer_payment_mode_id.id
|
self.payment_mode_id = self.partner_id.customer_payment_mode_id.id
|
||||||
|
|
||||||
@api.multi
|
@api.multi
|
||||||
@@ -22,6 +20,6 @@ class AccountAnalyticAccount(models.Model):
|
|||||||
if self.payment_mode_id:
|
if self.payment_mode_id:
|
||||||
invoice_vals['payment_mode_id'] = self.payment_mode_id.id
|
invoice_vals['payment_mode_id'] = self.payment_mode_id.id
|
||||||
invoice = self.env['account.invoice'].new(invoice_vals)
|
invoice = self.env['account.invoice'].new(invoice_vals)
|
||||||
invoice.payment_mode_id_change()
|
invoice._onchange_payment_mode_id()
|
||||||
invoice_vals = invoice._convert_to_write(invoice._cache)
|
invoice_vals = invoice._convert_to_write(invoice._cache)
|
||||||
return invoice_vals
|
return invoice_vals
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
# Copyright 2016 Antiun Ingenieria S.L. - Antonio Espinosa
|
# Copyright 2016 Antiun Ingenieria S.L. - Antonio Espinosa
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
# -*- coding: utf-8 -*-
|
|
||||||
# Copyright 2015 Antiun Ingenieria S.L. - Antonio Espinosa
|
# Copyright 2015 Antiun Ingenieria S.L. - Antonio Espinosa
|
||||||
# Copyright 2017 Tecnativa - Vicent Cubells
|
# Copyright 2017 Tecnativa - Vicent Cubells
|
||||||
# Copyright 2017 Tecnativa - David Vidal
|
# Copyright 2017 Tecnativa - David Vidal
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<odoo>
|
<odoo>
|
||||||
|
|
||||||
<record id="account_analytic_account_payment_form" model="ir.ui.view">
|
<record id="account_analytic_account_payment_form" model="ir.ui.view">
|
||||||
|
|||||||
Reference in New Issue
Block a user