Skip to content

Commit a053a75

Browse files
committed
Added recalculation
1 parent 364e2bd commit a053a75

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

app/controllers/reports/annual_reports_controller.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ def range
5656

5757
def get_range_report(year_start, year_end)
5858
(year_start..year_end).map do |year|
59-
Reports.retrieve_report(organization: current_organization, year: year)
59+
Reports.retrieve_report(organization: current_organization, year: year, recalculate: true)
6060
rescue ActiveRecord::RecordInvalid => e
6161
Rails.logger.error("Failed to retrieve annual report for year #{year}: #{e.message}")
6262
nil

app/views/reports/annual_reports/index.html.erb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
text: "Export Yearly Reports"
3535
)
3636
%>
37+
This will recalculate all the reports, and may take some time.
3738
</div>
3839
<div class="col-md-12">
3940
<div class="card card-primary">

0 commit comments

Comments
 (0)