model 如下 class Student(models.Model): user = models.ForeignKey('auth.User', null=True, blank=True, verbose_name=u'学员') created = models.DateTimeField(auto_now_add=True) last_modified = models.DateTimeField(auto_now=True)
def __unicode__(self): return self.user
然后运行 然后报错 coercing to Unicode: need string or buffer, User found