Sha256: 7d31224c2dcd015fbf5661d2596e9fd7ff21fc22d46ae247795289f1ecd8c4f7

Contents?: true

Size: 299 Bytes

Versions: 10

Compression:

Stored size: 299 Bytes

Contents

# Additions to ActiveRecord::Base.
module Pose
  module ActiveRecordBaseAdditions

    def posify &block
      raise "You must provide a block that returns the searchable content to 'posify'." unless block_given?
      include Pose::ModelAdditions
      self.pose_content = block
    end

  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
pose-1.3.4 lib/pose/activerecord_base_additions.rb
pose-1.3.3 lib/pose/activerecord_base_additions.rb
pose-1.3.2 lib/pose/activerecord_base_additions.rb
pose-1.3.1 lib/pose/activerecord_base_additions.rb
pose-1.3 lib/pose/activerecord_base_additions.rb
pose-1.2.5 lib/pose/activerecord_base_additions.rb
pose-1.2.4 lib/pose/activerecord_base_additions.rb
pose-1.2.3 lib/pose/activerecord_base_additions.rb
pose-1.2.2 lib/pose/activerecord_base_additions.rb
pose-1.2.1 lib/pose/activerecord_base_additions.rb