Skip to content

Commit

Permalink
Merge pull request #4 from mitodl/fix_aq_django_2
Browse files Browse the repository at this point in the history
Provide support for Django 2.0+
  • Loading branch information
amir-qayyum-khan authored Jul 17, 2018
2 parents 56eb85b + 68c3e95 commit 8d97d57
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion dj_elastictranscoder/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '0.9.6'
__version__ = '0.9.7'
3 changes: 2 additions & 1 deletion dj_elastictranscoder/migrations/0001_initial.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
from __future__ import unicode_literals

from django.db import models, migrations
import django.db.models.deletion


class Migration(migrations.Migration):
Expand All @@ -20,7 +21,7 @@ class Migration(migrations.Migration):
('message', models.TextField()),
('created_at', models.DateTimeField(auto_now_add=True)),
('last_modified', models.DateTimeField(auto_now=True)),
('content_type', models.ForeignKey(to='contenttypes.ContentType')),
('content_type', models.ForeignKey(to='contenttypes.ContentType', on_delete=django.db.models.deletion.CASCADE)),
],
),
]
3 changes: 1 addition & 2 deletions dj_elastictranscoder/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
from django.contrib.contenttypes.fields import GenericForeignKey



class EncodeJob(models.Model):
STATE_CHOICES = (
(0, 'Submitted'),
Expand All @@ -13,7 +12,7 @@ class EncodeJob(models.Model):
(4, 'Complete'),
)
id = models.CharField(max_length=100, primary_key=True)
content_type = models.ForeignKey(ContentType)
content_type = models.ForeignKey(ContentType, on_delete=models.CASCADE)
object_id = models.PositiveIntegerField()
state = models.PositiveIntegerField(choices=STATE_CHOICES, default=0, db_index=True)
content_object = GenericForeignKey()
Expand Down

0 comments on commit 8d97d57

Please sign in to comment.