diff options
author | Jarka Kadlecova <jarka@gitlab.com> | 2017-05-03 10:48:01 +0200 |
---|---|---|
committer | Jarka Kadlecova <jarka@gitlab.com> | 2017-05-05 15:45:49 +0200 |
commit | e4f7b87ddb4ba83456871eb83b841192b1b56799 (patch) | |
tree | cf79d159784d2c5573acf8a56a8ea09bccaf2d81 /app/views/layouts/snippets.html.haml | |
parent | 729c006ff82fcb87afe8eb3e6a21254892f43afd (diff) | |
download | gitlab-ce-e4f7b87ddb4ba83456871eb83b841192b1b56799.tar.gz |
Support comments for personal snippets
Diffstat (limited to 'app/views/layouts/snippets.html.haml')
-rw-r--r-- | app/views/layouts/snippets.html.haml | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/views/layouts/snippets.html.haml b/app/views/layouts/snippets.html.haml index 02ca3ee7a28..98b75cea03f 100644 --- a/app/views/layouts/snippets.html.haml +++ b/app/views/layouts/snippets.html.haml @@ -1,3 +1,9 @@ - header_title "Snippets", snippets_path +- content_for :page_specific_javascripts do + - if @snippet&.persisted? && current_user + :javascript + window.uploads_path = "#{upload_path('personal_snippet', @snippet)}"; + window.preview_markdown_path = "#{preview_markdown_snippet_path(@snippet)}"; + = render template: "layouts/application" |