912 |
ariadna |
1 |
{{!
|
|
|
2 |
This file is part of Moodle - http://moodle.org/
|
|
|
3 |
|
|
|
4 |
Moodle is free software: you can redistribute it and/or modify
|
|
|
5 |
it under the terms of the GNU General Public License as published by
|
|
|
6 |
the Free Software Foundation, either version 3 of the License, or
|
|
|
7 |
(at your option) any later version.
|
|
|
8 |
|
|
|
9 |
Moodle is distributed in the hope that it will be useful,
|
|
|
10 |
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
11 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
12 |
GNU General Public License for more details.
|
|
|
13 |
|
|
|
14 |
You should have received a copy of the GNU General Public License
|
|
|
15 |
along with Moodle. If not, see <http://www.gnu.org/licenses/>.
|
|
|
16 |
}}
|
|
|
17 |
{{!
|
918 |
ariadna |
18 |
@template theme_universe_child/courseindex/cmcompletion
|
912 |
ariadna |
19 |
|
|
|
20 |
Displays a course index course-module entry.
|
|
|
21 |
|
|
|
22 |
Example context (json):
|
|
|
23 |
{
|
|
|
24 |
"state": 1,
|
|
|
25 |
"iscomplete": true,
|
|
|
26 |
"isincomplete": true,
|
|
|
27 |
"isfail": true,
|
|
|
28 |
"hasstate": true
|
|
|
29 |
}
|
|
|
30 |
}}
|
|
|
31 |
{{#iscomplete}}
|
|
|
32 |
<span class="completioninfo completion_complete" data-for="cm_completion" data-value="{{state}}">
|
|
|
33 |
{{#pix}} t/completion_complete, moodle, {{#str}} done, completion {{/str}} {{/pix}}
|
|
|
34 |
</span>
|
|
|
35 |
{{/iscomplete}}
|
|
|
36 |
{{#isincomplete}}
|
|
|
37 |
<span class="completioninfo completion_incomplete" data-for="cm_completion" data-value="{{state}}">
|
|
|
38 |
{{#pix}} t/completion_incomplete, moodle, {{#str}} todo, completion {{/str}} {{/pix}}
|
|
|
39 |
</span>
|
|
|
40 |
{{/isincomplete}}
|
|
|
41 |
{{#isfail}}
|
|
|
42 |
<span class="completioninfo completion_fail" data-for="cm_completion" data-value="{{state}}">
|
|
|
43 |
{{#pix}} t/completion_fail, moodle, {{#str}} failed, completion {{/str}} {{/pix}}
|
|
|
44 |
</span>
|
|
|
45 |
{{/isfail}}
|
|
|
46 |
{{^hasstate}}
|
|
|
47 |
<span class="completioninfo completion_none" data-for="cm_completion" data-value="{{state}}"></span>
|
|
|
48 |
{{/hasstate}}
|