aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/api
diff options
context:
space:
mode:
authorGrégoire Aubert <gregoire.aubert@sonarsource.com>2018-10-16 17:03:32 +0200
committerSonarTech <sonartech@sonarsource.com>2018-11-16 20:21:04 +0100
commit3ea9808248000c145f53a4f1cdb8711d63b97da4 (patch)
tree3b18082347d14718b90b3409b28740ca971b1568 /server/sonar-web/src/main/js/api
parentbcddd9658c7eea3bb5576bece3a0c2b985a7d506 (diff)
downloadsonarqube-3ea9808248000c145f53a4f1cdb8711d63b97da4.tar.gz
sonarqube-3ea9808248000c145f53a4f1cdb8711d63b97da4.zip
SONAR-11322 Import repos from bound organizations
* Move project create page in the create folder * Move HOCs to components * Update create project page * Move getting user organizations in CreateProjectPage (1 level higher) * Creact OrganizationSelect component * Create RemoteRepositories component * Use OrganizationSelect in ManualProjectCreate * Add OrganizationSelect and RemoteRepositories in AutoProjectCreate page * Rework validation of the create organization page * Add 'organization' param on list_repositories and provision_projects
Diffstat (limited to 'server/sonar-web/src/main/js/api')
-rw-r--r--server/sonar-web/src/main/js/api/alm-integration.ts13
1 files changed, 5 insertions, 8 deletions
diff --git a/server/sonar-web/src/main/js/api/alm-integration.ts b/server/sonar-web/src/main/js/api/alm-integration.ts
index c3f560044f2..5805eea72b9 100644
--- a/server/sonar-web/src/main/js/api/alm-integration.ts
+++ b/server/sonar-web/src/main/js/api/alm-integration.ts
@@ -35,18 +35,15 @@ export function getAlmOrganization(data: { installationId: string }): Promise<Al
);
}
-export function getRepositories(): Promise<{
- almIntegration: {
- installed: boolean;
- installationUrl: string;
- };
- repositories: AlmRepository[];
-}> {
- return getJSON('/api/alm_integration/list_repositories').catch(throwGlobalError);
+export function getRepositories(data: {
+ organization: string;
+}): Promise<{ repositories: AlmRepository[] }> {
+ return getJSON('/api/alm_integration/list_repositories', data).catch(throwGlobalError);
}
export function provisionProject(data: {
installationKeys: string[];
+ organization: string;
}): Promise<{ projects: Array<{ projectKey: string }> }> {
return postJSON('/api/alm_integration/provision_projects', {
...data,