|
|
|
@ -43,7 +43,7 @@ class Attachment < ActiveRecord::Base
|
|
|
|
|
#elasticsearch kaminari init
|
|
|
|
|
Kaminari::Hooks.init
|
|
|
|
|
Elasticsearch::Model::Response::Response.__send__ :include, Elasticsearch::Model::Response::Pagination::Kaminari
|
|
|
|
|
settings index: { number_of_shards: 1 } do
|
|
|
|
|
settings index: { number_of_shards: 5 } do
|
|
|
|
|
mappings dynamic: 'false' do
|
|
|
|
|
indexes :filename, analyzer: 'smartcn',index_options: 'offsets'
|
|
|
|
|
indexes :downloads, analyzer: 'smartcn',index_options: 'offsets'
|
|
|
|
|