diff --git a/dmp-frontend/src/app/datasets/listing/dataset-listing.component.ts b/dmp-frontend/src/app/datasets/listing/dataset-listing.component.ts index f5bdfdb3a..84b0f9909 100644 --- a/dmp-frontend/src/app/datasets/listing/dataset-listing.component.ts +++ b/dmp-frontend/src/app/datasets/listing/dataset-listing.component.ts @@ -55,7 +55,6 @@ export class DatasetListingComponent implements OnInit { ngOnInit() { this.route.params.subscribe((params: Params) => { this.dmpId = params['dmpId']; - // if (this.dmpId != null) this.setDmpTitle(this.dmpId); this.criteria.setCriteria(this.getDefaultCriteria(this.dmpId)); this.refresh(); this.criteria.setRefreshCallback(() => this.refresh()); diff --git a/dmp-frontend/src/app/dmps/listing/dmp-listing.component.html b/dmp-frontend/src/app/dmps/listing/dmp-listing.component.html index 4fd94cd57..e2eb714f3 100644 --- a/dmp-frontend/src/app/dmps/listing/dmp-listing.component.html +++ b/dmp-frontend/src/app/dmps/listing/dmp-listing.component.html @@ -59,8 +59,8 @@ - - + + - {{'DMP-WIZARD.FIRST-STEP.TITLE' | translate}} + {{'DMP-WIZARD.FIRST-STEP.DATASETS' | translate}} diff --git a/dmp-frontend/src/app/dmps/wizard/listing/dataset-wizard-listing.component.html b/dmp-frontend/src/app/dmps/wizard/listing/dataset-wizard-listing.component.html index e2ce0c91d..6ac6c32e2 100644 --- a/dmp-frontend/src/app/dmps/wizard/listing/dataset-wizard-listing.component.html +++ b/dmp-frontend/src/app/dmps/wizard/listing/dataset-wizard-listing.component.html @@ -1,5 +1,5 @@
-

{{titlePrefix}} {{'DATASET-LISTING.TITLE' | translate}}

+

{{'DATASET-LISTING.TITLE' | translate}} {{titlePrefix}}

diff --git a/dmp-frontend/src/app/dmps/wizard/listing/dataset-wizard-listing.component.ts b/dmp-frontend/src/app/dmps/wizard/listing/dataset-wizard-listing.component.ts index 2af12af8d..ed000e17e 100644 --- a/dmp-frontend/src/app/dmps/wizard/listing/dataset-wizard-listing.component.ts +++ b/dmp-frontend/src/app/dmps/wizard/listing/dataset-wizard-listing.component.ts @@ -56,7 +56,9 @@ export class DatasetWizardListingComponent implements OnInit { ngOnInit() { - if (this.dmpId != null) this.setDmpTitle(this.dmpId); + this.route.params.subscribe((params: Params) => { + if (this.dmpId != null) this.titlePrefix ="for " + params['dmpLabel']; + }); let request: DataTableRequest = new DataTableRequest(null, null, null); request.criteria = new DatasetCriteria(); request.criteria.dmpIds = [this.dmpId]; @@ -66,13 +68,6 @@ export class DatasetWizardListingComponent implements OnInit { this.formGroup.addControl("datasets", new FormBuilder().array(new Array())) } - setDmpTitle(dmpId: String) { - this.dataManagementPlanService.getSingle(dmpId).map(data => data as DataManagementPlanModel) - .subscribe(data => { - this.titlePrefix = data.label; - }); - } - selectionChanged(event,selectedItems) { this.formGroup.removeControl("datasets"); this.formGroup.addControl("datasets", new FormBuilder().array(new Array())) diff --git a/dmp-frontend/src/assets/lang/en.json b/dmp-frontend/src/assets/lang/en.json index 08979dd21..a2edf34aa 100644 --- a/dmp-frontend/src/assets/lang/en.json +++ b/dmp-frontend/src/assets/lang/en.json @@ -211,5 +211,16 @@ "SAVE": "Save", "CANCEL": "Cancel" } + }, + "DMP-WIZARD":{ + "FIRST-STEP":{ + "DMP":"DMP Editor", + "DATASETS":"Datasets" + }, + "ACTIONS": { + "NEXT": "Next", + "BACK": "Back", + "SAVE": "Save" + } } } \ No newline at end of file