... | ... |
@@ -20,13 +20,14 @@ |
20 | 20 |
my $commits = $git->branch_commits($rep, $rev1, $rev2); |
21 | 21 |
my $commits_count = @$commits; |
22 | 22 |
my $commits_date = {}; |
23 |
+ my $authors = {}; |
|
23 | 24 |
for my $commit (@$commits) { |
24 | 25 |
my $date = $commit->{age_string_date}; |
25 | 26 |
$commits_date->{$date} ||= []; |
27 |
+ $authors->{$commit->{author}} = 1; |
|
26 | 28 |
push @{$commits_date->{$date}}, $commit; |
27 | 29 |
} |
28 |
- |
|
29 |
- use D;d $commits; |
|
30 |
+ my $authors_count = keys %$authors; |
|
30 | 31 |
|
31 | 32 |
# Global variable |
32 | 33 |
stash(user => $user, project => $project); |
... | ... |
@@ -42,7 +43,7 @@ |
42 | 43 |
padding-bottom:5px; |
43 | 44 |
} |
44 | 45 |
|
45 |
- /* Header */ |
|
46 |
+ /* Compare header */ |
|
46 | 47 |
.compare_header { |
47 | 48 |
border-bottom:1px solid #ccc; |
48 | 49 |
padding-bottom:10px; |
... | ... |
@@ -57,21 +58,10 @@ |
57 | 58 |
float:right; |
58 | 59 |
} |
59 | 60 |
|
60 |
- .compare_tabs { |
|
61 |
- overflow:hidden; |
|
62 |
- } |
|
63 |
- .compare_tabs li { |
|
64 |
- float:left; |
|
65 |
- padding:12px; |
|
66 |
- } |
|
67 |
- .compare_tabs .ccommits { |
|
68 |
- font-weight:bold; |
|
69 |
- } |
|
70 |
- |
|
71 |
- /* Compare menu */ |
|
61 |
+ /* Compare tabs */ |
|
72 | 62 |
.compare_tabs { |
73 | 63 |
margin-top:7px; |
74 |
- margin-bottom:15px; |
|
64 |
+ margin-bottom:10px; |
|
75 | 65 |
height:30px; |
76 | 66 |
overflow:hidden; |
77 | 67 |
} |
... | ... |
@@ -111,7 +101,13 @@ |
111 | 101 |
font-weight:bold; |
112 | 102 |
} |
113 | 103 |
.compare_tabs .ccommits a { |
114 |
- color:#333 |
|
104 |
+ color:#333; |
|
105 |
+ } |
|
106 |
+ |
|
107 |
+ /* Commits number */ |
|
108 |
+ .commits_number { |
|
109 |
+ color:#333; |
|
110 |
+ padding-bottom:10px; |
|
115 | 111 |
} |
116 | 112 |
% end |
117 | 113 |
|
... | ... |
@@ -136,7 +132,7 @@ |
136 | 132 |
</div> |
137 | 133 |
|
138 | 134 |
<div class="commits_number"> |
139 |
- Showing 47 commits by 1 author. |
|
135 |
+ Showing <%= @$commits %> commits by <%= $authors_count %> author. |
|
140 | 136 |
</div> |
141 | 137 |
|
142 | 138 |
% for my $date (sort keys %$commits_date) { |