E
E
Elena Stepanova2015-04-08 15:32:40
Django
Elena Stepanova, 2015-04-08 15:32:40

Django 1.8 ignores models.TextField, what's wrong?

there are models

class Site(models.Model):
     name = models.CharField(max_length=200, verbose_name=u'Домен')
     webroot = models.TextField(blank=True),
     enabled = models.BooleanField(verbose_name=u'Активен', default=False)

class Templates(models.Model):
     site_id = models.ForeignKey('Site')
     tpl = models.TextField(),
     updtime = models.DateTimeField(auto_now=True)

manage.py check does not swear, When creating migrations, the webroot and tpl fields are not created, if they are manually entered into the migration, they are of course created, but they are not picked up in django.admin. What's wrong with them?
(base sqlite)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Rostislav Grigoriev, 2015-04-08
@Insolita

Why are there commas at the end of lines?
Most likely this is the reason. The commas are superfluous.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question