Minor update.
[cas.git] / src / accounts / migrations / 0001_initial.py
index 87acc1b..01ffb9c 100644 (file)
@@ -1,38 +1,27 @@
 # -*- coding: utf-8 -*-
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-
-class Migration(SchemaMigration):
-
-    def forwards(self, orm):
-        # Adding model 'Service'
-        db.create_table(u'accounts_service', (
-            (u'id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
-            ('ordering', self.gf('django.db.models.fields.IntegerField')()),
-            ('name', self.gf('django.db.models.fields.CharField')(max_length=255)),
-            ('url', self.gf('django.db.models.fields.URLField')(max_length=200)),
-            ('image', self.gf('django.db.models.fields.files.ImageField')(max_length=100)),
-        ))
-        db.send_create_signal(u'accounts', ['Service'])
-
-
-    def backwards(self, orm):
-        # Deleting model 'Service'
-        db.delete_table(u'accounts_service')
-
-
-    models = {
-        u'accounts.service': {
-            'Meta': {'ordering': "('ordering',)", 'object_name': 'Service'},
-            u'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
-            'image': ('django.db.models.fields.files.ImageField', [], {'max_length': '100'}),
-            'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
-            'ordering': ('django.db.models.fields.IntegerField', [], {}),
-            'url': ('django.db.models.fields.URLField', [], {'max_length': '200'})
-        }
-    }
-
-    complete_apps = ['accounts']
\ No newline at end of file
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+    ]
+
+    operations = [
+        migrations.CreateModel(
+            name='Service',
+            fields=[
+                ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
+                ('ordering', models.IntegerField()),
+                ('name', models.CharField(max_length=255)),
+                ('url', models.URLField()),
+                ('image', models.ImageField(upload_to='accounts/service/')),
+            ],
+            options={
+                'ordering': ('ordering',),
+            },
+            bases=(models.Model,),
+        ),
+    ]