(url, item).pipe(
+ catchError((error: any) => throwError(error)));
+ }
+
}
diff --git a/dmp-frontend/src/app/ui/contact/contact-content/contact-content.component.html b/dmp-frontend/src/app/ui/contact/contact-content/contact-content.component.html
index 059ed608b..611c28e7a 100644
--- a/dmp-frontend/src/app/ui/contact/contact-content/contact-content.component.html
+++ b/dmp-frontend/src/app/ui/contact/contact-content/contact-content.component.html
@@ -15,7 +15,8 @@
{{'GENERAL.VALIDATION.REQUIRED' | translate}}
-
+
+
diff --git a/dmp-frontend/src/app/ui/contact/contact-content/contact-content.component.ts b/dmp-frontend/src/app/ui/contact/contact-content/contact-content.component.ts
index 71f6531d3..b79641261 100644
--- a/dmp-frontend/src/app/ui/contact/contact-content/contact-content.component.ts
+++ b/dmp-frontend/src/app/ui/contact/contact-content/contact-content.component.ts
@@ -1,7 +1,7 @@
import { Location } from '@angular/common';
import { Component, Input, OnInit } from '@angular/core';
import { AbstractControl, FormArray, FormControl, UntypedFormGroup } from '@angular/forms';
-import { ContactEmailFormModel } from '@app/core/model/contact/contact-email-form-model';
+import { ContactEmailFormModel, ContactSupportPersist } from '@app/core/model/contact/contact-support-form-model';
import { ContactSupportService } from '@app/core/services/contact-support/contact-support.service';
import { SnackBarNotificationLevel, UiNotificationService } from '@app/core/services/notification/ui-notification-service';
import { BaseComponent } from '@common/base/base.component';
@@ -51,7 +51,8 @@ export class ContactContentComponent extends BaseComponent implements OnInit {
}
send() {
- this.contactSupportService.postEmail(this.formGroup.value)
+ const formData = this.formService.getValue(this.formGroup.getRawValue()) as ContactSupportPersist;
+ this.contactSupportService.send(formData)
.pipe(takeUntil(this._destroyed))
.subscribe(
complete => this.onCallbackSuccess(),
diff --git a/dmp-frontend/src/app/ui/sidebar/sidebar-footer/sidebar-footer.component.ts b/dmp-frontend/src/app/ui/sidebar/sidebar-footer/sidebar-footer.component.ts
index cc159042a..29e0ebdc6 100644
--- a/dmp-frontend/src/app/ui/sidebar/sidebar-footer/sidebar-footer.component.ts
+++ b/dmp-frontend/src/app/ui/sidebar/sidebar-footer/sidebar-footer.component.ts
@@ -2,7 +2,7 @@ import { Component, OnInit } from '@angular/core';
import { UntypedFormGroup } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { Router } from '@angular/router';
-import { ContactEmailFormModel } from '@app/core/model/contact/contact-email-form-model';
+import { ContactEmailFormModel } from '@app/core/model/contact/contact-support-form-model';
import { ContactSupportService } from '@app/core/services/contact-support/contact-support.service';
import { SnackBarNotificationLevel, UiNotificationService } from '@app/core/services/notification/ui-notification-service';
import { ContactDialogComponent } from '@app/ui/contact/contact-dialog/contact-dialog.component';
@@ -63,7 +63,7 @@ export class SidebarFooterComponent extends BaseComponent implements OnInit {
});
dialogRef.afterClosed().pipe(takeUntil(this._destroyed)).subscribe(data => {
if (data) {
- this.contactSupportService.postEmail(data.value)
+ this.contactSupportService.send(data.value)
.pipe(takeUntil(this._destroyed))
.subscribe(
complete => this.onCallbackSuccess(),