Looking to allow user edits of data using Modal

I have an app that lists from an order as they are picked and brought to the loading dock before being placed on the truck.

The data is in a table and I want to use a modal form to allow the user to input changes.

There are three pieces of data that are needed from the loader:

  1. Units Picked (in case it is different than the order)
  2. Blue Tag Starting number - (a sequential inventory tag is placed on each item).
  3. Blue Tag Ending Number - (since these are sequential, the last number is calculated)

The modal works well as far as listing the selected row and accepting the data inputs. However I am not clear how to get the data from the modal form to update the table.

Should I add a button to the modal, or would I add loogic to the modal close process?

If the original table is populated by a query with data from your database then your modal should be a form where upon submission updates the database using whatever primary key you are using along with the changes made.

Thanks Scott! I was wondering if that might be the case.

I am actually using a database view based on the order details table and my plan was to write these records into a delivery details table. The reason I was doing it this way is that this project has two types of orders; pre-order (actually a reservation for product) and regular order (entire order to be delivered on next truck).

In this workflow, the picker decides how many of the "pre-order" units to include with the current delivery, so there is a difference in the ordered quantities and the delivered quantities which must be accounted for until the pre-order amount is delivered.

I will look to see if I can use a transition table to store this dataset and allow for the modal to do the edits.