Re: [tryton-dev] Adding images in reports

2018-02-19 Thread Maxime Richez
> import barcode > > from barcode.writer import ImageWriter > > > class Product: > > barcode = fields.Function(fields.Binary("Barcode", > > states={ > > 'invisible': ~Eval('barcode'), > > }), > > 'get_barcode') > > > >

Re: [tryton-dev] Adding images in reports

2018-02-19 Thread Maxime Richez
> Hi, > > I try your code to generate a barcode on a report. > I had to install "Pillow" (pip install Pillow) to avoid an NoneType error. > How display this new field 'barcode' inside LibreOffice writer ? I try to add > a frame but don't know how to link my binary field and relatorio >