view app/views/attachments/toggle_active.html.erb @ 1477:f2ad2199b49a bibplugin_integration

Close obsolete branch bibplugin_integration
author Chris Cannam
date Fri, 30 Nov 2012 14:41:31 +0000
parents 04114f36670d
children
line wrap: on
line source
<%=
file = Attachment.find(params[:id])
active_id = "active-" + file.id.to_s
link_to_remote image_tag(file.active? ? 'fav.png' : 'fav_off.png'),
  :url => {:controller => 'attachments', :action => 'toggle_active', :project_id => @project.id, :id => file},
  :update => active_id
%>