each action in controller should have it's view so why don't you use
<%= render :partial ... %> or <%= render_component ... %>
in your case listProjects (actually should be list_projects) must be class method of your Project model;
class Project < ActiveRecord::Base def list_projects( user = nil ) Project.find_by_user_id user end end
cheers