On Apr 2, 2:50 am, "Adrian Holovaty" <[EMAIL PROTECTED]> wrote: > On 4/1/07, SmileyChris <[EMAIL PROTECTED]> wrote: > > > I'm not sure if there's a ticket for this, but I remember talk about > > it being an unnecessary wart which was going to be removed eventually. > > Is it in the 1.0 plan? > > Yes, I'd like to drop those two options. > > auto_now can be accomplished with "default=datetime.datetime.now", and > auto_now_add can be accomplished with a custom save() method. > > Adrian
It could be just me, but although i don't mind losing auto_*, it don't look very DRY in save. I know it's only a few lines (like 4 ? for both options, not using default= for sake of keeping the logic together) but when lots of models have a cre_date and mod_date, those lines are repeated over and over again in save(). Maybe a decorator or the dispatcher can help for all the models with automaticly filled cre and mod_date's. This could also be combined with things like last_modified_by_user and created_by_user. Cause to me it seems these are all standard (housekeeping) tasks which you would like to associate with a model and not repeat the code for it in every model. But i could be missing the point entirely :) Malcolm's 'It's Monday' comment could apply to me too ;) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-developers?hl=en -~----------~----~----~----~------~----~------~--~---