overview.tpl 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <div class="exercise-container">
  2. {{ time_control }}
  3. {% if status is not empty %}
  4. <div class="alert alert-warning" role="alert">
  5. {{ status }}
  6. </div>
  7. {% endif %}
  8. {% if data.edit and data.session_id == api_get_session_id %}
  9. <div class="pull-right">
  10. <a class="btn btn-default" title="{{ "Edit"|get_lang }}" href="{{ _p.web_main }}exercise/admin.php?{{ _p.web_cid_query }}&id_session={{ _c.session_id }}&exerciseId={{ data.id }}">
  11. <i class="fa fa-pencil" aria-hidden="true"></i>
  12. </a>
  13. </div>
  14. {% endif %}
  15. <div class="title">
  16. <h2>{{ data.title }}</h2>
  17. </div>
  18. <div class="description">
  19. {{ data.description }}
  20. </div>
  21. {% if data.url is not empty %}
  22. <div class="exercise-btn">
  23. <a href="{{ data.url }}" class="btn btn-success btn-exercise">
  24. {{ label }}
  25. </a>
  26. </div>
  27. {% endif %}
  28. {% if count == data.attempts %}
  29. <div class="alert alert-error" role="alert">
  30. {{ "Attempts" |get_lang }} {{ count }} / {{ data.attempts }}
  31. </div>
  32. {% else %}
  33. <div class="attempts">
  34. <ul class="attempts-status">
  35. {% if count != 0 %}
  36. {% for i in 0..count - 1 %}
  37. <li><img src="{{ _p.web_css_theme }}images/attempt-check.png"></li>
  38. {% endfor %}
  39. {% endif %}
  40. {% if count != data.attempts %}
  41. {% for i in 0..data.attempts - count - 1 %}
  42. <li><img src="{{ _p.web_css_theme }}images/attempt-nocheck.png"></li>
  43. {% endfor %}
  44. {% endif %}
  45. </ul>
  46. <div class="details">
  47. {{ "Attempts" |get_lang }} {{ count }} / {{ data.attempts }}
  48. </div>
  49. </div>
  50. {% endif %}
  51. {% if table_result is not empty %}
  52. <div class="table-responsive">
  53. {{ table_result }}
  54. </div>
  55. {% endif %}
  56. </div>