Skip to Content
Menú
This question has been flagged
2 Respostes
2115 Vistes

Hello,

I need to make 'taxes_id' field in Purchase order line, v15, as read only and unselectable. 

I made an inherited view, but didn't work:

{'readonly':[('state', 'in', ['draft','purchase', 'done', 'cancel'])]}

True

{'no_create_edit': True}



Thanks

Avatar
Descartar
Best Answer

Hi,

You can try like this:

xpath expr="//field[@name='order_line']/tree[1]/field[@name='taxes_id']" position="attributes"
"readonly">1
/xpath



Thanks

Avatar
Descartar

<xpath expr="/field[@name='order_line']/tree[1]/field[@name='taxes_id']" position="attributes">
<attribute name="readonly">1</attribute>
</xpath>

Autor

Thanks Niyas,
I tried it but still not working:
<?xml version="1.0"?>
<data>
<xpath expr="//field[@name='order_line']/tree[1]//field[@name='taxes_id']" position="attributes">
<attribute name="readonly">1</attribute>
<attribute name="force_save">1</attribute>
</xpath>
</data>

Best Answer

Hi,

Please try this XML code:


<xpath expr="/field[@name='order_line']/tree[1]/field[@name='taxes_id']"
           position="attributes">
        <attribute name="readonly">1</attribute>
    </xpath>




Hope it helps


Avatar
Descartar
Related Posts Respostes Vistes Activitat
3
de jul. 23
5271
2
d’oct. 22
4402
1
d’oct. 22
8045
2
de juny 24
10002
0
d’abr. 22
2985