@vgroup/dialbox 0.0.88 → 0.0.90
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.
|
@@ -2396,6 +2396,7 @@ class DialboxComponent {
|
|
|
2396
2396
|
this.callData.img = contact.img;
|
|
2397
2397
|
this.callData.from = contact.from;
|
|
2398
2398
|
this.sanitizedNum = contact.number;
|
|
2399
|
+
console.log('274', contact);
|
|
2399
2400
|
this.getUserInformation(contact);
|
|
2400
2401
|
// this.incomingCallsList.push(contact)
|
|
2401
2402
|
this.initiateCall();
|
|
@@ -2405,6 +2406,7 @@ class DialboxComponent {
|
|
|
2405
2406
|
setTimeout(() => {
|
|
2406
2407
|
this.isDialpadHidden = false;
|
|
2407
2408
|
}, 1000);
|
|
2409
|
+
console.log('282', contact);
|
|
2408
2410
|
this.getUserInformation(contact);
|
|
2409
2411
|
// this.incomingCallsList.push(contact)
|
|
2410
2412
|
this.dialedNumber = contact.number;
|
|
@@ -2446,12 +2448,14 @@ class DialboxComponent {
|
|
|
2446
2448
|
if (incomingCallData) {
|
|
2447
2449
|
if (this.isCallInProgress) {
|
|
2448
2450
|
this.newIncomingCalls.push(incomingCallData);
|
|
2451
|
+
console.log('325', incomingCallData);
|
|
2449
2452
|
this.getUserInformation(incomingCallData);
|
|
2450
2453
|
}
|
|
2451
2454
|
else {
|
|
2452
2455
|
this.isCallInProgress = true;
|
|
2453
2456
|
this.isDialpadHidden = false;
|
|
2454
2457
|
this.callData.phone = incomingCallData.parameters['From'];
|
|
2458
|
+
console.log('332', incomingCallData);
|
|
2455
2459
|
this.getUserInformation(incomingCallData);
|
|
2456
2460
|
this.callData.name = incomingCallData.customParameters.get('name');
|
|
2457
2461
|
this.callData.img = incomingCallData.customParameters.get('image') || 'assets/images/user.jpg';
|
|
@@ -2481,9 +2485,13 @@ class DialboxComponent {
|
|
|
2481
2485
|
getUserInformation(incomingCallData) {
|
|
2482
2486
|
// console.log('getUserInformation', incomingCallData);
|
|
2483
2487
|
let data = this.fromEntries(Array.from(incomingCallData.customParameters.entries()));
|
|
2488
|
+
console.log('366---', data);
|
|
2484
2489
|
this.extensionService.getUserInformation(data['twilioAuthId']).subscribe(response => {
|
|
2485
2490
|
incomingCallData['userInfo'] = response;
|
|
2486
|
-
this.incomingCallsList.
|
|
2491
|
+
const alreadyExists = this.incomingCallsList.some((call) => { var _a, _b; return ((_a = call.parameters) === null || _a === void 0 ? void 0 : _a.CallSid) === ((_b = incomingCallData.parameters) === null || _b === void 0 ? void 0 : _b.CallSid); });
|
|
2492
|
+
if (!alreadyExists) {
|
|
2493
|
+
this.incomingCallsList.push(incomingCallData);
|
|
2494
|
+
}
|
|
2487
2495
|
}, error => {
|
|
2488
2496
|
console.error('Error starting recording', error);
|
|
2489
2497
|
});
|
|
@@ -2510,12 +2518,14 @@ class DialboxComponent {
|
|
|
2510
2518
|
// this.isDialpadHidden = false; // Show dialpad on incoming call
|
|
2511
2519
|
if (this.isCallInProgress) {
|
|
2512
2520
|
this.newIncomingCalls.push(this.incomingCallData);
|
|
2521
|
+
console.log('404', this.incomingCallData);
|
|
2513
2522
|
this.getUserInformation(this.incomingCallData);
|
|
2514
2523
|
}
|
|
2515
2524
|
else {
|
|
2516
2525
|
this.isCallInProgress = true;
|
|
2517
2526
|
this.isDialpadHidden = false;
|
|
2518
2527
|
this.callData.phone = this.incomingCallData.parameters['From'];
|
|
2528
|
+
console.log('411', this.incomingCallData);
|
|
2519
2529
|
this.getUserInformation(this.incomingCallData);
|
|
2520
2530
|
this.callData.name = this.incomingCallData.customParameters.get('name');
|
|
2521
2531
|
this.callData.img = this.incomingCallData.customParameters.get('image') || 'assets/images/user.jpg';
|