Just declare a parameter in your helper method à la:
def render_blocks(my_variable) my_variable.collect end
You then call it in your view and pass the variable that is valid for that view.
<%= render_blocks(@free) %>
Just declare a parameter in your helper method à la:
def render_blocks(my_variable) my_variable.collect end
You then call it in your view and pass the variable that is valid for that view.
<%= render_blocks(@free) %>
Just declare a parameter in your helper method à la:
def render_blocks(my_variable) my_variable.collect end
You then call it in your view and pass the variable that is valid for that view.
<%= render_blocks(@free) %>
grand. cheers