aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorXinhui2016-09-21 17:52:38 +0200
committerXinhui2016-09-21 17:52:38 +0200
commitaee34855c9a546ac846a60bf837f2093c670ab4e (patch)
tree8f803d21f5d402c4d9fab195b014cc5747a6c2e8
parentd5d1923112cf4c47b78b7fe415c0f638a96c7074 (diff)
downloadchouette-core-aee34855c9a546ac846a60bf837f2093c670ab4e.tar.bz2
Fix operator seed
Refs #1687
-rw-r--r--db/seeds.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/db/seeds.rb b/db/seeds.rb
index 956b9562c..9d91a9e85 100644
--- a/db/seeds.rb
+++ b/db/seeds.rb
@@ -19,8 +19,8 @@ end
OfferWorkbench.find_or_create_by(name: "Gestion de l'offre", organisation: stif)
-operator = Organisation.find_or_create_by(code: 'transporteur-a') do |organisation|
- operator.name = "Transporteur A"
+operator = Organisation.find_or_create_by!(name: 'Transporteur A') do |organisation|
+ organisation.code = "transporteur-a"
end
operator.users.find_or_create_by!(username: "transporteur") do |user|
@@ -35,7 +35,7 @@ stop_area_referential = StopAreaReferential.find_or_create_by(name: "Reflex") do
end
10.times do |n|
- stop_area_referential.stop_areas.find_or_create_by name: "Test #{n}", area_type: "Quay"
+ stop_area_referential.stop_areas.find_or_create_by name: "Test #{n}", area_type: "Quay", objectid: "StopArea: #{n}"
end
line_referential = LineReferential.find_or_create_by(name: "CodifLigne") do |referential|