import { Component , ViewRef } from '@angular/core' ; import { HsCompositionsService } from '../compositions.service' ; import { HsDialogComponent } from '../../layout/dialogs/dialog-component.interface' ; import { HsDialogContainerService } from '../../layout/dialogs/dialog-container.service' ; @ Component ( { selector : 'hs-compositions-delete-dialog' , templateUrl : './dialog_delete.html' , } ) export class HsCompositionsDeleteDialogComponent implements HsDialogComponent { viewRef : ViewRef ; data : any ; constructor ( public HsDialogContainerService , public HsCompositionsService ) { } close ( ) { this . HsDialogContainerService . destroy ( this ) ; } public param { object } composition description delete ( composition ) { this . HsCompositionsService . deleteComposition ( composition ) ; this . close ( ) ; } }