from django.db import models

# Create your models here.
class Persona(models.Model):
    id = models.AutoField(primary_key = True)
    nombre = models.CharField(max_length = 200)
    apellidos = models.CharField(max_length = 200)
    edad = models.IntegerField()
    telefono = models.CharField(max_length =12)

    def __str__(self):
        return self.nombre


class Mascota(models.Model):
    id = models.AutoField(primary_key = True)
    nombre = models.CharField(max_length = 150)
    edad = models.IntegerField()
    persona = models.ForeignKey(Persona, on_delete = models.CASCADE)

    def __str__(self):
        return self.nombre

eaf6e9a40d3094cdcd61b862248fec486e1f7ab3
<mask token>


class Mascota(models.Model):
    id = models.AutoField(primary_key=True)
    nombre = models.CharField(max_length=150)
    edad = models.IntegerField()
    persona = models.ForeignKey(Persona, on_delete=models.CASCADE)

    def __str__(self):
        return self.nombre

<mask token>


class Persona(models.Model):
    <mask token>
    <mask token>
    <mask token>
    <mask token>
    <mask token>
    <mask token>


class Mascota(models.Model):
    id = models.AutoField(primary_key=True)
    nombre = models.CharField(max_length=150)
    edad = models.IntegerField()
    persona = models.ForeignKey(Persona, on_delete=models.CASCADE)

    def __str__(self):
        return self.nombre

<mask token>


class Persona(models.Model):
    <mask token>
    <mask token>
    <mask token>
    <mask token>
    <mask token>

    def __str__(self):
        return self.nombre


class Mascota(models.Model):
    id = models.AutoField(primary_key=True)
    nombre = models.CharField(max_length=150)
    edad = models.IntegerField()
    persona = models.ForeignKey(Persona, on_delete=models.CASCADE)

    def __str__(self):
        return self.nombre

<mask token>


class Persona(models.Model):
    id = models.AutoField(primary_key=True)
    nombre = models.CharField(max_length=200)
    apellidos = models.CharField(max_length=200)
    edad = models.IntegerField()
    telefono = models.CharField(max_length=12)

    def __str__(self):
        return self.nombre


class Mascota(models.Model):
    id = models.AutoField(primary_key=True)
    nombre = models.CharField(max_length=150)
    edad = models.IntegerField()
    persona = models.ForeignKey(Persona, on_delete=models.CASCADE)

    def __str__(self):
        return self.nombre

from django.db import models

# Create your models here.
class Persona(models.Model):
    id = models.AutoField(primary_key = True)
    nombre = models.CharField(max_length = 200)
    apellidos = models.CharField(max_length = 200)
    edad = models.IntegerField()
    telefono = models.CharField(max_length =12)

    def __str__(self):
        return self.nombre


class Mascota(models.Model):
    id = models.AutoField(primary_key = True)
    nombre = models.CharField(max_length = 150)
    edad = models.IntegerField()
    persona = models.ForeignKey(Persona, on_delete = models.CASCADE)

    def __str__(self):
        return self.nombre
