Sha256: 8640fce640a5f2c717f8045551f429a1016e81509486f297b914c2d1246e2026

Contents?: true

Size: 971 Bytes

Versions: 27

Compression:

Stored size: 971 Bytes

Contents

module RocketCMS::ElasticSearch
  extend ActiveSupport::Concern
  included do
    searchkick(
        language: "Russian",
        suggest: ["name"],
        settings: {
            analysis: {
                analyzer: {
                    default_index: {
                        type: "custom",
                        tokenizer: "standard",
                        filter: ["standard", "lowercase", "asciifolding", "searchkick_index_shingle", "searchkick_stemmer", "snowball"]

                        # https://github.com/imotov/elasticsearch-analysis-morphology
                        # filter: ["standard", "lowercase", "asciifolding", "searchkick_index_shingle", "searchkick_stemmer", "snowball", "russian_morphology", "english_morphology"]
                    }
                }
            }
        }
    )

    def search_data
      {
          _id: _id,
          name: name,
          content: SmartExcerpt.strip_tags(content),
      }
    end
  end
end

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
ack_rocket_cms-0.9.2 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.9.1.3 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.9.1.2 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.9.1.1 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.9.1 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.9 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.8.2 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.8.0 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.7.1 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.7 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.6.4 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.6.3 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.6.2 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.6.1 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.6 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.5.2 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.5.1 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.5 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.4.1 lib/rocket_cms/elastic_search.rb
ack_rocket_cms-0.7.4 lib/rocket_cms/elastic_search.rb