Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2017-06-02 11:05:38 +0300
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2017-06-02 11:05:38 +0300
commitea531e1effa51bcec84e50a69901e6eec7c789c1 (patch)
treed3c1281deea1c9b2e8596cfa79a2e9d5cd4f7a10 /app/views/layouts/snippets.html.haml
parent4d141cb30dfcad94db89bdc08f4ea907dc2f8bdf (diff)
parentfc56d2fbaa2a317813c9dd7ba36e584162175fe6 (diff)
Merge remote-tracking branch 'origin/master' into 25426-group-dashboard-ui
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/views/layouts/snippets.html.haml')
-rw-r--r--app/views/layouts/snippets.html.haml6
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"