text: # Generated by Django 2.2.10 on 2020-02-25 16:59
  
  from django.conf import settings
  from django.db import migrations, models
  import django.db.models.deletion
  
  
  class Migration(migrations.Migration):
  
      dependencies = [
          migrations.swappable_dependency(settings.AUTH_USER_MODEL),
          ('learning', '0002_registration_on_course'),
      ]
  
      operations = [
          migrations.AlterField(
              model_name='activity',
              name='access',
              field=models.CharField(choices=[('PUBLIC', 'Public'), ('EXISTING_COURSES', 'Only in courses'), ('COLLABORATORS_ONLY', 'Collaborators only'), ('PRIVATE', 'Private')], default='PUBLIC', max_length=20, verbose_name='Access'),
          ),
          migrations.AlterField(
              model_name='course',
              name='collaborators',
              field=models.ManyToManyField(related_name='collaborates_on_course', through='learning.CourseCollaborator', to=settings.AUTH_USER_MODEL, verbose_name='Collaborators'),
          ),
          migrations.AlterField(
              model_name='resource',
              name='access',
              field=models.CharField(choices=[('PUBLIC', 'Public'), ('EXISTING_ACTIVITIES', 'Only in activities'), ('COLLABORATORS_ONLY', 'Collaborators only'), ('PRIVATE', 'Private')], default='PUBLIC', max_length=20, verbose_name='Access'),
          ),
          migrations.AlterField(
              model_name='resource',
              name='description',
              field=models.TextField(blank=True, verbose_name='Description'),
          ),
          migrations.CreateModel(
              name='ResourceCollaborator',
              fields=[
                  ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                  ('role', models.CharField(choices=[('TEACHER', 'Teacher'), ('NON_EDITOR_TEACHER', 'Non-editor Teacher'), ('OWNER', 'Owner')], default='NON_EDITOR_TEACHER', max_length=20, verbose_name='Role')),
                  ('created', models.DateTimeField(auto_now_add=True, verbose_name='Since the')),
                  ('updated', models.DateTimeField(auto_now=True, verbose_name='Last updated the')),
                  ('collaborator', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='resource_collaborators', to=settings.AUTH_USER_MODEL, verbose_name='Collaborator')),
                  ('resource', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='resource_collaborators', to='learning.Resource', verbose_name='Course')),
              ],
              options={
                  'verbose_name': 'resource collaborator',
                  'verbose_name_plural': 'resource collaborators',
                  'ordering': ['resource__updated', 'role'],
                  'unique_together': {('collaborator', 'resource')},
              },
          ),
          migrations.CreateModel(
              name='ActivityCollaborator',
              fields=[
                  ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                  ('role', models.CharField(choices=[('TEACHER', 'Teacher'), ('NON_EDITOR_TEACHER', 'Non-editor Teacher'), ('OWNER', 'Owner')], default='NON_EDITOR_TEACHER', max_length=20, verbose_name='Role')),
                  ('created', models.DateTimeField(auto_now_add=True, verbose_name='Since the')),
                  ('updated', models.DateTimeField(auto_now=True, verbose_name='Last updated the')),
                  ('activity', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='activity_collaborators', to='learning.Activity', verbose_name='Course')),
                  ('collaborator', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='activity_collaborators', to=settings.AUTH_USER_MODEL, verbose_name='Collaborator')),
              ],
              options={
                  'verbose_name': 'activity collaborator',
                  'verbose_name_plural': 'activity collaborators',
                  'ordering': ['activity__updated', 'role'],
                  'unique_together': {('collaborator', 'activity')},
              },
          ),
          migrations.AddField(
              model_name='activity',
              name='collaborators',
              field=models.ManyToManyField(related_name='collaborates_on_activity', through='learning.ActivityCollaborator', to=settings.AUTH_USER_MODEL, verbose_name='Collaborators'),
          ),
          migrations.AddField(
              model_name='resource',
              name='collaborators',
              field=models.ManyToManyField(related_name='collaborates_on_resource', through='learning.ResourceCollaborator', to=settings.AUTH_USER_MODEL, verbose_name='Collaborators'),
          ),
      ]
  