Sha256: 0845699cf677b939377832efbe687a21b69287cdf1f973776f13e0b2e0fd8832
Contents?: true
Size: 721 Bytes
Versions: 3
Compression:
Stored size: 721 Bytes
Contents
module Krikri ## # Handles HTTP requests for the Reports dashboard, presenting all types of # reports, filtered by {Krikri::Provider} if given. class ReportsController < ApplicationController layout 'krikri/application' ## # Renders the index view, giving `@validation_reports` and `@qa_reports` # for the specified provider. def index @current_provider = params[:provider] @validation_reports = Krikri::ValidationReport.new.all do self.provider_id = @current_provider end if @current_provider @qa_reports = Array(Krikri::QAReport.find_by(provider: @current_provider)) else @qa_reports = Krikri::QAReport.all end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
krikri-0.5.2 | app/controllers/krikri/reports_controller.rb |
krikri-0.5.1 | app/controllers/krikri/reports_controller.rb |
krikri-0.5.0 | app/controllers/krikri/reports_controller.rb |