app/views/questions/show.html.erb
<div id="content_detail" class="ui-corner-all">
<h1 class="title"><%= t('page.showing', :model => t('activerecord.models.question')) -%></h1>
<div id="content_list">
<p id="notice"><%= notice %></p>
<p>
<strong><%= t('activerecord.models.user') -%>:</strong>
<%= link_to @question.user.username, @question.user if @question.user -%>
</p>
<p>
<strong><%= t('activerecord.attributes.question.body') -%>:</strong>
<%= raw auto_link(markdown(h(@question.body))) -%>
</p>
<p>
<strong><%= t('activerecord.attributes.question.shared') -%>:</strong>
<%= localized_boolean(@question.shared) -%>
<strong><%= t('activerecord.attributes.question.solved') -%>:</strong>
<%= localized_boolean(@question.solved) -%>
</p>
<p>
<strong><%= t('page.created_at') -%>:</strong>
<%= l(@question.created_at) -%>
<strong><%= t('page.updated_at') -%>:</strong>
<%= l(@question.updated_at) -%>
</p>
<p>
<strong><%= link_to t('activerecord.models.answer'), question_answers_path(@question) -%>:</strong>
</p>
<ul>
<%- @question.answers.public_answers.each do |answer| -%>
<li><%= link_to answer.user.username, answer.user if answer.user -%>
(<%=l answer.updated_at %>)<br />
<%= raw auto_link(markdown(h(answer.body))) -%><br />
<% unless answer.items.empty? %>
<ul>
<% answer.items.each do |item| %>
<li><%= link_to item.manifestation.original_title, item.manifestation %><br /></li>
<% end %>
</ul>
<% end %>
</li>
<%- end -%>
</ul>
</div>
</div>
<div id="submenu" class="ui-corner-all">
<ul>
<li><%= link_to t('question.answer_question'), new_question_answer_path(@question) -%></li>
<%- if can? :update, @question -%>
<li><%= link_to t('page.edit'), edit_question_path(@question) -%></li>
<%- end -%>
<%- if can? :destroy, @question -%>
<li><%= link_to t('page.destroy'), @question, :confirm => t('page.are_you_sure'), :method => :delete -%></li>
<%- end -%>
<li><%= link_to t('page.back'), questions_path -%></li>
<% if false %>
<li><%= link_to 'レファレンス協同データベース用XMLファイル', question_path(@question, :mode => 'crd', :format => 'xml') -%></li>
<% end %>
</ul>
</div>