blob: ac45afd299059e816e668c76dc5f1ba253b494aa (
plain)
1
2
3
4
5
6
7
8
9
10
|
from django.db import models
from django.contrib.auth.models import User
class Person(models.Model):
name = models.CharField(maxlength=20)
class Article(models.Model):
title = models.CharField(maxlength=100)
body = models.TextField()
creator = models.ForeignKey(User)
|