Bläddra i källkod

Ajout d'un lien direct vers les commentaires

François Drouhard 3 år sedan
förälder
incheckning
f31411ce63
2 ändrade filer med 13 tillägg och 13 borttagningar
  1. 12 12
      templates/videotheque/liste.html.twig
  2. 1 1
      templates/videotheque/voirfilm.html.twig

+ 12 - 12
templates/videotheque/liste.html.twig

@@ -72,17 +72,6 @@
 							{{ vu_icone | raw }}
 						</button>
 					</div>
-					<div class="ms-auto">
-						{%  if film.authered is defined %}
-							Ajouté par 
-							{{ film.authered.username }}
-							{% if film.authered.activeNow %}
-								<i class="fa fa-user text-success" data-bs-toggle="tooltip" title="En ligne"></i>
-							{% else %}
-								<i class="fa fa-user-o text-secondary" data-bs-toggle="tooltip" title="Hors ligne"></i>
-							{% endif %}
-						{% endif %}
-					</div>
 				{% endif %}
 			</div>
 			<div class="card-body">
@@ -104,7 +93,7 @@
 					</div>
 					<div class="">
 						{% if film.nbComs %}
-							<div class="badge bg-warning text-dark">{{ film.nbComs }} commentaire{% if film.nbComs > 1 %}s{% endif %}</div>
+							<a href="{{ path('videotheque_voirfilm', {'id': film.id}) }}#coms"><span class="badge bg-warning text-dark">{{ film.nbComs }} commentaire{% if film.nbComs > 1 %}s{% endif %}</span></a>
 						{% endif %}
 					</div>
 				</div>
@@ -135,6 +124,17 @@
 				</table>
 
 			</div>
+			<div class="card-footer text-end">
+				{%  if film.authered is defined %}
+					Ajouté par 
+					{{ film.authered.username }}
+					{% if film.authered.activeNow %}
+						<i class="fa fa-user text-success" data-bs-toggle="tooltip" title="En ligne"></i>
+					{% else %}
+						<i class="fa fa-user-o text-secondary" data-bs-toggle="tooltip" title="Hors ligne"></i>
+					{% endif %}
+				{% endif %}
+			</div>
 		</article>
 		{% endfor %}
 	</section>

+ 1 - 1
templates/videotheque/voirfilm.html.twig

@@ -144,7 +144,7 @@
             </div>
         </div>
         <div class="col-sm-4">
-            <div class="card border-info">
+            <div id="coms" class="card border-info">
                 <div class="card-header">
                     <h5>Commentaires</h5>
                 </div>