Created
February 27, 2012 22:47
-
-
Save ehrenmurdick/1927680 to your computer and use it in GitHub Desktop.
activity_sequence
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
Actions = [PersonalValues, PersonActions, SomeOther] | |
Locations = [first_action_path, second_action_path, third_action_path] | |
def next_activity(thing) | |
Locations[Actions.index(thing.class) + 1] | |
end | |
def prev_activity(thing) | |
Locations[Actions.index(thing.class) - 1] | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment