Proyectos de Subversion Moodle

Rev

Rev 1 | | Comparar con el anterior | Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
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/content
19
 
20
    The internal content of a section.
21
 
22
    Example context (json):
23
    {
24
        "num": 3,
25
        "id": 35,
26
        "controlmenu": "[tools menu]",
27
        "header": {
28
            "name": "Section title",
29
            "title": "<a href=\"http://moodle/course/view.php?id=5#section-0\">Section title</a>",
30
            "url": "#",
31
            "ishidden": true
32
        },
33
        "cmlist": {
34
            "cms": [
35
                {
36
                    "cmitem": {
37
                        "cmformat": {
38
                            "cmname": "<a class=\"aalink\" href=\"#\"><span class=\"instancename\">Forum example</span></a>",
39
                            "hasname": "true"
40
                        },
41
                        "id": 3,
42
                        "module": "forum",
43
                        "anchor": "activity-3",
44
                        "extraclasses": "newmessages"
45
                    }
46
                },
47
                {
48
                    "cmitem": {
49
                        "cmformat": {
50
                            "cmname": "<a class=\"aalink\" href=\"#\"><span class=\"instancename\">Assign example</span></a>",
51
                            "hasname": "true"
52
                        },
53
                        "id": 4,
54
                        "anchor": "activity-4",
55
                        "module": "assign",
56
                        "extraclasses": ""
57
                    }
58
                }
59
            ],
60
            "hascms": true
61
        },
62
        "ishidden": false,
63
        "iscurrent": true,
64
        "currentlink": "<span class=\"accesshide\">This topic</span>",
65
        "availability": {
66
            "info": "<span class=\"badge badge-info\">Hidden from students</span>",
67
            "hasavailability": true
68
        },
69
        "summary": {
70
            "summarytext": "Summary text!"
71
        },
72
        "controlmenu": {
73
            "menu": "<a href=\"#\" class=\"d-inline-block dropdown-toggle icon-no-margin\">Edit<b class=\"caret\"></b></a>",
74
            "hasmenu": true
75
        },
76
        "cmcontrols": "[Add an activity or resource]",
77
        "iscoursedisplaymultipage": true,
78
        "sectionreturnid": 0,
79
        "contentcollapsed": false,
80
        "insertafter": true,
81
        "numsections": 42,
82
        "sitehome": false,
83
        "highlightedlabel" : "Highlighted"
84
    }
85
}}
86
{{#singleheader}}
87
{{$ core_courseformat/local/content/section/header }}
88
    {{> core_courseformat/local/content/section/header }}
89
{{/ core_courseformat/local/content/section/header }}
90
{{/singleheader}}
91
{{#header}}
92
{{$ core_courseformat/local/content/section/header }}
93
    {{> core_courseformat/local/content/section/header }}
94
{{/ core_courseformat/local/content/section/header }}
95
{{/header}}
96
{{#restrictionlock}}
1441 ariadna 97
    <div class="align-self-center ms-2">
1 efrain 98
        {{#pix}}t/unlock, core{{/pix}}
99
    </div>
100
{{/restrictionlock}}
101
<div data-region="sectionbadges" class="sectionbadges d-flex align-items-center">
102
    {{$ core_courseformat/local/content/section/badges }}
103
        {{> core_courseformat/local/content/section/badges }}
104
    {{/ core_courseformat/local/content/section/badges }}
105
</div>
106
{{#controlmenu}}
1441 ariadna 107
        {{^displayonesection}}
108
            {{$ core_courseformat/local/content/section/controlmenu }}
109
                {{> core_courseformat/local/content/section/controlmenu }}
110
            {{/ core_courseformat/local/content/section/controlmenu }}
111
        {{/displayonesection}}
112
    {{/controlmenu}}
113
    {{#header}}
114
        {{#headerdisplaymultipage}}
115
            {{^displayonesection}}
116
                {{^controlmenu}}
117
                    <div class="section_goto bulk-hidden ms-auto" data-sectionid="{{id}}">
118
                        <a href="{{{url}}}"
119
                           class="btn btn-icon btn-light d-flex align-items-center justify-content-center icon-no-margin"
120
                           title="{{#str}}gotosection, course, {{name}}{{/str}}">
121
                            <span class="dir-rtl-hide">
122
                                {{#pix}}t/right, moodle{{/pix}}
123
                            </span>
124
                            <span class="dir-ltr-hide">
125
                                {{#pix}}t/left, moodle, {{#str}}gotosection, course, {{name}}{{/str}}{{/pix}}
126
                            </span>
127
                            <span class="sr-only">
128
                                {{#str}}gotosection, course, {{name}}{{/str}}
129
                            </span>
130
                        </a>
131
                    </div>
132
                {{/controlmenu}}
133
            {{/displayonesection}}
134
        {{/headerdisplaymultipage}}
135
    {{/header}}
1 efrain 136
</div>
137
<div id="coursecontentcollapse{{num}}"
138
    class="content {{^iscoursedisplaymultipage}}
139
        {{^sitehome}}course-content-item-content collapse {{^contentcollapsed}}show{{/contentcollapsed}}{{/sitehome}}
140
    {{/iscoursedisplaymultipage}}">
141
    <div class="{{#hasavailability}}description my-3{{/hasavailability}}" data-for="sectioninfo">
142
    {{#summary}}
143
        {{$ core_courseformat/local/content/section/summary }}
144
            {{> core_courseformat/local/content/section/summary }}
145
        {{/ core_courseformat/local/content/section/summary }}
146
    {{/summary}}
147
    {{#availability}}
148
        {{$ core_courseformat/local/content/section/availability }}
149
            {{> core_courseformat/local/content/section/availability }}
150
        {{/ core_courseformat/local/content/section/availability }}
151
    {{/availability}}
152
</div>
153
{{#cmsummary}}
154
    {{$ core_courseformat/local/content/section/cmsummary }}
155
        {{> core_courseformat/local/content/section/cmsummary }}
156
    {{/ core_courseformat/local/content/section/cmsummary }}
157
{{/cmsummary}}
158
{{#cmlist}}
159
    {{$ core_courseformat/local/content/section/cmlist }}
160
        {{> core_courseformat/local/content/section/cmlist }}
161
    {{/ core_courseformat/local/content/section/cmlist }}
162
{{/cmlist}}
163
{{{cmcontrols}}}
164
{{#insertafter}}
165
    {{#numsections}}
166
        {{$ core_courseformat/local/content/addsection}}
167
            {{> core_courseformat/local/content/addsection}}
168
        {{/ core_courseformat/local/content/addsection}}
169
    {{/numsections}}
170
{{/insertafter}}