2018-03-17 18:26:18 +05:30
- merge_request = local_assigns.fetch(:merge_request, nil)
- project = local_assigns.fetch(:project) { merge_request&.project }
- ref = local_assigns.fetch(:ref) { merge_request&.source_branch }
2016-06-02 11:05:42 +05:30
- commits, hidden = limited_commits(@commits)
- commits.chunk { |c| c.committed_date.in_time_zone.to_date }.each do |day, commits|
2017-09-10 17:25:29 +05:30
%li.commit-header.js-commit-header{ data: { day: day } }
%span.day= l(day, format: '%d %b, %Y')
%span.commits-count= n_("%d commit", "%d commits", commits.count) % commits.count
%li.commits-row{ data: { day: day } }
%ul.content-list.commit-list.flex-list
2018-03-17 18:26:18 +05:30
= render partial: 'projects/commits/commit', collection: commits, locals: { project: project, ref: ref, merge_request: merge_request }
2016-06-02 11:05:42 +05:30
- if hidden > 0
2016-06-22 15:30:34 +05:30
%li.alert.alert-warning
2017-09-10 17:25:29 +05:30
= n_('%s additional commit has been omitted to prevent performance issues.', '%s additional commits have been omitted to prevent performance issues.', hidden) % number_with_delimiter(hidden)