[SQLObject] Overriding new()..._SO_new()?
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
From: Brad B. <br...@bb...> - 2003-10-10 15:12:24
|
Hi, I would have thought it to be pretty common to want to customize what happens when a new SQLObject is created. In my case, I have to use cases at the moment: 1. I want the default of a date column in my Transaction object to be the time at which the object was created. 2. I want my other types of transactions (Purchase, Refund, ChargeBack, ServiceCharge, etc, etc) to be smart enough to accept all the arguments (in their new() method) of both their respective tables, and the transaction table, so that each one is smart enough to transparently add the necessary row to the transaction table. In both cases, I need to customize the behaviour of creating a new SQLObject. Am I missing a way in which this can be done, or should SQLObject have an _SO_new? -- Brad Bollenbach BBnet.ca |