inventory in my app

0
Hii guys, I need to make a product inventory for my project. For example if I add 10 tables to my inventory. A worker can make a reservation for this tables. If he makes a reservation for 5 tables the inventory amount must go to 5. (10-5 = 5). Can someone please help me. Its for a school project and im a little stuck here.
asked
1 answers
0

Hello Tim,

You can add one overview page to show the inventories what you have added and a new edit page to add the inventories as an admin. Now for user(here worker) to make a reservation for the inventories you have added, add a page where he can see the inventories you have added and provide a provision to select the inventories or to reserve them. After selecting, provide user a button to reserve the inventories he has selected. Upon hitting that button, in the backend, trigger a microflow which calculate the count of the inventories he has selected. Take the count of total inventories from DB. Add a list operation which does the subtract function of total inventories(or you can use the variable which does the subtraction of both) and the inventories user has selected. Take the count of that subtracted list and store in an attribute called amount.

Hope I helped you!

Edit: Added a picture of the MF. You can use this microflow for a calculated attribute as well.

answered