summaryrefslogtreecommitdiff
path: root/addons/payment/models
diff options
context:
space:
mode:
authormreficent <miquel.raich@eficent.com>2020-02-19 12:42:23 +0000
committerMartin Trigaux <mat@odoo.com>2020-02-20 14:58:33 +0000
commit3dffce34bf80c2a8d8682ef986d6daafa5bb0b7f (patch)
tree3ec174f7aa3d672d07635d4f54401ff3d7fa3725 /addons/payment/models
parent62c9227fdaac43329e48cd9446b40eee60dfeb1c (diff)
[IMP] fields: log warning for ignored selection
When a field is related, defining a selection or selection_add will have no effect and the paramater is ignored. Log a warning and fix all fields badly definied Closes odoo/odoo#45716 closes odoo/odoo#45832 Related: odoo/enterprise#8613 Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
Diffstat (limited to 'addons/payment/models')
-rw-r--r--addons/payment/models/payment_acquirer.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/addons/payment/models/payment_acquirer.py b/addons/payment/models/payment_acquirer.py
index ae90f89fa92..6453965ff5f 100644
--- a/addons/payment/models/payment_acquirer.py
+++ b/addons/payment/models/payment_acquirer.py
@@ -9,7 +9,6 @@ import pprint
from odoo import api, exceptions, fields, models, _, SUPERUSER_ID
from odoo.tools import consteq, float_round, image_process, ustr
-from odoo.addons.base.models import ir_module
from odoo.exceptions import ValidationError
from odoo.tools.misc import DEFAULT_SERVER_DATETIME_FORMAT
from odoo.tools.misc import formatLang
@@ -154,7 +153,7 @@ class PaymentAcquirer(models.Model):
# TDE FIXME: remove that brol
module_id = fields.Many2one('ir.module.module', string='Corresponding Module')
- module_state = fields.Selection(selection=ir_module.STATES, string='Installation State', related='module_id.state', store=True)
+ module_state = fields.Selection(string='Installation State', related='module_id.state', store=True)
module_to_buy = fields.Boolean(string='Odoo Enterprise Module', related='module_id.to_buy', readonly=True, store=False)
image_128 = fields.Image("Image", max_width=128, max_height=128)