from django.db import models
from ingredients.models import Ingredient


# Create your models here.
class Item(models.Model):
    ingredient = models.ForeignKey(Ingredient, on_delete=models.CASCADE)
    amount = models.DecimalField(max_digits=5, decimal_places=2)

    def __str__(self):
        return self.ingredient.name + ' ' + self.amount


9288517b1d0531bf2e28633b769c8302ef18758e
<mask token>


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

<mask token>


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

    def __str__(self):
        return self.ingredient.name + ' ' + self.amount

<mask token>


class Item(models.Model):
    ingredient = models.ForeignKey(Ingredient, on_delete=models.CASCADE)
    amount = models.DecimalField(max_digits=5, decimal_places=2)

    def __str__(self):
        return self.ingredient.name + ' ' + self.amount

from django.db import models
from ingredients.models import Ingredient


class Item(models.Model):
    ingredient = models.ForeignKey(Ingredient, on_delete=models.CASCADE)
    amount = models.DecimalField(max_digits=5, decimal_places=2)

    def __str__(self):
        return self.ingredient.name + ' ' + self.amount

from django.db import models
from ingredients.models import Ingredient


# Create your models here.
class Item(models.Model):
    ingredient = models.ForeignKey(Ingredient, on_delete=models.CASCADE)
    amount = models.DecimalField(max_digits=5, decimal_places=2)

    def __str__(self):
        return self.ingredient.name + ' ' + self.amount

