1
0
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:
Adrian Holovaty
2005-08-25 22:51:30 +00:00
parent aec0a73d73
commit 25264c8604
36 changed files with 956 additions and 720 deletions

View File

@@ -23,10 +23,8 @@ namespace as custom methods.
from django.core import meta
class Article(meta.Model):
fields = (
meta.CharField('headline', maxlength=100),
meta.DateField('pub_date'),
)
headline = meta.CharField(maxlength=100)
pub_date = meta.DateField()
def __repr__(self):
return self.headline