Module: Deli::Helper::ClassMethods

Defined in:
lib/deli/helper.rb

Instance Method Summary (collapse)

Instance Method Details

- (Object) queries(*args, &block)



10
11
12
13
14
15
16
# File 'lib/deli/helper.rb', line 10

def queries(*args, &block)
  options               = args.extract_options!
  name                  = args.shift || self.class.name.underscore.gsub("_controller", "").singularize
  self.query_controller = ::Deli::Controller.new(name, options, &block)
  
  self.send :before_filter, :deli, :only => :index
end