Merge pull request #61 from gopesht/fix_first_admin_setup
Fix admin first setup, email and password in README
This commit is contained in:
commit
5ed51c7499
2 changed files with 8 additions and 8 deletions
|
|
@ -27,9 +27,13 @@ class User < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def setup_role
|
||||
if self.id == 1
|
||||
self.role_ids = [3]
|
||||
end
|
||||
|
||||
if self.role_ids.empty?
|
||||
self.role_ids = [1]
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def popup_details
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue