07-24-2023, 04:19 AM
I'd like to implement the following form in my web app. I am using spring/thymeleaf. Mutiple rows to be submitted as described below.
The Dispense Details should not have a limit to the number of items and when I submit all rows in the "dispense details" form must be inserted into the dispense table.
[![Patient Consult Form][1]][1]
ER Diagram
[![enter image description here][2]][2]
[![enter image description here][3]][3]
My first attempt to solve the problem is to add a dispense item one at a time as shown above. On clicking "Add Item" the dispense item is written to the DB and read again to be displayed under "Dispensed"
I'd rather have multiple rows of dispense items in a grid which are written to the Db in one go.
[1]:
[2]:
[3]:
The Dispense Details should not have a limit to the number of items and when I submit all rows in the "dispense details" form must be inserted into the dispense table.
[![Patient Consult Form][1]][1]
ER Diagram
[![enter image description here][2]][2]
[![enter image description here][3]][3]
My first attempt to solve the problem is to add a dispense item one at a time as shown above. On clicking "Add Item" the dispense item is written to the DB and read again to be displayed under "Dispensed"
I'd rather have multiple rows of dispense items in a grid which are written to the Db in one go.
[1]:
[2]:
[3]: