Skip to content

Commit ac5d77a

Browse files
author
Raushan Kumar Raman
committed
[##6174] added metrics for logged contacts
1 parent 0b6219e commit ac5d77a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/controllers/health_controller.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def monthly_unique_users_graph_data
5353
monthly_counts_of_volunteers = LoginActivity.joins("INNER JOIN users ON users.id = login_activities.user_id AND login_activities.user_type = 'User'").where(users: {type: "Volunteer"}, success: true).group_by_month(:created_at, format: "%b %Y").distinct.count(:user_id)
5454
monthly_counts_of_supervisors = LoginActivity.joins("INNER JOIN users ON users.id = login_activities.user_id AND login_activities.user_type = 'User'").where(users: {type: "Supervisor"}, success: true).group_by_month(:created_at, format: "%b %Y").distinct.count(:user_id)
5555
monthly_counts_of_casa_admins = LoginActivity.joins("INNER JOIN users ON users.id = login_activities.user_id AND login_activities.user_type = 'User'").where(users: {type: "CasaAdmin"}, success: true).group_by_month(:created_at, format: "%b %Y").distinct.count(:user_id)
56-
monthly_logged_counts_of_volunteers = CaseContact.joins(:supervisor_volunteer).group_by_month(:created_at, format: "%b %Y").distinct.count(:creator_id)
56+
monthly_logged_counts_of_volunteers = CaseContact.joins(supervisor_volunteer: :volunteer).group_by_month(:created_at, format: "%b %Y").distinct.count(:creator_id)
5757

5858
monthly_line_graph_combined_data = first_day_of_last_12_months.map do |month|
5959
[

0 commit comments

Comments
 (0)