You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

show.html.erb 1.4KB

12345678910111213141516171819202122232425262728293031323334
  1. <div class="contextual">
  2. <% if User.current.allowed_to?(:manage_documents, @project) %>
  3. <%= link_to l(:button_edit), edit_document_path(@document), :class => 'icon icon-edit', :accesskey => accesskey(:edit) %>
  4. <%= link_to l(:button_delete), document_path(@document), :confirm => l(:text_are_you_sure), :method => :delete, :class => 'icon icon-del' %>
  5. <% end %>
  6. </div>
  7. <h2><%=h @document.title %></h2>
  8. <p><em><%=h @document.category.name %><br />
  9. <%= format_date @document.created_on %></em></p>
  10. <div class="wiki">
  11. <%= textilizable @document.description, :attachments => @document.attachments %>
  12. </div>
  13. <h3><%= l(:label_attachment_plural) %></h3>
  14. <%= link_to_attachments @document %>
  15. <% if authorize_for('documents', 'add_attachment') %>
  16. <p><%= link_to l(:label_attachment_new), {}, :onclick => "Element.show('add_attachment_form'); Element.hide(this); Element.scrollTo('add_attachment_form'); return false;",
  17. :id => 'attach_files_link' %></p>
  18. <%= form_tag({ :controller => 'documents', :action => 'add_attachment', :id => @document }, :multipart => true, :id => "add_attachment_form", :style => "display:none;") do %>
  19. <div class="box">
  20. <p><%= render :partial => 'attachments/form' %></p>
  21. </div>
  22. <%= submit_tag l(:button_add) %>
  23. <% end %>
  24. <% end %>
  25. <% html_title @document.title -%>
  26. <% content_for :header_tags do %>
  27. <%= stylesheet_link_tag 'scm' %>
  28. <% end %>