diff --git a/frontend/cypress/support/helper/dom-helper/pages/statisticsPage.ts b/frontend/cypress/support/helper/dom-helper/pages/statisticsPage.ts index ff080818c3..2f8c96c2e5 100644 --- a/frontend/cypress/support/helper/dom-helper/pages/statisticsPage.ts +++ b/frontend/cypress/support/helper/dom-helper/pages/statisticsPage.ts @@ -28,17 +28,17 @@ export default class StatisticsPage extends Page { .should('exist'); cy.contains('Anzahl erreichter Objectives') .should('exist'); - cy.contains('Key Results mit min. Target Zone') + cy.contains('Key Results mit min. Target Zone erreicht') .should('exist'); cy.contains('Verhältnis metrische vs. ordinale Key Results') .should('exist'); - cy.contains('Verteilung der Zonen in den Key Results') + cy.contains('Verteilung der Key Results') .should('exist'); } validateKrsObjectives(objective: number, keyResult: number, relation: number) { this.verifyStatisticsField('objectives-key-results', objective, 'Objectives'); - this.verifyStatisticsField('objectives-key-results', keyResult, 'KeyResults'); + this.verifyStatisticsField('objectives-key-results', keyResult, 'Key Results'); this.verifyStatisticsField('objectives-key-results', relation, 'KR\'s/Objective'); } @@ -63,8 +63,8 @@ export default class StatisticsPage extends Page { validateKrTypeRelation( valueMetric: number, percentageMetric: string, valueOrdinal: number, percentageOrdinal: string, barProgress: number ) { - this.verifyStatisticsField('kr-type-relation', valueMetric, 'metrisch'); - this.verifyStatisticsField('kr-type-relation', valueOrdinal, 'ordinal'); + this.verifyStatisticsField('kr-type-relation', valueMetric, 'Metrisch'); + this.verifyStatisticsField('kr-type-relation', valueOrdinal, 'Ordinal'); this.verifyStatisticsFieldSubTitle('kr-type-relation', percentageMetric); this.verifyStatisticsFieldSubTitle('kr-type-relation', percentageOrdinal); this.verifyStatisticsCardBar('kr-type-relation', barProgress); diff --git a/frontend/src/app/statistics/statistics-card/statistics-card.component.html b/frontend/src/app/statistics/statistics-card/statistics-card.component.html index f03d235493..d2e26fb1d1 100644 --- a/frontend/src/app/statistics/statistics-card/statistics-card.component.html +++ b/frontend/src/app/statistics/statistics-card/statistics-card.component.html @@ -1,5 +1,6 @@ -
+

{{ title }}

+

{{ subtitle }}

@@ -11,4 +12,4 @@

{{ title }}

[colorPreset]="barColorPreset" [progress]="barProgress *100 || 0" > -
\ No newline at end of file +
diff --git a/frontend/src/app/statistics/statistics-card/statistics-card.component.scss b/frontend/src/app/statistics/statistics-card/statistics-card.component.scss index 29fe80d709..d24157141f 100644 --- a/frontend/src/app/statistics/statistics-card/statistics-card.component.scss +++ b/frontend/src/app/statistics/statistics-card/statistics-card.component.scss @@ -5,3 +5,13 @@ border: #5d6974 1px solid; border-radius: 4px; } + +.statistic-card h3 { + margin: 0; + padding: 0; + line-height: 0 !important; +} + +.statistic-card h3:empty { + display: none; +} diff --git a/frontend/src/app/statistics/statistics-card/statistics-card.component.ts b/frontend/src/app/statistics/statistics-card/statistics-card.component.ts index 9bfca90526..adde790e6b 100644 --- a/frontend/src/app/statistics/statistics-card/statistics-card.component.ts +++ b/frontend/src/app/statistics/statistics-card/statistics-card.component.ts @@ -9,6 +9,8 @@ import { Component, Input } from '@angular/core'; export class StatisticsCardComponent { @Input() title = ''; + @Input() subtitle = ''; + @Input() barProgress?: number; @Input() barColorPreset?: string; diff --git a/frontend/src/app/statistics/statistics.component.html b/frontend/src/app/statistics/statistics.component.html index efbbdac0e1..3fdd797c29 100644 --- a/frontend/src/app/statistics/statistics.component.html +++ b/frontend/src/app/statistics/statistics.component.html @@ -30,13 +30,13 @@

Auswertung

*ngIf="statistics.objectiveAmount ==0 && statistics.keyResultAmount ==0" [attr.data-testId]="'no-data-banner'" > - Für diese Filterkombination sind keine Objectives bzw. KeyResults vorhanden. + Für dieses Team ist im ausgewählten Zeitraum kein Objective vorhanden.
{{ statistics.objectiveAmount }} - {{ statistics.keyResultAmount }} + {{ statistics.keyResultAmount }} {{ krObjectiveRelation(statistics) | number : '1.0-1' }} @@ -65,7 +65,8 @@

Auswertung

@@ -80,17 +81,18 @@

Auswertung

[barProgress]="relation.metric" [barColorPreset]="'relation'" > - + {{ statistics.keyResultsMetricAmount }} - + {{ statistics.keyResultsOrdinalAmount }}