Rename string-cell component to cell

pull/2/head
Max Ehrlicher-Schmidt 4 years ago
parent ac6e88b1bf
commit 9ded4854af

@ -31,7 +31,7 @@ import { GraphQLModule } from './graphql.module';
import { ParticipantsComponent } from './pages/tables/participants/participants.component';
import { LendingStationsComponent } from './pages/tables/lending-stations/lending-stations.component';
import { TableOverviewComponent } from './pages/table-overview/table-overview.component';
import { StringCellComponent } from './components/tableComponents/string-cell/string-cell.component';
import { CellComponent } from './components/tableComponents/cell/cell.component';
import { MenuListItemComponent } from './components/menu-list-item/menu-list-item.component';
import { NavService }from './components/menu-list-item/nav.service';
@ -44,7 +44,7 @@ import { NavService }from './components/menu-list-item/nav.service';
ParticipantsComponent,
LendingStationsComponent,
TableOverviewComponent,
StringCellComponent,
CellComponent,
],
imports: [
BrowserModule,

@ -2,11 +2,11 @@ import { Component, Input, Output, EventEmitter } from '@angular/core';
import { catchError } from 'rxjs/operators';
@Component({
selector: 'app-string-cell',
templateUrl: './string-cell.component.html',
styleUrls: ['./string-cell.component.scss'],
selector: 'app-cell',
templateUrl: './cell.component.html',
styleUrls: ['./cell.component.scss'],
})
export class StringCellComponent {
export class CellComponent {
@Input()
value: number | string;
@Output() valueChange = new EventEmitter<number | string>();

@ -39,10 +39,10 @@
<ng-container matColumnDef="name" sticky>
<th mat-header-cell *matHeaderCellDef mat-sort-header>Name</th>
<td mat-cell *matCellDef="let element">
<app-string-cell
<app-cell
[editable]="element.isGettingEdited"
[(value)]="element.name"
></app-string-cell>
></app-cell>
</td>
</ng-container>
@ -56,10 +56,10 @@
<ng-container matColumnDef="frameNumber">
<th mat-header-cell cdkDrag *matHeaderCellDef mat-sort-header>Fahrgestellnummer</th>
<td mat-cell *matCellDef="let element">
<app-string-cell
<app-cell
[editable]="element.isGettingEdited"
[(value)]="element.security.frameNumber"
></app-string-cell>
></app-cell>
</td>
</ng-container>
@ -67,11 +67,11 @@
<ng-container matColumnDef="numberOfChildren">
<th mat-header-cell cdkDrag *matHeaderCellDef mat-sort-header>Anzahl Kinder</th>
<td mat-cell *matCellDef="let element">
<app-string-cell
<app-cell
[editable]="element.isGettingEdited"
[(value)]="element.numberOfChildren"
inputType="number"
></app-string-cell>
></app-cell>
</td>
</ng-container>
@ -79,11 +79,11 @@
<ng-container matColumnDef="numberOfWheels">
<th mat-header-cell cdkDrag *matHeaderCellDef i18n="WheelCount">Räderanzahl</th>
<td mat-cell *matCellDef="let element">
<app-string-cell
<app-cell
[editable]="element.isGettingEdited"
[(value)]="element.numberOfWheels"
inputType="number"
></app-string-cell>
></app-cell>
</td>
</ng-container>

Loading…
Cancel
Save