podemos-info/census

View on GitHub
app/queries/person_pending_procedures.rb

Summary

Maintainability
A
0 mins
Test Coverage
# frozen_string_literal: true

class PersonPendingProcedures < Rectify::Query
  def self.for(person)
    new(person).query
  end

  def initialize(person)
    @person = person
  end

  def query
    @person.procedures.pending.order(created_at: :desc)
  end
end