sample/db/sample/gaku/changes/student_changes.rb in gaku-0.0.3 vs sample/db/sample/gaku/changes/student_changes.rb in gaku-0.1.0
- old
+ new
@@ -13,22 +13,20 @@
counter += 1
random_student = random_person.merge(
commute_method_type: @commute_method_type,
enrollment_status_code: @enrollment_status,
scholarship_status: @scholarship_status,
- student_id_number: "number_#{counter}",
- student_foreign_id_number: "foreign_number_#{counter}",
+ foreign_id_code: "foreign_id_code_#{counter}"
)
student = Gaku::Student.where(random_student).first_or_create!
student.name = Faker::Name.first_name
student.middle_name = Faker::Name.first_name
student.surname = Faker::Name.last_name
student.enrollment_status_code = enrollment_status.code
student.commute_method_type = commute_method_type
student.scholarship_status = scholarship_status
- student.student_id_number = "number_#{counter+100}"
- student.student_foreign_id_number = "foreign_number_#{counter+100}"
+ student.foreign_id_code = "foreign_code_#{counter+100}"
student.save!
student.soft_delete
student.destroy
end