Class: HasHelpers::User
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- HasHelpers::User
- Defined in:
- app/models/has_helpers/user.rb
Instance Method Summary collapse
Instance Method Details
#organization ⇒ Object
10 11 12 |
# File 'app/models/has_helpers/user.rb', line 10 def organization user_organizations.find { |uo| uo.is_primary == true }&.organization end |
#organization_id ⇒ Object
14 15 16 |
# File 'app/models/has_helpers/user.rb', line 14 def organization_id user_organizations.find { |uo| uo.is_primary == true }&.organization_id end |