mirror of
https://github.com/tomgi/git_stats.git
synced 2025-01-03 11:12:11 +01:00
hour of week table
This commit is contained in:
parent
628b650e2f
commit
faba8bfdad
2 changed files with 21 additions and 6 deletions
|
@ -21,3 +21,4 @@ en:
|
||||||
percentage: Percentage
|
percentage: Percentage
|
||||||
day: Day
|
day: Day
|
||||||
day_of_week: Day of week
|
day_of_week: Day of week
|
||||||
|
hour_of_week: Hour of week
|
|
@ -6,11 +6,11 @@
|
||||||
- (0..23).each do |h|
|
- (0..23).each do |h|
|
||||||
%th= h
|
%th= h
|
||||||
%tr
|
%tr
|
||||||
%td= :commits.t
|
%th= :commits.t
|
||||||
- repo.activity.by_hour_array.each do |commits|
|
- repo.activity.by_hour_array.each do |commits|
|
||||||
%td= commits
|
%td= commits
|
||||||
%tr
|
%tr
|
||||||
%td= :percentage.t
|
%th= :percentage.t
|
||||||
- repo.activity.by_hour_array.each do |commits|
|
- repo.activity.by_hour_array.each do |commits|
|
||||||
%td= (commits * 100.0 / repo.activity.by_hour_array.sum).round(2)
|
%td= (commits * 100.0 / repo.activity.by_hour_array.sum).round(2)
|
||||||
= high_chart("activity_by_hour", charts.activity_by_hour)
|
= high_chart("activity_by_hour", charts.activity_by_hour)
|
||||||
|
@ -24,11 +24,25 @@
|
||||||
- Date::ABBR_DAYNAMES.each do |d|
|
- Date::ABBR_DAYNAMES.each do |d|
|
||||||
%th= d
|
%th= d
|
||||||
%tr
|
%tr
|
||||||
%td= :commits.t
|
%th= :commits.t
|
||||||
- repo.activity.by_wday_array.each do |commits|
|
- repo.activity.by_wday_array.each do |commits|
|
||||||
%td= commits
|
%td= commits
|
||||||
%tr
|
%tr
|
||||||
%td= :percentage.t
|
%th= :percentage.t
|
||||||
- repo.activity.by_wday_array.each do |commits|
|
- repo.activity.by_wday_array.each do |commits|
|
||||||
%td= (commits * 100.0 / repo.activity.by_wday_array.sum).round(2)
|
%td= (commits * 100.0 / repo.activity.by_wday_array.sum).round(2)
|
||||||
= high_chart("activity_by_wday", charts.activity_by_wday)
|
= high_chart("activity_by_wday", charts.activity_by_wday)
|
||||||
|
|
||||||
|
|
||||||
|
.page-header
|
||||||
|
%h1.pagination-centered= :hour_of_week.t
|
||||||
|
%table{:class => "table table-bordered table-condensed"}
|
||||||
|
%tr
|
||||||
|
%th
|
||||||
|
- (0..23).each do |h|
|
||||||
|
%th= h
|
||||||
|
- (0..6).each do |day|
|
||||||
|
%tr
|
||||||
|
%th= Date::ABBR_DAYNAMES[day]
|
||||||
|
- (0..23).each do |hour|
|
||||||
|
%td= repo.activity.by_wday_hour[day][hour]
|
||||||
|
|
Loading…
Reference in a new issue