chewy
chewy copied to clipboard
How to migrate to chewy 7.2
befor chewy 7.2, I have some code like this
class MessagesIndex < Chewy::Index
[Post, Form, TemplatePost].each do |klass|
define_type klass do
field :id, type: 'integer'
field :title, type: 'string', analyzer: 'ik_max_word'
end
end
I can define mulityplie type in a single class, But After '7.2', 'define_type' was removed, How could I add multyply index for messages class
I keep getting this error Chewy::UndefinedIndex: Can not find index named `Messages#formIndex
Is there a way to create Index name likse Messages#formIndex ?