Files
odoo_source/addons/mail_plugin/models/res_partner_iap.py
T
Fabien Pinckaers 3363e55cac [IMP] cleanup of help messages in all modules
This commit aims at removing unuseful help message to:
1/ reduce translators work, to focus on more useful translations
2/ not sending unuseful information in load_views
3/ reduce help message to useful messages, so that we can mark
   fields having a tooltip in the future UI.
4/ some cleanup of existing messages too

The main use cases:
- REMOVED: help redundant with the field name, providing no extra info
- MOVED TO COMMENT: technical help messages, that should not be in UX

closes odoo/odoo#97279

Signed-off-by: Fabien Pinckaers <fp@odoo.com>
2022-08-02 00:26:53 +02:00

28 lines
1.0 KiB
Python

# -*- coding: utf-8 -*-
from odoo import fields, models
class ResPartnerIap(models.Model):
"""Technical model which stores the response returned by IAP.
The goal of this model is to not enrich 2 times the same company. We do it in a
separate model to not add heavy field (iap_enrich_info) on the <res.partner>
model.
We also save the requested domain, so whatever the values are on the <res.partner>,
we will always retrieve the already enriched <res.partner> and the corresponding
IAP information.
"""
_name = 'res.partner.iap'
_description = 'Partner IAP'
partner_id = fields.Many2one('res.partner', string='Partner',
ondelete='cascade', required=True)
iap_search_domain = fields.Char('Search Domain / Email', help='Domain used to find the company')
iap_enrich_info = fields.Text('IAP Enrich Info', help='IAP response stored as a JSON string', readonly=True)
_sql_constraints = [('unique_partner_id', 'UNIQUE(partner_id)', 'Only one partner IAP is allowed for one partner')]