Sha256: adf70b6d378b9905ef3fd9ee97cb4296f5bdfbf81cfa0b6e1098ab6aa29347a6
Contents?: true
Size: 631 Bytes
Versions: 8
Compression:
Stored size: 631 Bytes
Contents
module Headmin module Field extend ActiveSupport::Concern included do # Configuration has_closure_tree order: "position", numeric_order: true, dependent: :destroy # Associations belongs_to :fieldable, polymorphic: true, optional: true, touch: true belongs_to :field, optional: true, touch: true has_many :fields, foreign_key: "parent_id" accepts_nested_attributes_for :fields, allow_destroy: true # field_type: :files, :file has_many_attached :files, dependent: :detach accepts_nested_attributes_for :files_attachments, allow_destroy: true end end end
Version data entries
8 entries across 8 versions & 1 rubygems