这是我的代码,我收到此错误
root@ubuntu:~/public_html/todolist# ./manage.py sql todo
SyntaxError: invalid syntax (models.py, line 28)
编码:
from django.db import models
# Create your models here.
class Todo(models.model):
name = models.CharField('Name',
max_lenght =200,
help_text = 'Enter the project name' )
def __unicode__(self):
return self.name
class Meta:
ordering = ('name',)
class TodoArticulo (models.Model):
fktodo = models.ForeignKey(Todo)
task = models.TextField('Task', help_text= ' Task Descripcion')
date = models.DateField()
def __unicode__(self):
return u'%s | %s' % (self.fktodo, self.task)
class Meta:
verbose_name= u 'Todo Task'
verbose_name_plural= 'Todo Tasks'