Change DropDown list dynamically in Dropdown Field When we have parent Dropdown selected.

Hello,

What i am trying to achive is that i have a dropdown field named subtype which is dependent on parent dropdown type_2 (Dropdown field name).

I am trying to setup subtype dropdown list dynamically using dependency. But i am getting an issue, when i change the dropdown list dynamically my parent dropdown visiblity has been erased.

( When type_2 dropdown is AA then Subtype dropdon will be oi_status_list and If   type_2 dropdown is BB then subtype dropdown will be payment terms).

Could you please help me in how to implement this type of functionality.

See images for more understanding.