universal disabled form template
[edumed.git] / curriculum / migrations / 0005_auto__add_field_curriculumcourse_accusative.py
1 # -*- coding: 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
8 class Migration(SchemaMigration):
9
10     def forwards(self, orm):
11         # Adding field 'CurriculumCourse.accusative'
12         db.add_column('curriculum_curriculumcourse', 'accusative',
13                       self.gf('django.db.models.fields.CharField')(default='', max_length=255),
14                       keep_default=False)
15
16         if not db.dry_run:
17             orm.CurriculumCourse.objects.all().update(accusative=models.F('title'))
18
19
20     def backwards(self, orm):
21         # Deleting field 'CurriculumCourse.accusative'
22         db.delete_column('curriculum_curriculumcourse', 'accusative')
23
24
25     models = {
26         'curriculum.competence': {
27             'Meta': {'ordering': "['order']", 'object_name': 'Competence'},
28             'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
29             'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
30             'order': ('django.db.models.fields.IntegerField', [], {}),
31             'section': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['curriculum.Section']"}),
32             'slug': ('django.db.models.fields.SlugField', [], {'max_length': '50'})
33         },
34         'curriculum.competencelevel': {
35             'Meta': {'ordering': "['competence', 'level']", 'object_name': 'CompetenceLevel'},
36             'competence': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['curriculum.Competence']"}),
37             'description': ('django.db.models.fields.TextField', [], {}),
38             'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
39             'level': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['curriculum.Level']"})
40         },
41         'curriculum.curriculum': {
42             'Meta': {'object_name': 'Curriculum'},
43             'course': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['curriculum.CurriculumCourse']"}),
44             'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
45             'identifier': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
46             'level': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['curriculum.CurriculumLevel']"}),
47             'title': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
48             'type': ('django.db.models.fields.CharField', [], {'max_length': '16'})
49         },
50         'curriculum.curriculumcourse': {
51             'Meta': {'object_name': 'CurriculumCourse'},
52             'accusative': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
53             'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
54             'slug': ('django.db.models.fields.CharField', [], {'max_length': '255', 'db_index': 'True'}),
55             'title': ('django.db.models.fields.CharField', [], {'max_length': '255'})
56         },
57         'curriculum.curriculumlevel': {
58             'Meta': {'object_name': 'CurriculumLevel'},
59             'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
60             'title': ('django.db.models.fields.CharField', [], {'max_length': '16', 'db_index': 'True'})
61         },
62         'curriculum.level': {
63             'Meta': {'ordering': "['order']", 'object_name': 'Level'},
64             'group': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
65             'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
66             'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
67             'order': ('django.db.models.fields.IntegerField', [], {}),
68             'slug': ('django.db.models.fields.CharField', [], {'max_length': '255'})
69         },
70         'curriculum.section': {
71             'Meta': {'ordering': "['order']", 'object_name': 'Section'},
72             'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
73             'name': ('django.db.models.fields.CharField', [], {'max_length': '255'}),
74             'order': ('django.db.models.fields.IntegerField', [], {}),
75             'slug': ('django.db.models.fields.SlugField', [], {'max_length': '50'})
76         }
77     }
78
79     complete_apps = ['curriculum']