Skip to Content
Menu
You need to be registered to interact with the community.
This question has been flagged
1 Odgovori
3711 Prikazi

can we related a field to a related field ?

I did 1st object:

_columns = { 'sale_price_unit': fields.related('sale_line_id','price_unit',string='Prix de vente',type='float', store=True, readonly=True), }

2nd object:

_columns={ 'sale_price_unit': fields.related('procurement_id','sale_price_unit',string='Prix de vente',type='float', store=True, readonly=True), }

the value of the 2nd object alwayse equal 0.0 !!

Avatar
Opusti
Avtor Best Answer

Solution

_columns={

'sale_price_unit': fields.related('procurement_id','sale_line_id','price_unit',string='Prix de vente',type='float', store=True, readonly=True),

}

Avatar
Opusti
Related Posts Odgovori Prikazi Aktivnost
1
jun. 18
3977
2
nov. 16
6280
1
jan. 19
3679
0
maj 17
3078
1
okt. 23
1858