debian-mirror-gitlab/app/views/projects/snippets/index.html.haml
2018-03-17 18:26:18 +05:30

12 lines
482 B
Text

- page_title "Snippets"
- if current_user
.top-area
- include_private = @project.team.member?(current_user) || current_user.admin?
= render partial: 'snippets/snippets_scope_menu', locals: { subject: @project, include_private: include_private }
.nav-controls
- if can?(current_user, :create_project_snippet, @project)
= link_to "New snippet", new_project_snippet_path(@project), class: "btn btn-new", title: "New snippet"
= render 'snippets/snippets'