Files
Redmine/app/views/repositories/_changeset.html.erb
Go MAEDA f992df684f Small refactorization of avatar methods (#31391).
* move existing methods from ApplicationHelper to a new helper file (AvatarsHelper)
* change default avatar size from 50 to 24 because most of the avatars are using the  size 24
* class 'gravatar' is always added and all custom classes are appended
* added user name as default title for avatar images
* added two new methods: @assignee_avatar@ and @author_avatar@

Patch by Marius BALTEANU.


git-svn-id: http://svn.redmine.org/redmine/trunk@18175 e93f8b46-1217-0410-a6f0-8f06a7374b81
2019-05-19 22:27:41 +00:00

66 lines
2.1 KiB
Plaintext

<h2><%= l(:label_revision) %> <%= format_revision(@changeset) %></h2>
<div class="details">
<h4>
<%= avatar(@changeset.user) %>
<%= authoring(@changeset.committed_on, @changeset.author) %>
</h4>
<% if @changeset.scmid.present? || @changeset.parents.present? || @changeset.children.present? %>
<ul class="revision-info">
<% if @changeset.scmid.present? %>
<li>
<strong>ID </strong><%= @changeset.scmid %>
</li>
<% end %>
<% if @changeset.parents.present? %>
<li>
<strong><%= l(:label_parent_revision) %></strong>
<%= @changeset.parents.collect{
|p| link_to_revision(p, @repository, :text => format_revision(p))
}.join(", ").html_safe %>
</li>
<% end %>
<% if @changeset.children.present? %>
<li>
<strong><%= l(:label_child_revision) %></strong>
<%= @changeset.children.collect{
|p| link_to_revision(p, @repository, :text => format_revision(p))
}.join(", ").html_safe %>
</li>
<% end %>
</ul>
<% end %>
</div>
<div class="wiki changeset-comments">
<%= format_changeset_comments @changeset %>
</div>
<% if @changeset.issues.visible.any? || User.current.allowed_to?(:manage_related_issues, @repository.project) %>
<%= render :partial => 'related_issues' %>
<% end %>
<% if User.current.allowed_to?(:browse_repository, @repository.project) %>
<%
tabs = []
tabs << { name: 'revision', label: :label_change_plural,
url: { :action => 'revision',
:id => @project,
:repository_id => @repository.identifier_param,
:path => nil,
:rev => @changeset.identifier}
}
tabs << { name: 'diff', label: :label_view_diff,
url: { :action => 'diff',
:id => @project,
:repository_id => @repository.identifier_param,
:path => "",
:rev => @changeset.identifier }
} if action_name == 'diff' || @changeset.filechanges.any?
%>
<%= render :partial => 'common/tabs', :locals => {:tabs => tabs, :selected_tab => action_name} %>
<% end %>