Les événements globaux sont affichés pour toutes les régions
This commit is contained in:
parent
2b9d59b2a2
commit
6a786a16c1
@ -26,8 +26,8 @@ class Event < ActiveRecord::Base
|
||||
"#{year}-#{month.to_i-1}-23",
|
||||
"#{month == '12' ? year.to_i+1 : year}-#{month == '12' ? 1 : month.to_i+1}-7"
|
||||
}
|
||||
scope :region, -> region { where region: region }
|
||||
scope :tag, -> tag { where "tags like ?", "%#{tag}%" }
|
||||
scope :region, -> region { where 'region = ? or locality', region }
|
||||
scope :tag, -> tag { where 'tags like ?', "%#{tag}%" }
|
||||
|
||||
|
||||
before_validation(on: :create) do
|
||||
|
Loading…
Reference in New Issue
Block a user