Class: LWS::Resource::Folder
- Inherits:
-
Generic::Model
- Object
- Spyke::Base
- Generic::Model
- LWS::Resource::Folder
- Defined in:
- lib/lws/apps/resource.rb
Overview
The folder class
Instance Attribute Summary collapse
-
#account ⇒ LWS::Auth::Account
The account of the user that created the folder.
-
#account_id ⇒ Integer
The ID of the account of the user that created the folder.
-
#collection_ids ⇒ Array<Integer>
The IDs of the collections filed in the folder.
-
#collections ⇒ Array<Collection>
The collections filed in the folder.
-
#company ⇒ LWS::Auth::Company
The company the folder belongs to.
-
#company_id ⇒ Integer
The ID of the company the folder belongs to.
-
#deleted_at ⇒ String?
The timestamp of when the folder was deleted.
-
#description ⇒ String
The description of the folder.
-
#email ⇒ String
readonly
The email adress of the folder.
-
#favourite ⇒ Boolean
Flag whether the folder is considered as a favourite.
-
#folder_ids ⇒ Array<Integer>
The IDs of the (child) folders contained in the folder.
-
#folders ⇒ Array<Folder>
The (child) folders contained in the folder.
-
#name ⇒ String
The name of the folder.
-
#parent ⇒ Folder?
The parent folder of the folder.
-
#parent_id ⇒ Integer?
The ID of the parent folder of the folder.
-
#permission ⇒ "700", ...
A UNIX-style permission that indicates whether the folder is shared and who can read/write in it: * 700: not shared (the default), only readable/writable by the associated account * 740: readable by anyone in the company * 770: readable/writeable by anyone in the company.
-
#temporary ⇒ Boolean
Whether the folder is temporary and thus will be deleted after some time.
Attributes inherited from Generic::Model
#created_at, #id, #updated_at, #url, #url_html
Method Summary
Methods inherited from Generic::Model
#deep_dup, #dig, #reload, #rollback, #save
Instance Attribute Details
#account ⇒ LWS::Auth::Account
Returns the account of the user that created the folder.
442 |
# File 'lib/lws/apps/resource.rb', line 442 belongs_to :account, class_name: "LWS::Auth::Account" |
#account_id ⇒ Integer
Returns the ID of the account of the user that created the folder.
447 |
# File 'lib/lws/apps/resource.rb', line 447 attribute :account_id |
#collection_ids ⇒ Array<Integer>
Returns the IDs of the collections filed in the folder.
451 |
# File 'lib/lws/apps/resource.rb', line 451 attribute :collection_ids |
#collections ⇒ Array<Collection>
Returns the collections filed in the folder.
455 |
# File 'lib/lws/apps/resource.rb', line 455 has_many :collections |
#company ⇒ LWS::Auth::Company
Returns the company the folder belongs to.
459 |
# File 'lib/lws/apps/resource.rb', line 459 belongs_to :company, class_name: "LWS::Auth::Company" |
#company_id ⇒ Integer
Returns the ID of the company the folder belongs to.
463 |
# File 'lib/lws/apps/resource.rb', line 463 attribute :company_id |
#deleted_at ⇒ String?
Returns the timestamp of when the folder was deleted.
467 |
# File 'lib/lws/apps/resource.rb', line 467 attribute :deleted_at |
#description ⇒ String
Returns the description of the folder.
471 |
# File 'lib/lws/apps/resource.rb', line 471 attribute :description |
#email ⇒ String (readonly)
Returns the email adress of the folder.
475 |
# File 'lib/lws/apps/resource.rb', line 475 attribute :email |
#favourite ⇒ Boolean
Returns flag whether the folder is considered as a favourite.
488 |
# File 'lib/lws/apps/resource.rb', line 488 attribute :favourite |
#folder_ids ⇒ Array<Integer>
Returns the IDs of the (child) folders contained in the folder.
480 |
# File 'lib/lws/apps/resource.rb', line 480 attribute :folder_ids |
#folders ⇒ Array<Folder>
Returns the (child) folders contained in the folder.
484 |
# File 'lib/lws/apps/resource.rb', line 484 has_many :folders |
#name ⇒ String
Returns the name of the folder.
492 |
# File 'lib/lws/apps/resource.rb', line 492 attribute :name |
#parent ⇒ Folder?
Returns the parent folder of the folder.
496 497 |
# File 'lib/lws/apps/resource.rb', line 496 belongs_to :parent, class_name: "LWS::Resource::Folder", foreign_key: "parent_id" |
#parent_id ⇒ Integer?
Returns the ID of the parent folder of the folder.
501 |
# File 'lib/lws/apps/resource.rb', line 501 attribute :parent_id |
#permission ⇒ "700", ...
A UNIX-style permission that indicates whether the folder is shared and who can read/write in it:
-
700: not shared (the default), only readable/writable by the associated account
-
740: readable by anyone in the company
-
770: readable/writeable by anyone in the company
511 |
# File 'lib/lws/apps/resource.rb', line 511 attribute :permission |
#temporary ⇒ Boolean
Returns whether the folder is temporary and thus will be deleted after some time.
516 |
# File 'lib/lws/apps/resource.rb', line 516 attribute :temporary |