Skip to content

Commit

Permalink
[17.0][IMP] crm_tag_team: improve module structure
Browse files Browse the repository at this point in the history
  • Loading branch information
vehi-invitu committed Dec 21, 2024
1 parent 30a8261 commit 3c9b14f
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 25 deletions.
6 changes: 6 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
3 changes: 0 additions & 3 deletions __init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
# Part of Odoo. See LICENSE file for full copyright and licensing details.


from . import models
32 changes: 16 additions & 16 deletions __manifest__.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
# Part of Odoo. See LICENSE file for full copyright and licensing details.
# Copyright 2024 Invitu SARL
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
{
'name': 'CRM Tags Sales Team',
'author': 'INVITU, Cyril VINH-TUNG',
'website': 'https://www.invitu.com',
'version': '1.0',
'category': 'CRM',
'description': """
This module adds a filter by sales_team for crm_tag.
===========================================================================
""",
'depends': ['crm'],
'data': [
'views/crm_tag_views.xml',
'views/crm_lead_views.xml',
"name": "CRM Tags Sales Team",
"summary": "This module adds a filter by sales_team for crm_tags",
"author": "INVITU, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/crm",
"version": "17.0.1.0",
"license": "AGPL-3",
"category": "Customer Relationship Management",
"depends": [
"crm",
],
'installable': True,
"data": [
"views/crm_tag_views.xml",
"views/crm_lead_views.xml",
],
"installable": True,
}
3 changes: 0 additions & 3 deletions models/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
# Part of Odoo. See LICENSE file for full copyright and licensing details.


from . import crm_tag
3 changes: 0 additions & 3 deletions models/crm_tag.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
# -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.

from odoo import fields, models


Expand Down
Empty file added pyproject.toml
Empty file.
5 changes: 5 additions & 0 deletions views/crm_lead_views.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@
<field name="inherit_id" ref="crm.crm_lead_view_form"/>
<field name="priority" eval="100"/>
<field name="arch" type="xml">
<field name="tag_ids" position="attributes">
<attribute name="domain">
['|', ('sales_team_ids', '=', False),('sales_team_ids', 'in', team_id)]
</attribute>
</field>
<xpath expr="//group[@name='lead_priority']/field[@name='tag_ids']" position="attributes">
<attribute name="domain">
['|', ('sales_team_ids', '=', False),('sales_team_ids', 'in', team_id)]
Expand Down

0 comments on commit 3c9b14f

Please sign in to comment.