Proyectos de Subversion Moodle

Rev

| 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 tool_lp/course_competency_statistics
19
 
20
    IDs required for JS:
21
    * none
22
 
23
    Classes required for JS:
24
    * none
25
 
26
    Data attributes required for JS:
27
    * none
28
 
29
    Context variables required for this template:
30
 
31
    See competency/classes/external/course_competency_statistics_exporter
32
 
33
    Example context (json):
34
    {
35
        "competencycount": 4,
36
        "canbegradedincourse": true,
37
        "canmanagecoursecompetencies": true,
38
        "proficientcompetencycount": 3,
39
        "proficientcompetencypercentage": 75,
40
        "proficientcompetencypercentageformatted": 75.0,
41
        "leastproficientcount": 1,
42
        "leastproficient": [
43
            { "id": 1, "shortname": "Comp 1", "idnumber": "C1" }
44
        ]
45
    }
46
 
47
}}
48
{{!
49
    Template statistics template.
50
}}
51
{{#competencycount}}
52
<hr class="hr-small" />
53
<div data-region="coursecompetencystatistics" class="mt-4 wrapper-fw">
54
    {{#canbegradedincourse}}
55
        {{< tool_lp/progress_bar}}
56
            {{$progresstext}}
57
                {{#str}}xcompetenciesproficientoutofyincourse, tool_lp, { "x": "{{proficientcompetencycount}}", "y": "{{competencycount}}" } {{/str}}
58
            {{/progresstext}}
59
            {{$percentage}}{{proficientcompetencypercentage}}{{/percentage}}
60
            {{$percentlabel}}{{proficientcompetencypercentageformatted}}&nbsp;%{{/percentlabel}}
61
        {{/tool_lp/progress_bar}}
62
    {{/canbegradedincourse}}
63
    {{#canmanagecoursecompetencies}}
64
    {{#leastproficientcount}}
65
    <div>
66
        <div>
67
            <div class="badge badge-info">{{#str}}competenciesmostoftennotproficientincourse, tool_lp{{/str}}</div>
68
        </div>
69
        <nav class="my-5 pb-0 border-bottom">
70
            <ul class="list-unstyled d-inline-flex">
71
            {{#leastproficient}}
72
                <li class="mr-4">
73
                <a href="#competency-info-link-{{id}}" class="d-block my-2">
74
                <div class="d-inline-flex"><h4 class="mb-0"><span class="shortname py-1 mr-2">{{{shortname}}}</span><div class="badge badge-info">{{idnumber}}</div></h4></div>
75
                </a>
76
                </li>
77
            {{/leastproficient}}
78
            </ul
79
        </nav>
80
    </div>
81
    {{/leastproficientcount}}
82
    {{/canmanagecoursecompetencies}}
83
</div>
84
{{/competencycount}}