Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
1 Beantwoorden
4143 Weergaven

Suppose i am declaring a field like

name = fields.Char()

and i can call python function using compute attribute in this case.

but if i declare a field like

category = fields.Many2one('album_files')

how can i call a function i this case. 

Avatar
Annuleer
Beste antwoord

Hello, 
You can define like

category = fields.Many2one('sale.order',compute='album_files')

For Compute method: 

If your category filed depends on any other file than you can use @api.depends and in this case your filed value store=True otherwise you can use @api.multi your field value store=False

Thanks 


Avatar
Annuleer
Gerelateerde posts Antwoorden Weergaven Activiteit
2
dec. 23
15609
0
okt. 23
33
3
okt. 23
790
1
okt. 23
569
0
okt. 23
1544