#388: change rdf:about links,
[redakcja.git] / apps / wiki / migrations / 0002_auto__add_theme.py
1 # encoding: utf-8
2 import datetime
3 from south.db import db
4 from south.v2 import SchemaMigration
5 from django.db import models
6
7 class Migration(SchemaMigration):
8     
9     def forwards(self, orm):
10         
11         # Adding model 'Theme'
12         db.create_table('wiki_theme', (
13             ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
14             ('name', self.gf('django.db.models.fields.CharField')(unique=True, max_length=50)),
15         ))
16         db.send_create_signal('wiki', ['Theme'])
17         
18         if not db.dry_run:
19             from django.core.management import call_command
20             call_command("loaddata", "initial_themes.yaml")
21
22     
23     
24     def backwards(self, orm):
25         
26         # Deleting model 'Theme'
27         db.delete_table('wiki_theme')
28     
29     
30     models = {
31         'wiki.theme': {
32             'Meta': {'object_name': 'Theme'},
33             'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
34             'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '50'})
35         }
36     }
37     
38     complete_apps = ['wiki']