Sha256: c093de747f76e11df945e9e4c88641783869682ce621470dc85591c0ca3bbb55
Contents?: true
Size: 871 Bytes
Versions: 1
Compression:
Stored size: 871 Bytes
Contents
module Season module Legacy def self.included(base) base.class_eval do def self.created_before(date) where("#{table_name}.created_at < ?", date) end def self.created_between(start_date, end_date) where("#{table_name}.created_at > ? AND #{table_name}.created_at < ?", start_date, end_date) end def self.created_after(date) where("#{table_name}.created_at > ?", date) end def self.updated_before(date) where("#{table_name}.updated_at < ?", date) end def self.updated_between(start_date, end_date) where("#{table_name}.updated_at > ? AND #{table_name}.updated_at < ?", start_date, end_date) end def self.updated_after(date) where("#{table_name}.updated_at > ?", date) end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
season-0.3 | lib/season/legacy.rb |