@vgroup/dialbox 0.6.3-0.18 → 0.6.3-0.19
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 +37 -21
- package/fesm2015/vgroup-dialbox.mjs +57 -31
- package/fesm2015/vgroup-dialbox.mjs.map +1 -1
- package/fesm2020/vgroup-dialbox.mjs +36 -20
- package/fesm2020/vgroup-dialbox.mjs.map +1 -1
- package/lib/components/call-progress/call-progress.component.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1769,6 +1769,7 @@ class CallProgressComponent {
|
|
|
1769
1769
|
this.isIncomingCallBtnDisable = false;
|
|
1770
1770
|
this.isNewAddedCall = false;
|
|
1771
1771
|
this.deviceNumberList = [];
|
|
1772
|
+
this.ourNumberInfo = {};
|
|
1772
1773
|
this.micOn = false;
|
|
1773
1774
|
this.isMinimised = false;
|
|
1774
1775
|
this.showDisconnectModal = false;
|
|
@@ -1839,9 +1840,9 @@ class CallProgressComponent {
|
|
|
1839
1840
|
}
|
|
1840
1841
|
this.newIncomingCallsList.forEach((callInfo, i) => {
|
|
1841
1842
|
this.conferenceId = i == 0 ? this.newIncomingCallsList[i].conferenceId : this.conferenceId;
|
|
1842
|
-
|
|
1843
|
-
console.log(
|
|
1844
|
-
if (
|
|
1843
|
+
this.ourNumberInfo = this.newIncomingCallsList[i].participants.find((resData) => ((this.deviceNumberList.includes(resData?.from) && resData?.to == 'c2c_softphone_client') || (this.deviceNumberList.includes(resData?.to) && resData?.direction == 'incoming-call')) && !resData?.isLeft);
|
|
1844
|
+
console.log(this.ourNumberInfo, 'ourNumber');
|
|
1845
|
+
if (this.ourNumberInfo?.id) {
|
|
1845
1846
|
this.newIncomingCallsList[i].participants.forEach(async (res) => {
|
|
1846
1847
|
if (res?.to == 'c2c_softphone_client') {
|
|
1847
1848
|
this.hostnumber = res;
|
|
@@ -2679,23 +2680,24 @@ class CallProgressComponent {
|
|
|
2679
2680
|
deviceId: this.deviceId,
|
|
2680
2681
|
conferenceId: data?.conferenceId || 'no'
|
|
2681
2682
|
};
|
|
2682
|
-
|
|
2683
|
-
|
|
2684
|
-
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2683
|
+
this.extensionService.setIncomingCallStatus(payload).subscribe(async (res) => {
|
|
2684
|
+
if (res.status == 200) {
|
|
2685
|
+
this.call = await this.twilioService.connect({ conferenceId: res.conferenceId, conferenceName: res.conferenceName });
|
|
2686
|
+
this.incomeingCallSocketService.isCurrentIncomingCallList.push(data?.id);
|
|
2687
|
+
console.log(this.call, 'callConnect');
|
|
2688
|
+
data.isAcceptCall = true;
|
|
2689
|
+
this.isIncomingCallBtnDisable = false;
|
|
2690
|
+
this.incomeingCallSocketService.pause();
|
|
2691
|
+
}
|
|
2692
|
+
else {
|
|
2693
|
+
let index = this.currentCallList.findIndex((res) => res.participantId == data.participantId);
|
|
2694
|
+
this.currentCallList.splice(index, 1);
|
|
2695
|
+
swal("Error", res?.message.join("<br/>"), "error");
|
|
2696
|
+
this.incomeingCallSocketService.pause();
|
|
2697
|
+
this.isIncomingCallBtnDisable = false;
|
|
2698
|
+
this.endCallEvent.emit(data);
|
|
2699
|
+
}
|
|
2700
|
+
});
|
|
2699
2701
|
}
|
|
2700
2702
|
async callContact(contact, isUnsavedNumber) {
|
|
2701
2703
|
console.log('Adding participant:', contact);
|
|
@@ -2891,6 +2893,15 @@ class CallProgressComponent {
|
|
|
2891
2893
|
// participentList.push(resData?.participantId)
|
|
2892
2894
|
// }
|
|
2893
2895
|
// })
|
|
2896
|
+
let selfInfo = this.allParticipentList.find((resData) => (this.deviceNumberList.includes(resData?.from) && resData?.to == 'c2c_softphone_client') || (this.deviceNumberList.includes(resData?.to)));
|
|
2897
|
+
console.log(selfInfo, 'selfInfo');
|
|
2898
|
+
await this.onholdOrUnholdParticipant({
|
|
2899
|
+
participantId: [selfInfo?.participantId],
|
|
2900
|
+
conferenceId: this.currentCall?.conferenceId,
|
|
2901
|
+
hold: true,
|
|
2902
|
+
mute: this.currentCall?.mute || false,
|
|
2903
|
+
conference: this.currentCall?.isConference || false
|
|
2904
|
+
});
|
|
2894
2905
|
if (participentList?.length) {
|
|
2895
2906
|
// await this.onholdOrUnholdParticipant({
|
|
2896
2907
|
// participantId: participentList,
|
|
@@ -2899,6 +2910,11 @@ class CallProgressComponent {
|
|
|
2899
2910
|
// mute: this.currentCall?.mute || false,
|
|
2900
2911
|
// conference: this.currentCall?.isConference || false
|
|
2901
2912
|
// });
|
|
2913
|
+
this.newIncomingCallsList.forEach((resData) => {
|
|
2914
|
+
if (resData?.participantId) {
|
|
2915
|
+
participentList.push(resData?.participantId);
|
|
2916
|
+
}
|
|
2917
|
+
});
|
|
2902
2918
|
if (this.currentCall?.isConference) {
|
|
2903
2919
|
this.isConferenceCallHold = true;
|
|
2904
2920
|
}
|