activity.html.twig 3.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. {% if app.user.status != 5 %} <!-- main/template/default/course_home/activity.html.twig -->
  2. <div class="accordion accordion-b4" id="course-tools">
  3. {% for block in blocks %}
  4. <div class="card">
  5. <div class="card-header" id="heading-{{ block.class }}">
  6. {% if block.title %}
  7. <h5 class="card-title">
  8. <a class="{{ ( block.title == 'Authoring') ? ' ' : 'collapse' }}" role="button" data-toggle="collapse" data-target="#collapse-{{ block.class }}" aria-expanded="{{ ( block.title == 'Authoring') ? 'true' : 'false' }}" aria-controls="collapse-{{ block.class }}">
  9. {{ block.title }}
  10. </a>
  11. </h5>
  12. {% endif %}
  13. </div>
  14. <div id="collapse-{{ block.class }}" class="collapse show" aria-labelledby="heading-{{ block.class }}" data-parent="#course-tools">
  15. <div class="grid-tools">
  16. {% if 'homepage_view'|api_get_setting == 'activity' %}
  17. {% for item in block.content %}
  18. <div class="col-md-4 course-tool">
  19. {{ item.extra|raw }}
  20. {{ item.visibility|raw }}
  21. {{ item.icon|raw }}
  22. {{ item.link|raw }}
  23. </div>
  24. {% endfor %}
  25. {% endif %}
  26. {% if 'homepage_view'|api_get_setting == 'activity_big' %}
  27. {% for item in block.content %}
  28. <div class="items-tools ">
  29. <div class="tools mt-3 mb-3">
  30. <div class="big_icon">
  31. {{ item.tool.image|raw }}
  32. </div>
  33. <div class="content pt-2 pb-2">
  34. {{ item.extra|raw }}
  35. {{ item.link|raw }}
  36. {% if item.visibility is not empty %}
  37. <div class="view">
  38. {{ item.visibility|raw }}
  39. </div>
  40. {% endif %}
  41. </div>
  42. </div>
  43. </div>
  44. {% endfor %}
  45. {% endif %}
  46. </div>
  47. </div>
  48. </div>
  49. {% endfor %}
  50. </div>
  51. {% else %}
  52. <div class="grid-tools">
  53. {% for block in blocks %}
  54. {% if 'homepage_view'|api_get_setting == 'activity_big' %}
  55. {% for item in block.content %}
  56. <div class="items-tools">
  57. <div class="tools mt-3 mb-3">
  58. <div class="big_icon">
  59. {{ item.tool.image|raw }}
  60. </div>
  61. <div class="content pt-2 pb-2">
  62. {{ item.extra|raw }}
  63. {{ item.link|raw }}
  64. {% if item.visibility is not empty %}
  65. <div class="view">
  66. {{ item.visibility|raw }}
  67. </div>
  68. {% endif %}
  69. </div>
  70. </div>
  71. </div>
  72. {% endfor %}
  73. {% endif %}
  74. {% endfor %}
  75. </div>
  76. {% endif %}