Sha256: 17c5758694401d82975de428ba2a85ee80637fd800d33d79fc2938780a084180

Contents?: true

Size: 453 Bytes

Versions: 1

Compression:

Stored size: 453 Bytes

Contents

module SportDB::Models


class Country < ActiveRecord::Base
  self.table_name = 'countries'

  def self.create_from_ary!( countries )
    countries.each do |values|
      
      ## key & title required
      attr = {
        :key   => values[0],
        :title => values[1],
        :tag   => values[2]
      }
      
      Country.create!( attr )
    end # each country
  end

end # class Country


end # module Models::SportDB

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sportdb-0.5.0 lib/sportdb/models/country.rb