Skip to content
Snippets Groups Projects
Unverified Commit b11c8c22 authored by Sébastien Gaya's avatar Sébastien Gaya Committed by GitHub
Browse files

Merge branch 'main' into server-update-websites

parents dbbac9a3 90e8ba78
No related branches found
No related tags found
No related merge requests found
......@@ -75,7 +75,7 @@ class Communication::Website::Agenda::Event < ApplicationRecord
scope :for_category, -> (category_id) { joins(:categories).where(communication_website_categories: { id: category_id }).distinct }
scope :future, -> { where('from_day > :today', today: Date.today).ordered_asc }
scope :future_or_current, -> { where('from_day <= :today', today: Date.today).ordered_asc }
scope :future_or_current, -> { where('from_day >= :today', today: Date.today).ordered_asc }
scope :current, -> { where('(from_day <= :today AND to_day IS NULL) OR (from_day <= :today AND to_day >= :today)', today: Date.today).ordered_asc }
scope :archive, -> { where('to_day < :today', today: Date.today).ordered_desc }
scope :past, -> { archive }
......
......@@ -14,10 +14,6 @@ authors:
- "<%= @about.translated_author.slug %>"
<% end %>
<% if @about.categories.any? %>
categories:
<% @about.categories.each do |category| %>
- "<%= category.slug_with_ancestors_slugs %>"
<% end %>
posts_categories:
<% @about.categories.each do |category| %>
- "<%= category.slug_with_ancestors_slugs %>"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment