Skip ke Konten
Menu
Pertanyaan ini telah diberikan tanda
2657 Tampilan

I created a many2one field to select a product in a form. I filter the possible items to choose with a domain:

`light_system = fields.Many2one('product.product', string='Lighting System', ondelete='restrict', domain=[('categ_id.name', '=','Lighting System')])`

Is it possible to get the category to be set to "Lighting System" by default when I choose to create a new item directly from this field with 'create new""' or 'create and edit""' ?

Avatar
Buang
Post Terkait Replies Tampilan Aktivitas
1
Des 16
2926
0
Mar 15
5529
2
Feb 25
5707
1
Des 24
5911
1
Des 24
1324