I have 3 table which is as followed:
School Table has following:
- schoolName (String type), Mutliple:NO
- classes (Class type), Mutliple:YES
Class Table has following:
- className(String type), Mutliple:NO
- students (Student type), Mutliple:YES
Student table has following:
- id (Long type), Mutliple:NO
- name (String type), Mutliple:NO
On my form, I have a container, bind with school collection, which has multiple lines of class.
Each line of class has 2 select fields on my form, one listing all the classnames. The other will list the student names based on the class selected on first select field. And each line is identified by $item
, because the binding of collection.
How do I code the field for student name listing?
I can bind the first select (listing class name) using $data.classList
. But how do I get the selected value from the first select ?