Module: Gitlab::Client::Notes
- Included in:
- Gitlab::Client
- Defined in:
- lib/gitlab/client/notes.rb
Overview
Defines methods related to notes.
Instance Method Summary collapse
-
#create_issue_note(project, issue, body) ⇒ Gitlab::ObjectifiedHash
Creates a new issue note.
-
#create_note(project, body) ⇒ Gitlab::ObjectifiedHash
Creates a new wall note.
-
#create_snippet_note(project, snippet, body) ⇒ Gitlab::ObjectifiedHash
Creates a new snippet note.
-
#issue_note(project, issue, id) ⇒ Gitlab::ObjectifiedHash
Gets a single issue note.
-
#issue_notes(project, issue) ⇒ Array<Gitlab::ObjectifiedHash>
Gets a list of notes for a issue.
-
#note(project, id) ⇒ Gitlab::ObjectifiedHash
Gets a single wall note.
-
#notes(project) ⇒ Array<Gitlab::ObjectifiedHash>
Gets a list of projects notes.
-
#snippet_note(project, snippet, id) ⇒ Gitlab::ObjectifiedHash
Gets a single snippet note.
-
#snippet_notes(project, snippet) ⇒ Array<Gitlab::ObjectifiedHash>
Gets a list of notes for a snippet.
Instance Method Details
#create_issue_note(project, issue, body) ⇒ Gitlab::ObjectifiedHash
Creates a new issue note.
92 93 94 |
# File 'lib/gitlab/client/notes.rb', line 92 def create_issue_note(project, issue, body) post("/projects/#{project}/issues/#{issue}/notes", :body => {:body => body}) end |
#create_note(project, body) ⇒ Gitlab::ObjectifiedHash
Creates a new wall note.
82 83 84 |
# File 'lib/gitlab/client/notes.rb', line 82 def create_note(project, body) post("/projects/#{project}/notes", :body => {:body => body}) end |
#create_snippet_note(project, snippet, body) ⇒ Gitlab::ObjectifiedHash
Creates a new snippet note.
102 103 104 |
# File 'lib/gitlab/client/notes.rb', line 102 def create_snippet_note(project, snippet, body) post("/projects/#{project}/snippets/#{snippet}/notes", :body => {:body => body}) end |
#issue_note(project, issue, id) ⇒ Gitlab::ObjectifiedHash
Gets a single issue note.
60 61 62 |
# File 'lib/gitlab/client/notes.rb', line 60 def issue_note(project, issue, id) get("/projects/#{project}/issues/#{issue}/notes/#{id}") end |
#issue_notes(project, issue) ⇒ Array<Gitlab::ObjectifiedHash>
Gets a list of notes for a issue.
23 24 25 |
# File 'lib/gitlab/client/notes.rb', line 23 def issue_notes(project, issue) get("/projects/#{project}/issues/#{issue}/notes") end |
#note(project, id) ⇒ Gitlab::ObjectifiedHash
Gets a single wall note.
47 48 49 |
# File 'lib/gitlab/client/notes.rb', line 47 def note(project, id) get("/projects/#{project}/notes/#{id}") end |
#notes(project) ⇒ Array<Gitlab::ObjectifiedHash>
Gets a list of projects notes.
11 12 13 |
# File 'lib/gitlab/client/notes.rb', line 11 def notes(project) get("/projects/#{project}/notes") end |
#snippet_note(project, snippet, id) ⇒ Gitlab::ObjectifiedHash
Gets a single snippet note.
73 74 75 |
# File 'lib/gitlab/client/notes.rb', line 73 def snippet_note(project, snippet, id) get("/projects/#{project}/snippets/#{snippet}/notes/#{id}") end |
#snippet_notes(project, snippet) ⇒ Array<Gitlab::ObjectifiedHash>
Gets a list of notes for a snippet.
35 36 37 |
# File 'lib/gitlab/client/notes.rb', line 35 def snippet_notes(project, snippet) get("/projects/#{project}/snippets/#{snippet}/notes") end |