Skip to content
Snippets Groups Projects
Commit 84516d02 authored by Marlène SIMONDANT's avatar Marlène SIMONDANT
Browse files

fix closeOrientation

parent a5e222c3
No related branches found
No related tags found
1 merge request!983feat(dashboard) : create dashboard !
Pipeline #124256 passed
......@@ -66,13 +66,20 @@ export class OrientationDetailsComponent implements OnInit {
const comment = this.commentTextarea?.value || '';
const sanitizedHtml = this.sanitizer.sanitize(SecurityContext.HTML, comment);
const sanitizedComment = this.extractPlainText(sanitizedHtml || '');
this.patchOrientation({
const patchData: any = {
status: this.selectedStatus,
action: null,
processingComment: sanitizedComment,
closingDate: isClosed ? null : new Date(),
modifiedBy: this.userProfile._id,
});
};
// Only add closingDate if orientation is not already closed
if (!isClosed) {
patchData.closingDate = new Date();
}
this.patchOrientation(patchData);
}
this.isModalOpenned = false;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment