Sha256: 6e9ddd0497e6748b8f6e95f1347133d33740150cf124be2afb398ef9b0960810
Contents?: true
Size: 374 Bytes
Versions: 8
Compression:
Stored size: 374 Bytes
Contents
require_dependency Locomotive::Engine.root.join('app', 'models', 'locomotive', 'page').to_s Locomotive::Page.class_eval do include Locomotive::Search::Extension search_by [:title, store: [:title, :slug, :site_id]], unless: :not_found? def indexable_id if respond_to?(:site_id) "site_#{site_id}_page_#{id}" else "page_#{id}" end end end
Version data entries
8 entries across 8 versions & 1 rubygems