Re: [tryton-dev] Using a fields.Reference in a domain clause of a fields.Many2One

2012-09-04 Thread Udo Spallek
Tue, 4 Sep 2012 17:08:36 +0200 Cédric Krier : >On 04/09/12 16:56 +0200, Udo Spallek wrote: >> is there a way to use a fields.Reference in a domain clause of a >> fields.Many2One? >Since [1], you can use tuple. >And since [2], you can use «active_model» from the evaluation context. >[1] http://hg.tr

Re: [tryton-dev] Using a fields.Reference in a domain clause of a fields.Many2One

2012-09-04 Thread Cédric Krier
On 04/09/12 16:56 +0200, Udo Spallek wrote: > Hi, > > is there a way to use a fields.Reference in a domain clause of a > fields.Many2One? E.g. > > class Product(ModelSQL, ModelView): > _name = "product.product" > > picture_attachment = fields.Many2One('ir.attachment', > 'Picture

[tryton-dev] Using a fields.Reference in a domain clause of a fields.Many2One

2012-09-04 Thread Udo Spallek
Hi, is there a way to use a fields.Reference in a domain clause of a fields.Many2One? E.g. class Product(ModelSQL, ModelView): _name = "product.product" picture_attachment = fields.Many2One('ir.attachment', 'Picture Attachment', domain=[ ('type', '=', 'data'),