Post

Replies

Boosts

Views

Activity

Comment on Unknown Errors From Inverse Relationship. Please Help!!!
You should set the "recipeList" relationship to be to-many. Then you build your recipes as Recipe entities, you build your collections of recipes as RecipeCollection entities", and you link them. Depending on exactly how you set up the relationships, a given recipe can be in only one collection (like a physical recipe in a folder), or it can be in many (like how Gmail tags work).
Jun ’22
Comment on creating a list from an array of structs
Absolutely! There are a lot of other ways to do this, too. You can store the name, amount, and bag values as separate state variables, then only instantiate a Drug object when you're ready to add it to the array. You could have a detail view to edit objects, and make the Add button add a new, blank Drug which you then edit to your desired values. All of these have tradeoffs. I recommend trying several styles to see which works best for you.
Jun ’22