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_courseformat/local/content/section/cmitem
|
|
|
19 |
|
|
|
20 |
Displays the course module list inside a course section.
|
|
|
21 |
|
|
|
22 |
Example context (json):
|
|
|
23 |
{
|
|
|
24 |
"cmformat": {
|
|
|
25 |
"cmname": "<a class=\"aalink\" href=\"#\"><span class=\"instancename\">Activity example</span></a>",
|
|
|
26 |
"hasname": "true",
|
|
|
27 |
"moveicon": "<i>[Move]</i>",
|
|
|
28 |
"indent": 2,
|
|
|
29 |
"afterlink": "<span class=\"badge bg-primary\">30 unread messages</span>",
|
|
|
30 |
"hasextras": true,
|
|
|
31 |
"extras": ["<span class=\"badge bg-secondary\">[extras]</span>"],
|
|
|
32 |
"completion": "<span class=\"badge bg-success\">Completed!</span>"
|
|
|
33 |
},
|
|
|
34 |
"id": 3,
|
|
|
35 |
"anchor": "module-3",
|
|
|
36 |
"module": "forum",
|
|
|
37 |
"extraclasses": "newmessages",
|
|
|
38 |
"indent": 0
|
|
|
39 |
}
|
|
|
40 |
}}
|
|
|
41 |
<li
|
|
|
42 |
class="activity activity-wrapper {{module}} modtype_{{module}} {{extraclasses}} {{#hasinfo}}hasinfo{{/hasinfo}} {{#indent}}indented{{/indent}}"
|
|
|
43 |
id="{{anchor}}"
|
|
|
44 |
data-for="cmitem"
|
|
|
45 |
data-id="{{id}}"
|
|
|
46 |
>
|
|
|
47 |
{{#cmformat}}
|
|
|
48 |
{{$ core_courseformat/local/content/cm}}
|
|
|
49 |
{{> core_courseformat/local/content/cm}}
|
|
|
50 |
{{/ core_courseformat/local/content/cm}}
|
|
|
51 |
{{/cmformat}}
|
|
|
52 |
</li>
|