On 12/10/11 12:59 +0200, Albert Cervera i Areny wrote: > A Dimecres, 12 d'octubre de 2011 12:45:00, Cédric Krier va escriure: > > On 12/10/11 12:24 +0200, Albert Cervera i Areny wrote: > > > One option would be to add a hook to Model.init() between field creation > > > and removal so we could override in account_invoice module to update the > > > necessary information. The hook could be called > > > "init_before_fields_removal()" for example, or maybe somebody can find a > > > better name. > > > > Simply update ir.model.field value before calling init. > > I cannot because at that moment, the record for the new field > (customer_payment_term) does not yet in ir.model.field exist and > ir_property.field has a NOT NULL attribute.
I don't see any issue to change the name in ir.model.field before calling super().init() > > > Another thing related to properties is that in 'ir.property' there's a > > > field called 'name' which seems to store redundant information because > > > the name of the property is already stored in ir.model.field. Is there > > > really a need for such field or maybe we should remove it? > > > > Yes legacy of OE. > > Yes means "I should remove it" or "there's really a need"? You mean the the > former don't you? I think it could be removed. -- Cédric Krier B2CK SPRL Rue de Rotterdam, 4 4000 Liège Belgium Tel: +32 472 54 46 59 Email/Jabber: [email protected] Website: http://www.b2ck.com/
pgpHauGUcgjed.pgp
Description: PGP signature
