Created
May 21, 2012 19:58
-
-
Save iDiserrollador/2764305 to your computer and use it in GitHub Desktop.
models
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 *-* | |
from django.db import models | |
class Propietario(models.Model): | |
propietario = models.CharField(max_length=255) | |
class Vehiculo(models.Model): | |
clase = models.CharField(max_length=255) | |
marca = models.CharField(max_length=25) | |
combustible = models.CharField(max_length=15) | |
carroseria = models.CharField(max_length=25) | |
class DetallePropitario(models.Model): | |
vehiculo = models.ForeignKey(Vehiculo) | |
propietario = models.ForeignKey(Propietario) | |
estado = models.BooleanField() | |
class Placa(models.Model): | |
numero = models.CharField(max_length=15) | |
estado = models.BooleanField() | |
vehiculo = models.ForeignKey(Vehiculo) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment