Last change
on this file since e0cdea2 was 8e74e2f, checked in by DimitarSlezenkovski <dslezenkovski@…>, 4 years ago |
Fix bugs, add some more.
|
-
Property mode
set to
100644
|
File size:
740 bytes
|
Line | |
---|
1 | import { Component, OnInit, Inject } from '@angular/core';
|
---|
2 | import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
---|
3 | import { IPharmacy } from '../../shared/interfaces';
|
---|
4 |
|
---|
5 | @Component({
|
---|
6 | selector: 'app-edit-pharmacy-dialog',
|
---|
7 | templateUrl: './edit-pharmacy-dialog.component.html',
|
---|
8 | styleUrls: ['./edit-pharmacy-dialog.component.css']
|
---|
9 | })
|
---|
10 | export class EditPharmacyDialogComponent implements OnInit {
|
---|
11 | pharmacy: IPharmacy;
|
---|
12 |
|
---|
13 | constructor(private dialogRef: MatDialogRef<EditPharmacyDialogComponent>, @Inject(MAT_DIALOG_DATA) data) {
|
---|
14 | this.pharmacy = data;
|
---|
15 | }
|
---|
16 |
|
---|
17 | ngOnInit(): void {
|
---|
18 | }
|
---|
19 |
|
---|
20 | save() {
|
---|
21 | console.log(this.pharmacy);
|
---|
22 | this.dialogRef.close(this.pharmacy);
|
---|
23 | }
|
---|
24 |
|
---|
25 | close() {
|
---|
26 | this.dialogRef.close();
|
---|
27 | }
|
---|
28 |
|
---|
29 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.