Sha256: 5b5eb477dc383de2b218892f0f0758023a0840191c5bd3d6a5b40bd86bbfe013

Contents?: true

Size: 857 Bytes

Versions: 2

Compression:

Stored size: 857 Bytes

Contents

require "action_view"

module Datagrid

  extend ActiveSupport::Autoload

  autoload :Core
  autoload :ActiveModel
  autoload :Filters
  autoload :Columns
  autoload :Ordering

  autoload :Helper
  ActionView::Base.send(:include, Datagrid::Helper)
  
  autoload :FormBuilder
  ActionView::Helpers::FormBuilder.send(:include, Datagrid::FormBuilder)
  
  autoload :Renderer

  autoload :Engine

  def self.included(base)
    base.extend         ClassMethods
    base.class_eval do

      include ::Datagrid::Core
      include ::Datagrid::ActiveModel
      include ::Datagrid::Filters
      include ::Datagrid::Columns
      include ::Datagrid::Ordering

    end
  end # self.included

  module ClassMethods
  end # ClassMethods

  class ConfigurationError < StandardError; end
  class ArgumentError < ::ArgumentError; end

end

require "datagrid/scaffold"


Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
datagrid-0.8.1 lib/datagrid.rb
datagrid-0.8.0 lib/datagrid.rb