{{!
    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/>.
}}
{{!
    @template local_aiquestions/loading

    Template which defines the data shown when question are ready.

    Classes required for JS:
    * none

    Data attributes required for JS:
    * none

    Example context (json):
    {
        "wwwroot": "https://moodle.example.com",
        "courseid": "2",
        "uniqid" : "1234567890",
        "userid" : "2",
        "cron": "0"
    }
}}
{{#cron}}
    <div class="alert-warning">
        {{#str}}cronoverdue, local_aiquestions{{/str}}
    </div>
{{/cron}}
<p class='local_aiquestions_created' id="local_aiquestions_success">
    {{#str}}generating, local_aiquestions{{/str}}
    <br>
    {{#pix}}i/loading, core{{/pix}}
</p>
<div id="local_aiquestions_info">
    {{>local_aiquestions/bar}}
</div>

<div id="local_aiquestions_uniqid" style="display:none;">{{uniqid}}</div>
<div id="local_aiquestions_userid" style="display:none;">{{userid}}</div>

<p class="local_aiquestions_backtocourse"><a href='{{wwwroot}}/course/view.php?id={{courseid}}'>
    {{#str}}backtocourse, local_aiquestions{{/str}}</a></p>
<p class="local_aiquestions_gotoquestionbank"><a href='{{wwwroot}}/question/edit.php?courseid={{courseid}}'>
    {{#str}}gotoquestionbank, local_aiquestions{{/str}}</a></p>
<p class="local_aiquestions_generatemore"><a href='{{wwwroot}}/local/aiquestions/story.php?courseid={{courseid}}'>
    {{#str}}generatemore, local_aiquestions{{/str}}</a></p>
