diff options
author | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-02-15 15:03:37 +0100 |
---|---|---|
committer | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-02-15 15:03:37 +0100 |
commit | 14e8e9923666991703f747a4abfd6fbfb96d2dc1 (patch) | |
tree | 9442c98cd9e7bf95f48e36b7d3220be6f4cb0e7c /app/models/user.rb | |
parent | 3d11d0a3a047a12bfd40b61252e269cabac76225 (diff) |
Show sim_cards of a user. Misc.
Diffstat (limited to 'app/models/user.rb')
-rw-r--r-- | app/models/user.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/user.rb b/app/models/user.rb index fdcd617..6c67351 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -150,6 +150,10 @@ class User < ActiveRecord::Base self.user_groups.include?(UserGroup.find(2)) end + def sim_cards + SimCard.where(:sip_account_id => self.sip_account_ids) + end + private def hash_new_pin |