0002-Structure-the-document-show-page.patch

Mizuki ISHIKAWA, 2021-08-17 02:33

Download (1.9 KB)

View differences:

app/views/documents/show.html.erb
7 7
<% end %>
8 8
</div>
9 9

  
10
<h2><%= @document.title %></h2>
10
<h2 class="title"><%= @document.title %></h2>
11 11

  
12
<p><em><%= @document.category.name %><br />
13
<%= format_date @document.created_on %></em></p>
12
<div id="document-details" class="document">
13
<div class="attributes">
14
  <div class="category-name"><em><%= @document.category.name %></em></div>
15
  <div class="created-on"><em><%= format_date @document.created_on %></em></div>
14 16

  
15
<% if @document.custom_field_values.any? %>
16
<ul>
17
  <% render_custom_field_values(@document) do |custom_field, formatted| %>
18
    <li><span class="label"><%= custom_field.name %>:</span> <%= formatted %></li>
17
  <% if @document.custom_field_values.any? %>
18
    <ul class="document-custom-field-values">
19
      <% render_custom_field_values(@document) do |custom_field, formatted| %>
20
        <li><span class="label"><%= custom_field.name %>:</span> <%= formatted %></li>
21
      <% end %>
22
    </ul>
19 23
  <% end %>
20
</ul>
21
<% end %>
24
</div>
22 25

  
23
<div class="wiki">
26
<div class="wiki description">
24 27
<%= textilizable @document, :description, :attachments => @document.attachments %>
25 28
</div>
26 29

  
30
<div class="attachments-area">
27 31
<h3><%= l(:label_attachment_plural) %></h3>
28 32
<%= link_to_attachments @document, :thumbnails => true %>
29 33

  
......
37 41
  <%= submit_tag l(:button_add) %>
38 42
  <% end %>
39 43
<% end %>
44
</div>
45

  
46
</div>
40 47

  
41 48
<% html_title @document.title -%>
42
-