Skip to content
Snippets Groups Projects
Commit 3ffd6acc authored by Thibault Delavallée's avatar Thibault Delavallée
Browse files

[IMP] mail: concatenate all Base class code in a single override

Merge two overrides of Base into the same file. Just moving code to clean
module, nothing changes functionally or technically.

LINKS

Task ID-2431217
COM PR odoo/odoo#67322
ENT PR odoo/enterprise#16876
UPG PR odoo/upgrade#2236
parent 14036869
Branches
Tags
No related merge requests found
......@@ -5,17 +5,6 @@ from odoo import _, api, fields, models
from odoo.exceptions import UserError
class Base(models.AbstractModel):
_inherit = 'base'
def _valid_field_parameter(self, field, name):
# allow tracking on abstract models; see also 'mail.thread'
return (
name == 'tracking' and self._abstract
or super()._valid_field_parameter(field, name)
)
class IrModel(models.Model):
_inherit = 'ir.model'
_order = 'is_mail_thread DESC, name ASC'
......
......@@ -9,6 +9,13 @@ from odoo import api, models, tools, _
class BaseModel(models.AbstractModel):
_inherit = 'base'
def _valid_field_parameter(self, field, name):
# allow tracking on abstract models; see also 'mail.thread'
return (
name == 'tracking' and self._abstract
or super()._valid_field_parameter(field, name)
)
# ------------------------------------------------------------
# GENERIC MAIL FEATURES
# ------------------------------------------------------------
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment