@vgroup/dialbox 0.5.46 → 0.5.47
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.
|
@@ -3751,6 +3751,7 @@ class DialboxComponent {
|
|
|
3751
3751
|
this.cdk.detectChanges();
|
|
3752
3752
|
}
|
|
3753
3753
|
console.log('test', this.incomingCallsList);
|
|
3754
|
+
this.incomeingCallSocketService.pause();
|
|
3754
3755
|
this.isIncomingCallnotification = false;
|
|
3755
3756
|
if (!((_e = this.incomingCallsList) === null || _e === void 0 ? void 0 : _e.length)) {
|
|
3756
3757
|
this.isCallInProgress = false;
|
|
@@ -3922,41 +3923,42 @@ class DialboxComponent {
|
|
|
3922
3923
|
}
|
|
3923
3924
|
incomingCallNotification(callerInfo) {
|
|
3924
3925
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
3925
|
-
|
|
3926
|
-
|
|
3927
|
-
|
|
3928
|
-
|
|
3929
|
-
|
|
3930
|
-
|
|
3931
|
-
|
|
3932
|
-
|
|
3933
|
-
|
|
3934
|
-
|
|
3935
|
-
|
|
3936
|
-
|
|
3937
|
-
|
|
3938
|
-
|
|
3939
|
-
|
|
3940
|
-
|
|
3941
|
-
|
|
3942
|
-
|
|
3943
|
-
|
|
3944
|
-
|
|
3945
|
-
|
|
3946
|
-
|
|
3947
|
-
|
|
3948
|
-
|
|
3949
|
-
|
|
3950
|
-
|
|
3951
|
-
|
|
3952
|
-
|
|
3953
|
-
|
|
3954
|
-
this.cdk.detectChanges();
|
|
3955
|
-
if ((_l = this.incomingCallnotification.data.data) === null || _l === void 0 ? void 0 : _l.participantId) {
|
|
3956
|
-
this.isCallInProgress = true;
|
|
3926
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
3927
|
+
let incomingCall = {
|
|
3928
|
+
conferenceId: 'no',
|
|
3929
|
+
isActive: true,
|
|
3930
|
+
isIncomingCall: true,
|
|
3931
|
+
participantId: (_a = this.incomingCallnotification.data.data) === null || _a === void 0 ? void 0 : _a.participantId,
|
|
3932
|
+
participants: [
|
|
3933
|
+
{ direction: "incoming-call", img: ((_b = this.incomingCallnotification.data.data) === null || _b === void 0 ? void 0 : _b.fromImage) || ((_c = this.incomingCallnotification.data.data) === null || _c === void 0 ? void 0 : _c.image) || 'assets/images/user.jpg', isIncomingCall: true, isHold: false, isConference: false, isAcceptCall: false, dial: true, phone: (_d = this.incomingCallnotification.data.data) === null || _d === void 0 ? void 0 : _d.fromNumber, to: (_e = this.incomingCallnotification.data.data) === null || _e === void 0 ? void 0 : _e.toNumber,
|
|
3934
|
+
from: (_f = this.incomingCallnotification.data.data) === null || _f === void 0 ? void 0 : _f.fromNumber, fromName: (_g = this.incomingCallnotification.data.data) === null || _g === void 0 ? void 0 : _g.fromName, participantId: (_h = this.incomingCallnotification.data.data) === null || _h === void 0 ? void 0 : _h.participantId, name: (_j = this.incomingCallnotification.data.data) === null || _j === void 0 ? void 0 : _j.fromName, time: '', id: (_k = this.incomingCallnotification.data.data) === null || _k === void 0 ? void 0 : _k.participantId }
|
|
3935
|
+
],
|
|
3936
|
+
};
|
|
3937
|
+
this.notificationCallList = yield this.notificationCallList.filter((res) => (res === null || res === void 0 ? void 0 : res.endTime) > (new Date().getTime()));
|
|
3938
|
+
if (callerInfo) {
|
|
3939
|
+
incomingCall.participants[0]['email'] = callerInfo.email;
|
|
3940
|
+
incomingCall.participants[0]['name'] = callerInfo.name;
|
|
3941
|
+
incomingCall.participants[0]['image'] = callerInfo.image;
|
|
3942
|
+
incomingCall.participants[0]['extension'] = callerInfo.extension;
|
|
3943
|
+
incomingCall.participants[0]['userInfoId'] = callerInfo.id;
|
|
3944
|
+
incomingCall.participants[0]['message'] = callerInfo.message;
|
|
3945
|
+
incomingCall.participants[0]['note'] = callerInfo.note;
|
|
3946
|
+
incomingCall.participants[0]['number'] = callerInfo.number;
|
|
3947
|
+
incomingCall.participants[0]['pointName'] = callerInfo.pointName;
|
|
3948
|
+
incomingCall.participants[0]['softphoneTwilioAuthId'] = callerInfo.softphoneTwilioAuthId;
|
|
3949
|
+
incomingCall.participants[0]['sourceName'] = callerInfo.sourceName;
|
|
3950
|
+
incomingCall.participants[0]['subject'] = callerInfo.subject;
|
|
3951
|
+
}
|
|
3952
|
+
incomingCall['endTime'] = (new Date().getTime() + 45 * 1000);
|
|
3953
|
+
this.notificationCallList.push(incomingCall);
|
|
3954
|
+
this.incomingCallsList = [...this.incomingCallsList, ...this.notificationCallList];
|
|
3957
3955
|
this.cdk.detectChanges();
|
|
3958
|
-
this.
|
|
3959
|
-
|
|
3956
|
+
if ((_l = this.incomingCallnotification.data.data) === null || _l === void 0 ? void 0 : _l.participantId) {
|
|
3957
|
+
this.isCallInProgress = true;
|
|
3958
|
+
this.cdk.detectChanges();
|
|
3959
|
+
this.isDialpadHidden = false;
|
|
3960
|
+
}
|
|
3961
|
+
});
|
|
3960
3962
|
}
|
|
3961
3963
|
addNumber(num) {
|
|
3962
3964
|
if (num == '#' || num == '*' || num == '+' || Number.isInteger(num)) {
|