updated models.rb and erd