Sha256: 11d74966058123160b3f8c86ecb5e72720c8d4db87fa54bbf583af9c9d6b85e8
Contents?: true
Size: 359 Bytes
Versions: 2
Compression:
Stored size: 359 Bytes
Contents
# encoding: utf-8 ## todo: how to best extends city model? module WorldDb::Model class City has_many :teams, class_name: 'SportDb::Model::Team', foreign_key: 'city_id' has_many :grounds, class_name: 'SportDb::Model::Ground', foreign_key: 'city_id' has_many :games, :through => :grounds end end # module WorldDb::Model
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
sportdb-1.8.3 | lib/sportdb/models/world/city.rb |
sportdb-1.8.2 | lib/sportdb/models/world/city.rb |