Sha256: c675a1b639b99c194e6b155226876606a1c4499d3275cadf178df89ade5e5aa8
Contents?: true
Size: 748 Bytes
Versions: 3
Compression:
Stored size: 748 Bytes
Contents
module Seedy class UserGraph < AbstractGraph @@related_records = { 'Teams' => 1, 'Accounts' => 20, 'Bugs' => 60, 'Calls' => 480, 'Cases' => 80, 'Contacts' => 80, 'Documents'=> 80, 'Emails' => 320, 'EmailAddresses'=> 80, 'Leads' => 80, 'Meetings' => 160, 'Notes' => 80, 'Opportunities' => 40, 'Products' => 80, 'ProductBundles' => 40, 'Quotes' => 20, 'Tasks' => 80, } # Creates a new user record, and all the dependent records listed above def initialize user = Users.build @@related_records.each_pair do |module_name,count| count.times { record = module_name.build(self) DatabaseBuffer.insert(record) } end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
seedy-0.6.5 | lib/seedy/graphs/user_graph.rb |
seedy-0.6.4 | lib/seedy/graphs/user_graph.rb |
seedy-0.6.3 | lib/seedy/graphs/user_graph.rb |