source: remit/finance_core/migrations/0003_lengthen-transaction-name.py @ 2fb5a35

client
Last change on this file since 2fb5a35 was 2fb5a35, checked in by Alex Dehnert <adehnert@…>, 15 years ago

Increase the length of the transaction name field

Previously, the transaction name field was 40 characters. However, the
reimbursement request short description field was 50 characters. Therefore,
long request names could overflow the transaction's name field, causing
voucher approval to fail with a 500 error.

  • Property mode set to 100644
File size: 3.8 KB
Line 
1
2from south.db import db
3from django.db import models
4from finance_core.models import *
5
6class Migration:
7   
8    def forwards(self, orm):
9        "Write your forwards migration here"
10   
11   
12    def backwards(self, orm):
13        "Write your backwards migration here"
14   
15   
16    models = {
17        'finance_core.budgetarea': {
18            'account_number': ('django.db.models.fields.IntegerField', [], {'null': 'True', 'blank': 'True'}),
19            'always': ('django.db.models.fields.BooleanField', [], {'default': 'False', 'blank': 'True'}),
20            'budget_term': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['finance_core.BudgetTerm']"}),
21            'comment': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
22            'depth': ('django.db.models.fields.PositiveIntegerField', [], {}),
23            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
24            'interested': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
25            'name': ('django.db.models.fields.CharField', [], {'max_length': '50'}),
26            'numchild': ('django.db.models.fields.PositiveIntegerField', [], {'default': '0'}),
27            'owner': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
28            'path': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'}),
29            'use_owner': ('django.db.models.fields.BooleanField', [], {'default': 'False', 'blank': 'True'})
30        },
31        'finance_core.budgetareaterm': {
32            'budget_area': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['finance_core.BudgetArea']"}),
33            'budget_term': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['finance_core.BudgetTerm']"}),
34            'comment': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
35            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
36        },
37        'finance_core.budgetterm': {
38            'end_date': ('django.db.models.fields.DateField', [], {}),
39            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
40            'name': ('django.db.models.fields.CharField', [], {'max_length': '20'}),
41            'slug': ('django.db.models.fields.SlugField', [], {'max_length': '20', 'db_index': 'True'}),
42            'start_date': ('django.db.models.fields.DateField', [], {}),
43            'submit_deadline': ('django.db.models.fields.DateField', [], {})
44        },
45        'finance_core.lineitem': {
46            'amount': ('django.db.models.fields.DecimalField', [], {'max_digits': '7', 'decimal_places': '2'}),
47            'budget_area': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['finance_core.BudgetArea']"}),
48            'budget_term': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['finance_core.BudgetTerm']"}),
49            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
50            'label': ('django.db.models.fields.CharField', [], {'max_length': '60'}),
51            'layer': ('django.db.models.fields.IntegerField', [], {}),
52            'tx': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['finance_core.Transaction']"})
53        },
54        'finance_core.transaction': {
55            'desc': ('django.db.models.fields.TextField', [], {'blank': 'True'}),
56            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
57            'incurred_time': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
58            'name': ('django.db.models.fields.CharField', [], {'max_length': '60'}),
59            'tx_create_time': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'})
60        }
61    }
62   
63    complete_apps = ['finance_core']
Note: See TracBrowser for help on using the repository browser.