Skip to content

Commit

Permalink
conflict resolved for task that populate data
Browse files Browse the repository at this point in the history
  • Loading branch information
Mathias Abraham committed Jul 4, 2012
2 parents 6e2756e + 03382e6 commit 20b1dae
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 17 deletions.
18 changes: 7 additions & 11 deletions lib/tasks/sample_data.rake
Expand Up @@ -74,17 +74,14 @@ amespace :db do
bid_amount= rand(10000...100000)
description=Faker::Lorem.paragraph(sentence_count = 3)

#Just to add different types of statuses

if n%3 == 0
status="Closed"
else if n%3==1
status="Lost"
else status="Initiated"
#Just to add different types of statuses




tender=Tender.new(title: title,
company_name: company_name,
buyer_name: buyer_name,
opening_date: opening_date,
closing_date: closing_date,
bid_amount: bid_amount ,
Expand All @@ -95,9 +92,8 @@ amespace :db do
# Just to add the 10 companies' to different tenders
tender.company_id=Company.find((n/4)+1).id
tender.save
end


end
end

end
end

15 changes: 9 additions & 6 deletions lib/tasks/sample_data.rake~
Expand Up @@ -74,16 +74,20 @@ amespace :db do
bid_amount= rand(10000...100000)
description=Faker::Lorem.paragraph(sentence_count = 3)

#Just to add different types of statuses

#Just to add different types of statuses

if n%3 == 0
status="Closed"
else if n%3==1
status="Lost"
else status="Initiated"




tender=Tender.new(title: title,
company_name: company_name,
buyer_name: buyer_name,
opening_date: opening_date,
closing_date: closing_date,
bid_amount: bid_amount ,
Expand All @@ -94,9 +98,8 @@ amespace :db do
# Just to add the 10 companies' to different tenders
tender.company_id=Company.find((n/4)+1).id
tender.save
end


end
end

end
end

0 comments on commit 20b1dae

Please sign in to comment.