Class: ClickUp::Folder
- Inherits:
-
APIResource
- Object
- APIResource
- ClickUp::Folder
- Defined in:
- lib/click_up/hierarchy/folder.rb
Class Method Summary collapse
- .formatted_params(params) ⇒ Object
- .index_path(params = {}) ⇒ Object
- .rejected_params ⇒ Object
- .resource_path(params = {}) ⇒ Object
Methods included from APIOperations::All
Methods included from APIOperations::Create
Methods included from APIOperations::Get
Methods included from APIOperations::Delete
Methods inherited from APIResource
Class Method Details
.formatted_params(params) ⇒ Object
26 27 28 29 30 31 |
# File 'lib/click_up/hierarchy/folder.rb', line 26 def formatted_params(params) params.reject {|key, _| rejected_params.include?(key) } # { # "name": "Updated Folder Name" # } end |
.index_path(params = {}) ⇒ Object
11 12 13 |
# File 'lib/click_up/hierarchy/folder.rb', line 11 def index_path(params={}) "/space/#{params[:space_id]}/folder" end |
.rejected_params ⇒ Object
19 20 21 22 23 24 |
# File 'lib/click_up/hierarchy/folder.rb', line 19 def rejected_params [ :id, :space_id ] end |
.resource_path(params = {}) ⇒ Object
15 16 17 |
# File 'lib/click_up/hierarchy/folder.rb', line 15 def resource_path(params={}) "/folder/#{params[:id]}" end |