main #48

Closed
sebastian wants to merge 44 commits from main into inventory
3 changed files with 25 additions and 1 deletions
Showing only changes of commit eae55eb49c - Show all commits

View File

@ -1 +1,21 @@
<p>inherited-item-characteristic-editor works!</p>
<table mat-table [dataSource]="datasource" class="mat-elevation-z8">
<ng-container matColumnDef="characteristic">
<th mat-header-cell *matHeaderCellDef>Characteristic</th>
<td mat-cell *matCellDef="let characteristicValue">{{characteristicValue.key.characteristicName}}</td>
</ng-container>
<ng-container matColumnDef="value">
<th mat-header-cell *matHeaderCellDef>Value</th>
<td mat-cell *matCellDef="let characteristicValue">{{characteristicValue.value}}</td>
</ng-container>
<ng-container matColumnDef="edit">
<th mat-header-cell *matHeaderCellDef></th>
<td mat-cell *matCellDef="let characteristicValue">
<button mat-icon-button><mat-icon>edit</mat-icon></button>
</td>
</ng-container>
<tr mat-header-row *matHeaderRowDef="displayedColumns"></tr>
<tr mat-row *matRowDef="let row; columns: displayedColumns;"></tr>
</table>

View File

@ -15,6 +15,7 @@ export class InheritedItemCharacteristicEditorComponent implements OnInit{
@Input() item: Item | undefined
datasource: MatTableDataSource<ItemgroupCharacteristicValue> = new MatTableDataSource<ItemgroupCharacteristicValue>();
displayedColumns: string[] = ['characteristic', 'value', 'edit']
ngOnInit() {
this.item!.initializeItemCharacteristics();