Skip to content
Snippets Groups Projects
Commit e18a5d55 authored by Matthieu Benoist's avatar Matthieu Benoist
Browse files

move data initialisation from ngOnInit to initDatasetInfo (route based)

parent b191f027
Branches
Tags
1 merge request!146move data initialisation from ngOnInit to initDatasetInfo (route based)
...@@ -61,8 +61,6 @@ export class DatasetDetailComponent implements OnInit, OnDestroy { ...@@ -61,8 +61,6 @@ export class DatasetDetailComponent implements OnInit, OnDestroy {
this.isLoading = true; this.isLoading = true;
this.initDatasetInfo(); this.initDatasetInfo();
}); });
this._datasetDetailService.retrieveDatasetData().subscribe();
} }
ngOnDestroy() { ngOnDestroy() {
...@@ -249,6 +247,8 @@ export class DatasetDetailComponent implements OnInit, OnDestroy { ...@@ -249,6 +247,8 @@ export class DatasetDetailComponent implements OnInit, OnDestroy {
// Emit event to indicate to child component that the dataset has changed // Emit event to indicate to child component that the dataset has changed
this._datasetDetailService.datasetChanged(); this._datasetDetailService.datasetChanged();
// move subscription from ngOnInit
this._datasetDetailService.retrieveDatasetData().subscribe();
} }
setPosition() { setPosition() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment