Skip to content

Instantly share code, notes, and snippets.

/ruby.rb Secret

Created December 2, 2015 06:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/0bfbaf86a9480d8b3102 to your computer and use it in GitHub Desktop.
Save anonymous/0bfbaf86a9480d8b3102 to your computer and use it in GitHub Desktop.
def find_by_year_and_month(year, month) # find_by_year_and_month("2015", 3)
if found_year = RTMYearName.find_by( year: year.to_s )
find_by mm_year_plan_id: found_year.id, month_nr: month.to_i #Problem on this line
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment