Sha256: 455456d4a4908e333e15f00687d080c5a727c7b4831858c91b35eaaaddc233c9

Contents?: true

Size: 430 Bytes

Versions: 2

Compression:

Stored size: 430 Bytes

Contents

# encoding: utf-8

## todo: how to best extends country model?

module WorldDb::Model

  class Country
    has_many :teams,   class_name: 'SportDb::Model::Team',   foreign_key: 'country_id'
    has_many :leagues, class_name: 'SportDb::Model::League', foreign_key: 'country_id'
    has_many :grounds, class_name: 'SportDb::Model::Ground', foreign_key: 'country_id'
  end # class Country

end # module WorldDb::Model

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
sportdb-1.8.3 lib/sportdb/models/world/country.rb
sportdb-1.8.2 lib/sportdb/models/world/country.rb