← Back to team overview

c2c-oerpscenario team mailing list archive

Re: [Bug 781619] [NEW] fields with many2one ir.attachment crash when saving object

 

On Thursday 12 May 2011, you wrote:

>LIGNE 1 : ...ULL,NULL,E'False',2,E'manual_periodic',1,E'False',E'/9j/4R6T...
>                                                              ^

Just above that, there must be the Postgres error message, which says which 
field it is about. It is the photo_primary one, isn't it?

Please also consider the addon from ChriCar GmBh, that had added a photo field 
to products, since a few years. It was a straight binary field, not an 
ir.attachment.

Nevertheless, your bug is worth investigating.

-- 
Say NO to spam and viruses. Stop using Microsoft Windows!

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/781619

Title:
  fields with many2one ir.attachment crash when saving object

Status in OpenERP Server:
  New

Bug description:
  Didn't really know if it's a bug or not but trying to add attachment
  to an object through a form with photo =
  fields.many2one('ir.attachment', 'photo_primary') throw an error.

  [code]
  +VObp6UinIGMUuhMrW2emjHcHp0opBwMUtLqZvyYVGTkEen/AOr+dPzjr+AqJj1OepqkhrzG1Mrk
  jHQVF1pAefpVNXXoa3b66kxcce9Rl+wPWmk0zPNCig136/cSCpVJ6cVCDVlO3FKei1JbSd/6ZaiP
  IzzzitORCICT121nRDLKMdSK15xi3Y47VlFXu1pqvxZrh3evCz1ck7X2eh//2Q==
   »
  LIGNE 1 : ...ULL,NULL,E'False',2,E'manual_periodic',1,E'False',E'/9j/4R6T...
                                                                 ^

  > /home/franck/.virtualenvs/openerp6.0/src/server/bin/sql_db.py(131)execute()
  -> res = self._obj.execute(query, params)
  (Pdb) 'insert into "product_product" (id,product_tmpl_id,"ean13","price_extra","default_code","variants","track_outgoing","label","valuation","main_artist","track_incoming","photo_secondary","active","catalog_number","photo_primary","track_production","price_margin",create_uid,create_date) values (50,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,now())'

  [/code]


References