templates/sonata/list_fields/list_lot_target_plan.html.twig line 1

Open in your IDE?
  1. {% block field %}
  2.     <td class="lot-plan" style="position: relative; height: 150px;">
  3.         {% set plan = object.getPlan() %}
  4.         {% if plan is not null %}
  5.             {% set filename = plan.getUnserializedFilename() %}
  6.             {% if filename is not empty %}
  7.                 <img class="minia-plan clickable-image listing-plan" data-toggle="modal" data-backdrop="static" data-target="#planModal-{{ object.id }}" height="130" src="{{ asset('/uploads/pieces_jointes/' ~ filename) }}" alt="Plan du lot" loading="lazy"/>
  8.             {% endif %}
  9.         {% endif %}
  10.     </td>
  11.     {% if plan is not null %}
  12.         {% set filename = plan.getUnserializedFilename() %}
  13.         {% if filename is not empty %}
  14.             <div class="modal fade" id="planModal-{{ object.id }}" tabindex="-1" role="dialog" aria-labelledby="planModalLabel-{{ object.id }}" aria-hidden="true">
  15.                 <div class="modal-dialog" role="document">
  16.                     <div class="modal-content">
  17.                         <div class="modal-header">
  18.                             <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  19.                                 <span aria-hidden="true">&times;</span>
  20.                             </button>
  21.                         </div>
  22.                         <div class="modal-body">
  23.                             <img class="minia-plan minia-plan-white" width="100%" src="{{ asset('/uploads/pieces_jointes/' ~ filename) }}" alt="Plan du lot"/>
  24.                         </div>
  25.                     </div>
  26.                 </div>
  27.             </div>
  28.         {% endif %}
  29.     {% endif %}
  30. {% endblock %}