Skip to content

Commit

Permalink
Merge pull request #1333 from eclipse-tractusx/chore/908-fix-notifica…
Browse files Browse the repository at this point in the history
…tion-detail

chore(release): 908 - Changed notification detail view.
  • Loading branch information
ds-lcapellino authored Jul 30, 2024
2 parents 6a8df39 + 26948a0 commit 31263dc
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 7 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,14 @@ to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
_**For better traceability add the corresponding GitHub issue number in each changelog entry, please.**_
## [UNRELEASED - DD.MM.YYYY]

### Added
- #908 Add owner field to affected parts view in notification details

### Changed
- #1252 adapt IRS example response for integration tests to reflect current state
- #1122 Fixed editing notification sendTo attribute
- #1328 Fixed semanticDataModel translation and part name within notification detail / edit view.
- #908 Renamed header in notification detail for parts from Supplier Parts to Affected parts

## [13.0.1 - 26.07.2024]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,8 @@ export class NotificationDetailComponent implements AfterViewInit, OnDestroy {
private setTableConfigs(data: Notification): void {
this.isReceived = !data.isFromSender;

const displayedColumns = [ 'id', 'semanticDataModel', 'nameAtManufacturer', 'semanticModelId' ];
const sortableColumns = { id: true, semanticDataModel: true, nameAtManufacturer: true, semanticModelId: true };
const displayedColumns = [ 'id', 'owner', 'semanticDataModel', 'nameAtManufacturer', 'semanticModelId' ];
const sortableColumns = { id: true, owner: true, semanticDataModel: true, nameAtManufacturer: true, semanticModelId: true };

const tableConfig = {
displayedColumns,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -421,14 +421,17 @@ <h3>{{ 'table.noResultFound' | i18n }}</h3>
<td
*matCellDef="let element" mat-cell class="table--cell" data-testid="table-component--cell-data"
[ngClass]="{'max-width-column': labelId === 'contracts' && column === 'contractId' }">
<ng-container *ngIf="!isDateElement(column)"
<ng-container *ngIf="!isDateElement(column) && !isOwnerElement(column)"
[ngTemplateOutlet]="tableConfig?.cellRenderers?.[column] ? tableConfig?.cellRenderers?.[column] : (column === 'constraints' ? constraintsFormat : (column === 'contractType' ? contractTypeFormat : autoFormat))"
[ngTemplateOutletContext]="{ value: element[column], row: element }"
>
</ng-container>
<ng-container *ngIf="isDateElement(column)">
{{ (element[column] | date:'yyyy-MM-dd HH:mm') }}
</ng-container>
<ng-container *ngIf="isOwnerElement(column)">
{{'table.owner.' + element[column]?.toLowerCase() | i18n}}
</ng-container>
</td>
</ng-container>
</ng-template>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -430,6 +430,11 @@ export class TableComponent {
return isDateFilter(key);
}

public isOwnerElement(key: string) {
const OWNER_KEY = [ 'owner'];
return OWNER_KEY.includes(key);
}

protected readonly MainAspectType = MainAspectType;
protected readonly ContractType = ContractType;
}
2 changes: 1 addition & 1 deletion frontend/src/assets/locales/de/page.alert.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

"subHeadline": {
"affectedParts": "Betroffene Produkte",
"supplierParts": "Produkte von Lieferanten"
"supplierParts": "Betroffene Produkte"
}
}
}
2 changes: 1 addition & 1 deletion frontend/src/assets/locales/de/page.investigation.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

"subHeadline": {
"affectedParts": "Betroffene Produkte",
"supplierParts": "Produkte von Lieferanten"
"supplierParts": "Betroffene Produkte"
}
}
}
2 changes: 1 addition & 1 deletion frontend/src/assets/locales/en/page.alert.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

"subHeadline": {
"affectedParts": "Affected parts",
"supplierParts": "Supplier parts"
"supplierParts": "Affected parts"
}
}
}
2 changes: 1 addition & 1 deletion frontend/src/assets/locales/en/page.investigation.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

"subHeadline": {
"affectedParts": "Affected parts",
"supplierParts": "Supplier parts"
"supplierParts": "Affected parts"
}
}
}

0 comments on commit 31263dc

Please sign in to comment.