MDL-37624 calendar: Added location support
[moodle.git] / calendar / templates / event_summary_body.mustache
CommitLineData
68c3e21a
SL
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_calendar/event_summary_body
19
20 This template renders the body of calendar events summary modal.
21
22 Example context (json):
23 {
24 "timestart": 1490320388,
25 "description": "An random event description",
ef4e04ee 26 "location": "13th floor, building 42",
4cc382d5
SL
27 "eventtype": "User",
28 "source": "Ical imported",
29 "groupname": "Group 1"
68c3e21a
SL
30 }
31}}
2dbfb484 32<div{{!
f0fc8a19 33 }} class="summary-modal-container"{{!
2dbfb484
AN
34 }} data-region="summary-modal-container"{{!
35 }} data-event-id="{{id}}"{{!
36 }} data-event-title="{{name}}"{{!
e00aed51 37 }} data-event-count="{{eventcount}}"{{!
2dbfb484
AN
38 }} data-event-="{{repeatid}}"{{!
39 }} data-action-event="{{isactionevent}}"{{!
40 }} data-edit-url="{{editurl}}"{{!
41 }}>
4febb36e
RW
42 <div class="container-fluid">
43 <div class="row">
44 <div class="col-xs-1">{{#pix}} i/calendareventtime, core, {{#str}} when, core_calendar {{/str}} {{/pix}}</div>
45 <div class="col-xs-11">{{#userdate}} {{timestart}}, {{#str}} strftimerecentfull {{/str}} {{/userdate}}</div>
46 </div>
47 <div class="row m-t-1">
48 <div class="col-xs-1">{{#pix}} i/calendar, core, {{#str}} eventtype, core_calendar {{/str}} {{/pix}}</div>
49 <div class="col-xs-11">{{eventtype}}</div>
50 </div>
51 {{#description}}
52 <div class="row m-t-1">
53 <div class="col-xs-1">{{#pix}} i/calendareventdescription, core, {{#str}} description {{/str}} {{/pix}}</div>
f0fc8a19 54 <div class="description-content col-xs-11">{{{.}}}</div>
4febb36e
RW
55 </div>
56 {{/description}}
ef4e04ee
MH
57 {{#location}}
58 <div class="row m-t-1">
59 <div class="col-xs-1">{{#pix}} i/location, core, {{#str}} location {{/str}} {{/pix}}</div>
60 <div class="location-content col-xs-11">{{{.}}}</div>
61 </div>
62 {{/location}}
89260305
RW
63 {{#isactionevent}}
64 <div class="row m-t-1">
65 <div class="col-xs-1">{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}</div>
66 <div class="col-xs-11"><a href="{{course.viewurl}}">{{{course.fullname}}}</a></div>
67 </div>
68 {{/isactionevent}}
4febb36e
RW
69 {{#iscategoryevent}}
70 <div class="row m-t-1">
71 <div class="col-xs-1">{{#pix}} i/categoryevent, core, {{#str}} category {{/str}} {{/pix}}</div>
72 <div class="col-xs-11">{{{category.nestedname}}}</div>
73 </div>
74 {{/iscategoryevent}}
75 {{#iscourseevent}}
76 <div class="row m-t-1">
77 <div class="col-xs-1">{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}</div>
78 <div class="col-xs-11"><a href="{{url}}">{{{course.fullname}}}</a></div>
79 </div>
80 {{/iscourseevent}}
81 {{#groupname}}
82 <div class="row m-t-1">
83 <div class="col-xs-1">{{#pix}} i/courseevent, core, {{#str}} course {{/str}} {{/pix}}</div>
84 <div class="col-xs-11"><a href="{{url}}">{{{course.fullname}}}</a></div>
85 </div>
86 <div class="row m-t-1">
87 <div class="col-xs-1">{{#pix}} i/groupevent, core, {{#str}} group {{/str}} {{/pix}}</div>
88 <div class="col-xs-11">{{{groupname}}}</div>
89 </div>
90 {{/groupname}}
91 {{#subscription}}
92 {{#displayeventsource}}
20a5056d
SL
93 <div class="row m-t-1">
94 <div class="col-xs-1">{{#pix}} i/rss, core, {{#str}} eventsource, core_calendar {{/str}} {{/pix}}</div>
95 <div class="col-xs-11">
96 {{#subscriptionurl}}
97 <p><a href="{{subscriptionurl}}">{{#str}}subscriptionsource, core_calendar, {{{subscriptionname}}}{{/str}}</a></p>
98 {{/subscriptionurl}}
99 {{^subscriptionurl}}
100 <p>{{#str}}subscriptionsource, core_calendar, {{{subscriptionname}}}{{/str}}</p>
101 {{/subscriptionurl}}
102 </div>
4febb36e 103 </div>
4febb36e
RW
104 {{/displayeventsource}}
105 {{/subscription}}
106 </div>
68c3e21a 107</div>