Ir al contenido
Menú
Se marcó esta pregunta
1 Responder
1218 Vistas

Hi,

In a multi Company Environment and in the Lead form (CRM), tags that are showen have to be added by a creator from the envirement company : Here is a static example :


I have tried : 
- [("create_uid.company_id", "=", "env.company.id")]- 

- [("create_uid.company_id", "=", " self.env.company.id  ")]
- [("create_uid.company_id", "=", " self.env.user.company_id ")]
Knowing that I am using Odoo 17!

I will be thankful if I get a help to fix that !
Thanks in advance! 


Rgards
/Jabran





Avatar
Descartar
Mejor respuesta

Hi,

Please try this Python code :
    def get_domain(self):
        return [("create_uid.company_id", "=", self.env.company.id)]

    tag_ids = fields.Many2many(
        'crm.tag', 'crm_tag_rel', 'lead_id', 'tag_id', string='Tags',
        help="Classify and analyze your lead/opportunity categories like: Training, Service",domain='get_domain')


Hope it helps

Avatar
Descartar
Autor

Thanks for your efforts, but it didn't work !

Publicaciones relacionadas Respuestas Vistas Actividad
2
jul 25
1641
3
jul 25
2089
1
jul 25
1398
3
nov 24
361
4
sept 24
3035