aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/apps/permissions
diff options
context:
space:
mode:
authorJeremy Davis <jeremy.davis@sonarsource.com>2020-12-16 18:18:11 +0100
committersonartech <sonartech@sonarsource.com>2020-12-22 20:09:37 +0000
commitd83e1ab9825c2c14256a6680bf44d75c13ea4d5a (patch)
tree97d6e51f3823f1988fb7509d5dc8f0562ef2f40f /server/sonar-web/src/main/js/apps/permissions
parentd30fb63f3535dd0a4643f5123f38b5755d34de53 (diff)
downloadsonarqube-d83e1ab9825c2c14256a6680bf44d75c13ea4d5a.tar.gz
sonarqube-d83e1ab9825c2c14256a6680bf44d75c13ea4d5a.zip
SONAR-13999 Drop frontend organizations leftovers
Diffstat (limited to 'server/sonar-web/src/main/js/apps/permissions')
-rw-r--r--server/sonar-web/src/main/js/apps/permissions/global/components/AllHoldersList.tsx3
-rw-r--r--server/sonar-web/src/main/js/apps/permissions/project/components/ApplyTemplate.tsx2
-rw-r--r--server/sonar-web/src/main/js/apps/permissions/project/components/PageHeader.tsx1
-rw-r--r--server/sonar-web/src/main/js/apps/permissions/project/components/__tests__/ApplyTemplate-test.tsx2
4 files changed, 2 insertions, 6 deletions
diff --git a/server/sonar-web/src/main/js/apps/permissions/global/components/AllHoldersList.tsx b/server/sonar-web/src/main/js/apps/permissions/global/components/AllHoldersList.tsx
index ac153dcd69f..1c474cdb2fa 100644
--- a/server/sonar-web/src/main/js/apps/permissions/global/components/AllHoldersList.tsx
+++ b/server/sonar-web/src/main/js/apps/permissions/global/components/AllHoldersList.tsx
@@ -45,7 +45,6 @@ interface OwnProps {
onLoadMore: () => void;
onFilter: (filter: string) => void;
onSearch: (query: string) => void;
- organization?: T.Organization;
query: string;
revokePermissionFromGroup: (groupName: string, permission: string) => Promise<void>;
revokePermissionFromUser: (login: string, permission: string) => Promise<void>;
@@ -77,7 +76,7 @@ export class AllHoldersList extends React.PureComponent<Props> {
render() {
const { appState, filter, groups, groupsPaging, users, usersPaging } = this.props;
- const l10nPrefix = this.props.organization ? 'organizations_permissions' : 'global_permissions';
+ const l10nPrefix = 'global_permissions';
const hasPortfoliosEnabled = appState.qualifiers.includes(ComponentQualifier.Portfolio);
const hasApplicationsEnabled = appState.qualifiers.includes(ComponentQualifier.Application);
diff --git a/server/sonar-web/src/main/js/apps/permissions/project/components/ApplyTemplate.tsx b/server/sonar-web/src/main/js/apps/permissions/project/components/ApplyTemplate.tsx
index 7b7189ec18f..9ed5b5da893 100644
--- a/server/sonar-web/src/main/js/apps/permissions/project/components/ApplyTemplate.tsx
+++ b/server/sonar-web/src/main/js/apps/permissions/project/components/ApplyTemplate.tsx
@@ -29,7 +29,6 @@ import { applyTemplateToProject, getPermissionTemplates } from '../../../../api/
interface Props {
onApply?: () => void;
onClose: () => void;
- organization?: string;
project: { key: string; name: string };
}
@@ -71,7 +70,6 @@ export default class ApplyTemplate extends React.PureComponent<Props, State> {
handleSubmit = () => {
if (this.state.permissionTemplate) {
return applyTemplateToProject({
- organization: this.props.organization,
projectKey: this.props.project.key,
templateId: this.state.permissionTemplate
}).then(() => {
diff --git a/server/sonar-web/src/main/js/apps/permissions/project/components/PageHeader.tsx b/server/sonar-web/src/main/js/apps/permissions/project/components/PageHeader.tsx
index 64c1e76cd4b..4bdf603fc1a 100644
--- a/server/sonar-web/src/main/js/apps/permissions/project/components/PageHeader.tsx
+++ b/server/sonar-web/src/main/js/apps/permissions/project/components/PageHeader.tsx
@@ -89,7 +89,6 @@ export default class PageHeader extends React.PureComponent<Props, State> {
<ApplyTemplate
onApply={this.props.loadHolders}
onClose={this.handleApplyTemplateClose}
- organization={component.organization}
project={component}
/>
)}
diff --git a/server/sonar-web/src/main/js/apps/permissions/project/components/__tests__/ApplyTemplate-test.tsx b/server/sonar-web/src/main/js/apps/permissions/project/components/__tests__/ApplyTemplate-test.tsx
index 28432a0976b..9d097921506 100644
--- a/server/sonar-web/src/main/js/apps/permissions/project/components/__tests__/ApplyTemplate-test.tsx
+++ b/server/sonar-web/src/main/js/apps/permissions/project/components/__tests__/ApplyTemplate-test.tsx
@@ -45,7 +45,7 @@ jest.mock('../../../../../api/permissions', () => ({
it('render correctly', async () => {
const wrapper = shallow(
- <ApplyTemplate onClose={jest.fn()} organization="foo" project={{ key: 'foo', name: 'Foo' }} />
+ <ApplyTemplate onClose={jest.fn()} project={{ key: 'foo', name: 'Foo' }} />
);
expect(wrapper).toMatchSnapshot();
await waitAndUpdate(wrapper);