diff --git a/src/account/migrations/0016_auto_20180203_2022.py b/src/account/migrations/0016_auto_20180203_2022.py new file mode 100644 index 0000000000000000000000000000000000000000..86c2ae6dc33f0c16b7e8f1ea9489baf1e3d9cdd6 --- /dev/null +++ b/src/account/migrations/0016_auto_20180203_2022.py @@ -0,0 +1,23 @@ +# Generated by Django 2.0.1 on 2018-02-03 19:22 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('account', '0015_auto_20180203_2014'), + ] + + operations = [ + migrations.AlterField( + model_name='profile', + name='motivation', + field=models.TextField(blank=True, default=''), + ), + migrations.AlterField( + model_name='profile', + name='nick', + field=models.CharField(blank=True, default='', max_length=15), + ), + ] diff --git a/src/account/models.py b/src/account/models.py index 8e86ff99fb2d707a671af6cb5b92b540f8eb2874..da900ea17f179da18d9c525722bf52c203cea34d 100644 --- a/src/account/models.py +++ b/src/account/models.py @@ -22,8 +22,9 @@ class Profile(models.Model): join_date = models.DateTimeField(auto_now_add=True, editable=False) updated_at = models.DateTimeField(auto_now=True, editable=False) user = models.OneToOneField(User, related_name='profile', on_delete=models.CASCADE) - motivation = models.TextField(null=True) - nick = models.CharField(max_length=15, blank=True, null=True) + # TODO: Change the default to json render side + motivation = models.TextField(blank=True, default='') + nick = models.CharField(max_length=15, blank=True, default='') signed = models.BooleanField(default=False, null=False) groups = models.ManyToManyField(GroupChoice, related_name='profiles') # Homeworks=models.ForeignKey(Homework)