summaryrefslogtreecommitdiff
path: root/app/views/discussions/_notes.html.haml
blob: db5ab9399482d2f7398fe003fef9b5832188554c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
.discussion-notes
  %ul.notes{ data: { discussion_id: discussion.id } }
    = render partial: "shared/notes/note", collection: discussion.notes, as: :note

  .flash-container

  .discussion-reply-holder
    - if can_create_note?
      - if discussion.potentially_resolvable?
        - line_type = local_assigns.fetch(:line_type, nil)

        .btn-group-justified.discussion-with-resolve-btn{ role: "group" }
          .btn-group{ role: "group" }
            = link_to_reply_discussion(discussion, line_type)

          = render "discussions/resolve_all", discussion: discussion

          .btn-group.discussion-actions
            = render "discussions/new_issue_for_discussion", discussion: discussion, merge_request: discussion.noteable
            = render "discussions/jump_to_next", discussion: discussion
      - else
        = link_to_reply_discussion(discussion)
    - elsif !current_user
      .disabled-comment.text-center
        Please
        = link_to "register", new_session_path(:user, redirect_to_referer: 'yes')
        or
        = link_to "sign in", new_session_path(:user, redirect_to_referer: 'yes')
        to reply