conditional selection in edit forms
Posted: Wed Apr 26, 2023 10:10 pm
Hello there! I'm trying to create a app to prepare medical recieps.
I want to create a system made to avoid wrong prescription while assisting the operator in the choice for the correct drug or exam.
I have three tabs: one for the prescription category (anti-pain, antibiotics, X-rays etc) with the ID and the name of the category; in another tab I've put the drugs, with the unique ID and the category ID as external key; in the last tab I've got the posology pattern, of course with the unique ID and the drug ID as external key. All relations were made at the database level.
I'm tryin to build a edit form for another table (prescriptions) to be populated with the data from three select object: one for the category, one for the drug and one for the posology, and I'd like to have the objects refreshed with the correct value as a selection is made (obviously in the "category->drug->posology" order).
How can I link the value of a select object to another one's query, and having the successive object ready with the right selection?
I want to create a system made to avoid wrong prescription while assisting the operator in the choice for the correct drug or exam.
I have three tabs: one for the prescription category (anti-pain, antibiotics, X-rays etc) with the ID and the name of the category; in another tab I've put the drugs, with the unique ID and the category ID as external key; in the last tab I've got the posology pattern, of course with the unique ID and the drug ID as external key. All relations were made at the database level.
I'm tryin to build a edit form for another table (prescriptions) to be populated with the data from three select object: one for the category, one for the drug and one for the posology, and I'd like to have the objects refreshed with the correct value as a selection is made (obviously in the "category->drug->posology" order).
How can I link the value of a select object to another one's query, and having the successive object ready with the right selection?