update
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
<div class="handover icon-btn-sm" (click)="openHandoutDialog()" matTooltip="Schlüsselübergaben" [matTooltipShowDelay]="400"></div>
|
||||
<div class="magnifying-glass icon-btn-sm" (click)="openLostKeyDialog()" matTooltip="Verloren melden" [matTooltipShowDelay]="400"></div>
|
||||
<div class="delete icon-btn-sm" (click)="delete()" matTooltip="Löschen" [matTooltipShowDelay]="400"></div>
|
||||
<div class="delete icon-btn-sm" (click)="delete()" matTooltip="Löschen" [matTooltipShowDelay]="400"></div>
|
||||
<!-- <div class="edit icon-btn-sm" (click)="edit()" matTooltip="Bearbeiten" [matTooltipShowDelay]="400"></div> -->
|
||||
@@ -9,6 +9,7 @@ import { HotToastService } from '@ngxpert/hot-toast';
|
||||
import { HandoverDialogComponent } from '../../../../modules/keys/components/handover-dialog/handover-dialog.component';
|
||||
import { MatTooltipModule } from '@angular/material/tooltip';
|
||||
import { LostKeyComponent } from '../../../../modules/keys/components/lost-key/lost-key.component';
|
||||
import { CreateKeyComponent } from '../../../../modules/keys/create/create.component';
|
||||
|
||||
@Component({
|
||||
selector: 'app-ag-delete-key',
|
||||
@@ -50,6 +51,25 @@ export class AgDeleteKeyComponent implements ICellRendererAngularComp {
|
||||
})
|
||||
}
|
||||
|
||||
edit() {
|
||||
const ref = this.dialog.open(CreateKeyComponent, {
|
||||
data: this.key,
|
||||
autoFocus: false,
|
||||
maxWidth: '100vw',
|
||||
maxHeight: '100vh'
|
||||
})
|
||||
ref.afterClosed().subscribe({
|
||||
next: n => {
|
||||
if (n != null) {
|
||||
this.key.handedOut = n;
|
||||
this.params.api.refreshCells();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// ref.componentInstance.editKey(this.key)
|
||||
}
|
||||
|
||||
deleteThisKey() {
|
||||
this.params.api.setGridOption("loading", true);
|
||||
this.api.deleteKey(this.key.id).pipe(
|
||||
|
||||
Reference in New Issue
Block a user