feat: Display Shopping List Item Recipe Refs (#2501)

* added recipe ref display to shopping list items

* added backend support for recipe notes

* added recipe note to item recipe ref display

* fixed note merge bug with 3+ notes

* tweak display

* lint

* updated alembic refs

---------

Co-authored-by: Hayden <64056131+hay-kot@users.noreply.github.com>
This commit is contained in:
Michael Genson
2023-08-21 12:18:37 -05:00
committed by GitHub
parent 50a92c165c
commit d6e4829e6f
8 changed files with 247 additions and 42 deletions

View File

@@ -35,6 +35,9 @@ class ShoppingListItemRecipeRefCreate(MealieModel):
recipe_scale: NoneFloat = 1
"""the number of times this recipe has been added"""
recipe_note: str | None = None
"""the original note from the recipe"""
@validator("recipe_quantity", pre=True)
def default_none_to_zero(cls, v):
return 0 if v is None else v