Fixed seeds for registrar updates

This commit is contained in:
Priit Tark 2015-02-17 01:48:02 +02:00
parent 41bb72e043
commit dd1063c8f7
2 changed files with 9 additions and 2 deletions

View file

@ -29,6 +29,7 @@ ActiveRecord::Schema.define(version: 20150213104014) do
t.string "creator_str" t.string "creator_str"
t.string "updator_str" t.string "updator_str"
t.string "country_code" t.string "country_code"
t.string "state"
end end
create_table "api_users", force: :cascade do |t| create_table "api_users", force: :cascade do |t|

View file

@ -4,7 +4,10 @@
registrar1 = Registrar.where( registrar1 = Registrar.where(
name: 'Registrar First AS', name: 'Registrar First AS',
reg_no: '10300220', reg_no: '10300220',
address: 'Pärnu mnt 2, Tallinna linn, Harju maakond, 11415', street: 'Pärnu mnt 2',
city: 'Tallinn',
state: 'Harju maakond',
zip: '11415',
email: 'registrar1@example.com', email: 'registrar1@example.com',
country_code: 'EE' country_code: 'EE'
).first_or_create! ).first_or_create!
@ -19,7 +22,10 @@ ApiUser.where(
registrar2 = Registrar.where( registrar2 = Registrar.where(
name: 'Registrar Second AS', name: 'Registrar Second AS',
reg_no: '10529229', reg_no: '10529229',
address: 'Vabaduse pst 32, 11316 Tallinn', street: 'Vabaduse pst 32',
city: 'Tallinn',
state: 'Harju maakond',
zip: '11315',
email: 'registrar2@example.com', email: 'registrar2@example.com',
country_code: 'EE' country_code: 'EE'
).first_or_create! ).first_or_create!