Created
April 7, 2015 20:53
-
-
Save kenmazaika/4f0caaf00b73f3b34d7f to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| kk |
This file contains hidden or 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
| # this should load the workout drill with the id that is passed through | |
| # logic about the "next" drill should be done elsewhere! The show | |
| # action should be stupid. | |
| def show | |
| @workout_drill = WorkoutDrill.find(params[:id]) | |
| # NO: @workout = current_user.workouts.last | |
| # NO: @workout_drill = @workout.workout_drills.where(:complete => false).first | |
| # NO: if @workout.workout_drills.any?{|w| w.complete == false} | |
| # NO: else | |
| # NO: flash[:notice] = "All done! Congratulations!" | |
| # NO: redirect_to dashboard_player_path | |
| # NO: end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment