app/models/entities/campaign.rb
# Make sure end date > start date.
#----------------------------------------------------------------------------
Make sure end date > start date.
Make sure end date > start date .
def start_and_end_dates
    if (self.starts_on && self.ends_on) && (self.starts_on > self.ends_on)
      errors.add(:ends_on, :dates_not_in_sequence)
    end
  end
def start_and_end_dates if ( self . starts_on && self . ends_on ) && ( self . starts_on > self . ends_on ) errors . add ( :ends_on , :dates_not_in_sequence ) end end
Make sure end date > start date.
Make sure end date > start date .