cascading combo boxes in editable table

cascading combo boxes in editable table


I have an editable table which have 2 combo boxes the first "consumables Types" is loaded, the second  "consumables" is not loaded at first (cause ), on the "Type" combo box change it loads the second  filtering it by the selected type

and it saves fine..

the problem happens on loading the already saved records

the first drop down is loaded with the saved value, the second needs assigning to the typeID to get all consumableByTypeID with the saved type ID in each row to load the right selection in the second combo box to load the saved id in it


I guess the best way to handle that situation is to put "consumables" combo box inside a web block. Web block should receive a TypeId. Then put WB inside table records