34 lines
959 B
Text
34 lines
959 B
Text
<h1><%= @user&.login || @user&.id || "Statuses" %></h1>
|
|
<a href="/timeline">All Statuses</a>
|
|
<hr>
|
|
|
|
<div class="userstatus">
|
|
<% if @statuses.present? %>
|
|
<% @statuses.each do |status| %>
|
|
<% if status.icon.attached? %>
|
|
<%= image_tag status.icon %>
|
|
<% end %>
|
|
|
|
<%= time_ago_in_words(status.created_at) %> |
|
|
<% if current_user %>
|
|
<%= link_to 'Edit', edit_user_status_path(status.user, status) %> |
|
|
<%= link_to t("Delete"), user_status_path(status.user, status),
|
|
data: { confirm: t("Are you sure? All information in this status will be lost.") },
|
|
method: :delete %>
|
|
<% end %>
|
|
|
|
<p><%= raw sanitize_field(status, :text) %></p>
|
|
|
|
<% if status.mood.present? %>
|
|
<p>Mood: <%= status.mood %></p>
|
|
<% end %>
|
|
|
|
<% if status.music.present? %>
|
|
<p>Music: <%= status.music %></p>
|
|
<% end %>
|
|
|
|
<hr>
|
|
<% end %>
|
|
<% end %>
|
|
</div>
|
|
|