journalduhacker/app/views/users/show.html.erb
joshua stein e6c74e8251 add moderation logging
- add users.is_moderator and look at that for most things, not
is_admin

- make default user in readme be a moderator

- log moderator actions in story edits, comment
  deletions/undeletions (and later, user disabling).

- remove ability for moderators to edit comments, there's really no
  reason to.
2012-09-02 12:18:52 -05:00

46 lines
1.1 KiB
Plaintext

<div class="box wide">
<div class="legend">
<%= @showing_user.username %>
<% if @user %>
(<a href="/messages?to=<%= @showing_user.username %>">Send a Message</a>)
<% end %>
</div>
<label class="required">Status:</label>
<span class="d">
Active <%= @showing_user.is_admin? ? "administrator" :
(@showing_user.is_moderator? ? "moderator" : "user") %>
</span>
<br>
<label class="required">Joined:</label>
<span class="d">
<%= time_ago_in_words(@showing_user.created_at) %> ago
</span>
<br>
<label class="required">Karma:</label>
<span class="d">
<%= @showing_user.karma %>
</span>
<br>
<label class="required">Stories Submitted:</label>
<span class="d">
<%= @showing_user.stories_submitted_count %>
</span>
<br>
<label class="required">Comments Posted:</label>
<span class="d">
<%= @showing_user.comments_posted_count %>
</span>
<br>
<label class="required">About:</label>
<div class="shorten_first_p" style="margin-left: 12em;">
<%= raw @showing_user.linkified_about %>
</div>
</div>