Sha256: a00c93b1a0bf1aa6255fd97581ae73a7c20752771f63ddabcd737b97abbc0bf9

Contents?: true

Size: 280 Bytes

Versions: 5

Compression:

Stored size: 280 Bytes

Contents

# frozen_string_literal: true

require "models/arunit2_model"
require "active_support/core_ext/object/with_options"

class College < ARUnit2Model
  has_many :courses

  with_options dependent: :destroy do |assoc|
    assoc.has_many :students, -> { where(active: true) }
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
ibm_db-5.5.0 test/models/college.rb
ibm_db-5.4.1 test/models/college.rb
ibm_db-5.4.0 test/models/college.rb
ibm_db-5.3.2 test/models/college.rb
ibm_db-5.3.1 test/models/college.rb