aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.js
diff options
context:
space:
mode:
authorStas Vilchik <vilchiks@gmail.com>2017-03-30 14:09:03 +0200
committerStas Vilchik <stas-vilchik@users.noreply.github.com>2017-04-03 10:38:52 +0200
commit2c890d852dd6c355a64679e1d603c17bfac29bc5 (patch)
tree541bf0a796a10944ecf5ce72f719edc2d0321cff /server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.js
parent0f56fb56a40c1ee72f68dd170b12202e690086d9 (diff)
downloadsonarqube-2c890d852dd6c355a64679e1d603c17bfac29bc5.tar.gz
sonarqube-2c890d852dd6c355a64679e1d603c17bfac29bc5.zip
SONAR-8927 Change format of quality profile permalinks
Diffstat (limited to 'server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.js')
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.js32
1 files changed, 14 insertions, 18 deletions
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.js b/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.js
index f6760f674f5..ea38598bd65 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.js
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.js
@@ -34,26 +34,19 @@ type Props = {
updateProfiles: () => Promise<*>
};
+type ProfileInheritanceDetails = {
+ activeRuleCount: number,
+ key: string,
+ language: string,
+ name: string,
+ overridingRuleCount?: number
+};
+
type State = {
- ancestors?: Array<{
- activeRuleCount: number,
- key: string,
- name: string,
- overridingRuleCount?: number
- }>,
- children?: Array<{
- activeRuleCount: number,
- key: string,
- name: string,
- overridingRuleCount?: number
- }>,
+ ancestors?: Array<ProfileInheritanceDetails>,
+ children?: Array<ProfileInheritanceDetails>,
loading: boolean,
- profile?: {
- activeRuleCount: number,
- key: string,
- name: string,
- overridingRuleCount?: number
- }
+ profile?: ProfileInheritanceDetails
};
export default class ProfileInheritance extends React.PureComponent {
@@ -129,6 +122,7 @@ export default class ProfileInheritance extends React.PureComponent {
className="js-inheritance-ancestor"
depth={index}
key={ancestor.key}
+ language={this.props.profile.language}
organization={this.props.organization}
profile={ancestor}
/>
@@ -138,6 +132,7 @@ export default class ProfileInheritance extends React.PureComponent {
className={currentClassName}
depth={this.state.ancestors ? this.state.ancestors.length : 0}
displayLink={false}
+ language={this.props.profile.language}
organization={this.props.organization}
profile={this.state.profile}
/>
@@ -148,6 +143,7 @@ export default class ProfileInheritance extends React.PureComponent {
className="js-inheritance-child"
depth={this.state.ancestors ? this.state.ancestors.length + 1 : 0}
key={child.key}
+ language={this.props.profile.language}
organization={this.props.organization}
profile={child}
/>