overview.tpl 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  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 data.attempts is not empty %}
  29. {% if count == data.attempts %}
  30. <div class="attempts error">
  31. {{ "Attempts" |get_lang }} {{ count }} / {{ data.attempts }}
  32. </div>
  33. {% else %}
  34. <div class="attempts">
  35. <ul class="attempts-status">
  36. {% if count != 0 %}
  37. {% for i in 0..count - 1 %}
  38. <li><img src="{{ _p.web_css_theme }}images/attempt-check.png"></li>
  39. {% endfor %}
  40. {% endif %}
  41. {% if count != data.attempts %}
  42. {% for i in 0..data.attempts - count - 1 %}
  43. <li><img src="{{ _p.web_css_theme }}images/attempt-nocheck.png"></li>
  44. {% endfor %}
  45. {% endif %}
  46. </ul>
  47. <div class="details">
  48. {{ "Attempts" |get_lang }} {{ count }} / {{ data.attempts }}
  49. </div>
  50. </div>
  51. {% endif %}
  52. {% endif %}
  53. {% if table_result is not empty %}
  54. <div class="table-responsive">
  55. {{ table_result }}
  56. </div>
  57. {% endif %}
  58. </div>