From 1c9b0b86b7fd752f67e6aea61e7b2f2b51e60762 Mon Sep 17 00:00:00 2001 From: JUNG YI DAM Date: Fri, 19 Aug 2022 10:16:14 +0000 Subject: [PATCH] =?UTF-8?q?=EB=8F=84=EB=A9=94=EC=9D=B8=EC=82=AD=EC=A0=9C?= =?UTF-8?q?=20=EC=95=8C=EB=A6=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../domain/components/list.component.html | 6 +++- .../domain/components/list.component.ts | 32 +++++++++++++++++++ 2 files changed, 37 insertions(+), 1 deletion(-) diff --git a/src/app/modules/admin/settings/domain/components/list.component.html b/src/app/modules/admin/settings/domain/components/list.component.html index 9947e48..b44a439 100644 --- a/src/app/modules/admin/settings/domain/components/list.component.html +++ b/src/app/modules/admin/settings/domain/components/list.component.html @@ -145,7 +145,11 @@ style="text-align: center" > diff --git a/src/app/modules/admin/settings/domain/components/list.component.ts b/src/app/modules/admin/settings/domain/components/list.component.ts index 1caa9e4..d34f830 100644 --- a/src/app/modules/admin/settings/domain/components/list.component.ts +++ b/src/app/modules/admin/settings/domain/components/list.component.ts @@ -92,6 +92,7 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy { private _unsubscribeAll: Subject = new Subject(); + configForm!: FormGroup; /** * Constructor */ @@ -120,6 +121,28 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy { // Mark for check this._changeDetectorRef.markForCheck(); }); */ + this.configForm = this._formBuilder.group({ + title: '알림', + message: + '정말로 삭제하시겠습니까? 삭제!', + icon: this._formBuilder.group({ + show: true, + name: 'heroicons_outline:exclamation', + color: 'warn', + }), + actions: this._formBuilder.group({ + confirm: this._formBuilder.group({ + show: true, + label: '삭제', + color: 'warn', + }), + cancel: this._formBuilder.group({ + show: true, + label: '취소', + }), + }), + dismissible: true, + }); this._activatedRoute.data.subscribe((data) => { let listSitesResult: ListSitesResponse.Result = data['listSites']; @@ -154,6 +177,15 @@ export class ListComponent implements OnInit, AfterViewInit, OnDestroy { // @ Private methods // ----------------------------------------------------------------------------------------------------- + __onClickRemoveBtn(event: MouseEvent, id: string): void { + // Open the dialog and save the reference of it + const dialogRef = this._fuseConfirmationService.open(this.configForm.value); + + // Subscribe to afterClosed from the dialog reference + dialogRef.afterClosed().subscribe((result) => { + console.log(result); + }); + } /** * Create product */