Created
November 10, 2017 02:08
-
-
Save nthock/891bbd26b7ebfc5c6b740b536e2e5348 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def status_validations | |
rules = THE_RULES[self.event.status] | |
unless rules.nil? | |
errors.add(:status, 'Invalid update of Event Seat due to the current event status.') unless rules[status_was.to_sym].include? status | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment