Sha256: 81093dc2f9800b76a94f3470185077150ad04997664e9c435c2ec5826764711c

Contents?: true

Size: 586 Bytes

Versions: 130

Compression:

Stored size: 586 Bytes

Contents

# frozen_string_literal: true

module Renalware
  module Admin
    module Users
      class SummaryPart < Renalware::SummaryPart
        def to_partial_path
          "renalware/admin/users/summary_part"
        end

        def users_needing_approval_count
          @users_needing_approval_count ||= User.unapproved.count
        end

        def users_needing_approval_title
          [
            users_needing_approval_count,
            "user".pluralize(users_needing_approval_count),
            "awaiting approval"
          ].join(" ")
        end
      end
    end
  end
end

Version data entries

130 entries across 130 versions & 1 rubygems

Version Path
renalware-core-2.0.139 app/presenters/renalware/admin/users/summary_part.rb.dead
renalware-core-2.0.138 app/presenters/renalware/admin/users/summary_part.rb.dead
renalware-core-2.0.137 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.136 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.135 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.134 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.133 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.132 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.131 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.130 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.129 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.128 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.127 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.126 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.125 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.124 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.123 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.121 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.120 app/presenters/renalware/admin/users/summary_part.rb
renalware-core-2.0.119 app/presenters/renalware/admin/users/summary_part.rb