remove south, fix migration problems
parent
f3cb6c9edf
commit
9da195dcc8
|
@ -105,7 +105,7 @@ class Key(models.Model):
|
|||
return "Key with name {0}".format(self.name)
|
||||
|
||||
class CeleryTask(models.Model):
|
||||
created = models.DateTimeField(auto_now_add=True, default=now())
|
||||
created = models.DateTimeField(auto_now_add=True)
|
||||
task_id = models.CharField(max_length=255)
|
||||
user = models.ForeignKey(User, related_name="tasks", null=True)
|
||||
description = models.CharField(max_length=2048, null=True) # a description of what the task is
|
||||
|
@ -259,8 +259,7 @@ class Acq(models.Model):
|
|||
CHOICES = ((INDIVIDUAL,'Individual license'),(LIBRARY,'Library License'),(BORROWED,'Borrowed from Library'), (TESTING,'Just for Testing'), (RESERVE,'On Reserve'),(THANKED,'Already Thanked'),)
|
||||
created = models.DateTimeField(auto_now_add=True, db_index=True,)
|
||||
expires = models.DateTimeField(null=True)
|
||||
refreshes = models.DateTimeField(auto_now_add=True, default=now())
|
||||
refreshes.editable=True
|
||||
refreshes = models.DateTimeField(auto_now_add=True)
|
||||
refreshed = models.BooleanField(default=True)
|
||||
work = models.ForeignKey("Work", related_name='acqs', null=False)
|
||||
user = models.ForeignKey(User, related_name='acqs')
|
||||
|
|
|
@ -205,6 +205,10 @@ class IPAddressModelField(models.IPAddressField):
|
|||
defaults = {'form_class': IPAddressFormField}
|
||||
defaults.update(kwargs)
|
||||
return super(models.IPAddressField, self).formfield(**defaults)
|
||||
|
||||
def deconstruct(self):
|
||||
name, path, args, kwargs = super(models.IPAddressField, self).deconstruct()
|
||||
return name, path, args, kwargs
|
||||
|
||||
class Block(models.Model):
|
||||
library = models.ForeignKey(Library, related_name='ip_auths')
|
||||
|
@ -230,10 +234,6 @@ class Block(models.Model):
|
|||
ordering = ['lower',]
|
||||
|
||||
|
||||
from south.modelsinspector import add_introspection_rules
|
||||
escaped_package= __name__.replace('.', '\.')
|
||||
add_introspection_rules([], ['^' + escaped_package + '\.IPAddressModelField'])
|
||||
|
||||
# from http://en.wikipedia.org/wiki/Luhn_algorithm#Implementation_of_standard_Mod_10
|
||||
def luhn_checksum(card_number):
|
||||
def digits_of(n):
|
||||
|
|
|
@ -7,7 +7,6 @@ PyPDF2==1.23
|
|||
PyGithub==1.15.0
|
||||
PyYAML==3.11
|
||||
git+git://github.com/urschrei/pyzotero.git@v0.9.51
|
||||
South==0.8.4
|
||||
SPARQLWrapper==1.6.4
|
||||
WebOb==1.2.3
|
||||
WebTest==1.4.0
|
||||
|
|
|
@ -143,7 +143,6 @@ INSTALLED_APPS = (
|
|||
'django.contrib.staticfiles',
|
||||
'django_comments',
|
||||
'django.contrib.humanize',
|
||||
'south',
|
||||
'django_extensions',
|
||||
'regluit.frontend',
|
||||
'regluit.api',
|
||||
|
@ -310,8 +309,6 @@ LOGIN_ERROR_URL = '/accounts/login-error/'
|
|||
|
||||
USER_AGENT = "unglue.it.bot v0.0.1 <https://unglue.it>"
|
||||
|
||||
SOUTH_TESTS_MIGRATE = True
|
||||
|
||||
AUTH_PROFILE_MODULE = "core.UserProfile"
|
||||
|
||||
# The amount of the transaction that Gluejar takes
|
||||
|
@ -468,13 +465,6 @@ DROPBOX_KEY = '4efhwty5aph52bd' #for unglue.it, just.unglue.it
|
|||
# generated from rdhyee account
|
||||
GITHUB_PUBLIC_TOKEN = 'f702409f913d7f9046f93c677710f829e2b599c9'
|
||||
|
||||
# https://github.com/celery/django-celery/blob/master/docs/introduction.rst#for-django-17-and-newer
|
||||
SOUTH_MIGRATION_MODULES = {
|
||||
'default': 'social.apps.django_app.default.south_migrations',
|
||||
'tastypie': 'tastypie.south_migrations',
|
||||
'djcelery': 'djcelery.south_migrations',
|
||||
}
|
||||
|
||||
MOBIGEN_URL = "https://docker.gluejar.com:5001/mobigen"
|
||||
MOBIGEN_USER_ID = "admin"
|
||||
MOBIGEN_PASSWORD = "CXq5FSEQFgXtP_s"
|
||||
|
|
Loading…
Reference in New Issue