3 from south.db import db
4 from south.v2 import SchemaMigration
5 from django.db import models
7 class Migration(SchemaMigration):
9 def forwards(self, orm):
11 # Adding field 'ClientVersionSource.client'
12 db.add_column('cloudcms_clientversionsource', 'client', self.gf('django.db.models.fields.related.ForeignKey')(default=1, to=orm['cloudcms.Client']), keep_default=False)
14 # Removing M2M table for field sources on 'Client'
15 db.delete_table('cloudcms_client_sources')
18 def backwards(self, orm):
20 # Deleting field 'ClientVersionSource.client'
21 db.delete_column('cloudcms_clientversionsource', 'client_id')
23 # Adding M2M table for field sources on 'Client'
24 db.create_table('cloudcms_client_sources', (
25 ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)),
26 ('client', models.ForeignKey(orm['cloudcms.client'], null=False)),
27 ('clientversionsource', models.ForeignKey(orm['cloudcms.clientversionsource'], null=False))
29 db.create_unique('cloudcms_client_sources', ['client_id', 'clientversionsource_id'])
33 'cloudcms.application': {
34 'Meta': {'object_name': 'Application'},
35 'app_url': ('django.db.models.fields.URLField', [], {'max_length': '200', 'null': 'True', 'blank': 'True'}),
36 'code': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
37 'extra_styles': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
38 'facebook_username': ('django.db.models.fields.CharField', [], {'max_length': '255', 'blank': 'True'}),
39 'favicon': ('feincms.module.medialibrary.fields.MediaFileForeignKey', [], {'blank': 'True', 'related_name': "'as_favicon'", 'null': 'True', 'to': "orm['medialibrary.MediaFile']"}),
40 'footer_bottom': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
41 'footer_top': ('django.db.models.fields.TextField', [], {'default': "''", 'blank': 'True'}),
42 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
43 'index_url': ('django.db.models.fields.CharField', [], {'default': "'/'", 'max_length': '255'}),
44 'linked_in_username': ('django.db.models.fields.CharField', [], {'max_length': '255', 'blank': 'True'}),
45 'logo': ('feincms.module.medialibrary.fields.MediaFileForeignKey', [], {'to': "orm['medialibrary.MediaFile']", 'null': 'True', 'blank': 'True'}),
46 'show_twitter_feed_on_top': ('django.db.models.fields.BooleanField', [], {'default': 'False', 'blank': 'True'}),
47 'site': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['sites.Site']"}),
48 'title': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
49 'twitter_username': ('django.db.models.fields.CharField', [], {'max_length': '255', 'blank': 'True'})
52 'Meta': {'object_name': 'Client'},
53 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
54 'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
55 'uid': ('django.db.models.fields.CharField', [], {'max_length': '255'})
57 'cloudcms.clientversionsource': {
58 'Meta': {'object_name': 'ClientVersionSource'},
59 'architecture': ('django.db.models.fields.CharField', [], {'max_length': '255', 'null': 'True', 'blank': 'True'}),
60 'client': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['cloudcms.Client']"}),
61 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
62 'link': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
63 'logo': ('feincms.module.medialibrary.fields.MediaFileForeignKey', [], {'to': "orm['medialibrary.MediaFile']", 'null': 'True', 'blank': 'True'}),
64 'os': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
65 'source_type': ('django.db.models.fields.CharField', [], {'max_length': '60'})
67 'medialibrary.category': {
68 'Meta': {'object_name': 'Category'},
69 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
70 'parent': ('django.db.models.fields.related.ForeignKey', [], {'blank': 'True', 'related_name': "'children'", 'null': 'True', 'to': "orm['medialibrary.Category']"}),
71 'slug': ('django.db.models.fields.SlugField', [], {'max_length': '150', 'db_index': 'True'}),
72 'title': ('django.db.models.fields.CharField', [], {'max_length': '200'})
74 'medialibrary.mediafile': {
75 'Meta': {'object_name': 'MediaFile'},
76 'categories': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['medialibrary.Category']", 'null': 'True', 'blank': 'True'}),
77 'copyright': ('django.db.models.fields.CharField', [], {'max_length': '200', 'blank': 'True'}),
78 'created': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
79 'file': ('django.db.models.fields.files.FileField', [], {'max_length': '255'}),
80 'file_size': ('django.db.models.fields.IntegerField', [], {'null': 'True', 'blank': 'True'}),
81 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
82 'type': ('django.db.models.fields.CharField', [], {'max_length': '12'})
85 'Meta': {'object_name': 'Site', 'db_table': "'django_site'"},
86 'domain': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
87 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
88 'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
92 complete_apps = ['cloudcms']