@TeeSee1
First of all thank you for your time that you took to look into my sample app and your feedback.
My guess is you are creating a ‘calculator’ app and not really a production order system?
You are kind of correct. It is “not yet” a production order system. At this moment, it is still just an app to store & manage;
- How many sizes are created for that specific product
- The qty. of production per size of that specific product
- What kind of materials are used for that specific product
- What kinds of materials are available to use, and the MOQ and unit price (which I forgot to include in the Material Table)
and from this data, it’s able to calculate;
- How much materials are needed to manufacture a specific product
- The total cost per material
- Total cost per product
People in my company will take a look at these numbers and if they are satisfied, only then they will proceed to make an order of materials.
So RECIPES have to reference SIZE table in order to retrieve the production qty. There is no way around it. (There is no way to get to the production qty via PRODUCTS and MATERIALS).
As for the PRODUCTS reference in RECIPES, you can remove it because the PRODUCT to produce is available in the SIZE row which you have to access anyway.
Going back to this part of your post, this is where I’m kind of stuck? I guess.
So as an app maker probably the best way to go about it, is to remove the PRODUCTS reference in the RECIPES table and stick with just the SIZE reference in the RECIPES table.
But as an app user and as a UX POV, it’s kind of tedious to
[go into a Product]→[go into a size]→[add/fill in recipe for each size]
and also hard to look at the whole picture.
So what I did was, as you recommended;
- PRODUCTS reference (is_part_of) in the SIZE table
- SIZE reference (is_part_of) in the RECIPES table
So that when deleting, it would go through proper route to delete,
but for an easier overview for users, I have created;
- PRODUCTS reference in the RECIPES table
This way, just by going into the PRODUCTS detail view, you are able to
- See the whole recipe for that product
- add a material and select the proper size to create recipe
I’m not fully sure what you meant by;
You currently specify the materials needed directly in RECIPE rows. I would create a ‘validation’ table containing permissible PRODUCT-SIZE-MATERIAL combinations to make sure you do not enter incorrect materials.
But I’m guessing it’s about what I’ve mentioned above;
- add a material and select the proper size to create recipe
In my company I think this validation can be handled by the employees themselves without error.
This might be something I have to think about but not really a priority issue. Thank you for your concern.
I also noticed that when you create SIZE’s (production orders), they are not related to each other and wondered how they are bundled together to calculate the total production qty. My guess is you are creating a ‘calculator’ app and not really a production order system?
Going back to this part, SIZE doesn’t need to be related to each other nor to SIZEs of other PRODUCTS. As long as each SIZE is related to their parent Product, I can get the total production qty. by SELECT and SUM the qty. of each size.
For my specific use case, and what my company wants, I think I am on the right track. (maybe not but I have to keep moving, and if something goes wrong I’d have to come back)
One last question though.
My next move would be to create a PURCHASE ORDER for those materials in the RECIPE table, not by each material but by each vendor.
Taking the sample app as an example;
- Material 1 & Material 2 = Same Vendor (Vendor 1)
- Material 3 = Different Vendor (Vendor 2)
Product A needs;
20 of Material 1
200 of Material 2
300 of Material 3
Product B needs;
40 of Material 1
250 of Material 2
450 of Material 3
So I need to make a total purchase order to;
Vendor 1
60 of Material 1
450 of Material 2
Vendor 2
750 of Material 3
Are there any sample apps or templates that might lead me to the right path?
Again, thank you very much for your time!