SciPost Code Repository

Skip to content
Snippets Groups Projects
Commit cb5c0bdd authored by Jean-Sébastien Caux's avatar Jean-Sébastien Caux
Browse files

Add profile field to Contributor

parent 23fff561
No related branches found
No related tags found
No related merge requests found
# -*- coding: utf-8 -*-
# Generated by Django 1.11.4 on 2018-09-29 10:48
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('profiles', '0002_auto_20180916_1643'),
('scipost', '0014_auto_20180414_2218'),
]
operations = [
migrations.AddField(
model_name='contributor',
name='profile',
field=models.OneToOneField(blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, to='profiles.Profile'),
),
]
...@@ -42,7 +42,8 @@ class Contributor(models.Model): ...@@ -42,7 +42,8 @@ class Contributor(models.Model):
All *science* users of SciPost are Contributors. All *science* users of SciPost are Contributors.
username, password, email, first_name and last_name are inherited from User. username, password, email, first_name and last_name are inherited from User.
""" """
profile = models.OneToOneField('profiles.Profile', on_delete=models.PROTECT,
null=True, blank=True)
user = models.OneToOneField(settings.AUTH_USER_MODEL, on_delete=models.PROTECT, unique=True) user = models.OneToOneField(settings.AUTH_USER_MODEL, on_delete=models.PROTECT, unique=True)
invitation_key = models.CharField(max_length=40, blank=True) invitation_key = models.CharField(max_length=40, blank=True)
activation_key = models.CharField(max_length=40, blank=True) activation_key = models.CharField(max_length=40, blank=True)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment