是否可以打开自定义对话框组件,然后将数据发送回打开自定义对话框的组件?
this._dialogService.showCustomDialog({
component: CustomSelectComponent,
providers: [{provide: 'ROOM_ID', useValue: 1}],
isModal: true,
styles: {'width': '580px'},
clickOutsideToClose: true
}).subscribe((dialogReference: MdlDialogReference) => {
dialogReference.onHide().subscribe((data) => {
// DATA SHOULD CONTAIN THE DATA PASSED IN TO THE hide METHOD
console.log(data);
});
});