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 core_grades/feedback_modal
19
 
20
    The body of the modal displayed when viewing feedback for a grade item.
21
 
22
    Context variables required for this template:
23
    * feedbacktext - The full text of the feedback.
24
    * user - Object containing information about the student.
25
        * picture - The image corresponding to the user.
26
        * fullname - The users full name.
27
        * additionalfield - Additional text displayed below the users full name (e.g. the users email address)
28
 
29
    Example context (json):
30
    {
31
        "feedbacktext": "<p>Example feedback text</p>",
32
        "user": {
33
            "picture": "<img src=\"http://example.com/pluginfile.php/14/user/icon/boost/f2\" class=\"userpicture\" width=\"40\" alt=\"\">",
34
            "fullname": "John Doe",
35
            "additionalfield": "johndoe@example.com"
36
        }
37
    }
38
}}
39
 
40
{{#user}}
41
    <div class="d-flex p-3">
42
        <div class="d-block pr-3">
43
            {{#picture}}
44
                {{{picture}}}
45
            {{/picture}}
46
            {{^picture}}
47
                <span class="userinitials"></span>
48
            {{/picture}}
49
        </div>
50
        <div class="d-block">
51
            <span class="p-0 font-weight-bold">
52
                {{fullname}}
53
            </span>
54
            {{#additionalfield}}
55
                <span class="d-block small">
56
                    {{additionalfield}}
57
                </span>
58
            {{/additionalfield}}
59
        </div>
60
    </div>
61
{{/user}}
62
<div class="box p-3">
63
    {{{feedbacktext}}}
64
</div>