Code

Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#6221 closed (invalid)

auto_now and auto_now_add still documented

Reported by: philipp@… Owned by: nobody
Component: Documentation Version: master
Severity: Keywords: auto_now auto_now_add
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

Hi,

the auto_now and auto_now_add fields are still documented, even though they were removed http://groups.google.com/group/django-users/browse_frm/thread/fa3347d7e3e6bfd6/. Maybe one could insert a short version of the save() Method from this blog-post http://coderseye.com/2007/django-auto_now-removal-gotcha.html, so one knows about a possible replacement? :)

Regards,
Philipp Wollermann

Attachments (0)

Change History (2)

comment:1 Changed 6 years ago by gwilson

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to invalid
  • Status changed from new to closed

The aren't gone yet, take a loot at the source for proof.

comment:2 Changed 6 years ago by info@…

Sorry, error on my part, I tried with

class TestModel(models.Model):
    dttest = models.DateTimeField(auto_now)

It didn't work and I overlooked, that I forgot to specify =True to the keyword argument, then I got an error saying "auto_now is not defined" and thought "Well, that must be the removal, which was announced way back" :) Thanks for pointing me to the source, I found my error :)

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.