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.
-
#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.
-
#favourite ⇒ Boolean
Flag whether the folder is considered as a favourite.
-
#folders ⇒ Array<Folder>
The 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.
497 |
# File 'lib/lws/apps/resource.rb', line 497 belongs_to :account, class_name: "LWS::Auth::Account" |
#account_id ⇒ Integer
Returns the ID of the account of the user that created the folder.
502 |
# File 'lib/lws/apps/resource.rb', line 502 attribute :account_id |
#collections ⇒ Array<Collection>
Returns the collections filed in the folder.
506 |
# File 'lib/lws/apps/resource.rb', line 506 has_many :collections |
#company ⇒ LWS::Auth::Company
Returns the company the folder belongs to.
510 |
# File 'lib/lws/apps/resource.rb', line 510 belongs_to :company, class_name: "LWS::Auth::Company" |
#company_id ⇒ Integer
Returns the ID of the company the folder belongs to.
514 |
# File 'lib/lws/apps/resource.rb', line 514 attribute :company_id |
#deleted_at ⇒ String?
Returns the timestamp of when the folder was deleted.
518 |
# File 'lib/lws/apps/resource.rb', line 518 attribute :deleted_at |
#description ⇒ String
Returns the description of the folder.
522 |
# File 'lib/lws/apps/resource.rb', line 522 attribute :description |
#favourite ⇒ Boolean
Returns flag whether the folder is considered as a favourite.
530 |
# File 'lib/lws/apps/resource.rb', line 530 attribute :favourite |
#folders ⇒ Array<Folder>
Returns the folders contained in the folder.
526 |
# File 'lib/lws/apps/resource.rb', line 526 has_many :folders |
#name ⇒ String
Returns the name of the folder.
534 |
# File 'lib/lws/apps/resource.rb', line 534 attribute :name |
#parent ⇒ Folder?
Returns the parent folder of the folder.
538 539 |
# File 'lib/lws/apps/resource.rb', line 538 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.
543 |
# File 'lib/lws/apps/resource.rb', line 543 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
553 |
# File 'lib/lws/apps/resource.rb', line 553 attribute :permission |
#temporary ⇒ Boolean
Returns whether the folder is temporary and thus will be deleted after some time.
558 |
# File 'lib/lws/apps/resource.rb', line 558 attribute :temporary |