view.html.twig 526 B

1234567891011121314151617
  1. {% set handled = false %}
  2. {% for block in handle_event('ViewAttachment', {'attachment': attachment, 'note': note, 'title': title}) %}
  3. {% set handled = true %}
  4. <div class="note-attachments-unit">
  5. {{ block | raw }}
  6. </div>
  7. {% endfor %}
  8. {% if not handled %}
  9. <div class="note-attachments-unit">
  10. {% if attachment.getFilename() is not null %}
  11. <a href="{{ attachment.getShowUrl(note) }}">{{ title }}</a>
  12. {% else %}
  13. {{ title }}
  14. {% endif %}
  15. </div>
  16. {% endif %}