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 theme_universe/settings-additionalresources-filelist
19
 
20
    Boost Union settingsfilelist layout template.
21
 
22
    Context variables required for this template:
23
    * files - Array of files
24
 
25
    Example context (json):
26
    {
27
        "files": [
28
            {
29
                "fileicon": "<img class='icon ' alt='Image (JPEG)' title='Image (JPEG)' src='/theme/image.php/boost_union/core/1666077095/f/jpeg-64'>",
30
                "filename": "foo.jpg",
31
                "filetype": "image/jpeg",
32
                "filesize": "38.5 KB",
33
                "fileurlpersistent": "http://localhost/pluginfile.php/1/theme_universe/additionalresources/0/foo.jpg",
34
                "fileurlrevisioned": "http://localhost/pluginfile.php/1/theme_universe/additionalresources/1666077095/foo.jpg"
35
            }
36
        ]
37
    }
38
}}
39
 
40
<ul class="list-group px-0 mx-0 my-3 settings-additionalresources-filelist">
41
    {{#files}}
42
        <li class="border rounded mb-1 list-group-item d-flex justify-content-between">
43
            <div class="d-flex flex-row">
44
                {{{fileicon}}}
45
                <div class="ml-2">
46
                    <h6 class="mb-0">{{filename}}</h6>
47
                    <small>{{#str}}mimetype, tool_filetypes{{/str}}: {{filetype}}</small><br>
48
                    <small>{{#str}}size, repository{{/str}}: {{filesize}}</small><br>
49
                    <small>{{#str}}additionalresourcesfileurlpersistent, theme_universe{{/str}}: <a href="{{fileurlpersistent}}">{{fileurlpersistent}}</a></small><br>
50
                    <small>{{#str}}additionalresourcesfileurlrevisioned, theme_universe{{/str}}: <a href="{{fileurlrevisioned}}">{{fileurlrevisioned}}</a></small>
51
                </div>
52
            </div>
53
        </li>
54
    {{/files}}
55
</ul>