Sha256: 56d998b43edbb5eb30e1a2b1c13a128237c5efda0e38aa4238f175bc724e2312
Contents?: true
Size: 786 Bytes
Versions: 1
Compression:
Stored size: 786 Bytes
Contents
# This file should contain all the record creation needed to seed the database with its default values. # The data can then be loaded with the rails db:seed command (or created alongside the database with db:setup). # # Examples: # # movies = Movie.create([{ name: 'Star Wars' }, { name: 'Lord of the Rings' }]) # Character.create(name: 'Luke', movie: movies.first) <<-DOC age_dep = [100,75,65,60,50,45,35,28,22,20,18,15,12,10,8,8,7,7,6,6,5] kms_dep = [100,80,75,70,67,65,60,55,53,50,48,44,40,36,34,30,28,26,24,22,20,19,18,17,16,15,14,13,12,11,10] i = 0 while i < kms_dep.length MileageDepreciation.create(id: i+1, kms: i, depreciation: kms_dep[i]) i = i+1 end i = 0 while i < age_dep.length do AgeDepreciation.create(id: i+1, age: i, depreciation: age_dep[i]) i = i+1 end DOC
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
Depreciation-0.1.3 | db/seeds.rb |