Hi,
I have a csv file which have the user detail. I want to migrate this
information into the "users" table.
My application use "Authlogic" for user aunthentication so I have to
encrypt the password during migration. I have written the script which
is reading the csv file and adds the record into "users" table, it is
working fine. But I am not able to encrypt the password.
I am doing like this:-
user=User.find(1)
user.password="password"
user.save
My users.rb as follows :-
"acts_as_authentic do |c|
c.transition_from_restful_authentication = true
end"
It is creating the entry in users table with crypted_password is equal
to "password".
How should I fix this?
Any help appreciated?
Thanks,
Tushar Gandhi
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.