I implemented multiple users with devise, following steps of this link
I generate models per type of user and extends from Users Model. Then, I add a column named type
with string datatype to the user table in the database using a migration.
But, when I login with whatever user I get the following error:
ActiveRecord::StatementInvalid in Devise::SessionsController#create
Mysql2::Error: Unknown column 'type' in 'field list': UPDATE `users` SET `last_sign_in_at` = '2015-05-16 15:51:00', `current_sign_in_at` = '2015-05-26 22:49:23', `sign_in_count` = 10, `updated_at` = '2015-05-26 22:49:23' WHERE `users`.`id` = 1
Thanks for your advice! Sorry for my english.