bug fixes

This commit is contained in:
Diamantis Tziotzios 2019-12-13 13:15:12 +02:00
parent d4db0e204e
commit 55b6da619f
17 changed files with 123 additions and 61 deletions

View File

@ -1,5 +1,6 @@
import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
import { ReloadHelperComponent } from '@app/ui/misc/reload-helper/reload-helper.component';
import { B2AccessLoginComponent } from './ui/auth/login/b2access/b2access-login.component';
const appRoutes: Routes = [
@ -183,7 +184,8 @@ const appRoutes: Routes = [
component: B2AccessLoginComponent,
data: {
},
}
},
{ path: 'reload', component: ReloadHelperComponent }
];
@NgModule({

View File

@ -16,6 +16,7 @@ import { DatasetCreateWizardModule } from '@app/ui/dataset-create-wizard/dataset
import { BreadcrumbModule } from '@app/ui/misc/breadcrumb/breadcrumb.module';
import { HelpContentModule } from '@app/ui/misc/help-content/help-content.module';
import { NavigationModule } from '@app/ui/misc/navigation/navigation.module';
import { ReloadHelperComponent } from '@app/ui/misc/reload-helper/reload-helper.component';
import { NavbarModule } from '@app/ui/navbar/navbar.module';
import { SidebarModule } from '@app/ui/sidebar/sidebar.module';
import { MomentUtcDateAdapter } from '@common/date/moment-utc-date-adapter';
@ -94,7 +95,8 @@ const cookieConfig: NgcCookieConsentConfig = {
NgcCookieConsentModule.forRoot(cookieConfig)
],
declarations: [
AppComponent
AppComponent,
ReloadHelperComponent
],
providers: [
{

View File

@ -9,6 +9,7 @@ import { UserInfoListingModel } from "../user/user-info-listing";
import { DatasetModel } from "../dataset/dataset";
import { ProjectModel } from "../project/project";
import { FunderModel } from "../funder/funder";
import { DmpStatus } from '@app/core/common/enum/dmp-status';
export interface DmpModel {
id: string;
@ -16,7 +17,7 @@ export interface DmpModel {
groupId: String;
profile: String;
version: number;
status: Status;
status: DmpStatus;
lockable: boolean;
description: String;
grant: GrantListingModel;

View File

@ -203,10 +203,10 @@ export class ExternalServiceEditorModel {
buildForm(context: ValidationContext = null, disabled: boolean = false): FormGroup {
return new FormBuilder().group({
id: [this.id],
abbreviation: [this.abbreviation],
label: [this.label],
abbreviation: [this.abbreviation, Validators.required],
label: [this.label, Validators.required],
reference: [this.reference],
uri: [this.uri],
uri: [this.uri, Validators.required],
definition: [this.definition]
});
}
@ -246,10 +246,10 @@ export class ExternalRegistryEditorModel {
buildForm(context: ValidationContext = null, disabled: boolean = false): FormGroup {
return new FormBuilder().group({
id: [this.id],
abbreviation: [this.abbreviation],
label: [this.label],
abbreviation: [this.abbreviation, Validators.required],
label: [this.label, Validators.required],
reference: [this.reference],
uri: [this.uri],
uri: [this.uri, Validators.required],
definition: [this.definition],
source: [this.source]
});
@ -291,10 +291,10 @@ export class ExternalDatasetEditorModel {
buildForm(context: ValidationContext = null, disabled: boolean = false): FormGroup {
return new FormBuilder().group({
id: [this.id],
abbreviation: [this.abbreviation],
name: [this.name],
abbreviation: [this.abbreviation, Validators.required],
name: [this.name, Validators.required],
reference: [this.reference],
type: [this.type, Validators.required],
type: [this.type],
info: [this.info],
source: [this.source]
});
@ -335,9 +335,9 @@ export class ExternalDataRepositoryEditorModel {
buildForm(context: ValidationContext = null, disabled: boolean = false): FormGroup {
return new FormBuilder().group({
id: [this.id],
label: [this.label],
abbreviation: [this.abbreviation],
uri: [this.uri],
label: [this.label, [Validators.required]],
abbreviation: [this.abbreviation, [Validators.required]],
uri: [this.uri, [Validators.required]],
info: [this.info],
reference: [this.reference],
source: [this.source]

View File

@ -50,7 +50,7 @@
</div>
</div>
</div>
<form *ngIf="formGroup" (ngSubmit)="formSubmit()">
<form *ngIf="formGroup">
<div class="d-flex flex-column">
<mat-tab-group class="mt-3">
<mat-tab>
@ -112,8 +112,8 @@
<button mat-raised-button (click)="cancel()" type="button" class="cancelButton" color="primary">
{{'DMP-EDITOR.ACTIONS.CANCEL' | translate}}
</button>
<button *ngIf="datasetWizardModel.status == 0 || isNew" mat-raised-button [disabled]="!isSemiFormValid(formGroup)" class="saveButton" color="primary" (click)="save();" type="button">{{ 'DATASET-WIZARD.ACTIONS.SAVE' | translate }}</button>
<button *ngIf="datasetWizardModel.status == 0 || isNew" mat-raised-button [disabled]="!formGroup.valid" class="finalizeButton" color="primary" (click)="saveFinalize();" type="button">{{ 'DATASET-WIZARD.ACTIONS.FINALIZE' | translate }}</button>
<button *ngIf="datasetWizardModel.status == 0 || isNew" mat-raised-button class="saveButton" color="primary" (click)="save();" type="button">{{ 'DATASET-WIZARD.ACTIONS.SAVE' | translate }}</button>
<button *ngIf="datasetWizardModel.status == 0 || isNew" mat-raised-button class="finalizeButton" color="primary" (click)="saveFinalize();" type="button">{{ 'DATASET-WIZARD.ACTIONS.FINALIZE' | translate }}</button>
<div class="fill-space"></div>
<button *ngIf="hasReversableStatus()" mat-raised-button class="reverseButton" color="primary" (click)="reverse()" type="button">{{ 'DATASET-WIZARD.ACTIONS.REVERSE' | translate }}</button>
</div>

View File

@ -18,7 +18,6 @@ import { ExternalSourcesConfigurationService } from '@app/core/services/external
import { ExternalSourcesService } from '@app/core/services/external-sources/external-sources.service';
import { SnackBarNotificationLevel, UiNotificationService } from '@app/core/services/notification/ui-notification-service';
import { SingleAutoCompleteConfiguration } from '@app/library/auto-complete/single/single-auto-complete-configuration';
import { ConfirmationDialogComponent } from '@common/modules/confirmation-dialog/confirmation-dialog.component';
import { DatasetCopyDialogueComponent } from '@app/ui/dataset/dataset-wizard/dataset-copy-dialogue/dataset-copy-dialogue.component';
import { DatasetWizardEditorModel } from '@app/ui/dataset/dataset-wizard/dataset-wizard-editor.model';
import { BreadcrumbItem } from '@app/ui/misc/breadcrumb/definition/breadcrumb-item';
@ -26,7 +25,10 @@ import { IBreadCrumbComponent } from '@app/ui/misc/breadcrumb/definition/IBreadC
import { DatasetDescriptionFormEditorModel } from '@app/ui/misc/dataset-description-form/dataset-description-form.model';
import { LinkToScroll } from '@app/ui/misc/dataset-description-form/tableOfContentsMaterial/table-of-contents';
import { BaseComponent } from '@common/base/base.component';
import { FormService } from '@common/forms/form-service';
import { FormValidationErrorsDialogComponent } from '@common/forms/form-validation-errors-dialog/form-validation-errors-dialog.component';
import { ValidationErrorModel } from '@common/forms/validation/error-model/validation-error-model';
import { ConfirmationDialogComponent } from '@common/modules/confirmation-dialog/confirmation-dialog.component';
import { TranslateService } from '@ngx-translate/core';
import * as FileSaver from 'file-saver';
import { Observable, of as observableOf } from 'rxjs';
@ -70,7 +72,8 @@ export class DatasetWizardComponent extends BaseComponent implements OnInit, IBr
public dmpService: DmpService,
public dialog: MatDialog,
public externalSourcesConfigurationService: ExternalSourcesConfigurationService,
private uiNotificationService: UiNotificationService
private uiNotificationService: UiNotificationService,
private formService: FormService
) {
super();
}
@ -89,8 +92,8 @@ export class DatasetWizardComponent extends BaseComponent implements OnInit, IBr
initialItems: (extraData) => this.searchDmp(''),
displayFn: (item) => this.getDatasetDisplay(item),
titleFn: (item) => item['label'],
// iconFn: (item) => this.publicMode ? '' : (item['status'] ? 'lock' : 'lock_open'),
// linkFn: (item) => this.publicMode ? '/explore-plans/overview/' + item['id'] : '/plans/overview/' + item['id']
// iconFn: (item) => this.publicMode ? '' : (item['status'] ? 'lock' : 'lock_open'),
// linkFn: (item) => this.publicMode ? '/explore-plans/overview/' + item['id'] : '/plans/overview/' + item['id']
};
const params = this.route.snapshot.params;
@ -384,10 +387,10 @@ export class DatasetWizardComponent extends BaseComponent implements OnInit, IBr
});
}
formSubmit(): void {
if (!this.isFormValid()) { return; }
this.onSubmit();
}
// formSubmit(): void {
// if (!this.isFormValid()) { return; }
// this.onSubmit();
// }
public isFormValid() {
return this.formGroup.valid;
@ -403,36 +406,53 @@ export class DatasetWizardComponent extends BaseComponent implements OnInit, IBr
return isValid;
}
onSubmit(): void {
this.datasetWizardService.createDataset(this.formGroup.value)
.pipe(takeUntil(this._destroyed))
.subscribe(
complete => {
this.datasetWizardService.getSingle(complete.id)
.pipe(takeUntil(this._destroyed))
.subscribe(
result => {
this.datasetWizardModel = new DatasetWizardEditorModel().fromModel(result);
}
);
this.onCallbackSuccess();
},
error => this.onCallbackError(error)
);
}
// onSubmit(): void {
// this.datasetWizardService.createDataset(this.formGroup.value)
// .pipe(takeUntil(this._destroyed))
// .subscribe(
// complete => {
// this.datasetWizardService.getSingle(complete.id)
// .pipe(takeUntil(this._destroyed))
// .subscribe(
// result => {
// this.datasetWizardModel = new DatasetWizardEditorModel().fromModel(result);
// }
// );
// this.onCallbackSuccess();
// },
// error => this.onCallbackError(error)
// );
// }
submit() {
this.datasetWizardService.createDataset(this.formGroup.getRawValue())
.pipe(takeUntil(this._destroyed))
.subscribe(data => {
this.router.navigate(['datasets'], { queryParams: { dmpId: this.formGroup.get('dmp').value.id } });
});
.subscribe(
data => {
this.onCallbackSuccess(this.datasetWizardModel.id);
},
error => this.onCallbackError(error));
}
save() {
this.formService.touchAllFormFields(this.formGroup);
if (!this.isSemiFormValid(this.formGroup)) {
this.showValidationErrorsDialog();
return;
}
this.submit();
}
private showValidationErrorsDialog(projectOnly?: boolean) {
const dialogRef = this.dialog.open(FormValidationErrorsDialogComponent, {
disableClose: true,
data: {
formGroup: this.formGroup,
projectOnly: projectOnly
},
});
}
hasReversableStatus(): boolean {
if (this.formGroup.get('dmp').value) {
return (this.formGroup.get('dmp').value.status == DmpStatus.Draft && this.formGroup.get('status').value == DatasetStatus.Finalized);
@ -461,6 +481,11 @@ export class DatasetWizardComponent extends BaseComponent implements OnInit, IBr
}
saveFinalize() {
this.formService.touchAllFormFields(this.formGroup);
if (!this.isFormValid()) {
this.showValidationErrorsDialog();
return;
}
const dialogRef = this.dialog.open(ConfirmationDialogComponent, {
restoreFocus: false,
data: {
@ -479,8 +504,9 @@ export class DatasetWizardComponent extends BaseComponent implements OnInit, IBr
});
}
onCallbackSuccess(): void {
onCallbackSuccess(id?: String): void {
this.uiNotificationService.snackBarNotification(this.isNew ? this.language.instant('GENERAL.SNACK-BAR.SUCCESSFUL-CREATION') : this.language.instant('GENERAL.SNACK-BAR.SUCCESSFUL-UPDATE'), SnackBarNotificationLevel.Success);
id ? this.router.navigate(['/reload']).then(() => { this.router.navigate(['/datasets', 'edit', id]); }) : this.router.navigate(['/datasets']);
}
onCallbackError(error: any) {
@ -614,7 +640,7 @@ export class DatasetWizardComponent extends BaseComponent implements OnInit, IBr
this.datasetWizardService.delete(id)
.pipe(takeUntil(this._destroyed))
.subscribe(
complete => { this.onCallbackSuccess(); this.router.navigateByUrl('/datasets') },
complete => this.onCallbackSuccess(),
error => this.onCallbackError(error)
);
}

View File

@ -4,6 +4,7 @@ import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { ExternalDataRepositoryService } from '@app/core/services/external-sources/data-repository/extternal-data-repository.service';
import { ExternalDataRepositoryEditorModel } from '@app/ui/dataset/dataset-wizard/dataset-wizard-editor.model';
import { BaseComponent } from '@common/base/base.component';
import { FormService } from '@common/forms/form-service';
import { takeUntil } from 'rxjs/operators';
@Component({
@ -16,7 +17,8 @@ export class DatasetExternalDataRepositoryDialogEditorComponent extends BaseComp
constructor(
private externalDataRepositoryService: ExternalDataRepositoryService,
public dialogRef: MatDialogRef<DatasetExternalDataRepositoryDialogEditorComponent>,
@Inject(MAT_DIALOG_DATA) public data: any
@Inject(MAT_DIALOG_DATA) public data: any,
private formService: FormService
) { super(); }
ngOnInit(): void {
@ -25,6 +27,8 @@ export class DatasetExternalDataRepositoryDialogEditorComponent extends BaseComp
}
send(value: any) {
this.formService.touchAllFormFields(this.formGroup);
if (!this.formGroup.valid) { return; }
this.externalDataRepositoryService.create(this.formGroup.value)
.pipe(takeUntil(this._destroyed))
.subscribe(

View File

@ -5,6 +5,7 @@ import { ExternalDatasetService } from '@app/core/services/external-sources/data
import { ExternalDatasetEditorModel } from '@app/ui/dataset/dataset-wizard/dataset-wizard-editor.model';
import { BaseComponent } from '@common/base/base.component';
import { takeUntil } from 'rxjs/operators';
import { FormService } from '@common/forms/form-service';
@Component({
templateUrl: 'dataset-external-dataset-dialog-editor.component.html',
@ -16,7 +17,8 @@ export class DatasetExternalDatasetDialogEditorComponent extends BaseComponent i
constructor(
private externalDatasetService: ExternalDatasetService,
public dialogRef: MatDialogRef<DatasetExternalDatasetDialogEditorComponent>,
@Inject(MAT_DIALOG_DATA) public data: any
@Inject(MAT_DIALOG_DATA) public data: any,
private formService: FormService
) { super(); }
ngOnInit(): void {
@ -25,6 +27,8 @@ export class DatasetExternalDatasetDialogEditorComponent extends BaseComponent i
}
send(value: any) {
this.formService.touchAllFormFields(this.formGroup);
if (!this.formGroup.valid) { return; }
this.externalDatasetService.create(this.formGroup.value)
.pipe(takeUntil(this._destroyed))
.subscribe(

View File

@ -4,6 +4,7 @@ import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { ExternalRegistryService } from '@app/core/services/external-sources/registry/external-registry.service';
import { ExternalRegistryEditorModel } from '@app/ui/dataset/dataset-wizard/dataset-wizard-editor.model';
import { BaseComponent } from '@common/base/base.component';
import { FormService } from '@common/forms/form-service';
import { takeUntil } from 'rxjs/operators';
@Component({
@ -16,7 +17,8 @@ export class DatasetExternalRegistryDialogEditorComponent extends BaseComponent
constructor(
private externalRegistryService: ExternalRegistryService,
public dialogRef: MatDialogRef<DatasetExternalRegistryDialogEditorComponent>,
@Inject(MAT_DIALOG_DATA) public data: any
@Inject(MAT_DIALOG_DATA) public data: any,
private formService: FormService
) { super(); }
ngOnInit(): void {
@ -25,6 +27,8 @@ export class DatasetExternalRegistryDialogEditorComponent extends BaseComponent
}
send(value: any) {
this.formService.touchAllFormFields(this.formGroup);
if (!this.formGroup.valid) { return; }
this.externalRegistryService.create(this.formGroup.value)
.pipe(takeUntil(this._destroyed))
.subscribe(

View File

@ -5,6 +5,7 @@ import { ExternalServiceService } from '@app/core/services/external-sources/serv
import { ExternalServiceEditorModel } from '@app/ui/dataset/dataset-wizard/dataset-wizard-editor.model';
import { BaseComponent } from '@common/base/base.component';
import { takeUntil } from 'rxjs/operators';
import { FormService } from '@common/forms/form-service';
@Component({
templateUrl: 'dataset-external-service-dialog-editor.component.html',
@ -16,7 +17,8 @@ export class DatasetExternalServiceDialogEditorComponent extends BaseComponent i
constructor(
private externalServiceService: ExternalServiceService,
public dialogRef: MatDialogRef<DatasetExternalServiceDialogEditorComponent>,
@Inject(MAT_DIALOG_DATA) public data: any
@Inject(MAT_DIALOG_DATA) public data: any,
private formService: FormService
) { super(); }
ngOnInit(): void {
@ -25,6 +27,8 @@ export class DatasetExternalServiceDialogEditorComponent extends BaseComponent i
}
send() {
this.formService.touchAllFormFields(this.formGroup);
if (!this.formGroup.valid) { return; }
this.externalServiceService.create(this.formGroup.value)
.pipe(takeUntil(this._destroyed))
.subscribe(

View File

@ -1,6 +1,5 @@
import { NgModule } from '@angular/core';
import { AutoCompleteModule } from '@app/library/auto-complete/auto-complete.module';
import { ConfirmationDialogModule } from '@common/modules/confirmation-dialog/confirmation-dialog.module';
import { ExportMethodDialogModule } from '@app/library/export-method-dialog/export-method-dialog.module';
import { UrlListingModule } from '@app/library/url-listing/url-listing.module';
import { DatasetCopyDialogueComponent } from '@app/ui/dataset/dataset-wizard/dataset-copy-dialogue/dataset-copy-dialogue.component';
@ -20,6 +19,8 @@ import { DatasetDescriptionFormModule } from '@app/ui/misc/dataset-description-f
import { TableOfContentsModule } from '@app/ui/misc/dataset-description-form/tableOfContentsMaterial/table-of-contents.module';
import { ExternalSourcesModule } from '@app/ui/misc/external-sources/external-sources.module';
import { CommonFormsModule } from '@common/forms/common-forms.module';
import { FormValidationErrorsDialogModule } from '@common/forms/form-validation-errors-dialog/form-validation-errors-dialog.module';
import { ConfirmationDialogModule } from '@common/modules/confirmation-dialog/confirmation-dialog.module';
import { CommonUiModule } from '@common/ui/common-ui.module';
import { AngularStickyThingsModule } from '@w11k/angular-sticky-things';
@ -35,7 +36,8 @@ import { AngularStickyThingsModule } from '@w11k/angular-sticky-things';
DatasetDescriptionFormModule,
TableOfContentsModule,
AngularStickyThingsModule,
DatasetRoutingModule
DatasetRoutingModule,
FormValidationErrorsDialogModule
],
declarations: [
DatasetListingComponent,

View File

@ -16,6 +16,7 @@ import { ValidationErrorModel } from '@common/forms/validation/error-model/valid
import { TranslateService } from '@ngx-translate/core';
import { Observable, of as observableOf } from 'rxjs';
import { map, takeUntil } from 'rxjs/operators';
import { DmpStatus } from '@app/core/common/enum/dmp-status';
@Component({
@ -58,6 +59,7 @@ export class DmpCloneComponent extends BaseComponent implements OnInit {
this.dmp.project = new ProjectFormModel();
this.dmp.funder = new FunderFormModel();
this.dmp.fromModel(data);
this.dmp.status = DmpStatus.Draft;
this.formGroup = this.dmp.buildForm();
this.parentDmpLabel = this.formGroup.get('label').value;

View File

@ -109,7 +109,7 @@ export class DmpEditorComponent extends BaseComponent implements OnInit, IBreadC
this.dmp.fromModel(data);
this.formGroup = this.dmp.buildForm();
//this.registerFormEventsForDmpProfile(this.dmp.definition);
if (!this.editMode || this.dmp.status === Status.Inactive) {
if (!this.editMode || this.dmp.status === DmpStatus.Finalized) {
this.isFinalized = true;
this.formGroup.disable();
}
@ -146,7 +146,7 @@ export class DmpEditorComponent extends BaseComponent implements OnInit, IBreadC
this.dmp.fromModel(data);
this.formGroup = this.dmp.buildForm();
//this.registerFormEventsForDmpProfile(this.dmp.definition);
if (!this.editMode || this.dmp.status === Status.Inactive) { this.formGroup.disable(); }
if (!this.editMode || this.dmp.status === DmpStatus.Finalized) { this.formGroup.disable(); }
// if (!this.isAuthenticated) {
const breadcrumbs = [];
breadcrumbs.push({ parentComponentName: null, label: this.language.instant('NAV-BAR.PUBLIC-DMPS').toUpperCase(), url: '/plans' });
@ -271,7 +271,7 @@ export class DmpEditorComponent extends BaseComponent implements OnInit, IBreadC
onCallbackSuccess(id?: String): void {
this.uiNotificationService.snackBarNotification(this.isNew ? this.language.instant('GENERAL.SNACK-BAR.SUCCESSFUL-CREATION') : this.language.instant('GENERAL.SNACK-BAR.SUCCESSFUL-UPDATE'), SnackBarNotificationLevel.Success);
id != null ? this.router.navigate(['/plans', 'edit', id]) : this.router.navigate(['/plans']);
id != null ? this.router.navigate(['/reload']).then(() => { this.router.navigate(['/plans', 'edit', id]); }) : this.router.navigate(['/reload']).then(() => { this.router.navigate(['/plans']); });
}
onCallbackError(error: any) {

View File

@ -1,7 +1,7 @@
import { FormBuilder, FormGroup, Validators } from "@angular/forms";
import { DmpProfileFieldDataType } from '@app/core/common/enum/dmp-profile-field-type';
import { DmpProfileType } from '@app/core/common/enum/dmp-profile-type';
import { Status } from '@app/core/common/enum/Status';
import { DmpStatus } from '@app/core/common/enum/dmp-status';
import { DatasetModel } from '@app/core/model/dataset/dataset';
import { DmpProfile, DmpProfileDefinition } from '@app/core/model/dmp-profile/dmp-profile';
import { DmpProfileField } from '@app/core/model/dmp-profile/dmp-profile-field';
@ -29,7 +29,7 @@ export class DmpEditorModel {
public version: number;
public lockable: boolean;
public creator: UserModel;
public status: Status = Status.Active;
public status: DmpStatus = DmpStatus.Draft;
public description: String;
public grant: GrantTabModel;
public project: ProjectFormModel;

View File

@ -14,6 +14,7 @@ import { ProjectFormModel } from '@app/ui/dmp/editor/grant-tab/project-form-mode
import { BackendErrorValidator } from '@common/forms/validation/custom-validator';
import { ValidationErrorModel } from '@common/forms/validation/error-model/validation-error-model';
import { ValidationContext } from '@common/forms/validation/validation-context';
import { DmpStatus } from '@app/core/common/enum/dmp-status';
export class DmpWizardEditorModel {
public id: string;
@ -23,7 +24,7 @@ export class DmpWizardEditorModel {
public version: number;
public lockable: boolean;
public creator: UserModel;
public status: Status = Status.Active;
public status: DmpStatus = DmpStatus.Draft;
public description: String;
public grant: GrantTabModel;
public funder: FunderFormModel;

View File

@ -0,0 +1,9 @@
import { Component } from "@angular/core";
@Component({
template: "",
})
export class ReloadHelperComponent {
constructor() { }
}

View File

@ -7,11 +7,12 @@ import { ValidJsonValidator } from '@app/library/auto-complete/auto-complete-cus
import { BackendErrorValidator } from '@common/forms/validation/custom-validator';
import { ValidationErrorModel } from '@common/forms/validation/error-model/validation-error-model';
import { ValidationContext } from '@common/forms/validation/validation-context';
import { DmpStatus } from '@app/core/common/enum/dmp-status';
export class DmpEditorWizardModel {
public id: string;
public label: string;
public status: Status = Status.Active;
public status: DmpStatus = DmpStatus.Draft;
public description: String;
public datasetProfile: DatasetProfileModel;
public definition: DmpProfileDefinition;