Ir al contenido
Menú
Se marcó esta pregunta
2 Respuestas
2064 Vistas

Is there a way to make the tags field required when creating a new opportunity in the CRM ?

Avatar
Descartar
Mejor respuesta

A "work around" to solve this without studio or additional modules could be creating an Automated Action to pop up a warning when creating new opportunities:



code:

if record.stage_id.name == 'New' and not record.tag_ids:
    raise UserError('Please set a tag for this opportunity.')

Avatar
Descartar
Mejor respuesta

You can use attrs to make it readonly on Opportunity state.

attrs="{'required': [('type','=','opportunity')]}"

Avatar
Descartar
Autor

already did that I want to get an invalid value error when the tags field is empty

Publicaciones relacionadas Respuestas Vistas Actividad
1
abr 23
1842
1
may 25
2386
1
abr 25
3422
1
abr 25
4231
1
abr 25
1732