@vgroup/dialbox 0.5.33 → 0.5.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/lib/components/call-progress/call-progress.component.mjs +4 -2
- package/esm2020/lib/dialbox.component.mjs +15 -9
- package/fesm2015/vgroup-dialbox.mjs +17 -9
- package/fesm2015/vgroup-dialbox.mjs.map +1 -1
- package/fesm2020/vgroup-dialbox.mjs +17 -9
- package/fesm2020/vgroup-dialbox.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -2146,13 +2146,14 @@ class CallProgressComponent {
|
|
|
2146
2146
|
this.endIncomingCallEvent.emit(c);
|
|
2147
2147
|
return false;
|
|
2148
2148
|
}
|
|
2149
|
-
let participantId = isAllCallEnd ? 'all' : c.participantId
|
|
2149
|
+
let participantId = isAllCallEnd ? 'all' : c.participantId;
|
|
2150
2150
|
let conferenceId = isAllCallEnd ? 'all' : c.conferenceId || this.currentCall.conferenceId;
|
|
2151
2151
|
let res = await this.getRemoveParticipants(participantId, conferenceId);
|
|
2152
2152
|
if (res?.status == 201 && res?.message == 'participant already left') {
|
|
2153
2153
|
this.cdr.detectChanges();
|
|
2154
2154
|
}
|
|
2155
2155
|
await this.getAllParticipants(this.currentCall.conferenceSid);
|
|
2156
|
+
this.currentCallList = this.currentCallList.filter((res) => res.participantId !== c.participantId);
|
|
2156
2157
|
this.incomeingCallSocketService.pause();
|
|
2157
2158
|
this.endIncomingCallEvent.emit(c);
|
|
2158
2159
|
this.cdr.detectChanges();
|
|
@@ -2525,6 +2526,7 @@ class CallProgressComponent {
|
|
|
2525
2526
|
else {
|
|
2526
2527
|
let index = this.currentCallList.findIndex((res) => res.participantId == data.participantId);
|
|
2527
2528
|
this.currentCallList.splice(index, 1);
|
|
2529
|
+
swal("Error", res?.message, "error");
|
|
2528
2530
|
this.incomeingCallSocketService.pause();
|
|
2529
2531
|
this.endCallEvent.emit(data);
|
|
2530
2532
|
}
|
|
@@ -3583,18 +3585,22 @@ class DialboxComponent {
|
|
|
3583
3585
|
// console.log("WS Event Received:", incomingCallData.data);
|
|
3584
3586
|
this.twilioService.conferenceCallInfo = incomingCallData;
|
|
3585
3587
|
if (!!incomingCallData?.length) {
|
|
3588
|
+
incomingCallData = incomingCallData.filter((item) => item.participants?.length > 0);
|
|
3586
3589
|
// this.incomingCallsList = incomingCallData.participants.filter((item: any) => !item.isLeft) || [];
|
|
3587
3590
|
this.incomingCallsList = incomingCallData || [];
|
|
3588
3591
|
let parentCall = [];
|
|
3589
|
-
this.notificationCallList.
|
|
3590
|
-
|
|
3591
|
-
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3595
|
-
|
|
3592
|
+
if (this.notificationCallList.length) {
|
|
3593
|
+
this.notificationCallList.filter((res) => res.endTime >= Date.now());
|
|
3594
|
+
this.notificationCallList.forEach((call) => {
|
|
3595
|
+
incomingCallData.forEach((item) => {
|
|
3596
|
+
let info = item.participants.find((resInfo) => resInfo?.id === call?.participantId);
|
|
3597
|
+
// return info?.id
|
|
3598
|
+
if (info) {
|
|
3599
|
+
parentCall.push(info.id);
|
|
3600
|
+
}
|
|
3601
|
+
});
|
|
3596
3602
|
});
|
|
3597
|
-
}
|
|
3603
|
+
}
|
|
3598
3604
|
if (parentCall?.length > 0) {
|
|
3599
3605
|
this.notificationCallList = this.notificationCallList.filter((item) => !parentCall.includes(item?.participantId));
|
|
3600
3606
|
this.incomingCallsList = [...this.incomingCallsList, ...this.notificationCallList];
|
|
@@ -4014,7 +4020,9 @@ class DialboxComponent {
|
|
|
4014
4020
|
incomingCall.participants[0]['sourceName'] = callerInfo.sourceName;
|
|
4015
4021
|
incomingCall.participants[0]['subject'] = callerInfo.subject;
|
|
4016
4022
|
}
|
|
4023
|
+
incomingCall['endTime'] = (Date.now() + 45 * 1000);
|
|
4017
4024
|
this.notificationCallList.push(incomingCall);
|
|
4025
|
+
this.notificationCallList.filter((res) => res.endTime >= Date.now());
|
|
4018
4026
|
this.incomingCallsList = [...this.incomingCallsList, ...this.notificationCallList];
|
|
4019
4027
|
this.cdk.detectChanges();
|
|
4020
4028
|
if (this.incomingCallnotification.data.data?.participantId) {
|