Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

APPEALS-51552: Test Appeal Organization tables #22237

Merged
merged 3 commits into from
Jul 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions app/models/queues/attorney_queue.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ def tasks
record.status = Constants.TASK_STATUSES.on_hold
end
end

caseflow_tasks = user.tasks.includes(*task_includes).incomplete_or_recently_completed
caseflow_tasks = user.tasks.not_correspondence.includes(*task_includes).incomplete_or_recently_completed
(colocated_tasks_for_attorney_tasks + caseflow_tasks).flatten
end

Expand Down
1 change: 1 addition & 0 deletions app/models/queues/generic_queue.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def tasks
def relevant_tasks
Task.incomplete_or_recently_completed.visible_in_queue_table_view
.where(assigned_to: user)
.not_correspondence
.includes(*task_includes)
.order(created_at: :asc)
.limit(limit)
Expand Down
2 changes: 1 addition & 1 deletion app/models/queues/judge_queue.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

class JudgeQueue < GenericQueue
def tasks
super.active.where(type: JudgeAssignTask.name)
super.active.not_correspondence.where(type: JudgeAssignTask.name)
end
end
2 changes: 1 addition & 1 deletion app/serializers/attorney_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ class AttorneySerializer
attribute :css_id
attribute :full_name
attribute :active_task_count do |object|
object.tasks.active.size + QueueRepository.tasks_for_user(object.css_id).count
object.tasks.not_correspondence.active.size + QueueRepository.tasks_for_user(object.css_id).count
end
end
Loading