summaryrefslogtreecommitdiff
path: root/addons/crm_iap_lead_enrich
diff options
context:
space:
mode:
authorThibault Delavallée <tde@odoo.com>2020-05-05 07:22:57 +0000
committerThibault Delavallée <tde@odoo.com>2020-08-18 11:41:59 +0000
commit8280c7d5598cc52996e0da9fd3a28dc5adc51b72 (patch)
tree5cdaa2830952f6ab27e395b113e2d880998cb9ed /addons/crm_iap_lead_enrich
parent323890f7ea68dde516f5c8dc2281e99b030c97ae (diff)
[ADD] iap_crm: bridge module for IAP and CRM
PURPOSE Clean and improve IAP services integration in Odoo. Clean IAP integrations tools and improve data sharing with base modules, notably for CRM and Partner. SPECIFICATIONS In this commit we create a bridge module between iap_mail and crm to hold notably some fields used in various CRM integrations. Now that we have clean bridge module we can safely update crm and partner integrations dependencies. LINKS Task ID-2248367 Community PR odoo/odoo#53214 Enterprise PR odoo/enterprise#11258 Upgrade PR odoo/upgrade#1363 IAP PR odoo/iap-apps#191
Diffstat (limited to 'addons/crm_iap_lead_enrich')
-rw-r--r--addons/crm_iap_lead_enrich/__manifest__.py3
-rw-r--r--addons/crm_iap_lead_enrich/models/__init__.py1
-rw-r--r--addons/crm_iap_lead_enrich/models/crm_lead.py1
-rw-r--r--addons/crm_iap_lead_enrich/models/ir_model_fields.py18
4 files changed, 2 insertions, 21 deletions
diff --git a/addons/crm_iap_lead_enrich/__manifest__.py b/addons/crm_iap_lead_enrich/__manifest__.py
index 55398d00cdd..3c82fa6283c 100644
--- a/addons/crm_iap_lead_enrich/__manifest__.py
+++ b/addons/crm_iap_lead_enrich/__manifest__.py
@@ -4,11 +4,12 @@
{
'name': 'Lead Enrichment',
'summary': 'Enrich Leads/Opportunities using email address domain',
+ 'version': '1.1',
'category': 'Sales/CRM',
'version': '1.1',
'depends': [
+ 'iap_crm',
'iap_mail',
- 'crm',
],
'data': [
'data/ir_cron.xml',
diff --git a/addons/crm_iap_lead_enrich/models/__init__.py b/addons/crm_iap_lead_enrich/models/__init__.py
index f1f911179a4..dcb5aa3d8a4 100644
--- a/addons/crm_iap_lead_enrich/models/__init__.py
+++ b/addons/crm_iap_lead_enrich/models/__init__.py
@@ -4,4 +4,3 @@
from . import crm_lead
from . import iap_enrich_api
from . import res_config_settings
-from . import ir_model_fields
diff --git a/addons/crm_iap_lead_enrich/models/crm_lead.py b/addons/crm_iap_lead_enrich/models/crm_lead.py
index d6953cc0bdd..4f679f6a957 100644
--- a/addons/crm_iap_lead_enrich/models/crm_lead.py
+++ b/addons/crm_iap_lead_enrich/models/crm_lead.py
@@ -13,7 +13,6 @@ _logger = logging.getLogger(__name__)
class Lead(models.Model):
_inherit = 'crm.lead'
- reveal_id = fields.Char(string='Reveal ID', index=True)
iap_enrich_done = fields.Boolean(string='Enrichment done', help='Whether IAP service for lead enrichment based on email has been performed on this lead.')
show_enrich_button = fields.Boolean(string='Allow manual enrich', compute="_compute_show_enrich_button")
diff --git a/addons/crm_iap_lead_enrich/models/ir_model_fields.py b/addons/crm_iap_lead_enrich/models/ir_model_fields.py
deleted file mode 100644
index 06a7fb6eeb0..00000000000
--- a/addons/crm_iap_lead_enrich/models/ir_model_fields.py
+++ /dev/null
@@ -1,18 +0,0 @@
-# -*- coding: utf-8 -*-
-# Part of Odoo. See LICENSE file for full copyright and licensing details
-
-from odoo import models
-
-
-class IrModelFields(models.Model):
- _inherit = 'ir.model.fields'
-
- def unlink(self):
- # Nasty hack to prevent the deletion of shared field reveal_id
- self = self.filtered(
- lambda rec: not (
- rec.model == 'crm.lead'
- and rec.name == 'reveal_id'
- )
- )
- return super(IrModelFields, self).unlink()