title: dynamic variable qweb odoo v8
body: <p>I have a web page where I need to create a number of fields and variables dynamically.</p>
  
  <p>Let me explain : On page One, I have a text field where i have to type the number of users I want. That number is passed as parameter to the next page (post method) and collected as nb_user on page Two.</p>
  
  <p>In the template.xml of page Two i have this code :</p>
  
  <pre><code>  &lt;form method="POST" class="col-md-8" action="/page_three"&gt;
  
  
    &lt;t t-foreach="nb_user" t-as="user"&gt;
      &lt;input type="text" name="comp_1_user_1" id="comp_1_user_1" class="form-control" placeholder="Computer user"/&gt;
  
     &lt;/t&gt;
  
  
  &lt;input type="submit" class="btn btn-primary" value="Validate"/&gt;
  </code></pre>
  
  <p>What I would like is that based on the number that is passed in post (nb_user), it should dynamically create that amount of text fields ans also create unique id (comp_1_user_1, comp_1_user_2 etc....) so that i can enter that data into my database. </p>
  
  <p>So if the parameter was 3 then it should create 3 text fields and create 3 variables comp_1_user_1, comp_1_user_2, comp_1_user_3.</p>
  
  <p>I hope I was clear enough .
  I am very new to Odoo and Qweb.</p>
  
  <p>Thanks for any help you can provide.</p>