Class: Osso::Models::EnterpriseAccount
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- Osso::Models::EnterpriseAccount
- Defined in:
- lib/osso/models/enterprise_account.rb
Overview
Base class for Enterprises. This should map one-to-one with your own Account model. Persisting the EnterpriseAccount id in your application’s database is recommended. The table also includes fields for external IDs such that you can persist your ID for an account in your Osso instance.
Instance Method Summary collapse
- #provider ⇒ Object (also: #identity_provider)
- #single_provider? ⇒ Boolean
Instance Method Details
#provider ⇒ Object Also known as: identity_provider
20 21 22 23 24 |
# File 'lib/osso/models/enterprise_account.rb', line 20 def provider return nil unless single_provider? identity_providers.first end |
#single_provider? ⇒ Boolean
16 17 18 |
# File 'lib/osso/models/enterprise_account.rb', line 16 def single_provider? identity_providers.not_pending.one? end |