Chris@0:
Chris@0: <%= link_to_if_authorized l(:button_edit), {:controller => 'documents', :action => 'edit', :id => @document}, :class => 'icon icon-edit', :accesskey => accesskey(:edit) %> Chris@0: <%= link_to_if_authorized l(:button_delete), {:controller => 'documents', :action => 'destroy', :id => @document}, :confirm => l(:text_are_you_sure), :method => :post, :class => 'icon icon-del' %> Chris@0:
Chris@0: Chris@0:

<%=h @document.title %>

Chris@0: Chris@0:

<%=h @document.category.name %>
Chris@0: <%= format_date @document.created_on %>

Chris@0:
Chris@0: <%= textilizable @document.description, :attachments => @document.attachments %> Chris@0:
Chris@0: Chris@0:

<%= l(:label_attachment_plural) %>

Chris@0: <%= link_to_attachments @document %> Chris@0: Chris@0: <% if authorize_for('documents', 'add_attachment') %> Chris@0:

<%= link_to l(:label_attachment_new), {}, :onclick => "Element.show('add_attachment_form'); Element.hide(this); Element.scrollTo('add_attachment_form'); return false;", Chris@0: :id => 'attach_files_link' %>

Chris@0: <% form_tag({ :controller => 'documents', :action => 'add_attachment', :id => @document }, :multipart => true, :id => "add_attachment_form", :style => "display:none;") do %> Chris@0:
Chris@0:

<%= render :partial => 'attachments/form' %>

Chris@0:
Chris@0: <%= submit_tag l(:button_add) %> Chris@0: <% end %> Chris@0: <% end %> Chris@0: Chris@0: <% html_title @document.title -%> Chris@0: Chris@0: <% content_for :header_tags do %> Chris@0: <%= stylesheet_link_tag 'scm' %> Chris@0: <% end %>