Browse Source

Change Proposicao.data_envio to nullable

pull/6/head
Marcio Mazza 10 years ago
parent
commit
8b2531e936
  1. 19
      materia/migrations/0002_auto_20150619_1807.py
  2. 3
      materia/models.py

19
materia/migrations/0002_auto_20150619_1807.py

@ -0,0 +1,19 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('materia', '0001_initial'),
]
operations = [
migrations.AlterField(
model_name='proposicao',
name='data_envio',
field=models.DateTimeField(null=True),
),
]

3
materia/models.py

@ -163,7 +163,8 @@ class Proposicao(models.Model):
materia = models.ForeignKey(MateriaLegislativa, blank=True, null=True) # cod_materia materia = models.ForeignKey(MateriaLegislativa, blank=True, null=True) # cod_materia
autor = models.ForeignKey(Autor) # cod_autor autor = models.ForeignKey(Autor) # cod_autor
tipo = models.ForeignKey(TipoProposicao) # tip_proposicao tipo = models.ForeignKey(TipoProposicao) # tip_proposicao
data_envio = models.DateTimeField() # dat_envio # XXX data_envio was not null, but actual data said otherwise!!!
data_envio = models.DateTimeField(null=True) # dat_envio
data_recebimento = models.DateTimeField(blank=True, null=True) # dat_recebimento data_recebimento = models.DateTimeField(blank=True, null=True) # dat_recebimento
txt_descricao = models.CharField(max_length=100) # txt_descricao txt_descricao = models.CharField(max_length=100) # txt_descricao
cod_mat_ou_doc = models.IntegerField(blank=True, null=True) # cod_mat_ou_doc cod_mat_ou_doc = models.IntegerField(blank=True, null=True) # cod_mat_ou_doc

Loading…
Cancel
Save