diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-07-23 18:09:28 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-07-23 18:09:28 +0300 |
commit | 14fb5a922285d71fea67de59164ee4bb81ee3486 (patch) | |
tree | d3f585c54feb676aec2f14cc85fe32d615fd7fc0 /app/assets/javascripts/snippets | |
parent | d9b0b3243e3cd71a08ff5d4035b7882cc7a5a35f (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets/javascripts/snippets')
-rw-r--r-- | app/assets/javascripts/snippets/components/edit.vue | 2 | ||||
-rw-r--r-- | app/assets/javascripts/snippets/components/snippet_header.vue | 8 |
2 files changed, 6 insertions, 4 deletions
diff --git a/app/assets/javascripts/snippets/components/edit.vue b/app/assets/javascripts/snippets/components/edit.vue index 71ba4e0c183..95d2bb0698b 100644 --- a/app/assets/javascripts/snippets/components/edit.vue +++ b/app/assets/javascripts/snippets/components/edit.vue @@ -95,7 +95,7 @@ export default { }, cancelButtonHref() { if (this.newSnippet) { - return this.projectPath ? `/${this.projectPath}/snippets` : `/snippets`; + return this.projectPath ? `/${this.projectPath}/-/snippets` : `/-/snippets`; } return this.snippet.webUrl; }, diff --git a/app/assets/javascripts/snippets/components/snippet_header.vue b/app/assets/javascripts/snippets/components/snippet_header.vue index 707e2b0ea30..bd06ef2cfc9 100644 --- a/app/assets/javascripts/snippets/components/snippet_header.vue +++ b/app/assets/javascripts/snippets/components/snippet_header.vue @@ -91,8 +91,8 @@ export default { condition: this.canCreateSnippet, text: __('New snippet'), href: this.snippet.project - ? `${this.snippet.project.webUrl}/snippets/new` - : '/snippets/new', + ? `${this.snippet.project.webUrl}/-/snippets/new` + : '/-/snippets/new', variant: 'success', category: 'secondary', cssClass: 'ml-2', @@ -130,7 +130,9 @@ export default { }, methods: { redirectToSnippets() { - window.location.pathname = `${this.snippet.project?.fullPath || 'dashboard'}/snippets`; + window.location.pathname = this.snippet.project + ? `${this.snippet.project.fullPath}/-/snippets` + : 'dashboard/snippets'; }, closeDeleteModal() { this.$refs.deleteModal.hide(); |