mirror of
https://github.com/tomgi/git_stats.git
synced 2025-01-03 11:12:11 +01:00
best authors table
This commit is contained in:
parent
d905197429
commit
8138c85a3b
2 changed files with 30 additions and 2 deletions
|
@ -41,3 +41,9 @@ en:
|
||||||
commits_sum_by_author_by_date: Commits sum by author by date
|
commits_sum_by_author_by_date: Commits sum by author by date
|
||||||
lines_added_by_author_by_date: Lines added by author by date
|
lines_added_by_author_by_date: Lines added by author by date
|
||||||
lines_deleted_by_author_by_date: Lines deleted by author by date
|
lines_deleted_by_author_by_date: Lines deleted by author by date
|
||||||
|
best_authors: Best authors
|
||||||
|
lines_added: Lines added
|
||||||
|
lines_deleted: Lines deleted
|
||||||
|
first_commit: First_commit
|
||||||
|
last_commit: Last commit
|
||||||
|
author: Author
|
|
@ -1,6 +1,8 @@
|
||||||
.tabbable.tabs-left
|
.tabbable.tabs-left
|
||||||
%ul.nav.nav-tabs
|
%ul.nav.nav-tabs
|
||||||
%li.active
|
%li.active
|
||||||
|
%a{:href => '#best_authors', 'data-toogle' => 'tab'}= :best_authors.t
|
||||||
|
%li
|
||||||
%a{:href => '#commits_count_by_author', 'data-toogle' => 'tab'}= :commits_count_by_author.t
|
%a{:href => '#commits_count_by_author', 'data-toogle' => 'tab'}= :commits_count_by_author.t
|
||||||
%li
|
%li
|
||||||
%a{:href => '#lines_added_by_author', 'data-toogle' => 'tab'}= :lines_added_by_author.t
|
%a{:href => '#lines_added_by_author', 'data-toogle' => 'tab'}= :lines_added_by_author.t
|
||||||
|
@ -14,7 +16,27 @@
|
||||||
%a{:href => '#lines_deleted_by_author_by_date', 'data-toogle' => 'tab'}= :lines_deleted_by_author_by_date.t
|
%a{:href => '#lines_deleted_by_author_by_date', 'data-toogle' => 'tab'}= :lines_deleted_by_author_by_date.t
|
||||||
|
|
||||||
.tab-content
|
.tab-content
|
||||||
.tab-pane.active{id: 'commits_count_by_author'}
|
.tab-pane.active{id: 'best_authors'}
|
||||||
|
.page-header
|
||||||
|
%h1.pagination-centered= :best_authors.t
|
||||||
|
%table{:class => "table table-bordered table-condensed table-hover"}
|
||||||
|
%tr
|
||||||
|
%th= :author.t
|
||||||
|
%th= :commits.t
|
||||||
|
%th= :lines_added.t
|
||||||
|
%th= :lines_deleted.t
|
||||||
|
%th= :first_commit.t
|
||||||
|
%th= :last_commit.t
|
||||||
|
- repo.authors.sort_by { |a| -a.commits.size}.each do |author|
|
||||||
|
%tr
|
||||||
|
%th= author.name
|
||||||
|
%td= author.commits.size
|
||||||
|
%td= author.lines_added
|
||||||
|
%td= author.lines_deleted
|
||||||
|
%td= author.commits.first.try(:date).try(:to_formatted_s, :long)
|
||||||
|
%td= author.commits.last.try(:date).try(:to_formatted_s, :long)
|
||||||
|
|
||||||
|
.tab-pane{id: 'commits_count_by_author'}
|
||||||
.page-header
|
.page-header
|
||||||
%h1.pagination-centered= :commits_count_by_author.t
|
%h1.pagination-centered= :commits_count_by_author.t
|
||||||
= high_chart("charts.commits_count_by_author", charts.commits_count_by_author)
|
= high_chart("charts.commits_count_by_author", charts.commits_count_by_author)
|
||||||
|
|
Loading…
Reference in a new issue