MDL-59750 core_calendar: better handling of event subscription
[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",
4cc382d5
SL
26 "eventtype": "User",
27 "source": "Ical imported",
28 "groupname": "Group 1"
68c3e21a
SL
29 }
30}}
2dbfb484
AN
31<div{{!
32 }} data-region="summary-modal-container"{{!
33 }} data-event-id="{{id}}"{{!
34 }} data-event-title="{{name}}"{{!
35 }} data-event-event-count="{{eventcount}}"{{!
36 }} data-event-="{{repeatid}}"{{!
37 }} data-action-event="{{isactionevent}}"{{!
38 }} data-edit-url="{{editurl}}"{{!
39 }}>
68c3e21a
SL
40 <h4>{{#str}} when, core_calendar {{/str}}</h4>
41 {{#userdate}} {{timestart}}, {{#str}} strftimerecentfull {{/str}} {{/userdate}}
42 <br>
548f5cf0
SL
43 {{#description}}
44 <h4>{{#str}} description {{/str}}</h4>
45 {{{description}}}
46 {{/description}}
68c3e21a
SL
47 <h4>{{#str}} eventtype, core_calendar {{/str}}</h4>
48 {{eventtype}}
00d2d344 49 {{#iscourseevent}}
c87ad4e5 50 <div><a href="{{url}}">{{course.fullname}}</a></div>
00d2d344 51 {{/iscourseevent}}
8afe9f8a 52 {{> core_calendar/event_subscription}}
4cc382d5 53 {{#groupname}}
7e365895
SL
54 <div><a href="{{url}}">{{{course.fullname}}}</a></div>
55 <div>{{{groupname}}}</div>
4cc382d5 56 {{/groupname}}
68c3e21a 57</div>