title: can't hide elements using jquery and twig
body: <p>I'm trying to hide an element called request-form-display from a page depending if I use the minus button or the plus button. I used diferent ways googling, but I get the same results. I'm talking about something like this:</p>
  
  <pre><code>   if($('.plus{{i}}').data('clicked')) {
          $('#request-form-display{{i}}').show();
      };
      if($('.minus{{i}}').data('clicked')){
          $('#request-form-display{{i}}').hide();
      }
      &lt;i class="glyphicon glyphicon-plus plus{{i}}"&gt;&lt;/i&gt;
      &lt;i class="glyphicon glyphicon-minus minus{{i}}" style="display: none"&gt;&lt;/i&gt;
  </code></pre>
  
  <p>the complete code context:</p>
  
  <pre><code>{% set i=1 %}
  {% for product in products %} 
      &lt;tr&gt;
          &lt;td&gt;{{product.code}}&lt;/td&gt;
          &lt;td&gt;{{product.name}}&lt;/td&gt;
          &lt;td&gt;{{product.typeString}}&lt;/td&gt;
          &lt;td&gt;{{product.node?product.node.name}}&lt;/td&gt;
          &lt;td id="pp" class="text-right"  &gt;
              {% if request is defined %}
                  &lt;a title="Create request" 
                     class="btn btn-sm btn-default"
                     onclick="javascript:loadModal($('#request-form-display{{i}}') ,'{{path('userBuyerProductRequestQuickCreate', {productId: product.id, bidId:bidId})}}');window.location='#productsSearchTable';$('.plus{{i}}').hide();$('.minus{{i}}').show();$('#request-form-display{{i}}').show();if($('.plus{{i}}').data('clicked')) {
                     $('#request-form-display{{i}}').show();
                     };
                     if($('.minus{{i}}').data('clicked')){
                     $('#request-form-display{{i}}').hide();
                     }"&gt;
                     &lt;i class="glyphicon glyphicon-plus plus{{i}}"&gt;&lt;/i&gt;
                     &lt;i class="glyphicon glyphicon-minus minus{{i}}" style="display: none"&gt;&lt;/i&gt;
                  &lt;/a&gt;
                  {% endif %}
              {% endif %}
          &lt;/td&gt;
          &lt;tr&gt;
              &lt;td colspan="4"&gt;
                  &lt;div class="table"&gt;
                      &lt;div id="request-form-display{{i}}" style="display:none"&gt;&lt;/div&gt;
                      {% set i=i+1 %}
                  &lt;/div&gt;
              &lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tr&gt;
  {% endfor %}
  </code></pre>