Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @courses = if params[:term]
- Course.where('name LIKE ?', "%#{params[:term]}%")
- else
- Course.all
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement