mirror of
https://github.com/TracksApp/tracks.git
synced 2026-01-29 20:26:11 +01:00
This change also changes context detail page URLs from /context/my_context to /contexts/my_context
Add a database index on the projects and contexts tables, user_d + name, to speed the lookup used in urls
Brought the URLs within various feeds up-to-date
git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@399 a4c988fc-2ded-0310-b66e-134b36920a42
34 lines
2 KiB
Text
34 lines
2 KiB
Text
<% note = notes -%>
|
|
<div id="note-<%= note.id.to_s %>-container">
|
|
<h2><%= link_to("Note #{note.id.to_s}", {:action => "show", :id => note.id}, :title => "Show note #{note.id.to_s}" ) %></h2>
|
|
|
|
<div id="note-<%= note.id.to_s %>">
|
|
<%= sanitize(textilize(note.body)) %>
|
|
|
|
<div class="note_footer">
|
|
<%= link_to_remote( image_tag("blank.png", :title =>"Delete this note", :class=>"delete_item"),
|
|
:update => "note-#{note.id}",
|
|
:loading => visual_effect(:fade, "note-#{note.id}-container"),
|
|
:complete => "Element.remove('note-#{note.id}-wrapper');",
|
|
:url => { :controller => "note", :action => "delete", :id => note.id },
|
|
:confirm => "Are you sure that you want to delete the note \'#{note.id.to_s}\'?" ) + " "%><%= link_to_function(image_tag( "blank.png", :title => "Edit item", :class=>"edit_item"),
|
|
"Element.toggle('note-#{note.id}'); Element.toggle('note-#{note.id}-edit-form'); Effect.Appear('note-#{note.id}-edit-form'); Form.focusFirstElement('form-note-#{note.id}');" ) + " | " %>
|
|
<%= link_to("In: " + note.project.name, project_path(note.project), :class=>"footer_link" ) %> |
|
|
Created: <%= format_date(note.created_at) %>
|
|
<% if note.updated_at? -%>
|
|
| Modified: <%= format_date(note.updated_at) %>
|
|
<% end -%>
|
|
</div>
|
|
</div><!-- [end.note.id] -->
|
|
|
|
<div id="note-<%= note.id %>-edit-form" class="edit-form" style="display:none;">
|
|
<% form_remote_tag :url => { :action => 'update', :id => note.id },
|
|
:html => { :id => "form-note-#{note.id}", :class => "inline-form" },
|
|
:update => "note-#{note.id}-container",
|
|
:complete => visual_effect(:appear, "note-#{note.id}-container") do -%>
|
|
<%= render :partial => "note_edit_form", :object => note %>
|
|
<% end -%>
|
|
</div><!-- [end:note-note.id-edit-form] -->
|
|
|
|
</div><!-- [end.note-note.id-container] -->
|
|
<% note = nil -%>
|