title: Adding cascading dropbox to dynamic form in knockoutJS
body: <p>I'm required to dynamically create forms based on json data coming from the server. The data is hierarchical and i'm using templates to create the form. </p>
  
  <p>I'm having trouble figuring out to add cascading dropbox to my form. The problem is that the objects are created dynamically, and when I create the dependent object I only know the id of the parent, but i don't have it's object to subscribe to. It can be assumed that the child is created after the father.</p>
  
  <p>This is a fragment of the data that illustrates the requirement</p>
  
  <pre><code>{"id":4, "name":"q", "description":"Parameter q", "type":"combo", "default":"1", 
      "options": {"A":1, "B":2, "C":3, "D":4}},
  {"id":4.1, "name":"q1", "description":"q Dependent", "type":"combo", 
   "default":"1", "parent" : 4 , 
   "options": {"A": {"A1":1.1, "A2":1.2}} ,
               "B": {"B1":2.1, "B2":2.2,"B3":2.3},
               "C": {"C1":3.1, "C2":3.2},
               "D": {"D1":4.1}},
  </code></pre>
  
  <p>parameter q1 is dependent on the values selected for parameter q.</p>
  
  <p>I'm not sure how to approach this problem. <a href="http://jsfiddle.net/7fJkh/" rel="nofollow">This</a> is what i've done so far - I will appreciate any guidance.</p>