Sha256: 1f1ae81b0ca3696f3334f298ef65c37f0932871cbde36360e3dc3ec7fc37f1b1

Contents?: true

Size: 607 Bytes

Versions: 25

Compression:

Stored size: 607 Bytes

Contents

class Shopping::Product < Auth::Shopping::Product
	
	include Auth::Concerns::Work::GoodConcern

	create_es_index(INDEX_DEFINITION)

   def set_autocomplete_tags
      if self.new_record?
         self.tags << "product"
         self.tags << self.name
         self.tags << self.description
      end
   end

   def as_indexed_json(options={})
        {
            tags: self.tags,
            public: self.public,
            document_type: Auth::OmniAuth::Path.pathify(self.class.name.to_s),
            resource_id: self.resource_id,
            resource_class: self.resource_class
        }
    end

end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
wordjelly-auth-1.6.0 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.9 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.8 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.7 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.6 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.5 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.4 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.3 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.2 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.1 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.5.0 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.9 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.8 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.7 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.6 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.5 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.4 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.3 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.2 spec/dummy/app/models/shopping/product.rb
wordjelly-auth-1.4.0 spec/dummy/app/models/shopping/product.rb