title: Class disappear from a tr line - Symfony
body: <p>I'm a little bit confused with this and I was hoping you could help me.</p>
  
  <p>Here is what I print:</p>
  
  <p><a href="https://i.stack.imgur.com/NCLli.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/NCLli.png" alt="print"></a></p>
  
  <p>As you can see there is 3 level: The first one is contrat (first tr) <br/> 
  The second one is the bold one (second tr)<br/>
  The third is the the lines following (third and fourth tr) </p>
  
  <p>My firefox debug is showing this</p>
  
  <p><a href="https://i.stack.imgur.com/X6FWf.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/X6FWf.png" alt="html"></a></p>
  
  <p>As you can see, you can find again the 3 level.</p>
  
  <p>The first one is <code>header_6</code> <br/>
  The second is <code>firstEnquete content_6</code><br/>
  The third is just <code>content_6</code><br/></p>
  
  <p>But what I don't understand is why my fourth tr has no class.</p>
  
  <p>I'm not showing the full code (I got condition for the differents level, but that's not that important here) but here is the structure :</p>
  
  <pre><code>{% set k_enq =0 %}
  {% set oldContrat = 0 %}
  {% for key, enquete in enquetes %}
      {% if enquete.contract_id != oldContrat %}
          {% set k_enq=k_enq+1 %}
      {% endif %}
      {% set oldContrat= enquete.contract_id %}
  
      {# first level #}
      &lt;tr id="header_{{ k_enq }}" onclick="toggleContrat(this.id);"&gt;
          &lt;td colspan="11" class="contractTR"&gt;&lt;span&gt;{{'Contract'|trans|upper}} {{enquete.contract_id}}&lt;/span&gt;
          &lt;/td&gt;
      &lt;/tr&gt;
  
      {# second level #}
      {% if mission != enquete.mission %}
          {% set mission = enquete.mission %}
              &lt;tr class="{{ enquete.mission }} firstEnquete content_{{ k_enq }}" style="display:none;"&gt;
              {% if enquete.is_pack %}
                  &lt;td class="pdvTaille2" style="width:40%;"&gt;
                      &lt;span style="color:#000000;"&gt;{{ enquete.code_mission }} - {{ enquete.nom_mission }}&lt;/span&gt;
                  &lt;/td&gt;
                  &lt;td class="periodeTaille2"&gt;{{ enquete.nom }}&lt;/td&gt;
                  &lt;td class="dateTaille periodeautorise"&gt;
                      {{ periodeAutorise|raw }}
                  &lt;/td&gt;
                  &lt;td class="dateTaille asaisirdate"&gt;
                      {% include('McFrontendBundle:Enquetes:asaisir-date.html.twig') with { enquete : enquete } %}
                  &lt;/td&gt;
                  &lt;td class="actions_"&gt;&lt;/td&gt;                   
            {% endif %}
            &lt;/tr&gt;
    {% endif %}&gt;
  
    {# third level (i'm not showing the td content it's not usefull) #}
    &lt;tr class="content_{{ k_enq }}" style="display:none;"
        &lt;td class="pdvTaille2"&gt;&lt;/td&gt;
        &lt;td class="periodeTaille2"&gt;&lt;/td&gt;
        &lt;td class="dateTaille periodeautorise"&gt;&lt;/td&gt;
        &lt;td class="dateTaille asaisirdate"&gt;&lt;/td&gt;
        &lt;td colspan="4"&gt;&lt;/td&gt;
        &lt;td class="actions darkGreen"&gt;&lt;/td&gt;
     &lt;/tr&gt;
  {% endfor %}
  </code></pre>
  
  <p>Thanks for your help !</p>