chewy icon indicating copy to clipboard operation
chewy copied to clipboard

How to migrate to chewy 7.2

Open lyb124553153 opened this issue 11 months ago • 1 comments

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

lyb124553153 avatar Feb 26 '24 06:02 lyb124553153

Is there a way to create Index name likse Messages#formIndex ?

lyb124553153 avatar Feb 26 '24 08:02 lyb124553153