Statistics
| Branch: | Tag: | Revision:

root / snf-astakos-app / astakos / quotaholder_app / migrations / 0007_auto__del_field_commission_issue_time.py @ c3b42b86

History | View | Annotate | Download (4.1 kB)

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
        # Deleting field 'Commission.issue_time'
12
        db.delete_column('quotaholder_app_commission', 'issue_time')
13

    
14

    
15
    def backwards(self, orm):
16
        
17
        # User chose to not deal with backwards NULL issues for 'Commission.issue_time'
18
        raise RuntimeError("Cannot reverse this migration. 'Commission.issue_time' and its values cannot be restored.")
19

    
20

    
21
    models = {
22
        'quotaholder_app.commission': {
23
            'Meta': {'object_name': 'Commission'},
24
            'clientkey': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
25
            'issue_datetime': ('django.db.models.fields.DateTimeField', [], {}),
26
            'name': ('django.db.models.fields.CharField', [], {'default': "''", 'max_length': '4096'}),
27
            'serial': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
28
        },
29
        'quotaholder_app.holding': {
30
            'Meta': {'unique_together': "(('holder', 'source', 'resource'),)", 'object_name': 'Holding'},
31
            'holder': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'db_index': 'True'}),
32
            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
33
            'limit': ('snf_django.lib.db.fields.IntDecimalField', [], {'max_digits': '38', 'decimal_places': '0'}),
34
            'resource': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
35
            'source': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'}),
36
            'usage_max': ('snf_django.lib.db.fields.IntDecimalField', [], {'default': '0', 'max_digits': '38', 'decimal_places': '0'}),
37
            'usage_min': ('snf_django.lib.db.fields.IntDecimalField', [], {'default': '0', 'max_digits': '38', 'decimal_places': '0'})
38
        },
39
        'quotaholder_app.provision': {
40
            'Meta': {'object_name': 'Provision'},
41
            'holder': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'db_index': 'True'}),
42
            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
43
            'quantity': ('snf_django.lib.db.fields.IntDecimalField', [], {'max_digits': '38', 'decimal_places': '0'}),
44
            'resource': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
45
            'serial': ('django.db.models.fields.related.ForeignKey', [], {'related_name': "'provisions'", 'to': "orm['quotaholder_app.Commission']"}),
46
            'source': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'})
47
        },
48
        'quotaholder_app.provisionlog': {
49
            'Meta': {'object_name': 'ProvisionLog'},
50
            'delta_quantity': ('snf_django.lib.db.fields.IntDecimalField', [], {'max_digits': '38', 'decimal_places': '0'}),
51
            'holder': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
52
            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
53
            'issue_time': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
54
            'limit': ('snf_django.lib.db.fields.IntDecimalField', [], {'max_digits': '38', 'decimal_places': '0'}),
55
            'log_time': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
56
            'name': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
57
            'reason': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
58
            'resource': ('django.db.models.fields.CharField', [], {'max_length': '4096'}),
59
            'serial': ('django.db.models.fields.BigIntegerField', [], {}),
60
            'source': ('django.db.models.fields.CharField', [], {'max_length': '4096', 'null': 'True'}),
61
            'usage_max': ('snf_django.lib.db.fields.IntDecimalField', [], {'max_digits': '38', 'decimal_places': '0'}),
62
            'usage_min': ('snf_django.lib.db.fields.IntDecimalField', [], {'max_digits': '38', 'decimal_places': '0'})
63
        }
64
    }
65

    
66
    complete_apps = ['quotaholder_app']