Class: ESP::User
- Defined in:
- lib/esp/resources/user.rb
Constant Summary
Constants inherited from Resource
Instance Method Summary collapse
-
#destroy ⇒ Object
Not Implemented.
-
#organization ⇒ Object
The organization this user belongs to.
-
#save ⇒ Object
Not Implemented.
-
#sub_organizations ⇒ Object
The collection of sub organizations that belong to the user.
-
#teams ⇒ Object
The collection of teams that belong to the user.
Methods inherited from Resource
arrange_options, filters, find, make_pageable, #serializable_hash, where
Instance Method Details
#destroy ⇒ Object
Not Implemented. You cannot destroy a User.
13 14 15 |
# File 'lib/esp/resources/user.rb', line 13 def destroy fail ESP::NotImplementedError end |
#organization ⇒ Object
The organization this user belongs to.
5 |
# File 'lib/esp/resources/user.rb', line 5 belongs_to :organization, class_name: 'ESP::Organization' |
#save ⇒ Object
Not Implemented. You cannot create or update a User.
8 9 10 |
# File 'lib/esp/resources/user.rb', line 8 def save fail ESP::NotImplementedError end |
#sub_organizations ⇒ Object
The collection of sub organizations that belong to the user.
19 20 21 22 |
# File 'lib/esp/resources/user.rb', line 19 def sub_organizations return attributes['sub_organizations'] if attributes['sub_organizations'].present? SubOrganization.where(id_in: sub_organization_ids) end |