On 24/12/11 10:27 +0100, Udo Spallek wrote: > Hi, > Am Sat, 24 Dec 2011 07:45:18 +0530 > schrieb Sharoon Thomas <[email protected]>: > > On Dec 24, 2011, at 3:09 AM, Cédric Krier wrote: > [...] > > > Second, we just need to ensure the carrier_weight will be loaded > > > after sale_shipment_cost if it is installed. For this, let's > > > introduce an other keyword "extra_depends" that will behave like > > > "depends" but it will not be read when installing the module. > > This will not prevent tryton module loader from loading classes which > > were meant to be inherited (but will be loaded as new). For example if > > you inherit `sale.sale` and change the behaviour of a method, and if > > sale module is not in `depends` tryton will create `sale.sale` as a > > new model ? > > Maybe we can control the class level with a decorator, like: > > @depends_module('account_invoice') > class Invoice(...): > _name='account.invoice' > ...
Not possible because there is no database up when loading modules. -- 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/
pgpr8LC1uzZp5.pgp
Description: PGP signature
