From 14018e728e0d7314616aa2af79964f08c5a03e5d Mon Sep 17 00:00:00 2001 From: Stas Vilchik Date: Thu, 12 Oct 2017 15:31:14 +0200 Subject: SONAR-9790 Add project context to a file permalink --- server/sonar-web/src/main/js/helpers/urls.ts | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'server/sonar-web/src/main/js/helpers') diff --git a/server/sonar-web/src/main/js/helpers/urls.ts b/server/sonar-web/src/main/js/helpers/urls.ts index 91c5bc35d35..aae5afb93bc 100644 --- a/server/sonar-web/src/main/js/helpers/urls.ts +++ b/server/sonar-web/src/main/js/helpers/urls.ts @@ -172,3 +172,7 @@ export function getDeprecatedActiveRulesUrl(query = {}, organization?: string | export function getMarkdownHelpUrl(): string { return getBaseUrl() + '/markdown/help'; } + +export function getCodeUrl(project: string, branch?: string, selected?: string) { + return { pathname: '/code', query: { id: project, branch, selected } }; +} -- cgit v1.2.3