{{!
    This file is part of Moodle - http://moodle.org/

    Moodle is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    Moodle is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
}}
<div id="quiz_stats-{{uniqid}}" class="local_quiz_stats_block">
  {{# has_courses_for_quiz }}
  <div class="quiz-list-wrapper">
    <select id="quiz-course-list" class="form-control">
      {{# courses_for_quiz}}
      <option data-courseid="{{ courseid }}">{{{ shortname }}}</option>
      {{/ courses_for_quiz}}
    </select>

    <select id="quiz-list" class="form-control">
      {{# quizzes_in_first_course}}
      <option data-courseid="{{ courseid }}" data-quizid="{{ quizid }}">{{{ quizname }}}</option>
      {{/ quizzes_in_first_course}}
    </select>
  </div>

  <div id="quiz-chart-area" class="chart">
    <canvas id="barChart"></canvas>
  </div>
  <div class="quiz-stats-error alert alert-danger" style="display:none">
    {{#str}}problemwhileloadingdata, local_edwiserpagebuilder{{/str}}
  </div>
  {{/ has_courses_for_quiz }}
</div>
{{#js}}
require(['local_edwiserpagebuilder/remuiblck/quizstats'], function(quizstats) {
quizstats.init('#quiz_stats-{{uniqid}}', "{{uniqid}}");
});
{{/js}}
