Skip to content

Commit

Permalink
Merge branch 'MDL-63119-34' of git://github.com/lameze/moodle into MO…
Browse files Browse the repository at this point in the history
…ODLE_34_STABLE
  • Loading branch information
David Monllao committed Sep 25, 2018
2 parents 816f9a5 + 0cd1bc0 commit 61859ec
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions calendar/classes/external/event_exporter.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@ protected function get_other_values(renderer_base $output) {
}
$values['url'] = $url->out(false);

// Override default formatted time to make sure the date portion of the time is always rendered.
$legacyevent = container::get_event_mapper()->from_event_to_legacy_event($event);
$values['formattedtime'] = calendar_format_event_time($legacyevent, time(), null, false);

if ($event instanceof action_event_interface) {
$actionrelated = [
'context' => $context,
Expand Down
2 changes: 1 addition & 1 deletion calendar/templates/event_summary_body.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
<div class="container-fluid">
<div class="row">
<div class="col-xs-1">{{#pix}} i/calendareventtime, core, {{#str}} when, core_calendar {{/str}} {{/pix}}</div>
<div class="col-xs-11">{{#userdate}} {{timestart}}, {{#str}} strftimerecentfull {{/str}} {{/userdate}}</div>
<div class="col-xs-11">{{{formattedtime}}}</div>
</div>
<div class="row m-t-1">
<div class="col-xs-1">{{#pix}} i/calendar, core, {{#str}} eventtype, core_calendar {{/str}} {{/pix}}</div>
Expand Down

0 comments on commit 61859ec

Please sign in to comment.