tracks/app/views/projects/edit.js.erb
Reinier Balt 35453acd57 migrate edit update and destroy to jQuery and refactor it
test for changing state is wip, forgot to mark it with @wip
2011-02-03 18:16:55 +01:00

5 lines
291 B
Text

newHtml = "<%= escape_javascript(render(:partial => 'project_form', :locals => { :project_form => @project })) %>"
$('div#<%=dom_id(@project, 'edit')%>').html(newHtml);
$('div#<%=dom_id(@project)%>').hide();
$('div#<%=dom_id(@project, 'edit')%>').show(500);
$('input.project-name').focus();