Sha256: 3ec3726c3f888d2683c9075d4239697519076edb8f2cd938bea22f8730a63ada
Contents?: true
Size: 667 Bytes
Versions: 15
Compression:
Stored size: 667 Bytes
Contents
# Global visits not scoped to a patient module Renalware module Clinics class VisitsController < BaseController include Renalware::Concerns::Pageable PER_PAGE = 25 def index visits_query = VisitQuery.new(query_params) visits = visits_query.call.page(page).per(PER_PAGE) authorize visits render locals: { visits: visits, query: visits_query.search, clinics: Clinic.ordered, users: User.ordered } end private def query_params params .fetch(:q, {}) .merge(page: page, per_page: per_page) end end end end
Version data entries
15 entries across 15 versions & 1 rubygems