Sha256: 76bd0d9a23cf7ed5e9521763afe023175438aa81f4ca02f8625edc56de6e87bb
Contents?: true
Size: 284 Bytes
Versions: 29
Compression:
Stored size: 284 Bytes
Contents
# frozen_string_literal: true class League include Mongoid::Document field :name, type: String embeds_many :divisions accepts_nested_attributes_for :divisions, allow_destroy: true before_destroy :destroy_children def destroy_children divisions.destroy_all end end
Version data entries
29 entries across 29 versions & 1 rubygems