Skip to content
Snippets Groups Projects
Commit b36cc68b authored by Hamza HRAMCHI's avatar Hamza HRAMCHI
Browse files

FEAT #15261 TIME 0:03 assign the existing sender to current Sender

parent 6498d2ed
No related branches found
No related tags found
No related merge requests found
...@@ -452,9 +452,8 @@ export class SentResourcePageComponent implements OnInit { ...@@ -452,9 +452,8 @@ export class SentResourcePageComponent implements OnInit {
setDefaultInfo() { setDefaultInfo() {
this.emailsubject = `[${this.resourceData.chrono}] ${this.resourceData.subject}`; this.emailsubject = `[${this.resourceData.chrono}] ${this.resourceData.subject}`;
this.emailsubject = this.emailsubject.substring(0, 70); this.emailsubject = this.emailsubject.substring(0, 70);
const withEmptyId = this.availableSenders.filter((element) => element.entityId === null);
if (this.headerService.user.entities.length === 0) { if (this.headerService.user.entities.length === 0) {
this.currentSender = withEmptyId[0]; this.currentSender = this.availableSenders[0];
} else { } else {
this.currentSender = this.availableSenders.filter(sender => sender.entityId === this.headerService.user.entities[0].id).length > 0 ? this.availableSenders.filter(sender => sender.entityId === this.headerService.user.entities[0].id)[0] : this.availableSenders[0]; this.currentSender = this.availableSenders.filter(sender => sender.entityId === this.headerService.user.entities[0].id).length > 0 ? this.availableSenders.filter(sender => sender.entityId === this.headerService.user.entities[0].id)[0] : this.availableSenders[0];
} }
......
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