Module: Teamlab::ProjectsTemplates
- Included in:
- Project
- Defined in:
- lib/teamlab/modules/projects/projects_templates.rb
Overview
Module for projects templates methods
Instance Method Summary collapse
- #create_template(title, options = {}) ⇒ Object
- #delete_template(id) ⇒ Object
- #get_template(template_id) ⇒ Object
- #get_templates ⇒ Object
- #update_template(id, title) ⇒ Object
Instance Method Details
#create_template(title, options = {}) ⇒ Object
14 15 16 |
# File 'lib/teamlab/modules/projects/projects_templates.rb', line 14 def create_template(title, = {}) @request.post(['template'], { title: title }.merge()) end |
#delete_template(id) ⇒ Object
22 23 24 |
# File 'lib/teamlab/modules/projects/projects_templates.rb', line 22 def delete_template(id) @request.delete(['template', id.to_s]) end |
#get_template(template_id) ⇒ Object
10 11 12 |
# File 'lib/teamlab/modules/projects/projects_templates.rb', line 10 def get_template(template_id) @request.get(['template', template_id.to_s]) end |
#get_templates ⇒ Object
6 7 8 |
# File 'lib/teamlab/modules/projects/projects_templates.rb', line 6 def get_templates @request.get(['template']) end |
#update_template(id, title) ⇒ Object
18 19 20 |
# File 'lib/teamlab/modules/projects/projects_templates.rb', line 18 def update_template(id, title) @request.put(['template', id.to_s], title: title) end |