mirror of
https://github.com/django/django.git
synced 2025-10-25 22:56:12 +00:00
Fixed #122 -- BIG, BACKWARDS-INCOMPATIBLE CHANGE. Changed model syntax to use fieldname=FieldClass() syntax. See ModelSyntaxChangeInstructions for important information on how to change your models
git-svn-id: http://code.djangoproject.com/svn/django/trunk@549 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -7,10 +7,8 @@ This is a basic model with only two non-primary-key fields.
|
||||
from django.core import meta
|
||||
|
||||
class Article(meta.Model):
|
||||
fields = (
|
||||
meta.CharField('headline', maxlength=100, default='Default headline'),
|
||||
meta.DateTimeField('pub_date'),
|
||||
)
|
||||
headline = meta.CharField(maxlength=100, default='Default headline')
|
||||
pub_date = meta.DateTimeField()
|
||||
|
||||
API_TESTS = """
|
||||
# No articles are in the system yet.
|
||||
|
||||
Reference in New Issue
Block a user