diff --git a/app/models/communication/website/agenda/event/with_time.rb b/app/models/communication/website/agenda/event/with_time.rb index 4f2078fd5b21324c44e2d47360fe7deadb85b7f6..9da9f67fc0c547fe7a5f253ab9d76ae608a01b1f 100644 --- a/app/models/communication/website/agenda/event/with_time.rb +++ b/app/models/communication/website/agenda/event/with_time.rb @@ -56,7 +56,7 @@ module Communication::Website::Agenda::Event::WithTime protected def set_time_zone - self.time_zone = Time.zone.name if self.time_zone.nil? + self.time_zone = website.default_time_zone if self.time_zone.blank? end def set_to_day diff --git a/app/views/admin/communication/websites/agenda/events/_dates.html.erb b/app/views/admin/communication/websites/agenda/events/_dates.html.erb index 7528bc5be65c40946c8b50059cabc20564d44fa2..68a6fb78ec37f336035a15fb9c6e716dbea88af8 100644 --- a/app/views/admin/communication/websites/agenda/events/_dates.html.erb +++ b/app/views/admin/communication/websites/agenda/events/_dates.html.erb @@ -21,7 +21,7 @@ day_format = detailed ? :full <%= l(event.to_hour, format: :time_only) if event.to_hour %> <% end %> <% end %> -<% unless event.from_hour.nil? && event.to_hour.nil? %> +<% unless event.from_hour.nil? && event.to_hour.nil? || event.time_zone == @website.default_time_zone %> <br> <%= t('admin.communication.website.agenda.events.formatted_time_zone', time_zone: event.time_zone) %> <% end %> \ No newline at end of file