Skip to content

Commit

Permalink
OTWO-7294 Check for analyzed projects for unclaimed people (#1797)
Browse files Browse the repository at this point in the history
  • Loading branch information
Priya5 authored Sep 12, 2024
1 parent 7a2780d commit 2a41d5b
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions app/models/person.rb
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,10 @@ def rebuild_by_project_id(project_id)
end

def include_relations_and_order_by_kudo_position_and_name(name_id)
includes({ project: [{ best_analysis: :main_language }, :logo] }, :name, name_fact: :primary_language)
.where(name_id: name_id)
.order(Arel.sql('COALESCE(kudo_position, 999999999), lower(effective_name)'))
joins(project: :best_analysis).includes({ project: [{ best_analysis: :main_language }, :logo] }, :name,
name_fact: :primary_language)
.where(name_id: name_id)
.order(Arel.sql('COALESCE(kudo_position, 999999999), lower(effective_name)'))
end

def unclaimed_people(opts)
Expand Down

0 comments on commit 2a41d5b

Please sign in to comment.