Revision 915:2a68662d5adf app/views/attachments

View differences:

app/views/attachments/toggle_active.erb
1
<%=
2
file = Attachment.find(params[:id])
3
active_id = "active-" + file.id.to_s
4
link_to_remote image_tag(file.active? ? 'fav.png' : 'fav_off.png'),
5
  :url => {:controller => 'attachments', :action => 'toggle_active', :project_id => @project.id, :id => file},
6
  :update => active_id
7
%>
app/views/attachments/toggle_active.rhtml
1
<%=
2
file = Attachment.find(params[:id])
3
active_id = "active-" + file.id.to_s
4
link_to_remote image_tag(file.active? ? 'fav.png' : 'fav_off.png'),
5
  :url => {:controller => 'attachments', :action => 'toggle_active', :project_id => @project.id, :id => file},
6
  :update => active_id
7
%>

Also available in: Unified diff