Class: LWS::Auth::Company
- Inherits:
-
Generic::Model
- Object
- Spyke::Base
- Generic::Model
- LWS::Auth::Company
- Defined in:
- lib/lws/apps/auth.rb
Overview
The company class
Instance Attribute Summary collapse
-
#accounts ⇒ Array<Account>
The accounts that are assigned to the company.
-
#activated ⇒ Boolean
Whether the company has been activated.
-
#address ⇒ String
The address of the company (at least 2 characters long).
-
#apps ⇒ Array<App>
The apps that are assigned to the company.
-
#city ⇒ String
The city of the company (at least 2 characters long).
-
#contact_person ⇒ Account
The contact person of the company.
-
#contact_person_id ⇒ Fixnum
The ID of the contact person of the company.
-
#contracts ⇒ Array<Contract>
The contracts of the company.
-
#country ⇒ String
The country of the company (at least 2 characters long).
-
#created_at ⇒ String
readonly
The timestamp of when the company was created.
-
#expire ⇒ Boolean
Whether the company is planned to be discontinued after the contract ends.
-
#id ⇒ Fixnum
readonly
The (unique) ID of the company.
-
#licenses ⇒ Array<License>
The licenses of the company.
-
#name ⇒ String
The name of the company (at least 2 characters long).
-
#number ⇒ String
The street address number of the company (at least 1 character long).
-
#parent ⇒ Company?
The parenty company.
-
#parent_id ⇒ Fixnum?
The ID of the parenty company.
-
#telephone_number ⇒ String
The telephone number of the company (at least 2 characters long).
-
#updated_at ⇒ String
readonly
The timestamp of when the company was last updated.
-
#usage_reports ⇒ Array<UsageReport>
The usage reports available/generated for the company.
-
#uuid ⇒ String
The UUID of the company.
-
#zip_code ⇒ String
The zip code of the company (at least 2 characters long).
Instance Attribute Details
#accounts ⇒ Array<Account>
Returns the accounts that are assigned to the company.
167 |
# File 'lib/lws/apps/auth.rb', line 167 has_many :accounts |
#activated ⇒ Boolean
Returns whether the company has been activated.
171 |
# File 'lib/lws/apps/auth.rb', line 171 attribute :activated |
#address ⇒ String
Returns the address of the company (at least 2 characters long).
180 |
# File 'lib/lws/apps/auth.rb', line 180 attribute :address |
#apps ⇒ Array<App>
Returns the apps that are assigned to the company.
175 |
# File 'lib/lws/apps/auth.rb', line 175 has_many :apps |
#city ⇒ String
Returns the city of the company (at least 2 characters long).
185 |
# File 'lib/lws/apps/auth.rb', line 185 attribute :city |
#contact_person ⇒ Account
Returns the contact person of the company.
189 190 191 |
# File 'lib/lws/apps/auth.rb', line 189 belongs_to :contact_person, class_name: "LWS::Auth::Account", foreign_key: :contact_person_id, uri: "accounts/:id" |
#contact_person_id ⇒ Fixnum
Returns the ID of the contact person of the company.
195 |
# File 'lib/lws/apps/auth.rb', line 195 attribute :contact_person_id |
#contracts ⇒ Array<Contract>
Returns the contracts of the company.
199 |
# File 'lib/lws/apps/auth.rb', line 199 has_many :contracts |
#country ⇒ String
Returns the country of the company (at least 2 characters long).
204 |
# File 'lib/lws/apps/auth.rb', line 204 attribute :country |
#created_at ⇒ String (readonly)
Returns the timestamp of when the company was created.
256 |
# File 'lib/lws/apps/auth.rb', line 256 attribute :created_at |
#expire ⇒ Boolean
Returns whether the company is planned to be discontinued after the contract ends.
209 |
# File 'lib/lws/apps/auth.rb', line 209 attribute :expire |
#id ⇒ Fixnum (readonly)
Returns the (unique) ID of the company.
163 |
# File 'lib/lws/apps/auth.rb', line 163 attribute :id |
#licenses ⇒ Array<License>
Returns the licenses of the company.
213 |
# File 'lib/lws/apps/auth.rb', line 213 has_many :licenses |
#name ⇒ String
Returns the name of the company (at least 2 characters long).
218 |
# File 'lib/lws/apps/auth.rb', line 218 attribute :name |
#number ⇒ String
Returns the street address number of the company (at least 1 character long).
223 |
# File 'lib/lws/apps/auth.rb', line 223 attribute :number |
#parent ⇒ Company?
Returns the parenty company.
227 228 229 |
# File 'lib/lws/apps/auth.rb', line 227 belongs_to :parent, class_name: "LWS::Auth::Company", foreign_key: :parent_id, uri: "companies/:id" |
#parent_id ⇒ Fixnum?
Returns the ID of the parenty company.
233 |
# File 'lib/lws/apps/auth.rb', line 233 attribute :parent_id |
#telephone_number ⇒ String
Returns the telephone number of the company (at least 2 characters long).
238 |
# File 'lib/lws/apps/auth.rb', line 238 attribute :telephone_number |
#updated_at ⇒ String (readonly)
Returns the timestamp of when the company was last updated.
260 |
# File 'lib/lws/apps/auth.rb', line 260 attribute :updated_at |
#usage_reports ⇒ Array<UsageReport>
Returns the usage reports available/generated for the company.
243 |
# File 'lib/lws/apps/auth.rb', line 243 has_many :usage_reports, uri: "company/:company_id/reports" |
#uuid ⇒ String
Returns the UUID of the company.
247 |
# File 'lib/lws/apps/auth.rb', line 247 attribute :uuid |
#zip_code ⇒ String
Returns the zip code of the company (at least 2 characters long).
252 |
# File 'lib/lws/apps/auth.rb', line 252 attribute :zip_code |