Sha256: 5b238e387194e99564098bbb709146d719553a3f4ddfa5ba22cbbb45a68b89d9
Contents?: true
Size: 460 Bytes
Versions: 21
Compression:
Stored size: 460 Bytes
Contents
# frozen_string_literal: true module Motor class Dashboard < ::Motor::ApplicationRecord belongs_to :author, polymorphic: true, optional: true has_many :taggable_tags, as: :taggable has_many :tags, through: :taggable_tags, class_name: 'Motor::Tag' serialize :preferences, HashSerializer scope :active, -> { where(deleted_at: nil) } def queries Motor::Query.where(id: preferences[:layout].pluck(:query_id)) end end end
Version data entries
21 entries across 21 versions & 1 rubygems