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

I want to add a custom html attribute (say - download ) to a field in the view

I tried these

<field name="attachment" filename="answer_id" download="answer_id" />

<field name="attachment" filename="answer_id" t-att-download="answer_id" />

but fails. How can achieve this. Thanks in advance

Avatar
Descartar
Mejor respuesta

Hi,

You can not directly add html attribute in field view.

you need to create widget and then it used in field view.

Thank you.

Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
1
mar 15
4560
1
mar 15
4473
1
ago 15
9169
0
jun 15
3390
1
mar 15
7463