1 |
efrain |
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 |
{{!
|
|
|
18 |
@template core_course/defaultactivitycompletion
|
|
|
19 |
|
|
|
20 |
Activity completion selector.
|
|
|
21 |
|
|
|
22 |
Example context (json):
|
|
|
23 |
{
|
|
|
24 |
"courseid": "2",
|
|
|
25 |
"sesskey": "AAAAAA",
|
|
|
26 |
"modules": [{
|
|
|
27 |
"id": "10",
|
|
|
28 |
"formattedname": "Assignment",
|
|
|
29 |
"canmanage": true,
|
|
|
30 |
"icon": "https://raw.githubusercontent.com/moodle/moodle/master/mod/assign/pix/monologo.svg",
|
|
|
31 |
"completionstatus": {
|
|
|
32 |
"string": "Manual",
|
|
|
33 |
"icon": "https://raw.githubusercontent.com/moodle/moodle/master/pix/i/completion-manual-enabled.png"
|
|
|
34 |
}
|
|
|
35 |
}],
|
|
|
36 |
"issite": true
|
|
|
37 |
}
|
|
|
38 |
}}
|
|
|
39 |
<div class="container-fluid">
|
|
|
40 |
<div class="row my-5 defaultactivitycompletion-header">
|
|
|
41 |
<div class="col">
|
|
|
42 |
{{#issite}}{{#str}}defaultactivitycompletionsite, core_completion{{/str}}{{/issite}}
|
|
|
43 |
{{^issite}}{{#str}}defaultactivitycompletioncourse, core_completion{{/str}}{{/issite}}
|
|
|
44 |
</div>
|
|
|
45 |
</div>
|
|
|
46 |
<div class="modules pt-3">
|
|
|
47 |
{{#modules}}
|
|
|
48 |
{{#canmanage}}
|
1441 |
ariadna |
49 |
{{<core/local/collapsable_section}}
|
|
|
50 |
{{$titlecontent}}
|
|
|
51 |
{{#activityicon}}
|
|
|
52 |
{{>core_course/activity_icon}}
|
|
|
53 |
{{/activityicon}}
|
|
|
54 |
<span class="activityname ms-3 mb-0">{{{formattedname}}}</span>
|
|
|
55 |
{{/titlecontent}}
|
|
|
56 |
{{$elementid}}activitycompletioncollapse-{{id}}{{/elementid}}
|
|
|
57 |
{{$extraclasses}}defaultactivitycompletion-item{{/extraclasses}}
|
|
|
58 |
{{$expandlabel}}
|
|
|
59 |
{{#str}} expandcategory, core, {{formattedname}} {{/str}}
|
|
|
60 |
{{/expandlabel}}
|
|
|
61 |
{{$collapselabel}}
|
|
|
62 |
{{#str}} collapsecategory, core, {{formattedname}} {{/str}}
|
|
|
63 |
{{/collapselabel}}
|
|
|
64 |
{{$extras}}
|
1 |
efrain |
65 |
data-region="activitycompletion-{{name}}"
|
1441 |
ariadna |
66 |
{{/extras}}
|
|
|
67 |
{{$sectioncontent}}
|
|
|
68 |
<hr>
|
1 |
efrain |
69 |
<div class="py-3">{{{formhtml}}}</div>
|
1441 |
ariadna |
70 |
{{/sectioncontent}}
|
|
|
71 |
{{/core/local/collapsable_section}}
|
|
|
72 |
<hr>
|
1 |
efrain |
73 |
{{/canmanage}}
|
|
|
74 |
{{/modules}}
|
|
|
75 |
</div>
|
|
|
76 |
</div>
|