{% import 'macro.html.twig' as macro %}
<li class="media">
  <div class="pull-left">
    <span class="glyphicon glyphicon-volume-down media-object"></span>
  </div>
  <div class="media-body">
    <div class="notification-body">
      {% set data = notification.content %}

      {% if data.type == 'classroom' %}
        {% set name = get_classroom_name() %}
      {% elseif data.type == 'course' %}
        {% set name = 'site.default.course'|trans %}
      {% endif %}

      {% set what = macro.link(data.title|purify_html, data.url) %}
      {{ 'notification.learn-notice'|trans({'%name%':name, '%what%':what})|raw }}
    </div>
    <div class="notification-footer">
     {{ notification.createdTime|date_format }}  
    </div>
  </div>
</li>
