diff options
author | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-01-24 14:45:43 +0100 |
---|---|---|
committer | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-01-24 14:45:43 +0100 |
commit | 2d6ebf19e5cea45dd714f92a64b1b81e1200a811 (patch) | |
tree | 37e4796c11a5c3b433308cf53e320421b87e6a4b /app/models/user.rb | |
parent | e024c99b6ffeb725cf73ebf8b7b55957f36772f5 (diff) |
Create a central docu page which gets a link in the navbar.
Diffstat (limited to 'app/models/user.rb')
-rw-r--r-- | app/models/user.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/app/models/user.rb b/app/models/user.rb index 9e8cbc0..afb3f04 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -144,6 +144,9 @@ class User < ActiveRecord::Base self.pin_hash == Digest::SHA2.hexdigest( "#{self.pin_salt}#{entered_pin}" ) end + def admin? + self.user_groups.include?(UserGroup.find(2)) + end private |