added open view from redirect_to and render
moved search to a new search method