diff --git a/dmp-frontend/src/app/ui/dataset-create-wizard/dmp-selector/dataset-dmp-selector.component.ts b/dmp-frontend/src/app/ui/dataset-create-wizard/dmp-selector/dataset-dmp-selector.component.ts index 619925565..f2600e2e7 100644 --- a/dmp-frontend/src/app/ui/dataset-create-wizard/dmp-selector/dataset-dmp-selector.component.ts +++ b/dmp-frontend/src/app/ui/dataset-create-wizard/dmp-selector/dataset-dmp-selector.component.ts @@ -18,6 +18,8 @@ import { IBreadCrumbComponent } from '@app/ui/misc/breadcrumb/definition/IBreadC import { BaseComponent } from '@common/base/base.component'; import { Observable } from 'rxjs'; import { map, takeUntil } from 'rxjs/operators'; +import { DatePipe } from "@angular/common"; +import { TranslateService } from "@ngx-translate/core"; @Component({ selector: 'dataset-dmp-selector-component', @@ -36,10 +38,10 @@ export class DatasetDmpSelector extends BaseComponent implements OnInit, IBreadC availableProfiles: DatasetProfileModel[] = []; constructor( - private router: Router, - private route: ActivatedRoute, public dmpService: DmpService, private datasetWizardService: DatasetWizardService, + private language: TranslateService, + private datepipe: DatePipe ) { super(); } @@ -50,7 +52,7 @@ export class DatasetDmpSelector extends BaseComponent implements OnInit, IBreadC initialItems: (extraData) => this.searchDmp(''), displayFn: (item) => item['label'], titleFn: (item) => item['label'], - subtitleFn: (item) => new Date(item['creationTime']).toISOString() + subtitleFn: (item) => this.language.instant('QUICKWIZARD.CREATE-ADD.ADD.CREATED') + " " + this.datepipe.transform(item['creationTime'], 'yyyy-MM-dd') }; this.formGroup.get('dmp').valueChanges diff --git a/dmp-frontend/src/assets/i18n/en.json b/dmp-frontend/src/assets/i18n/en.json index 1c78bee79..5ff1929e7 100644 --- a/dmp-frontend/src/assets/i18n/en.json +++ b/dmp-frontend/src/assets/i18n/en.json @@ -1146,9 +1146,7 @@ "CREATE-NEW-FUNDER": "Add Funder", "EXIST-FUNDER": "Use Existing Funder", "CREATE-NEW-PROJECT": "Add Project", - "EXIST-PROJECT": "Use Existing Project", - "CREATE-NEW-FUNDER": "Add Funder", - "EXIST-FUNDER": "Use Existing Funder" + "EXIST-PROJECT": "Use Existing Project" }, "FIRST-STEP": { "TITLE": "Grant", @@ -1200,7 +1198,8 @@ "TITLE": "Add a Dataset Description into an existing DMP", "DATASET-WIZARD": "Dataset Description Wizard", "POST-SELECTION-INFO": "This wizard simplifies the process of adding new Dataset Descriptions into existing DMPs, guiding you through and requesting only the most essential pieces of information for completing the task. Full access to the attributes of a Dataset Description can be obtained afterwards via the Dataset Description access menus of the System.", - "SUBTITLE": "This wizard allows you to describe additional Dataset Descriptions managed in the context of a DMP providing only the essential information for their description." + "SUBTITLE": "This wizard allows you to describe additional Dataset Descriptions managed in the context of a DMP providing only the essential information for their description.", + "CREATED": "Created on" } }, "SAVE-DIALOG": {