mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-27 01:24:07 +01:00
replace old prototype/jrails code for periodic checks and start work on autocomplete and edit projects
Signed-off-by: Reinier Balt <lrbalt@gmail.com>
This commit is contained in:
parent
69c811e365
commit
c834403340
24 changed files with 588 additions and 53 deletions
11
app/views/projects/edit.js.erb
Normal file
11
app/views/projects/edit.js.erb
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
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();
|
||||
|
||||
$('input.project-name').focus();
|
||||
|
||||
<%#*page[dom_id(@project, 'edit')].replace_html :partial => 'project_form', :locals => { :project_form => @project }%>
|
||||
<%#*page[@project].hide%>
|
||||
<%#*page[dom_id(@project, 'edit')].show%>
|
||||
<%#*page[dom_id(@project, 'edit_form')].find('input.project-name').focus%>
|
||||
Loading…
Add table
Add a link
Reference in a new issue