diff --git a/app/views/entries/index.html.erb b/app/views/entries/index.html.erb index d254b74..b562bcd 100644 --- a/app/views/entries/index.html.erb +++ b/app/views/entries/index.html.erb @@ -18,9 +18,28 @@
| Typ | @@ -34,44 +53,99 @@Fortschritt | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| <%= typ.capitalize %> | +<%= art.capitalize %> | -<%= remaining ? "#{remaining / 60} h #{remaining % 60} min" : "—" %> | -<%= spent ? "#{spent / 60} h #{spent % 60} min" : "—" %> | -<%= soll || "—" %> h | -<%= weekly || "—" %> h/Woche | -<%= @actual_hours_per_week[[typ, art]] ? "#{@actual_hours_per_week[[typ, art]]} h/Woche" : "—" %> | ++ <% if remaining.present? %> + <%= remaining / 60 %> h <%= remaining % 60 %> min + <% else %> + — + <% end %> + | + ++ <% if spent.present? %> + <%= spent / 60 %> h <%= spent % 60 %> min + <% else %> + — + <% end %> + | + ++ <% if soll.present? %> + <%= soll %> h + <% else %> + — + <% end %> + | + ++ <% if weekly.present? %> + <%= weekly %> h/Woche + <% else %> + — + <% end %> + | + ++ <% actual = @actual_hours_per_week[[typ, art]] %> + + <% if actual.present? %> + <%= actual %> h/Woche + <% else %> + — + <% end %> + | + ++ <%= ende.present? ? ende.strftime("%d.%m.%Y") : "—" %> + | -<%= ende.present? ? ende.strftime("%d.%m.%Y") : "—" %> | <% percent = @completion_percent_by_typ_art[[typ, art]] %> - <%= percent ? "#{percent} %" : "—" %> + <%= percent.present? ? "#{percent} %" : "—" %> |