summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2015-06-08 16:20:21 -0700
committerelijah <elijah@riseup.net>2015-06-08 16:20:21 -0700
commitff46b9ac95eb7a53dacaed4e854964c2c4997ca8 (patch)
treefae6a6fdb36e1eb0a5ada0528afd482b556028ed /app/views
parent4d976166d360462b411545256a6b00eba3080a5a (diff)
* added totals
* better link * report header * configurable rate * version summary
Diffstat (limited to 'app/views')
-rw-r--r--app/views/hooks/_view_report_link.html.erb8
-rw-r--r--app/views/version_reports/_issue_row.html.erb2
-rw-r--r--app/views/version_reports/_main_issue_row.html.erb4
-rw-r--r--app/views/version_reports/_project_row.html.erb2
-rw-r--r--app/views/version_reports/show.html.erb16
5 files changed, 27 insertions, 5 deletions
diff --git a/app/views/hooks/_view_report_link.html.erb b/app/views/hooks/_view_report_link.html.erb
index fdd59c9..b9758a3 100644
--- a/app/views/hooks/_view_report_link.html.erb
+++ b/app/views/hooks/_view_report_link.html.erb
@@ -1 +1,7 @@
-<br><br><%= link_to 'Time Tracking Report', version_report_path %> \ No newline at end of file
+<br>
+<br>
+<form method='get' action='<%= version_report_path %>'>
+ <button type="submit">Detailed Report</button><br>
+ <label><input type="checkbox" name="time" value="false">Hide Time</label><br>
+ <label><input type="checkbox" name="money" value="false">Hide Money</label><br>
+</form>
diff --git a/app/views/version_reports/_issue_row.html.erb b/app/views/version_reports/_issue_row.html.erb
index 7d89e69..25c11c6 100644
--- a/app/views/version_reports/_issue_row.html.erb
+++ b/app/views/version_reports/_issue_row.html.erb
@@ -4,7 +4,7 @@
<%= display_issue(issue, :tracker) %>
</td>
<td>
- <%= l_hours(issue.total_spent_hours) if @show_time %>
+ <%= issue_time(issue) %>
</td>
<td>
&nbsp;
diff --git a/app/views/version_reports/_main_issue_row.html.erb b/app/views/version_reports/_main_issue_row.html.erb
index c83eb6d..8ca4904 100644
--- a/app/views/version_reports/_main_issue_row.html.erb
+++ b/app/views/version_reports/_main_issue_row.html.erb
@@ -5,10 +5,10 @@
<%= hour_budget_error(issue) %>
</td>
<td>
- <%= l_hours(issue.total_spent_hours) if @show_time %>
+ <%= issue_time(issue) %>
</td>
<td>
- <%= hours_to_money(issue.total_spent_hours) if @show_money %>
+ <%= issue_money(issue, :format) %>
</td>
</tr>
<tr>
diff --git a/app/views/version_reports/_project_row.html.erb b/app/views/version_reports/_project_row.html.erb
index ac0acd2..dab51e2 100644
--- a/app/views/version_reports/_project_row.html.erb
+++ b/app/views/version_reports/_project_row.html.erb
@@ -1,5 +1,5 @@
<tr>
- <td colspan="2">
+ <td colspan="3">
<b><%= project.name %></b>
</td>
</tr>
diff --git a/app/views/version_reports/show.html.erb b/app/views/version_reports/show.html.erb
index 09c2b20..e8c4f70 100644
--- a/app/views/version_reports/show.html.erb
+++ b/app/views/version_reports/show.html.erb
@@ -1,6 +1,22 @@
<% html_title @version.name %>
+<%= report_header(@version) %>
+
+<h1><%= @version.description %></h1>
+<p><%= report_summary(@version) %></p>
+
<table>
+<% if @show_time || @show_money %>
+ <tr>
+ <td><b>Total</b></td>
+ <td>
+ <%= total_time(@version, @issues) %>
+ </td>
+ <td>
+ <%= total_money(@version, @issues) if @show_money %>
+ </td>
+ </tr>
+<% end %>
<% if @issues.present? %>
<%- @issues.each do |issue| -%>
<%= render :partial => 'main_issue_row', :locals => {:issue => issue} %>