Sha256: 3623b21a6e22ac5cb5dcfc965f4a1371c8ca73b715347e226505489e0415e2e2
Contents?: true
Size: 460 Bytes
Versions: 27
Compression:
Stored size: 460 Bytes
Contents
# frozen_string_literal: true class Actor include Mongoid::Document field :name field :after_custom_count, type: Integer, default: 0 has_and_belongs_to_many :tags embeds_many :things, validate: false, cascade_callbacks: true accepts_nested_attributes_for :things, allow_destroy: true define_model_callbacks :custom def do_something run_callbacks(:custom) do self.name = "custom" end end end require "support/models/actress"
Version data entries
27 entries across 27 versions & 1 rubygems