Sha256: 6cd988ff954c69f4c85301cfb453a0fb29b52242a1b1d6f7f548e1c57fa7f8b4
Contents?: true
Size: 487 Bytes
Versions: 23
Compression:
Stored size: 487 Bytes
Contents
require_dependency "ishapi/application_controller" module Ishapi class ReportsController < ApplicationController def show @report = Report.unscoped.find_by :name_seo => params[:name_seo] authorize! :show, @report end def index authorize! :index, Report @reports = Report.all if params[:cityname] city = City.find_by :cityname => params[:cityname] @reports = @reports.where( :city_id => city.id ) end end end end
Version data entries
23 entries across 23 versions & 1 rubygems