diff --git a/src/app/profile/dashboard/orientation-details/orientation-details.component.html b/src/app/profile/dashboard/orientation-details/orientation-details.component.html index 36f44aed0b29472c3c9bb30899a7e48b53d98686..7ab45f81e00273292cf2e4bb766e34590cec2a1a 100644 --- a/src/app/profile/dashboard/orientation-details/orientation-details.component.html +++ b/src/app/profile/dashboard/orientation-details/orientation-details.component.html @@ -263,7 +263,7 @@ </div> <div class="inline"> <app-svg-icon [iconClass]="'icon-20'" [folder]="'tags'" [icon]="'mail'" /> - <p><span class="category-name">Mail : </span>{{ orientation.orientator.email }}</p> + <p><span class="category-name">Mail : </span>{{ orientation.structureOrientator.structureMail }}</p> </div> <div class="inline"> <app-svg-icon [iconClass]="'icon-20'" [folder]="'tags'" [icon]="'clock'" /> diff --git a/src/app/profile/dashboard/orientation-details/orientation-details.component.scss b/src/app/profile/dashboard/orientation-details/orientation-details.component.scss index ab379d6b8bf5e515f439802244f7292653c16dbd..cb6b7ed782fbe9c24b173aeb08156d231361df06 100644 --- a/src/app/profile/dashboard/orientation-details/orientation-details.component.scss +++ b/src/app/profile/dashboard/orientation-details/orientation-details.component.scss @@ -115,7 +115,6 @@ .datePicker { display: inline-grid; input { - margin-top: 8px; width: 200px; height: 16px; padding: 8px; diff --git a/src/app/profile/dashboard/orientation-details/orientation-details.component.ts b/src/app/profile/dashboard/orientation-details/orientation-details.component.ts index def0180e800f21122861cea459d0f3c37c27aa6f..f049b8696483871beac077054ebfee2db0f851c4 100644 --- a/src/app/profile/dashboard/orientation-details/orientation-details.component.ts +++ b/src/app/profile/dashboard/orientation-details/orientation-details.component.ts @@ -30,6 +30,7 @@ export class OrientationDetailsComponent implements OnInit { public processingComment = ''; public selectedStatus = ''; public isClosed: boolean; + private closedStatuses = ['completed', 'uncompleted', 'expired']; ngOnInit(): void { this.route.queryParams.subscribe((params) => { @@ -43,7 +44,9 @@ export class OrientationDetailsComponent implements OnInit { this.orientation = orientation; this.acknowledgeNewOrientation(); this.isOrientationClosed(); - this.selectedStatus = this.orientation.status; + if (this.isClosed) { + this.selectedStatus = this.orientation.status; + } }); } }); @@ -102,12 +105,14 @@ export class OrientationDetailsComponent implements OnInit { } get isValidateDisabled(): boolean { + console.log(this.selectedStatus); + console.log(this.commentTextarea?.value?.trim()); + console.log(!this.selectedStatus || !this.commentTextarea?.value?.trim()); return !this.selectedStatus || !this.commentTextarea?.value?.trim(); } public isOrientationClosed(): void { - const closedStatuses = ['completed', 'uncompleted', 'expired']; - this.isClosed = closedStatuses.includes(this.orientation.status); + this.isClosed = this.closedStatuses.includes(this.orientation.status); } private patchOrientation(updatedFields): void {