ADD relational inverse field for payment.mode on payment.method

This commit is contained in:
Akim Juillerat
2017-07-12 13:09:46 +02:00
parent d049fce3a8
commit 4cda80669d
2 changed files with 4 additions and 1 deletions

View File

@@ -4,7 +4,7 @@
{
'name': 'Account Payment Mode',
'version': '10.0.1.0.0',
'version': '10.0.1.0.1',
'license': 'AGPL-3',
'author': "Akretion,Odoo Community Association (OCA)",
'website': 'https://github.com/OCA/bank-payment',

View File

@@ -22,6 +22,9 @@ class AccountPaymentMethod(models.Model):
display_name = fields.Char(
compute='compute_display_name',
store=True, string='Display Name')
payment_mode_ids = fields.One2many(
comodel_name='account.payment.mode', inverse_name='payment_method_id',
string='Payment modes')
@api.multi
@api.depends('code', 'name', 'payment_type')